feat: 两库对等物料管理及产品工号贯通全流程
- 新增 MES 本地物料表及双向同步接口,WMS 物料变更自动同步 - 全流程新增产品工号字段,贯通入库/库存/出库/检验环节 - 工单管理支持多工单混产,移除单工单互斥限制 - 新增批次号/SN 字段支持质量检验联动 WMS 库存处置 - 修复权限规则,仅内置管理员账号不允许修改删除 - 工位终端新增 SN 扫码自动切换所属工单功能
This commit is contained in:
@@ -319,6 +319,26 @@ func (_u *InboundOrderUpdate) ClearOwnershipNo() *InboundOrderUpdate {
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetProductWorkNo sets the "product_work_no" field.
|
||||
func (_u *InboundOrderUpdate) SetProductWorkNo(v string) *InboundOrderUpdate {
|
||||
_u.mutation.SetProductWorkNo(v)
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetNillableProductWorkNo sets the "product_work_no" field if the given value is not nil.
|
||||
func (_u *InboundOrderUpdate) SetNillableProductWorkNo(v *string) *InboundOrderUpdate {
|
||||
if v != nil {
|
||||
_u.SetProductWorkNo(*v)
|
||||
}
|
||||
return _u
|
||||
}
|
||||
|
||||
// ClearProductWorkNo clears the value of the "product_work_no" field.
|
||||
func (_u *InboundOrderUpdate) ClearProductWorkNo() *InboundOrderUpdate {
|
||||
_u.mutation.ClearProductWorkNo()
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetQualityStatus sets the "quality_status" field.
|
||||
func (_u *InboundOrderUpdate) SetQualityStatus(v string) *InboundOrderUpdate {
|
||||
_u.mutation.SetQualityStatus(v)
|
||||
@@ -563,6 +583,12 @@ func (_u *InboundOrderUpdate) sqlSave(ctx context.Context) (_node int, err error
|
||||
if _u.mutation.OwnershipNoCleared() {
|
||||
_spec.ClearField(inboundorder.FieldOwnershipNo, field.TypeString)
|
||||
}
|
||||
if value, ok := _u.mutation.ProductWorkNo(); ok {
|
||||
_spec.SetField(inboundorder.FieldProductWorkNo, field.TypeString, value)
|
||||
}
|
||||
if _u.mutation.ProductWorkNoCleared() {
|
||||
_spec.ClearField(inboundorder.FieldProductWorkNo, field.TypeString)
|
||||
}
|
||||
if value, ok := _u.mutation.QualityStatus(); ok {
|
||||
_spec.SetField(inboundorder.FieldQualityStatus, field.TypeString, value)
|
||||
}
|
||||
@@ -911,6 +937,26 @@ func (_u *InboundOrderUpdateOne) ClearOwnershipNo() *InboundOrderUpdateOne {
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetProductWorkNo sets the "product_work_no" field.
|
||||
func (_u *InboundOrderUpdateOne) SetProductWorkNo(v string) *InboundOrderUpdateOne {
|
||||
_u.mutation.SetProductWorkNo(v)
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetNillableProductWorkNo sets the "product_work_no" field if the given value is not nil.
|
||||
func (_u *InboundOrderUpdateOne) SetNillableProductWorkNo(v *string) *InboundOrderUpdateOne {
|
||||
if v != nil {
|
||||
_u.SetProductWorkNo(*v)
|
||||
}
|
||||
return _u
|
||||
}
|
||||
|
||||
// ClearProductWorkNo clears the value of the "product_work_no" field.
|
||||
func (_u *InboundOrderUpdateOne) ClearProductWorkNo() *InboundOrderUpdateOne {
|
||||
_u.mutation.ClearProductWorkNo()
|
||||
return _u
|
||||
}
|
||||
|
||||
// SetQualityStatus sets the "quality_status" field.
|
||||
func (_u *InboundOrderUpdateOne) SetQualityStatus(v string) *InboundOrderUpdateOne {
|
||||
_u.mutation.SetQualityStatus(v)
|
||||
@@ -1185,6 +1231,12 @@ func (_u *InboundOrderUpdateOne) sqlSave(ctx context.Context) (_node *InboundOrd
|
||||
if _u.mutation.OwnershipNoCleared() {
|
||||
_spec.ClearField(inboundorder.FieldOwnershipNo, field.TypeString)
|
||||
}
|
||||
if value, ok := _u.mutation.ProductWorkNo(); ok {
|
||||
_spec.SetField(inboundorder.FieldProductWorkNo, field.TypeString, value)
|
||||
}
|
||||
if _u.mutation.ProductWorkNoCleared() {
|
||||
_spec.ClearField(inboundorder.FieldProductWorkNo, field.TypeString)
|
||||
}
|
||||
if value, ok := _u.mutation.QualityStatus(); ok {
|
||||
_spec.SetField(inboundorder.FieldQualityStatus, field.TypeString, value)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user