mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-09 12:42:36 +01:00
Fix tax columns with inclusive taxes
This commit is contained in:
parent
8c8ebf75c6
commit
39640418b5
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -666,7 +666,9 @@ function calculateAmounts(invoice) {
|
||||
}
|
||||
}
|
||||
|
||||
if (invoice.account.inclusive_taxes != '1') {
|
||||
if (! taxRate1) {
|
||||
var taxAmount1 = 0;
|
||||
} else if (invoice.account.inclusive_taxes != '1') {
|
||||
var taxAmount1 = roundToTwo(lineTotal * taxRate1 / 100);
|
||||
} else {
|
||||
var taxAmount1 = roundToTwo((lineTotal * 100) / (100 + (taxRate1 * 100)));
|
||||
@ -681,7 +683,9 @@ function calculateAmounts(invoice) {
|
||||
}
|
||||
}
|
||||
|
||||
if (invoice.account.inclusive_taxes != '1') {
|
||||
if (! taxRate2) {
|
||||
var taxAmount2 = 0;
|
||||
} else if (invoice.account.inclusive_taxes != '1') {
|
||||
var taxAmount2 = roundToTwo(lineTotal * taxRate2 / 100);
|
||||
} else {
|
||||
var taxAmount2 = roundToTwo((lineTotal * 100) / (100 + (taxRate2 * 100)));
|
||||
|
Loading…
Reference in New Issue
Block a user