Skip to content
Code-Schnipsel Gruppen Projekte
Bestätigt Commit a40500b9 erstellt von Henning Leutz's avatar Henning Leutz :martial_arts_uniform:
Dateien durchsuchen

fix: nettoPrice was in the calc sometimes Price object

Übergeordneter 1fc88a41
Keine zugehörigen Branchen gefunden
Keine zugehörigen Tags gefunden
2 Merge Requests!97Next 2.x,!79Update 'next-3.x' with latest changes from 'main'
Pipeline-Nr. 12425 bestanden
......@@ -652,7 +652,11 @@ public function getProductPrice(
$priceFactors = $Product->getPriceFactors()->sort();
if ($Price) {
$nettoPrice = $Price->getValue();
if ($Price->getValue() instanceof QUI\ERP\Money\Price) {
$nettoPrice = $Price->getValue()->getPrice();
} else {
$nettoPrice = $Price->getValue();
}
}
if (empty($nettoPrice)) {
......
......@@ -167,6 +167,10 @@ public static function getPriceFieldForProduct(
}
}
if ($priceValue instanceof QUI\ERP\Money\Price) {
$priceValue = $priceValue->getValue();
}
return new QUI\ERP\Money\Price($priceValue, $Currency);
}
......
0% Lade oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren