From 088fe2e7795ecbe0152534644a52208f70353a9e Mon Sep 17 00:00:00 2001 From: guojia <445241500@qq.com> Date: Mon, 6 May 2024 23:13:57 +0800 Subject: [PATCH] t --- app/api/controller/Merchant.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/api/controller/Merchant.php b/app/api/controller/Merchant.php index 77d40d46..e8405f89 100644 --- a/app/api/controller/Merchant.php +++ b/app/api/controller/Merchant.php @@ -130,9 +130,9 @@ class Merchant extends Controller public function list(): Json { $model = new MerchantModel; $pageSize = $this->request->param('pageSize'); - $pageSize = empty($pageSize) ?? 15; + $pageSize = empty($pageSize) ? 15 : $pageSize; $sort = $this->request->param('sort'); - $sort = empty($sort) ?? "merchant_id"; + $sort = empty($sort) ? "merchant_id" : $sort; $list = $model->getList($this->request->param(), intval($pageSize), $sort)->toArray(); foreach ($list['data'] as $kr => $r) {