This commit is contained in:
苏尹岚
2020-12-22 17:58:58 +08:00
parent e73225be50
commit 09494dc4e5
3 changed files with 31 additions and 6 deletions

View File

@@ -3588,7 +3588,7 @@ func CreateStoreAudit(ctx *jxcontext.Context, storeAudit *model.StoreAudit) (err
return fmt.Errorf("门店地址必填!")
}
if storeAudit.Lng == 0 || storeAudit.Lat == 0 {
lng, lat, _ := api.AutonaviAPI.GetCoordinateFromAddressByPage(storeAudit.Address)
lng, lat, _ := api.AutonaviAPI.GetCoordinateFromAddress(storeAudit.Address, "")
if lng != 0 && lat != 0 {
storeAudit.Lng = jxutils.StandardCoordinate2Int(lng)
storeAudit.Lat = jxutils.StandardCoordinate2Int(lat)