['contract_name', 'contract_type', 'contract_code'], ]; } /** * @notes 获取项目合同列表 * @return array * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException * @author likeadmin * @date 2023/12/02 17:19 */ public function lists(): array { return Contract::where($this->searchWhere) ->field(['*']) ->limit($this->limitOffset, $this->limitLength) ->order(['approve_id' => 'desc']) ->select() ->toArray(); } /** * @notes 获取项目合同数量 * @return int * @author likeadmin * @date 2023/12/02 17:19 */ public function count(): int { return Contract::where($this->searchWhere)->count(); } }