['create_user_id', 'template_id', 'company_id', 'type', 'status'], ]; } /** * @notes 获取任务公司排期列表 * @return array * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException * @author likeadmin * @date 2023/08/08 10:08 */ public function lists(): array { return TaskScheduling::where($this->searchWhere) ->with(['admin','data_type','template','company']) ->field(['id', 'create_user_id', 'template_id', 'company_id', 'type', 'status']) ->limit($this->limitOffset, $this->limitLength) ->order(['id' => 'desc']) ->select() ->toArray(); } /** * @notes 获取任务公司排期数量 * @return int * @author likeadmin * @date 2023/08/08 10:08 */ public function count(): int { return TaskScheduling::where($this->searchWhere)->count(); } }