mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 05:02:36 +01:00
Hide unit cost if the quantity column is hidden
This commit is contained in:
parent
8bd2e84bc8
commit
786b6567b6
File diff suppressed because one or more lines are too long
@ -279,7 +279,7 @@ NINJA.invoiceColumns = function(invoice)
|
||||
|
||||
var count = 3;
|
||||
if (account.hide_quantity == '1') {
|
||||
count--;
|
||||
count -= 2;
|
||||
}
|
||||
if (account.show_item_taxes == '1') {
|
||||
count++;
|
||||
@ -336,11 +336,10 @@ NINJA.invoiceLines = function(invoice) {
|
||||
}
|
||||
if (invoice.features.invoice_ettings && account.custom_invoice_item_label2) {
|
||||
grid[0].push({text: account.custom_invoice_item_label2, style: ['tableHeader', 'custom2TableHeader']});
|
||||
}
|
||||
|
||||
grid[0].push({text: invoiceLabels.unit_cost, style: ['tableHeader', 'costTableHeader']});
|
||||
}
|
||||
|
||||
if (!hideQuantity) {
|
||||
grid[0].push({text: invoiceLabels.unit_cost, style: ['tableHeader', 'costTableHeader']});
|
||||
grid[0].push({text: invoiceLabels.quantity, style: ['tableHeader', 'qtyTableHeader']});
|
||||
}
|
||||
if (showItemTaxes) {
|
||||
@ -401,8 +400,8 @@ NINJA.invoiceLines = function(invoice) {
|
||||
if (invoice.features.invoice_settings && account.custom_invoice_item_label2) {
|
||||
row.push({style:["customValue2", rowStyle], text:custom_value2 || ' '});
|
||||
}
|
||||
row.push({style:["cost", rowStyle], text:cost});
|
||||
if (!hideQuantity) {
|
||||
row.push({style:["cost", rowStyle], text:cost});
|
||||
row.push({style:["quantity", rowStyle], text:qty || ' '});
|
||||
}
|
||||
if (showItemTaxes) {
|
||||
|
Loading…
Reference in New Issue
Block a user