- handle ConsigneeName maybe missing
This commit is contained in:
@@ -96,12 +96,12 @@ func (c *PurchaseHandler) Map2Order(orderData map[string]interface{}) (order *mo
|
|||||||
order = &model.GoodsOrder{
|
order = &model.GoodsOrder{
|
||||||
VendorOrderID: orderID,
|
VendorOrderID: orderID,
|
||||||
VendorID: model.VendorIDJD,
|
VendorID: model.VendorIDJD,
|
||||||
VendorStoreID: result["produceStationNo"].(string),
|
VendorStoreID: utils.Interface2String(result["produceStationNo"]),
|
||||||
StoreID: int(utils.Str2Int64WithDefault(utils.Interface2String(result["produceStationNoIsv"]), 0)),
|
StoreID: int(utils.Str2Int64WithDefault(utils.Interface2String(result["produceStationNoIsv"]), 0)),
|
||||||
StoreName: utils.Interface2String(result["produceStationName"]),
|
StoreName: utils.Interface2String(result["produceStationName"]),
|
||||||
ConsigneeName: result["buyerFullName"].(string),
|
ConsigneeName: utils.Interface2String(result["buyerFullName"]),
|
||||||
ConsigneeMobile: result["buyerMobile"].(string),
|
ConsigneeMobile: utils.Interface2String(result["buyerMobile"]),
|
||||||
ConsigneeAddress: result["buyerFullAddress"].(string),
|
ConsigneeAddress: utils.Interface2String(result["buyerFullAddress"]),
|
||||||
CoordinateType: model.CoordinateTypeMars,
|
CoordinateType: model.CoordinateTypeMars,
|
||||||
BuyerComment: utils.TrimBlankChar(utils.Interface2String(result["orderBuyerRemark"])),
|
BuyerComment: utils.TrimBlankChar(utils.Interface2String(result["orderBuyerRemark"])),
|
||||||
ExpectedDeliveredTime: utils.Str2TimeWithDefault(utils.Interface2String(result["orderPreEndDeliveryTime"]), utils.DefaultTimeValue),
|
ExpectedDeliveredTime: utils.Str2TimeWithDefault(utils.Interface2String(result["orderPreEndDeliveryTime"]), utils.DefaultTimeValue),
|
||||||
|
|||||||
Reference in New Issue
Block a user