update
This commit is contained in:
parent
65ec2c5dde
commit
e2fb325452
|
|
@ -307,11 +307,13 @@ func GetOrderDetail(orderId string) OrderDetail {
|
||||||
Discount: float64(orderSub.Discount),
|
Discount: float64(orderSub.Discount),
|
||||||
Goods: goods,
|
Goods: goods,
|
||||||
}
|
}
|
||||||
|
if orderSub.OrderStatus == 1 {
|
||||||
|
x := float64(orderSub.PayAmount) / 10
|
||||||
|
orderSubR1.PayAmount = strconv.FormatFloat(x, 'f', 1, 64)
|
||||||
|
}
|
||||||
if orderSubR1.Discount < 100 {
|
if orderSubR1.Discount < 100 {
|
||||||
//orderSubR1.PayAmount = int32(math.Round(float64(orderSubR1.TotalAmount) * (orderSubR1.Discount / 100.0)))
|
//orderSubR1.PayAmount = int32(math.Round(float64(orderSubR1.TotalAmount) * (orderSubR1.Discount / 100.0)))
|
||||||
//x := float64(orderSubR1.TotalAmount) * (orderSubR1.Discount / 100.0) / 10
|
//x := float64(orderSubR1.TotalAmount) * (orderSubR1.Discount / 100.0) / 10
|
||||||
x := float64(orderSub.PayAmount) / 10
|
|
||||||
orderSubR1.PayAmount = strconv.FormatFloat(x, 'f', 1, 64)
|
|
||||||
orderSubR1.DiscountAmount = orderSubR1.PayAmount
|
orderSubR1.DiscountAmount = orderSubR1.PayAmount
|
||||||
} else {
|
} else {
|
||||||
orderSubR1.DiscountAmount = strconv.Itoa(orderSubR1.TotalAmount)
|
orderSubR1.DiscountAmount = strconv.Itoa(orderSubR1.TotalAmount)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue