添加淘鲜达

This commit is contained in:
邹宗楠
2023-06-28 10:04:08 +08:00
parent 64e4339aeb
commit c0a97b4fad
51 changed files with 2109 additions and 2007 deletions

View File

@@ -119,6 +119,7 @@ func (p *PurchaseHandler) getOrder(vendorOrgCode, vendorOrderID, vendorStoreID s
if result.UserIdInfo != nil {
order.VendorUserID = result.UserIdInfo.IdCardNo
}
originalLng := utils.MustInterface2Float64(result.UserCoordinate.UserCoordinateLongitude)
originalLat := utils.MustInterface2Float64(result.UserCoordinate.UserCoordinateLatitude)
order.ConsigneeLng = jxutils.StandardCoordinate2Int(originalLng)
@@ -545,24 +546,6 @@ func (c *PurchaseHandler) postFakeMsg(vendorOrderID, cmd, VendorStatus, appOrgCo
// AcceptOrRefuseOrder 接单或者拒单(isAcceptIt:接单/拒单) 抖店暂无拒单
func (c *PurchaseHandler) AcceptOrRefuseOrder(order *model.GoodsOrder, isAcceptIt bool, userName string) (err error) {
//if isAcceptIt {
// if globals.EnableMtwmStoreWrite {
// err = getAPI(order.VendorOrgCode, jxutils.GetSaleStoreIDFromOrder(order), "").OrderConfirm(utils.Str2Int64(order.VendorOrderID))
// if err != nil {
// if utils.IsErrMatch(err, utils.Int2Str(mtwmapi.ErrCodeOpFailed), []string{
// "订单已经确认过了",
// }) {
// err = nil
// } else {
// globals.SugarLogger.Warnf("mtwm AcceptOrRefuseOrder orderID:%s failed with err:%v", order.VendorOrderID, err)
// }
// }
// }
//} else {
// if globals.EnableMtwmStoreWrite {
// err = c.CancelOrder(jxcontext.AdminCtx, order, "bu")
// }
//}
return err
}

View File

@@ -90,11 +90,11 @@ func (c *PurchaseHandler) onAfsOrderMsg(msgId string, msg interface{}) (retVal *
VendorOrgCode: utils.Int2Str(vendorOrgCode),
}
afsOrder.FreightUserMoney = tiktokAfsOrderDetail.Data.ProcessInfo.AfterSaleInfo.RefundPostAmount
afsOrder.AfsFreightMoney = 0 // 暂时未发现退货取件费用
afsOrder.BoxMoney = 0 // 餐盒费
afsOrder.TongchengFreightMoney = 0 // 同城配送费
afsOrder.SkuBoxMoney = 0 // 商品包装费
afsOrder.VendorStatus = orderStatus.VendorStatus // 退货状态
afsOrder.AfsFreightMoney = tiktokAfsOrderDetail.Data.ProcessInfo.AfterSaleInfo.RefundPostAmount // 暂时未发现退货取件费用
afsOrder.BoxMoney = 0 // 餐盒费
afsOrder.TongchengFreightMoney = 0 // 同城配送费
afsOrder.SkuBoxMoney = 0 // 商品包装费
afsOrder.VendorStatus = orderStatus.VendorStatus // 退货状态
for _, sku := range tiktokAfsOrderDetail.Data.OrderInfo.SkuOrderInfos {
orderSku := &model.OrderSkuFinancial{
Count: int(sku.AfterSaleItemCount),

View File

@@ -296,6 +296,7 @@ func (p *PurchaseHandler) CancelActs(ctx *jxcontext.Context, vendorOrgCode strin
// return cancelOneShopAct(putils.GetFixDirectDownAct(vendorOrgCode, storeID, 0), vendorStoreID, putils.StoreSku2ActStoreSku(model.SyncFlagDeletedMask, vendorStoreID, storeSkuList))
}
// UpdateStoreSkusSpecTag 更新限购
func (p *PurchaseHandler) UpdateStoreSkusSpecTag(ctx *jxcontext.Context, vendorOrgCode string, storeID int, vendorStoreID string, storeSkuList []*partner.StoreSkuInfo) (err error) {
//var foodDataList []map[string]interface{}
//for _, v := range storeSkuList {