DShopRostering.Class.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <?php
  2. /**
  3. * 打卡时间模板
  4. * Created by PhpStorm.
  5. * User: wxj
  6. * Date: 2019/10/31
  7. * Time: 15:02
  8. */
  9. namespace JinDouYun\Dao\Shop;
  10. use JinDouYun\Dao\BaseDao;
  11. class DShopRostering extends BaseDao
  12. {
  13. public function __construct($serviceDB = 'default')
  14. {
  15. $this->_table = 'shop_rostering';
  16. $this->_primary = 'id';
  17. $this->_fields = [
  18. "id", // int unsigned NOT NULL AUTO_INCREMENT,
  19. "name", // varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '名称',
  20. "template_id", // char(50) COLLATE utf8mb4_general_ci NOT NULL COMMENT '绑定模板',
  21. "shop_id", // int NOT NULL,
  22. "uid", // int NOT NULL COMMENT '员工id',
  23. "time", // int NOT NULL COMMENT '排班日期',
  24. "time_slot",//text COLLATE utf8mb4_general_ci NOT NULL COMMENT '时间段',
  25. "clock", //text COLLATE utf8mb4_general_ci COMMENT '打卡时间段',
  26. "createTime", // int DEFAULT NULL COMMENT '创建时间',
  27. ];
  28. $this->_readonly = ['id'];
  29. $this->_create_autofill = [
  30. 'createTime' => time()
  31. ];
  32. parent::__construct($serviceDB);
  33. }
  34. }