| | |
| | | BaseOperationTypeIncoming BaseOperationType = iota + 1 //收货 |
| | | BaseOperationTypeOutgoing //交货 |
| | | BaseOperationTypeInternal //内部调拨 |
| | | BaseOperationTypeDisuse //报废 |
| | | BaseOperationTypeAdjust //库存盘点 |
| | | ) |
| | | |
| | | func (slf BaseOperationType) IsValid() bool { |
| | |
| | | Consumables ProductType = iota + 1 // 消耗品 |
| | | Server // 服务 |
| | | StoredProduct // 可储存的产品 |
| | | ) |
| | | |
| | | type MaterialMode string |
| | | |
| | | const ( |
| | | MaterialModeRaw MaterialMode = "原材料" |
| | | MaterialModeSemi MaterialMode = "半成品" |
| | | MaterialModeFinished MaterialMode = "成品" |
| | | ) |
| | | |
| | | type MaterialStatus int |
| | | |
| | | const ( |
| | | MaterialStatusCreate MaterialStatus = iota // 新建 |
| | | MaterialStatusActive // 启用 |
| | | MaterialStatusInactive = -1 // 停用 |
| | | ) |
| | | |
| | | // InvoicingStrategy 开票策略 |
| | |
| | | LocationTypeInventoryLoss // 库存损失 |
| | | LocationTypeProduction // 生产 |
| | | LocationTypeTransit // 中转位置 |
| | | LocationTypeDisuse //报废位置 |
| | | LocationTypeAdjust //库存盘点 |
| | | ) |
| | | |
| | | func (t LocationType) Valid() bool { |
| | |
| | | const ( |
| | | CostingMethodStandardPrice CostingMethod = iota + 1 //标准价格 |
| | | CostingMethodFIFO //先进先出 |
| | | CostingMethodAverageCost // |
| | | CostingMethodAverageCost //平均成本 |
| | | ) |
| | | |
| | | func (t CostingMethod) Valid() bool { |
| | |
| | | func (t InventoryValuation) Valid() bool { |
| | | return t >= InventoryValuationManual && t <= InventoryValuationAuto |
| | | } |
| | | |
| | | type OperationStatus int |
| | | |
| | | const ( |
| | | OperationStatus_Draft OperationStatus = iota + 1 //草稿 |
| | | OperationStatus_Waiting //正在等待 |
| | | OperationStatus_Ready //就绪 |
| | | OperationStatus_Finish //完成 |
| | | ) |
| | | |
| | | type PostType int |
| | | |
| | | const ( |
| | | PostType_Soon PostType = iota + 1 //尽快 |
| | | PostType_AfterReady //当所有产品就绪时 |
| | | ) |