Kirin 4 년 전
부모
커밋
470c77929c
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      app/controller/api/store/merchant/Merchant.php

+ 2 - 2
app/controller/api/store/merchant/Merchant.php

@@ -43,8 +43,8 @@ class Merchant extends BaseController
     {
     {
         [$page, $limit] = $this->getPage();
         [$page, $limit] = $this->getPage();
         $where = $this->request->params(['keyword', 'order', 'is_best', 'location', 'category_id']);
         $where = $this->request->params(['keyword', 'order', 'is_best', 'location', 'category_id']);
-        if (!$where['location'] && $this->userInfo) {
-            $where['location'] = $this->userInfo['now_local'];
+        if (!$where['location']) {
+            $where['location'] = $this->repository->lonlat();
         }
         }
         return app('json')->success($this->repository->getList($where, $page, $limit, $this->userInfo));
         return app('json')->success($this->repository->getList($where, $page, $limit, $this->userInfo));
     }
     }