Merge remote-tracking branch 'origin/mark' into su

This commit is contained in:
苏尹岚
2020-02-21 14:05:06 +08:00
10 changed files with 31 additions and 21 deletions

View File

@@ -466,6 +466,12 @@ func generateOrder(ctx *jxcontext.Context, jxOrder *JxOrderInfo, addressID int64
} else {
outJxOrder.FreightPrice = 0
}
if outJxOrder.OrderPrice >= int64(storeDetail.DeliveryFeeDeductionSill) {
outJxOrder.FreightPrice -= int64(storeDetail.DeliveryFeeDeductionFee)
if outJxOrder.FreightPrice < 0 {
outJxOrder.FreightPrice = 0
}
}
if err == nil {
outJxOrder.TotalPrice = outJxOrder.OrderPrice + outJxOrder.FreightPrice
outJxOrder.ActualPayPrice = outJxOrder.TotalPrice