Add price rounding for specific price reductions in Product class

This commit is contained in:
2025-04-13 23:31:05 +02:00
parent 075fe64cc8
commit a6a57d6c53
2 changed files with 9 additions and 4 deletions

View File

@@ -3954,6 +3954,11 @@ class ProductCore extends ObjectModel
$price -= $specific_price_reduction;
}
// Zaokrąglanie w górę tylko gdy mamy redukcję
if ($specific_price && $specific_price['reduction'] > 0) {
$price = Tools::ceilf($price);
}
// Group reduction
if ($use_group_reduction) {
$reduction_from_category = GroupReduction::getValueForProduct($id_product, $id_group);