feat: 核心业务实体扩充(混产模板/产品BOM/试制记录)、WMS 库存检验增强与前端通用能力
- MES 新增实体:混产模板、产品BOM、产品工艺物料、试制记录(schema + ent 生成码 + logic/handler/前端页) - WMS 实体增强:检验记录、库存、半成品重构;新增序列号库存与短缺代报 - AGV 与产能:AGV 手动点位与链路、物料守卫、短缺预测、原因字典 - 前端通用能力:新增下一步引导组件 NextStepBar,统一帮助文档/布局/请求拦截与操作列 - 工位终端:界面与各 handler 调整(api/store/绑定/PLC/拧紧/上报等) - 配置与文档:更新 mes-api.yaml、WMS README 及案例/产线API/问题记录/项目说明/流程说明
This commit is contained in:
@@ -53,6 +53,12 @@ const (
|
||||
FieldInspectionNo = "inspection_no"
|
||||
// FieldReportNo holds the string denoting the report_no field in the database.
|
||||
FieldReportNo = "report_no"
|
||||
// FieldInspectionConclusion holds the string denoting the inspection_conclusion field in the database.
|
||||
FieldInspectionConclusion = "inspection_conclusion"
|
||||
// FieldDisposalStatus holds the string denoting the disposal_status field in the database.
|
||||
FieldDisposalStatus = "disposal_status"
|
||||
// FieldParentRecordID holds the string denoting the parent_record_id field in the database.
|
||||
FieldParentRecordID = "parent_record_id"
|
||||
// FieldDisposalType holds the string denoting the disposal_type field in the database.
|
||||
FieldDisposalType = "disposal_type"
|
||||
// FieldDisposalRemark holds the string denoting the disposal_remark field in the database.
|
||||
@@ -93,6 +99,9 @@ var Columns = []string{
|
||||
FieldInspector,
|
||||
FieldInspectionNo,
|
||||
FieldReportNo,
|
||||
FieldInspectionConclusion,
|
||||
FieldDisposalStatus,
|
||||
FieldParentRecordID,
|
||||
FieldDisposalType,
|
||||
FieldDisposalRemark,
|
||||
FieldReturnTrackingNo,
|
||||
@@ -126,6 +135,12 @@ var (
|
||||
DefaultBatchTotal int
|
||||
// DefaultRejectQty holds the default value on creation for the "reject_qty" field.
|
||||
DefaultRejectQty int
|
||||
// DefaultInspectionConclusion holds the default value on creation for the "inspection_conclusion" field.
|
||||
DefaultInspectionConclusion string
|
||||
// DefaultDisposalStatus holds the default value on creation for the "disposal_status" field.
|
||||
DefaultDisposalStatus string
|
||||
// DefaultParentRecordID holds the default value on creation for the "parent_record_id" field.
|
||||
DefaultParentRecordID int64
|
||||
// DefaultDisposalType holds the default value on creation for the "disposal_type" field.
|
||||
DefaultDisposalType string
|
||||
// DefaultCreatedAt holds the default value on creation for the "created_at" field.
|
||||
@@ -247,6 +262,21 @@ func ByReportNo(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldReportNo, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByInspectionConclusion orders the results by the inspection_conclusion field.
|
||||
func ByInspectionConclusion(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldInspectionConclusion, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByDisposalStatus orders the results by the disposal_status field.
|
||||
func ByDisposalStatus(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldDisposalStatus, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByParentRecordID orders the results by the parent_record_id field.
|
||||
func ByParentRecordID(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldParentRecordID, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByDisposalType orders the results by the disposal_type field.
|
||||
func ByDisposalType(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldDisposalType, opts...).ToFunc()
|
||||
|
||||
@@ -158,6 +158,21 @@ func ReportNo(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldReportNo, v))
|
||||
}
|
||||
|
||||
// InspectionConclusion applies equality check predicate on the "inspection_conclusion" field. It's identical to InspectionConclusionEQ.
|
||||
func InspectionConclusion(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// DisposalStatus applies equality check predicate on the "disposal_status" field. It's identical to DisposalStatusEQ.
|
||||
func DisposalStatus(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// ParentRecordID applies equality check predicate on the "parent_record_id" field. It's identical to ParentRecordIDEQ.
|
||||
func ParentRecordID(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// DisposalType applies equality check predicate on the "disposal_type" field. It's identical to DisposalTypeEQ.
|
||||
func DisposalType(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldDisposalType, v))
|
||||
@@ -1538,6 +1553,176 @@ func ReportNoContainsFold(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldContainsFold(FieldReportNo, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionEQ applies the EQ predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionEQ(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionNEQ applies the NEQ predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionNEQ(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldNEQ(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionIn applies the In predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionIn(vs ...string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldIn(FieldInspectionConclusion, vs...))
|
||||
}
|
||||
|
||||
// InspectionConclusionNotIn applies the NotIn predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionNotIn(vs ...string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldNotIn(FieldInspectionConclusion, vs...))
|
||||
}
|
||||
|
||||
// InspectionConclusionGT applies the GT predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionGT(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldGT(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionGTE applies the GTE predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionGTE(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldGTE(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionLT applies the LT predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionLT(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldLT(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionLTE applies the LTE predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionLTE(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldLTE(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionContains applies the Contains predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionContains(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldContains(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionHasPrefix applies the HasPrefix predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionHasPrefix(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldHasPrefix(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionHasSuffix applies the HasSuffix predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionHasSuffix(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldHasSuffix(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionEqualFold applies the EqualFold predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionEqualFold(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEqualFold(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// InspectionConclusionContainsFold applies the ContainsFold predicate on the "inspection_conclusion" field.
|
||||
func InspectionConclusionContainsFold(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldContainsFold(FieldInspectionConclusion, v))
|
||||
}
|
||||
|
||||
// DisposalStatusEQ applies the EQ predicate on the "disposal_status" field.
|
||||
func DisposalStatusEQ(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusNEQ applies the NEQ predicate on the "disposal_status" field.
|
||||
func DisposalStatusNEQ(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldNEQ(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusIn applies the In predicate on the "disposal_status" field.
|
||||
func DisposalStatusIn(vs ...string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldIn(FieldDisposalStatus, vs...))
|
||||
}
|
||||
|
||||
// DisposalStatusNotIn applies the NotIn predicate on the "disposal_status" field.
|
||||
func DisposalStatusNotIn(vs ...string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldNotIn(FieldDisposalStatus, vs...))
|
||||
}
|
||||
|
||||
// DisposalStatusGT applies the GT predicate on the "disposal_status" field.
|
||||
func DisposalStatusGT(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldGT(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusGTE applies the GTE predicate on the "disposal_status" field.
|
||||
func DisposalStatusGTE(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldGTE(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusLT applies the LT predicate on the "disposal_status" field.
|
||||
func DisposalStatusLT(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldLT(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusLTE applies the LTE predicate on the "disposal_status" field.
|
||||
func DisposalStatusLTE(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldLTE(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusContains applies the Contains predicate on the "disposal_status" field.
|
||||
func DisposalStatusContains(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldContains(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusHasPrefix applies the HasPrefix predicate on the "disposal_status" field.
|
||||
func DisposalStatusHasPrefix(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldHasPrefix(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusHasSuffix applies the HasSuffix predicate on the "disposal_status" field.
|
||||
func DisposalStatusHasSuffix(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldHasSuffix(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusEqualFold applies the EqualFold predicate on the "disposal_status" field.
|
||||
func DisposalStatusEqualFold(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEqualFold(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// DisposalStatusContainsFold applies the ContainsFold predicate on the "disposal_status" field.
|
||||
func DisposalStatusContainsFold(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldContainsFold(FieldDisposalStatus, v))
|
||||
}
|
||||
|
||||
// ParentRecordIDEQ applies the EQ predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDEQ(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// ParentRecordIDNEQ applies the NEQ predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDNEQ(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldNEQ(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// ParentRecordIDIn applies the In predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDIn(vs ...int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldIn(FieldParentRecordID, vs...))
|
||||
}
|
||||
|
||||
// ParentRecordIDNotIn applies the NotIn predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDNotIn(vs ...int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldNotIn(FieldParentRecordID, vs...))
|
||||
}
|
||||
|
||||
// ParentRecordIDGT applies the GT predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDGT(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldGT(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// ParentRecordIDGTE applies the GTE predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDGTE(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldGTE(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// ParentRecordIDLT applies the LT predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDLT(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldLT(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// ParentRecordIDLTE applies the LTE predicate on the "parent_record_id" field.
|
||||
func ParentRecordIDLTE(v int64) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldLTE(FieldParentRecordID, v))
|
||||
}
|
||||
|
||||
// DisposalTypeEQ applies the EQ predicate on the "disposal_type" field.
|
||||
func DisposalTypeEQ(v string) predicate.InspectionRecord {
|
||||
return predicate.InspectionRecord(sql.FieldEQ(FieldDisposalType, v))
|
||||
|
||||
Reference in New Issue
Block a user