28 lines
827 B
Go
28 lines
827 B
Go
|
|
package model
|
||
|
|
|
||
|
|
import "time"
|
||
|
|
|
||
|
|
type ProcessStep struct {
|
||
|
|
ID string `json:"id" db:"id"`
|
||
|
|
PlanID string `json:"plan_id" db:"plan_id"`
|
||
|
|
StepType string `json:"step_type" db:"step_type"`
|
||
|
|
Status string `json:"status" db:"status"`
|
||
|
|
Notes *string `json:"notes,omitempty" db:"notes"`
|
||
|
|
OperatorID *string `json:"operator_id,omitempty" db:"operator_id"`
|
||
|
|
CompanyID *string `json:"company_id,omitempty" db:"company_id"`
|
||
|
|
Timestamp *time.Time `json:"timestamp,omitempty" db:"timestamp"`
|
||
|
|
CreatedAt time.Time `json:"created_at" db:"created_at"`
|
||
|
|
|
||
|
|
// Aggregated
|
||
|
|
OperatorName string `json:"operator_name,omitempty"`
|
||
|
|
}
|
||
|
|
|
||
|
|
// StepOrder defines the 5-step production process sequence.
|
||
|
|
var StepOrder = []string{
|
||
|
|
"confirm",
|
||
|
|
"yarn_purchase",
|
||
|
|
"dyeing",
|
||
|
|
"machine_start",
|
||
|
|
"fabric_warehouse",
|
||
|
|
}
|