DTemplateModule.Class.php 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?php
  2. /**
  3. * 系统模版模块
  4. * Created by PhpStorm.
  5. * User: XiaoMing
  6. * Date: 2019/11/29
  7. * Time: 15:11
  8. */
  9. namespace JinDouYun\Dao\System;
  10. use JinDouYun\Dao\BaseDao;
  11. class DTemplateModule extends BaseDao
  12. {
  13. public function __construct($serviceDB = 'default')
  14. {
  15. $this->_table = 'template_module';
  16. $this->_primary = 'id';
  17. $this->_fields = [
  18. "id", //int(11) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  19. "templateId", //int(10) NOT NULL COMMENT '模版Id',
  20. "title", //varchar(50) NOT NULL COMMENT '模块名称',
  21. "alias", //varchar(50) NOT NULL COMMENT '模块别名',
  22. "local", //varchar(50) NOT NULL COMMENT '模块位置',
  23. "enableStatus", //tinyint(3) NOT NULL DEFAULT '5' COMMENT '模块是否展示 默认5 显示 4影藏',
  24. "extends", //json DEFAULT NULL COMMENT '拓展字段',
  25. "createTime", //int(10) NOT NULL DEFAULT '0' COMMENT '创建时间',
  26. "updateTime", //int(10) NOT NULL DEFAULT '0' COMMENT '更新时间',
  27. ];
  28. $this->_readonly = ['id'];
  29. $this->_create_autofill = [
  30. 'createTime' => time()
  31. ];
  32. $this->_update_autofill = [
  33. 'updateTime' => time()
  34. ];
  35. parent::__construct($serviceDB);
  36. }
  37. }