1
This commit is contained in:
@@ -227,8 +227,14 @@ class PostService
|
|||||||
content,
|
content,
|
||||||
latitude,
|
latitude,
|
||||||
longitude,
|
longitude,
|
||||||
|
`like`,
|
||||||
|
shop_name,
|
||||||
|
favorite,
|
||||||
|
comment,
|
||||||
created_at,
|
created_at,
|
||||||
updated_at,
|
updated_at,
|
||||||
|
price,
|
||||||
|
age,
|
||||||
(6371000 * ACOS(
|
(6371000 * ACOS(
|
||||||
COS(RADIANS(?)) * COS(RADIANS(latitude)) *
|
COS(RADIANS(?)) * COS(RADIANS(latitude)) *
|
||||||
COS(RADIANS(longitude) - RADIANS(?)) +
|
COS(RADIANS(longitude) - RADIANS(?)) +
|
||||||
@@ -240,7 +246,7 @@ class PostService
|
|||||||
LIMIT 50";
|
LIMIT 50";
|
||||||
|
|
||||||
// 根据场景设置半径
|
// 根据场景设置半径
|
||||||
$radius = $scene === 'nearby' ? 20000 : 200000;
|
$radius = $scene === 'nearby' ? 2000000000 : 200000;
|
||||||
|
|
||||||
// $query = Db::select($sql, [
|
// $query = Db::select($sql, [
|
||||||
// 'lat' => $lat,
|
// 'lat' => $lat,
|
||||||
|
|||||||
Reference in New Issue
Block a user