Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
vegimcarkaxhija committed Jun 20, 2024
1 parent e7f6661 commit 1a2945f
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions library/checkout/in3oldcheckout.php
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ public function getArticles()
'price' => round($item['price_wt'], 2),
];

$total += round($item['price_wt'], 2);
$total += round($item['price_wt'] * $item['quantity'], 2);
}

$wrapping = $this->cart->getOrderTotal(true, CartCore::ONLY_WRAPPING);
Expand Down Expand Up @@ -202,12 +202,13 @@ public function getArticles()
$total += round($shipping, 2);
}

if (abs($this->payment_request->amountDebit - $total) >= 0.01) {
$difference = round($this->payment_request->amountDebit - $total, 2);
if (abs($difference) >= 0.01) {
$products[] = [
'description' => 'Other fee/discount',
'identifier' => 'OFees',
'quantity' => 1,
'price' => round($this->payment_request->amountDebit - $total, 2),
'price' => $difference,
];
}

Expand Down

0 comments on commit 1a2945f

Please sign in to comment.