From d12e4edd0880656bab43d802155b5bb3faa37b8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8B=8F=E5=B0=B9=E5=B2=9A?= <770236076@qq.com> Date: Thu, 3 Dec 2020 11:33:52 +0800 Subject: [PATCH] aa --- business/model/dao/dao_job.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/business/model/dao/dao_job.go b/business/model/dao/dao_job.go index 4320954c6..1d6e5a3dc 100644 --- a/business/model/dao/dao_job.go +++ b/business/model/dao/dao_job.go @@ -436,7 +436,7 @@ func GetStationInfoList(db *DaoDB, stationName string, cityCode int, lat, lng fl SELECT SQL_CALC_FOUND_ROWS * ` if distanceFlag { - sql += `, ROUND(POWER((POWER(longitude-?,2))+(POWER(latitude-?,2)),1/2)) distance` + sql += `, ROUND(POWER((POWER(longitude-?,2))+(POWER(latitude-?,2)),1/2)) distance2` sqlParams = append(sqlParams, lng, lat) } sql += ` @@ -457,9 +457,9 @@ func GetStationInfoList(db *DaoDB, stationName string, cityCode int, lat, lng fl } if sortType != 0 { if sortType == 1 { - sql += " ORDER BY distance" + sql += " ORDER BY distance2" } else if sortType == -1 { - sql += " ORDER BY distance DESC" + sql += " ORDER BY distance2 DESC" } else if sortType == 2 { sql += " ORDER BY star_num" } else if sortType == -2 {