['merchant', 'order_arr', 'number'], ]; } /** * @notes 获取采购订单列表 * @return array * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException * @author likeadmin * @date 2024/04/27 11:26 */ public function lists(): array { return Opurchaseclass::where($this->searchWhere) ->field(['id', 'merchant', 'order_arr', 'cart_id', 'number', 'total', 'deduction_price', 'actual', 'money', 'paid']) ->limit($this->limitOffset, $this->limitLength) ->order(['id' => 'desc']) ->select() ->toArray(); } /** * @notes 获取采购订单数量 * @return int * @author likeadmin * @date 2024/04/27 11:26 */ public function count(): int { return Opurchaseclass::where($this->searchWhere)->count(); } }