DCustomerIntegralDesc.Class.php 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <?php
  2. namespace JinDouYun\Dao\Customer;
  3. use JinDouYun\Dao\BaseDao;
  4. class DCustomerIntegralDesc extends BaseDao
  5. {
  6. public function __construct($serviceDB = 'default')
  7. {
  8. $this->_table = 'customer_integral_desc';
  9. $this->_primary = 'id';
  10. $this->_fields = [
  11. "id", //int(10) NOT NULL AUTO_INCREMENT COMMENT '流水表',
  12. "userCenterId", //int(10) DEFAULT NULL COMMENT '用户id',
  13. "customerId", //int(10) DEFAULT NULL COMMENT '客户id',
  14. "shopId", //int(10) DEFAULT '0' COMMENT '商铺id',
  15. "ruleId", //int(10) DEFAULT NULL COMMENT '规则id',
  16. "originId", //int(10) DEFAULT '1' COMMENT '来源id',
  17. "originNo", //varchar(255) DEFAULT NULL COMMENT '来源单号',
  18. "title", //varchar(255) DEFAULT NULL COMMENT '说明',
  19. "amount", //decimal(8,2) DEFAULT NULL COMMENT '金额',
  20. "changeAmount", //decimal(8,2) DEFAULT NULL COMMENT '变动后金额',
  21. "type", //tinyint(1) DEFAULT NULL COMMENT '状态 4:减 5:加',
  22. "source", //tinyint(1) DEFAULT NULL COMMENT '来源 1:订单金额满足 2:购买指定商品 3:后台手动修改 4:积分兑换商品',
  23. "createTime", //int(10) DEFAULT NULL COMMENT '创建时间',
  24. "updateTime", //int(10) DEFAULT NULL COMMENT '修改时间',
  25. "extend", //json DEFAULT NULL COMMENT '扩展字段',
  26. ];
  27. $this->_readonly = ['id'];
  28. $this->_create_autofill = [
  29. 'createTime' => time()
  30. ];
  31. $this->_update_autofill = [
  32. 'updateTime' => time()
  33. ];
  34. parent::__construct($serviceDB);
  35. }
  36. }