feat: 两库对等物料管理及产品工号贯通全流程
- 新增 MES 本地物料表及双向同步接口,WMS 物料变更自动同步 - 全流程新增产品工号字段,贯通入库/库存/出库/检验环节 - 工单管理支持多工单混产,移除单工单互斥限制 - 新增批次号/SN 字段支持质量检验联动 WMS 库存处置 - 修复权限规则,仅内置管理员账号不允许修改删除 - 工位终端新增 SN 扫码自动切换所属工单功能
This commit is contained in:
@@ -369,6 +369,20 @@ func (_c *OutboundOrderCreate) SetNillableInspectionNo(v *string) *OutboundOrder
|
||||
return _c
|
||||
}
|
||||
|
||||
// SetProductWorkNo sets the "product_work_no" field.
|
||||
func (_c *OutboundOrderCreate) SetProductWorkNo(v string) *OutboundOrderCreate {
|
||||
_c.mutation.SetProductWorkNo(v)
|
||||
return _c
|
||||
}
|
||||
|
||||
// SetNillableProductWorkNo sets the "product_work_no" field if the given value is not nil.
|
||||
func (_c *OutboundOrderCreate) SetNillableProductWorkNo(v *string) *OutboundOrderCreate {
|
||||
if v != nil {
|
||||
_c.SetProductWorkNo(*v)
|
||||
}
|
||||
return _c
|
||||
}
|
||||
|
||||
// SetCreatedAt sets the "created_at" field.
|
||||
func (_c *OutboundOrderCreate) SetCreatedAt(v int64) *OutboundOrderCreate {
|
||||
_c.mutation.SetCreatedAt(v)
|
||||
@@ -601,6 +615,10 @@ func (_c *OutboundOrderCreate) createSpec() (*OutboundOrder, *sqlgraph.CreateSpe
|
||||
_spec.SetField(outboundorder.FieldInspectionNo, field.TypeString, value)
|
||||
_node.InspectionNo = value
|
||||
}
|
||||
if value, ok := _c.mutation.ProductWorkNo(); ok {
|
||||
_spec.SetField(outboundorder.FieldProductWorkNo, field.TypeString, value)
|
||||
_node.ProductWorkNo = value
|
||||
}
|
||||
if value, ok := _c.mutation.CreatedAt(); ok {
|
||||
_spec.SetField(outboundorder.FieldCreatedAt, field.TypeInt64, value)
|
||||
_node.CreatedAt = value
|
||||
@@ -1095,6 +1113,24 @@ func (u *OutboundOrderUpsert) ClearInspectionNo() *OutboundOrderUpsert {
|
||||
return u
|
||||
}
|
||||
|
||||
// SetProductWorkNo sets the "product_work_no" field.
|
||||
func (u *OutboundOrderUpsert) SetProductWorkNo(v string) *OutboundOrderUpsert {
|
||||
u.Set(outboundorder.FieldProductWorkNo, v)
|
||||
return u
|
||||
}
|
||||
|
||||
// UpdateProductWorkNo sets the "product_work_no" field to the value that was provided on create.
|
||||
func (u *OutboundOrderUpsert) UpdateProductWorkNo() *OutboundOrderUpsert {
|
||||
u.SetExcluded(outboundorder.FieldProductWorkNo)
|
||||
return u
|
||||
}
|
||||
|
||||
// ClearProductWorkNo clears the value of the "product_work_no" field.
|
||||
func (u *OutboundOrderUpsert) ClearProductWorkNo() *OutboundOrderUpsert {
|
||||
u.SetNull(outboundorder.FieldProductWorkNo)
|
||||
return u
|
||||
}
|
||||
|
||||
// SetCreatedAt sets the "created_at" field.
|
||||
func (u *OutboundOrderUpsert) SetCreatedAt(v int64) *OutboundOrderUpsert {
|
||||
u.Set(outboundorder.FieldCreatedAt, v)
|
||||
@@ -1664,6 +1700,27 @@ func (u *OutboundOrderUpsertOne) ClearInspectionNo() *OutboundOrderUpsertOne {
|
||||
})
|
||||
}
|
||||
|
||||
// SetProductWorkNo sets the "product_work_no" field.
|
||||
func (u *OutboundOrderUpsertOne) SetProductWorkNo(v string) *OutboundOrderUpsertOne {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
s.SetProductWorkNo(v)
|
||||
})
|
||||
}
|
||||
|
||||
// UpdateProductWorkNo sets the "product_work_no" field to the value that was provided on create.
|
||||
func (u *OutboundOrderUpsertOne) UpdateProductWorkNo() *OutboundOrderUpsertOne {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
s.UpdateProductWorkNo()
|
||||
})
|
||||
}
|
||||
|
||||
// ClearProductWorkNo clears the value of the "product_work_no" field.
|
||||
func (u *OutboundOrderUpsertOne) ClearProductWorkNo() *OutboundOrderUpsertOne {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
s.ClearProductWorkNo()
|
||||
})
|
||||
}
|
||||
|
||||
// SetCreatedAt sets the "created_at" field.
|
||||
func (u *OutboundOrderUpsertOne) SetCreatedAt(v int64) *OutboundOrderUpsertOne {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
@@ -2400,6 +2457,27 @@ func (u *OutboundOrderUpsertBulk) ClearInspectionNo() *OutboundOrderUpsertBulk {
|
||||
})
|
||||
}
|
||||
|
||||
// SetProductWorkNo sets the "product_work_no" field.
|
||||
func (u *OutboundOrderUpsertBulk) SetProductWorkNo(v string) *OutboundOrderUpsertBulk {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
s.SetProductWorkNo(v)
|
||||
})
|
||||
}
|
||||
|
||||
// UpdateProductWorkNo sets the "product_work_no" field to the value that was provided on create.
|
||||
func (u *OutboundOrderUpsertBulk) UpdateProductWorkNo() *OutboundOrderUpsertBulk {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
s.UpdateProductWorkNo()
|
||||
})
|
||||
}
|
||||
|
||||
// ClearProductWorkNo clears the value of the "product_work_no" field.
|
||||
func (u *OutboundOrderUpsertBulk) ClearProductWorkNo() *OutboundOrderUpsertBulk {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
s.ClearProductWorkNo()
|
||||
})
|
||||
}
|
||||
|
||||
// SetCreatedAt sets the "created_at" field.
|
||||
func (u *OutboundOrderUpsertBulk) SetCreatedAt(v int64) *OutboundOrderUpsertBulk {
|
||||
return u.Update(func(s *OutboundOrderUpsert) {
|
||||
|
||||
Reference in New Issue
Block a user