diff --git a/app/api/logic/LocalStoreLogic.php b/app/api/logic/LocalStoreLogic.php index 6e472b81..740c8b15 100644 --- a/app/api/logic/LocalStoreLogic.php +++ b/app/api/logic/LocalStoreLogic.php @@ -43,10 +43,10 @@ class LocalStoreLogic extends Logic $sql = "SELECT * FROM ls_local_store where lstore_id = 22 and is_delete = 0 and store_state = 1 and shopLogo is not null $s ORDER BY lstore_id asc limit " . $page . "," . $size; // var_dump($sql); $lists = Db::query($sql); -// foreach ($lists as $key => $value) { -// $lists[$key]['distance'] = round($this->distance($data['latitude'], $data['longitude'], $value['latitude'], $value['longitude']) / 1000, 2) . "公里"; -// $lists[$key]['store_nickname'] = $value["shopName"]; -// } + foreach ($lists as $key => $value) { + $lists[$key]['distance'] = round($this->distance($data['latitude'], $data['longitude'], $value['latitude'], $value['longitude']) / 1000, 2) . "公里"; + $lists[$key]['store_nickname'] = $value["shopName"]; + } $data = [ 'list' => $lists, 'page' => $data['page_no'],