catchAdmin/extend/catcher/base/CatchModel.php

31 lines
588 B
PHP
Raw Normal View History

2019-12-06 09:17:40 +08:00
<?php
namespace catcher\base;
use catcher\traits\db\BaseOptionsTrait;
use catcher\traits\db\TransTrait;
use think\model\concern\SoftDelete;
2019-12-12 09:14:08 +08:00
abstract class CatchModel extends \think\Model
2019-12-06 09:17:40 +08:00
{
use SoftDelete;
use TransTrait;
use BaseOptionsTrait;
2019-12-07 17:31:38 +08:00
protected $createTime = 'created_at';
2019-12-06 09:17:40 +08:00
2019-12-07 17:31:38 +08:00
protected $updateTime = 'updated_at';
2019-12-06 09:17:40 +08:00
2019-12-07 17:31:38 +08:00
protected $deleteTime = 'deleted_at';
2019-12-06 09:17:40 +08:00
2019-12-13 17:26:54 +08:00
protected $defaultSoftDelete = 0;
2019-12-07 17:31:38 +08:00
protected $autoWriteTimestamp = true;
2020-01-21 17:57:33 +08:00
public const LIMIT = 10;
2019-12-07 17:31:38 +08:00
// 开启
public const ENABLE = 1;
// 禁用
public const DISABLE = 2;
2019-12-06 09:17:40 +08:00
}