Edit invoice

This commit is contained in:
Peter Papp
2021-05-05 17:07:36 +02:00
parent bdfd92872e
commit 599b238ab4
22 changed files with 976 additions and 162 deletions

View File

@@ -161,7 +161,7 @@ function invoice_total($invoice)
foreach ($invoice['items'] as $item) {
$total_without_tax = $item['amount'] * $item['price'];
if ($item['tax_rate']) {
if ($invoice['user']['ic_dph'] && $item['tax_rate']) {
$total_without_tax += $total_without_tax * ($item['tax_rate'] / 100);
}