12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- <?php
- /**
- * 促销活动
- * Created by PhpStorm.
- * User: XiaoMing
- * Date: 2019/12/18
- * Time: 11:58
- */
- namespace JinDouYun\Dao\Market;
- use JinDouYun\Dao\BaseDao;
- class DActivity extends BaseDao
- {
- public function __construct($serviceDB = 'default')
- {
- $this->_table = 'activity';
- $this->_primary = 'id';
- $this->_fields = [
- "id",//int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键id',
- "activityType",//tinyint(3) unsigned NOT NULL DEFAULT '10' COMMENT '活动类型(10商品特价 20商品秒杀)',
- "title",//varchar(255) NOT NULL DEFAULT '' COMMENT '活动标题',
- "startTime",//int(11) unsigned NOT NULL DEFAULT '0' COMMENT '活动开始时间',
- "endTime",//int(11) unsigned NOT NULL DEFAULT '0' COMMENT '活动结束时间',
- "images",//json DEFAULT NULL COMMENT '促销活动图',
- "enableStatus",//tinyint(3) unsigned NOT NULL DEFAULT '5' COMMENT '活动上下架(5上架 4下架)',
- "useShop",//varchar(255) NOT NULL DEFAULT '' COMMENT '使用范围',
- "remark",// varchar(255) NOT NULL DEFAULT '' COMMENT '客户沟通',
- "customerRange",//tinyint(3) unsigned NOT NULL DEFAULT '5' COMMENT '客户范围(5全部 4部分)',
- "customerSourceId",//int(11) unsigned NOT NULL DEFAULT '0' COMMENT 'customerRange:4--客户id',
- "sort",//int(11) unsigned NOT NULL DEFAULT '0' COMMENT '排序方式(数字越大越靠前)',
- "describe",//text NOT NULL COMMENT '活动详情',
- "createTime",//int(11) unsigned NOT NULL DEFAULT '0' COMMENT '创建时间',
- "updateTime",//int(11) unsigned NOT NULL DEFAULT '0' COMMENT '更新时间',
- "isEnd",//tinyint(3) unsigned NOT NULL DEFAULT '5' COMMENT '是否结束(5未结束 4已结束)',
- "deleteStatus",//tinyint(3) unsigned NOT NULL DEFAULT '5' COMMENT '软删除(5未删除 4已删除)',
- "auditStatus",//tinyint(3) unsigned NOT NULL DEFAULT '1' COMMENT '审核状态(1待审 2审核通过 3未通过 4审核中)',
- "extends",//json DEFAULT NULL COMMENT '拓展字段',
- "isMutex",//tinyint(3) unsigned NOT NULL DEFAULT '5' COMMENT '是否互斥(5是 4否)',
- ];
- $this->_readonly = ['id'];
- $this->_create_autofill = [
- 'createTime' => time()
- ];
- $this->_update_autofill = [
- 'updateTime' => time()
- ];
- parent::__construct($serviceDB);
- }
- }
|