美团readstore城市名
This commit is contained in:
@@ -68,12 +68,10 @@ func (p *PurchaseHandler) ReadStore(ctx *jxcontext.Context, vendorOrgCode, vendo
|
|||||||
lat := jxutils.IntCoordinate2Standard(retVal.Lat)
|
lat := jxutils.IntCoordinate2Standard(retVal.Lat)
|
||||||
db := dao.GetDB()
|
db := dao.GetDB()
|
||||||
retVal.DistrictCode = api.AutonaviAPI.GetCoordinateDistrictCode(lng, lat)
|
retVal.DistrictCode = api.AutonaviAPI.GetCoordinateDistrictCode(lng, lat)
|
||||||
if district, err := dao.GetPlaceByCode(db, retVal.DistrictCode); err == nil {
|
city, err := dao.GetPlaceByCode(db, result.CityID)
|
||||||
city, err2 := dao.GetPlaceByCode(db, result.CityID)
|
retVal.Name = city.Name
|
||||||
err = err2
|
retVal.CityCode = result.CityID
|
||||||
retVal.Name = city.Name
|
|
||||||
retVal.CityCode = district.ParentCode
|
|
||||||
}
|
|
||||||
poiCode := result.AppPoiCode
|
poiCode := result.AppPoiCode
|
||||||
retVal.ID = int(utils.Str2Int64WithDefault(poiCode, 0))
|
retVal.ID = int(utils.Str2Int64WithDefault(poiCode, 0))
|
||||||
retVal.DeliveryRangeType = model.DeliveryRangeTypePolygon
|
retVal.DeliveryRangeType = model.DeliveryRangeTypePolygon
|
||||||
|
|||||||
Reference in New Issue
Block a user