AdminLog.php
737 字节
<?php
namespace app\api\controller;
use app\admin\controller\Base;
use app\admin\model\AdminLog as AdminLogModel;
class AdminLog extends Base
{
/**
* @name:日志列表
* @return void
* @author :liyuhang
* @method :get
*/
public function lists(){
//搜索条件处理
if(isset($this->param['text']) && !empty($this->param['text'])){
$this->param['text'] = ['like','%'.$this->param['text'].'%'];
}
$adminLogModel = new AdminLogModel();
$lists = $adminLogModel->manager()->where($this->param)->page($this->p, $this->row)->order('id desc')->select()->toArray();
$this->allCount = $adminLogModel->allCount;
$this->result($lists);
}
}