This commit is contained in:
苏尹岚
2021-01-12 10:55:25 +08:00
parent 41acd31fec
commit 03a32aa3d6

View File

@@ -153,7 +153,7 @@ func PublishJob(ctx *jxcontext.Context, jobExt *model.JobExt) (errCode string, e
}
}
if job.Address != "" && (job.Lng == 0 || job.Lat == 0) {
lng, lat, _ := api.AutonaviAPI.GetCoordinateFromAddress(job.Address, "")
lng, lat, _ := api.AutonaviAPI.GetCoordinateFromAddressByPage(job.Address, job.JobCityCode)
if lng == 0 || lat == 0 {
return errCode, fmt.Errorf("请填写完整且正确的门店地址!")
}