1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- <?php
- namespace catchAdmin\sms\model;
- use catchAdmin\system\model\SysDictData;
- use catcher\base\CatchModel as Model;
- class SmsSendLog extends Model
- {
- // 表名
- public $name = 'sms_send_log';
- // 数据库字段映射
- public $field = array(
- 'id',
- // 接收人
- 'recipient',
- // 内容
- 'content',
- // 结果
- 'sent_result',
- // 创建人ID
- 'creator_id',
- // 创建时间
- 'created_at',
- // 更新时间
- 'updated_at',
- // 软删除
- 'deleted_at',
- );
- public function getList()
- {
- $res=$this->catchSearch()
- ->order($this->aliasField('id'), 'desc')
- ->paginate();
- return $res;
- }
- public function searchTypeAttr($query, $value, $data)
- {
- return $query->where('type', $value);
- }
-
- }
|