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

Merge branch 'next' into 'master'

Next

See merge request !77
Übergeordnete 4e561ff3 3b6901d8
Keine zugehörigen Branchen gefunden
Keine zugehörigen Tags gefunden
2 Merge Requests!140Update 'next-4.x' with latest changes from 'main',!77Next
Pipeline-Nr. 8653 bestanden
...@@ -1096,11 +1096,21 @@ public static function calculateTotal(array $invoiceList, QUI\ERP\Currency\Curre ...@@ -1096,11 +1096,21 @@ public static function calculateTotal(array $invoiceList, QUI\ERP\Currency\Curre
$invNettoTotal = floatval($invoice['calculated_nettosum']); $invNettoTotal = floatval($invoice['calculated_nettosum']);
$invVatSumPC = QUI\Utils\Math::percent($invVatSum, $invBruttoSum); $invVatSumPC = QUI\Utils\Math::percent($invVatSum, $invBruttoSum);
$invBruttoSum = round($invBruttoSum, $Currency->getPrecision());
$invVatSum = round($invVatSum, $Currency->getPrecision());
$invPaid = round($invPaid, $Currency->getPrecision());
$invToPay = round($invToPay, $Currency->getPrecision());
$invNettoTotal = round($invNettoTotal, $Currency->getPrecision());
if ($invoice['paid_status'] === QUI\ERP\Constants::PAYMENT_STATUS_PAID) {
$invPaid = $invBruttoSum;
}
if ($invVatSumPC) { if ($invVatSumPC) {
if ($invToPay === 0.0) { if ($invToPay === 0.0) {
$invVatPaid = $invVatSum; $invVatPaid = $invVatSum;
} else { } else {
$invVatPaid = $invPaid * $invVatSumPC / 100; $invVatPaid = round($invPaid * $invVatSumPC / 100, $Currency->getPrecision());
} }
} else { } else {
$invVatPaid = 0; $invVatPaid = 0;
......
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