In ps_orders table advance_paid_amount is wrong in every order advance payment for full cart is entered.

This commit is contained in:
Sumit Panwar
2021-12-23 18:27:32 +05:30
parent 4b300f637b
commit 2a34e41b67

View File

@@ -355,7 +355,7 @@ abstract class PaymentModuleCore extends Module
// advance payment information
$order->is_advance_payment = $this->context->cart->is_advance_payment;
$order->advance_paid_amount = $cart_total_paid;
$order->advance_paid_amount = (float)Tools::ps_round((float)$this->context->cart->getOrderTotal(true, Cart::ADVANCE_PAYMENT, $order->product_list, $id_carrier), _PS_PRICE_COMPUTE_PRECISION_);
// Creating order
$result = $order->add();