_table = 'integral_goods'; $this->_primary = 'id'; $this->_fields = [ "id", //int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id', "shopId", //int(10) DEFAULT '0' COMMENT '商铺id', "name", //varchar(255) DEFAULT NULL COMMENT '商品名称', "images", //json DEFAULT NULL COMMENT '商品图片', "integral", //decimal(10,2) DEFAULT NULL COMMENT '积分价格', "sort", //int(10) DEFAULT '0' COMMENT '排序 从大到小', "limit", //int(10) DEFAULT '0' COMMENT '每人限购', "num", //int(10) DEFAULT '0' COMMENT '剩余数量', "changeNum", //int(10) DEFAULT '0' COMMENT '兑换数量', "desc", //text COMMENT '详情', "enableStatus", //tinyint(1) DEFAULT '5' COMMENT '启用状态 4:禁用 5:启用', "deleteStatus", //tinyint(1) DEFAULT '5' COMMENT '删除状态 4:删除 5:正常', "createTime", //int(10) DEFAULT NULL COMMENT '创建时间', "updateTime", //int(10) DEFAULT NULL COMMENT '修改时间', "extend", //json DEFAULT NULL COMMENT '扩展字段', ]; $this->_readonly = ['id']; $this->_create_autofill = [ 'createTime' => time() ]; $this->_update_autofill = [ 'updateTime' => time() ]; parent::__construct($serviceDB); } }