This commit is contained in:
gazebo
2019-11-27 18:02:47 +08:00
parent d6205e955d
commit d836376ac3

View File

@@ -94,6 +94,9 @@ func (c *NetSpiderController) QueryPageStores() {
if len(shopList2) > 0 {
for _, v := range shopList2 {
v.Distance = int(jxutils.EarthDistance(v.Lng, v.Lat, lng, lat) * 1000)
if v.Distance < 0 {
v.Distance = 0
}
if v.Distance <= params.Radius {
shopList = append(shopList, v)
}