['contract_no', 'party_a', 'party_b', 'check_status'], ]; } /** * @notes 获取列表 * @return array * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException * @author likeadmin * @date 2023/09/13 17:01 */ public function lists(): array { return ShopContract::where($this->searchWhere) ->field(['id', 'contract_no', 'party_a', 'party_b', 'area_manager', 'type', 'evidence_url', 'check_status', 'status', 'notes']) ->limit($this->limitOffset, $this->limitLength) ->order(['id' => 'desc']) ->with(['partyA', 'partyB']) ->select() ->toArray(); } /** * @notes 获取数量 * @return int * @author likeadmin * @date 2023/09/13 17:01 */ public function count(): int { return ShopContract::where($this->searchWhere)->count(); } }