feat(mes): 添加定时同步可生产数量到WMS及BOM项相关标准字段
- 在main.go中添加定时任务每10分钟同步可生产数量到WMS系统 - 为BomItem实体添加relatedStandard字段及相关CRUD方法 - 为InspectionRecord实体添加reportNo、materialCode、materialName等字段 - 更新ent schema确保新字段的验证和默认值设置 - 添加必要的数据库迁移和字段映射逻辑
This commit is contained in:
@@ -79,12 +79,11 @@ func logoutHandler(ctx *svc.ServiceContext) http.HandlerFunc {
|
||||
}
|
||||
}
|
||||
|
||||
// configHandler GET /api/config 返回工位配置:// 固定工位号 stationNo(由 yaml 配置在启动时加载,终端不可修改)、本工位需拧紧的螺丝颗数。
|
||||
// configHandler GET /api/config 返回工位配置:固定工位号 stationNo(由 yaml 配置在启动时加载,终端不可修改)。
|
||||
func configHandler(ctx *svc.ServiceContext) http.HandlerFunc {
|
||||
return func(w http.ResponseWriter, r *http.Request) {
|
||||
ok(w, map[string]any{
|
||||
"stationNo": ctx.Config.Station.StationNo,
|
||||
"screwCount": ctx.Config.Station.ScrewCount,
|
||||
"stationNo": ctx.Config.Station.StationNo,
|
||||
})
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user