You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
483 B
21 lines
483 B
<?php
|
|
|
|
namespace app\api\controller;
|
|
|
|
use \app\admin\model\Task as TaskModel;
|
|
use think\response\Json;
|
|
|
|
class Task extends ApiController
|
|
{
|
|
|
|
public function getList(): Json
|
|
{
|
|
if (!$this->request->isPost()) {
|
|
return $this->renderError('不支持GET请求');
|
|
}
|
|
$param = $this->request->post();
|
|
$list = TaskModel::getPageList($param);
|
|
return $this->renderSuccess(['list' => $list['data'], 'count' => $list['count']]);
|
|
}
|
|
|
|
}
|
|
|