修改供应链订单金额的错误
This commit is contained in:
parent
477b252cf7
commit
6d96a446ca
@ -447,6 +447,7 @@ class StoreOrderCreateRepository extends StoreOrderRepository
|
||||
}
|
||||
|
||||
//计算单个商品实际支付金额
|
||||
$orderProcurePrice = 0;
|
||||
foreach ($merchantCart['list'] as $_k => &$cart) {
|
||||
$cartTotalPrice = bcmul($this->cartByPrice($cart), $cart['cart_num'], 2);
|
||||
$_cartTotalPrice = $cartTotalPrice;
|
||||
@ -454,9 +455,10 @@ class StoreOrderCreateRepository extends StoreOrderRepository
|
||||
//单个商品实际支付金额
|
||||
$cart['coupon_price'] = bcsub($_cartTotalPrice, $cartTotalPrice, 2);
|
||||
$cart['true_price'] = $cartTotalPrice;
|
||||
$procure = $this->cartByPrice($cart, 1);
|
||||
$procure_price = bcmul($cart['cart_num'], $procure, 2);
|
||||
$orderProcurePrice = bcadd($orderProcurePrice, $procure_price, 2);
|
||||
}
|
||||
$procure = $this->cartByPrice($cart, 1);
|
||||
$procure_price = bcmul($cart['cart_num'], $procure, 2);
|
||||
unset($cart, $_k);
|
||||
$total_true_price = bcadd($_pay_price, $total_true_price, 2);
|
||||
if (count($merchantCartList) > 1 || count($merchantCart['list']) > 1) {
|
||||
@ -482,7 +484,7 @@ class StoreOrderCreateRepository extends StoreOrderRepository
|
||||
'delivery_status' => $deliveryStatus,
|
||||
'svip_discount' => $total_svip_discount,
|
||||
'use_svip' => $use_svip,
|
||||
'procure_price' => $procure_price
|
||||
'procure_price' => $orderProcurePrice
|
||||
];
|
||||
$order_total_postage = bcadd($order_total_postage, $postage_price, 2);
|
||||
$order_svip_discount = bcadd($total_svip_discount, $order_svip_discount, 2);
|
||||
|
Loading…
x
Reference in New Issue
Block a user