mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04: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;
|
var count = 3;
|
||||||
if (account.hide_quantity == '1') {
|
if (account.hide_quantity == '1') {
|
||||||
count--;
|
count -= 2;
|
||||||
}
|
}
|
||||||
if (account.show_item_taxes == '1') {
|
if (account.show_item_taxes == '1') {
|
||||||
count++;
|
count++;
|
||||||
@ -338,9 +338,8 @@ NINJA.invoiceLines = function(invoice) {
|
|||||||
grid[0].push({text: account.custom_invoice_item_label2, style: ['tableHeader', 'custom2TableHeader']});
|
grid[0].push({text: account.custom_invoice_item_label2, style: ['tableHeader', 'custom2TableHeader']});
|
||||||
}
|
}
|
||||||
|
|
||||||
grid[0].push({text: invoiceLabels.unit_cost, style: ['tableHeader', 'costTableHeader']});
|
|
||||||
|
|
||||||
if (!hideQuantity) {
|
if (!hideQuantity) {
|
||||||
|
grid[0].push({text: invoiceLabels.unit_cost, style: ['tableHeader', 'costTableHeader']});
|
||||||
grid[0].push({text: invoiceLabels.quantity, style: ['tableHeader', 'qtyTableHeader']});
|
grid[0].push({text: invoiceLabels.quantity, style: ['tableHeader', 'qtyTableHeader']});
|
||||||
}
|
}
|
||||||
if (showItemTaxes) {
|
if (showItemTaxes) {
|
||||||
@ -401,8 +400,8 @@ NINJA.invoiceLines = function(invoice) {
|
|||||||
if (invoice.features.invoice_settings && account.custom_invoice_item_label2) {
|
if (invoice.features.invoice_settings && account.custom_invoice_item_label2) {
|
||||||
row.push({style:["customValue2", rowStyle], text:custom_value2 || ' '});
|
row.push({style:["customValue2", rowStyle], text:custom_value2 || ' '});
|
||||||
}
|
}
|
||||||
row.push({style:["cost", rowStyle], text:cost});
|
|
||||||
if (!hideQuantity) {
|
if (!hideQuantity) {
|
||||||
|
row.push({style:["cost", rowStyle], text:cost});
|
||||||
row.push({style:["quantity", rowStyle], text:qty || ' '});
|
row.push({style:["quantity", rowStyle], text:qty || ' '});
|
||||||
}
|
}
|
||||||
if (showItemTaxes) {
|
if (showItemTaxes) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user