feat: 完成多模块迭代更新
- 新增过程巡检按步骤上报、数量不符上报、工位退料功能 - 增加工单工程编号三级归属字段 - 新增物料安全库存与缺货预警 - 新增附件管理、退库单管理模块 - 优化生产看板展示逻辑与前端页面文案 - 清理冗余的工艺路线相关代码与备份文件
This commit is contained in:
@@ -17,8 +17,9 @@ import (
|
||||
// PermissionUpdate is the builder for updating Permission entities.
|
||||
type PermissionUpdate struct {
|
||||
config
|
||||
hooks []Hook
|
||||
mutation *PermissionMutation
|
||||
hooks []Hook
|
||||
mutation *PermissionMutation
|
||||
modifiers []func(*sql.UpdateBuilder)
|
||||
}
|
||||
|
||||
// Where appends a list predicates to the PermissionUpdate builder.
|
||||
@@ -224,6 +225,12 @@ func (_u *PermissionUpdate) check() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Modify adds a statement modifier for attaching custom logic to the UPDATE statement.
|
||||
func (_u *PermissionUpdate) Modify(modifiers ...func(u *sql.UpdateBuilder)) *PermissionUpdate {
|
||||
_u.modifiers = append(_u.modifiers, modifiers...)
|
||||
return _u
|
||||
}
|
||||
|
||||
func (_u *PermissionUpdate) sqlSave(ctx context.Context) (_node int, err error) {
|
||||
if err := _u.check(); err != nil {
|
||||
return _node, err
|
||||
@@ -266,6 +273,7 @@ func (_u *PermissionUpdate) sqlSave(ctx context.Context) (_node int, err error)
|
||||
if value, ok := _u.mutation.Remark(); ok {
|
||||
_spec.SetField(permission.FieldRemark, field.TypeString, value)
|
||||
}
|
||||
_spec.AddModifiers(_u.modifiers...)
|
||||
if _node, err = sqlgraph.UpdateNodes(ctx, _u.driver, _spec); err != nil {
|
||||
if _, ok := err.(*sqlgraph.NotFoundError); ok {
|
||||
err = &NotFoundError{permission.Label}
|
||||
@@ -281,9 +289,10 @@ func (_u *PermissionUpdate) sqlSave(ctx context.Context) (_node int, err error)
|
||||
// PermissionUpdateOne is the builder for updating a single Permission entity.
|
||||
type PermissionUpdateOne struct {
|
||||
config
|
||||
fields []string
|
||||
hooks []Hook
|
||||
mutation *PermissionMutation
|
||||
fields []string
|
||||
hooks []Hook
|
||||
mutation *PermissionMutation
|
||||
modifiers []func(*sql.UpdateBuilder)
|
||||
}
|
||||
|
||||
// SetCode sets the "code" field.
|
||||
@@ -496,6 +505,12 @@ func (_u *PermissionUpdateOne) check() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Modify adds a statement modifier for attaching custom logic to the UPDATE statement.
|
||||
func (_u *PermissionUpdateOne) Modify(modifiers ...func(u *sql.UpdateBuilder)) *PermissionUpdateOne {
|
||||
_u.modifiers = append(_u.modifiers, modifiers...)
|
||||
return _u
|
||||
}
|
||||
|
||||
func (_u *PermissionUpdateOne) sqlSave(ctx context.Context) (_node *Permission, err error) {
|
||||
if err := _u.check(); err != nil {
|
||||
return _node, err
|
||||
@@ -555,6 +570,7 @@ func (_u *PermissionUpdateOne) sqlSave(ctx context.Context) (_node *Permission,
|
||||
if value, ok := _u.mutation.Remark(); ok {
|
||||
_spec.SetField(permission.FieldRemark, field.TypeString, value)
|
||||
}
|
||||
_spec.AddModifiers(_u.modifiers...)
|
||||
_node = &Permission{config: _u.config}
|
||||
_spec.Assign = _node.assignValues
|
||||
_spec.ScanValues = _node.scanValues
|
||||
|
||||
Reference in New Issue
Block a user