Skip to content

Commit

Permalink
BP-3663-Buckaroo Payment Fee Prices does not make a difference (Tax s…
Browse files Browse the repository at this point in the history
…ettings)
  • Loading branch information
SandervdHulst committed Oct 3, 2024
1 parent 3d997f1 commit 2f617cc
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
9 changes: 8 additions & 1 deletion Model/Total/Quote/BuckarooFee.php
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,15 @@ public function getBaseFee(
$total = $address->getBaseSubtotalTotalInclTax();
break;
}
$percentageFee = ($percentage / 100) * $total;

$basePaymentFee = ($percentage / 100) * $total;
if($inclTax){
if($percent > 0){
return $percentageFee / (1 + ($percent / 100));
}
} else{
return $percentageFee;
}

return $basePaymentFee;
}
Expand Down
9 changes: 8 additions & 1 deletion Model/Total/Quote/BuckarooFeeHyva.php
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,15 @@ public function getBaseFee(
$total = $address->getBaseSubtotalTotalInclTax();
break;
}
$percentageFee = ($percentage / 100) * $total;

$basePaymentFee = ($percentage / 100) * $total;
if($inclTax){
if($percent > 0){
return $percentageFee / (1 + ($percent / 100));
}
} else{
return $percentageFee;
}

return $basePaymentFee;
}
Expand Down

0 comments on commit 2f617cc

Please sign in to comment.