aa
This commit is contained in:
@@ -2,11 +2,9 @@ package dao
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"git.rosy.net.cn/baseapi/utils"
|
||||
"git.rosy.net.cn/jx-callback/business/jxutils"
|
||||
"git.rosy.net.cn/jx-callback/business/model"
|
||||
"git.rosy.net.cn/jx-callback/globals/api"
|
||||
"strings"
|
||||
)
|
||||
|
||||
type PageShopWithPlaceName struct {
|
||||
@@ -212,9 +210,8 @@ func QueryPageStores2(db *DaoDB, pageSize, offset int, keyword string, vendorSto
|
||||
for _, v := range shopList {
|
||||
if v.Address != "" && v.CityName != "" {
|
||||
result, _ := api.AutonaviAPI.GetCoordinateFromAddressByPageAll(v.Address, v.CityCode)
|
||||
coords := strings.Split(result.Location, ",")
|
||||
lng, lat := utils.Str2Float64(coords[0]), utils.Str2Float64(coords[1])
|
||||
v.DistrictName = result.Adname
|
||||
lng, lat := result.Lng, result.Lat
|
||||
v.DistrictName = result.AdName
|
||||
v.Lng, v.Lat = lng, lat
|
||||
if lng1 > 0 {
|
||||
if !(lng >= lng1 && lat >= lat1 && lng <= lng2 && lat <= lat2) {
|
||||
|
||||
Reference in New Issue
Block a user