From 25f5e11caa2e31eae3e9ff31bfb2772c78d00a5a Mon Sep 17 00:00:00 2001 From: wangxinglong <2371974647@qq.com> Date: Wed, 6 Apr 2022 11:50:45 +0800 Subject: [PATCH] setter --- app/controller/api/Consumer.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controller/api/Consumer.php b/app/controller/api/Consumer.php index 6cc0508..dce95bf 100644 --- a/app/controller/api/Consumer.php +++ b/app/controller/api/Consumer.php @@ -221,13 +221,14 @@ class Consumer extends Base return $this->request->domain() . $value; }); }, $orders); - if(!empty($list["list"])){ + + if(!empty($list["list"]->toArray())){ return $this->json(1,"ok",$list["list"]); } } } } - + $whereMap = []; $whereMap[] = ['position', '=', Slide::advertisement]; $list = $repo->slideList($whereMap, ["id","title","src as image","url","url_type as type"], $page, $size, function ($q){