This commit is contained in:
邹宗楠
2022-10-27 14:13:26 +08:00
parent b07f9963cb
commit 82d3eb2289
16 changed files with 507 additions and 372 deletions

View File

@@ -90,7 +90,7 @@ func (p *PurchaseHandler) getOrder(vendorOrgCode, vendorOrderID, vendorStoreID s
StoreID: 0,
CoordinateType: model.CoordinateTypeMars,
BuyerComment: result.BuyerWords,
ExpectedDeliveredTime: getTimeFromTimestamp(utils.Interface2Int64WithDefault(result.TargetArrivalTime, 0)),
ExpectedDeliveredTime: getTimeFromTimestamp(utils.Interface2Int64WithDefault(result.LatestReceiptTime, 0)), // 预计最晚送达时间
PickDeadline: utils.DefaultTimeValue,
VendorStatus: utils.Int64ToStr(result.OrderStatus), //1待支付/103部分支付/105已支付/2备货中/101部分发货/3已发货/4取消/完成/21发货前退款完成/22发货后退款/39收货后退款
OrderSeq: 0,
@@ -186,10 +186,10 @@ func (p *PurchaseHandler) getOrder(vendorOrgCode, vendorOrderID, vendorStoreID s
closeTime = localStore.CloseTime2
}
h, m, _ := utils.Timestamp2Time(result.CreateTime).Clock()
if utils.Str2Int16(fmt.Sprintf("%d%d", h, m)) >= openTime && utils.Str2Int16(fmt.Sprintf("%d%d", h, m)) < closeTime {
order.BusinessType = model.BusinessTypeDingshida
} else {
if utils.Str2Int16(fmt.Sprintf("%d%d", h, m)) >= openTime && utils.Str2Int16(fmt.Sprintf("%d%d", h, m)) < closeTime && localStore.Status == model.StoreStatusOpened {
order.BusinessType = model.BusinessTypeImmediate
} else {
order.BusinessType = model.BusinessTypeDingshida
}
@@ -640,7 +640,7 @@ func (c *PurchaseHandler) AgreeOrRefuseCancel(ctx *jxcontext.Context, order *mod
return err
}
// CancelOrder 取消订单 (抖音商家无法发起退单操作)
// CancelOrder 取消订单 (抖音商家无法发起退单操作,商家联系不到客户取消订单/拒收/缺货)
func (c *PurchaseHandler) CancelOrder(ctx *jxcontext.Context, order *model.GoodsOrder, reason string) (err error) {
if globals.EnableDdStoreWrite {
return errors.New("抖音商家无法发起退单操作")