feat: 两库对等物料管理及产品工号贯通全流程

- 新增 MES 本地物料表及双向同步接口,WMS 物料变更自动同步
- 全流程新增产品工号字段,贯通入库/库存/出库/检验环节
- 工单管理支持多工单混产,移除单工单互斥限制
- 新增批次号/SN 字段支持质量检验联动 WMS 库存处置
- 修复权限规则,仅内置管理员账号不允许修改删除
- 工位终端新增 SN 扫码自动切换所属工单功能
This commit is contained in:
SunYF
2026-09-29 14:55:03 +08:00
parent a229b6727a
commit 76c9b6a7e2
103 changed files with 9412 additions and 1726 deletions
@@ -43,6 +43,8 @@ const (
FieldOwnershipType = "ownership_type"
// FieldOwnershipNo holds the string denoting the ownership_no field in the database.
FieldOwnershipNo = "ownership_no"
// FieldProductWorkNo holds the string denoting the product_work_no field in the database.
FieldProductWorkNo = "product_work_no"
// FieldQualityStatus holds the string denoting the quality_status field in the database.
FieldQualityStatus = "quality_status"
// FieldVoided holds the string denoting the voided field in the database.
@@ -78,6 +80,7 @@ var Columns = []string{
FieldInspectionNo,
FieldOwnershipType,
FieldOwnershipNo,
FieldProductWorkNo,
FieldQualityStatus,
FieldVoided,
FieldVoidReason,
@@ -199,6 +202,11 @@ func ByOwnershipNo(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldOwnershipNo, opts...).ToFunc()
}
// ByProductWorkNo orders the results by the product_work_no field.
func ByProductWorkNo(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldProductWorkNo, opts...).ToFunc()
}
// ByQualityStatus orders the results by the quality_status field.
func ByQualityStatus(opts ...sql.OrderTermOption) OrderOption {
return sql.OrderByField(FieldQualityStatus, opts...).ToFunc()