123456789101112131415161718192021222324252627282930313233343536373839 |
- <?php
- namespace App\Model;
- class PurchaseOrder extends UseScopeBaseModel
- {
- protected $table = "purchase_order"; //指定表
- const CREATED_AT = 'crt_time';
- const UPDATED_AT = 'upd_time';
- protected $dateFormat = 'U';
- const STATE_ZERO = 0;//未确认
- const STATE_ONE = 1;//待确认
- const STATE_TWO = 2;//未入库
- const STATE_Three = 3;//待入库
- const STATE_Four = 4;//已入库
- const prefix = 'CG';
- public static $name = [
- self::STATE_ZERO => '未确认',
- self::STATE_ONE => '待确认',
- self::STATE_TWO => '未入库',
- self::STATE_Three => '待入库',
- self::STATE_Four => '已入库',
- ];
- const Order_type_one = 1;//总社采购
- const Order_type_two = 2;//分社外采
- const Order_type_three = 3;//分社要货 不要合同
- const Order_type_four = 4;//分社订货 要合同
- const Order_type_five = 5;
- public static $order_type = [
- self::Order_type_one => '总社采购',
- self::Order_type_two => '分社外采',
- self::Order_type_three => '分社要货',
- self::Order_type_four => '分社订货',
- ];
- const range_function = 'purchaseRange';
- }
|