chore: 批量完成项目多模块迭代优化

1. 废弃半成品库存表并统一库存主表
2. 修复列表排序与搜索大小写不敏感问题
3. 新增用户最近登录时间、工单BOM名称字段
4. 完善角色管理、工位选择器功能
5. 增加拧紧数据补录、成品自动回流WMS能力
6. 统一导出时间范围校验规则
7. 丰富物料/备料单筛选条件
8. 调整菜单与权限命名适配产品型号业务
This commit is contained in:
SunYF
2026-09-08 11:44:04 +08:00
parent 06689970e2
commit e852c7cd37
96 changed files with 4528 additions and 542 deletions
+35 -11
View File
@@ -225,28 +225,44 @@ func init() {
inspectionrecord.DefaultUpdatedAt = inspectionrecordDescUpdatedAt.Default.(func() int64)
inventoryFields := schema.Inventory{}.Fields()
_ = inventoryFields
// inventoryDescCategory is the schema descriptor for category field.
inventoryDescCategory := inventoryFields[1].Descriptor()
// inventory.DefaultCategory holds the default value on creation for the category field.
inventory.DefaultCategory = inventoryDescCategory.Default.(int)
// inventoryDescQuantity is the schema descriptor for quantity field.
inventoryDescQuantity := inventoryFields[5].Descriptor()
inventoryDescQuantity := inventoryFields[6].Descriptor()
// inventory.DefaultQuantity holds the default value on creation for the quantity field.
inventory.DefaultQuantity = inventoryDescQuantity.Default.(int)
// inventoryDescLockedQty is the schema descriptor for locked_qty field.
inventoryDescLockedQty := inventoryFields[6].Descriptor()
inventoryDescLockedQty := inventoryFields[7].Descriptor()
// inventory.DefaultLockedQty holds the default value on creation for the locked_qty field.
inventory.DefaultLockedQty = inventoryDescLockedQty.Default.(int)
// inventoryDescQualityStatus is the schema descriptor for quality_status field.
inventoryDescQualityStatus := inventoryFields[7].Descriptor()
inventoryDescQualityStatus := inventoryFields[8].Descriptor()
// inventory.DefaultQualityStatus holds the default value on creation for the quality_status field.
inventory.DefaultQualityStatus = inventoryDescQualityStatus.Default.(string)
// inventoryDescStatus is the schema descriptor for status field.
inventoryDescStatus := inventoryFields[9].Descriptor()
inventoryDescStatus := inventoryFields[10].Descriptor()
// inventory.DefaultStatus holds the default value on creation for the status field.
inventory.DefaultStatus = inventoryDescStatus.Default.(string)
// inventoryDescOrderNo is the schema descriptor for order_no field.
inventoryDescOrderNo := inventoryFields[14].Descriptor()
// inventory.DefaultOrderNo holds the default value on creation for the order_no field.
inventory.DefaultOrderNo = inventoryDescOrderNo.Default.(string)
// inventory.OrderNoValidator is a validator for the "order_no" field. It is called by the builders before save.
inventory.OrderNoValidator = inventoryDescOrderNo.Validators[0].(func(string) error)
// inventoryDescCompletedProcess is the schema descriptor for completed_process field.
inventoryDescCompletedProcess := inventoryFields[15].Descriptor()
// inventory.DefaultCompletedProcess holds the default value on creation for the completed_process field.
inventory.DefaultCompletedProcess = inventoryDescCompletedProcess.Default.(string)
// inventory.CompletedProcessValidator is a validator for the "completed_process" field. It is called by the builders before save.
inventory.CompletedProcessValidator = inventoryDescCompletedProcess.Validators[0].(func(string) error)
// inventoryDescCreatedAt is the schema descriptor for created_at field.
inventoryDescCreatedAt := inventoryFields[14].Descriptor()
inventoryDescCreatedAt := inventoryFields[17].Descriptor()
// inventory.DefaultCreatedAt holds the default value on creation for the created_at field.
inventory.DefaultCreatedAt = inventoryDescCreatedAt.Default.(func() int64)
// inventoryDescUpdatedAt is the schema descriptor for updated_at field.
inventoryDescUpdatedAt := inventoryFields[15].Descriptor()
inventoryDescUpdatedAt := inventoryFields[18].Descriptor()
// inventory.DefaultUpdatedAt holds the default value on creation for the updated_at field.
inventory.DefaultUpdatedAt = inventoryDescUpdatedAt.Default.(func() int64)
inventorylockFields := schema.InventoryLock{}.Fields()
@@ -269,24 +285,32 @@ func init() {
inventorylock.DefaultUpdatedAt = inventorylockDescUpdatedAt.Default.(func() int64)
materialFields := schema.Material{}.Fields()
_ = materialFields
// materialDescItemType is the schema descriptor for item_type field.
materialDescItemType := materialFields[6].Descriptor()
// material.DefaultItemType holds the default value on creation for the item_type field.
material.DefaultItemType = materialDescItemType.Default.(int)
// materialDescManageMode is the schema descriptor for manage_mode field.
materialDescManageMode := materialFields[6].Descriptor()
materialDescManageMode := materialFields[7].Descriptor()
// material.DefaultManageMode holds the default value on creation for the manage_mode field.
material.DefaultManageMode = materialDescManageMode.Default.(int)
// materialDescIsBatchManaged is the schema descriptor for is_batch_managed field.
materialDescIsBatchManaged := materialFields[7].Descriptor()
materialDescIsBatchManaged := materialFields[8].Descriptor()
// material.DefaultIsBatchManaged holds the default value on creation for the is_batch_managed field.
material.DefaultIsBatchManaged = materialDescIsBatchManaged.Default.(bool)
// materialDescIsSerialManaged is the schema descriptor for is_serial_managed field.
materialDescIsSerialManaged := materialFields[8].Descriptor()
materialDescIsSerialManaged := materialFields[9].Descriptor()
// material.DefaultIsSerialManaged holds the default value on creation for the is_serial_managed field.
material.DefaultIsSerialManaged = materialDescIsSerialManaged.Default.(bool)
// materialDescIsActive is the schema descriptor for is_active field.
materialDescIsActive := materialFields[11].Descriptor()
// material.DefaultIsActive holds the default value on creation for the is_active field.
material.DefaultIsActive = materialDescIsActive.Default.(bool)
// materialDescCreatedAt is the schema descriptor for created_at field.
materialDescCreatedAt := materialFields[10].Descriptor()
materialDescCreatedAt := materialFields[12].Descriptor()
// material.DefaultCreatedAt holds the default value on creation for the created_at field.
material.DefaultCreatedAt = materialDescCreatedAt.Default.(func() int64)
// materialDescUpdatedAt is the schema descriptor for updated_at field.
materialDescUpdatedAt := materialFields[11].Descriptor()
materialDescUpdatedAt := materialFields[13].Descriptor()
// material.DefaultUpdatedAt holds the default value on creation for the updated_at field.
material.DefaultUpdatedAt = materialDescUpdatedAt.Default.(func() int64)
ordermaterialledgerFields := schema.OrderMaterialLedger{}.Fields()