IO-2066 Update item used for adjustments.
This commit is contained in:
@@ -479,9 +479,7 @@ exports.default = function ({
|
|||||||
},
|
},
|
||||||
bodyshop.md_responsibility_centers.sales_tax_codes
|
bodyshop.md_responsibility_centers.sales_tax_codes
|
||||||
);
|
);
|
||||||
const account = responsibilityCenters.profits.find(
|
|
||||||
(c) => c.name === responsibilityCenters.defaults.profits["PAO"]
|
|
||||||
);
|
|
||||||
const QboTaxId = taxCodes[taxAccountCode];
|
const QboTaxId = taxCodes[taxAccountCode];
|
||||||
InvoiceLineAdd.push({
|
InvoiceLineAdd.push({
|
||||||
DetailType: "SalesItemLineDetail",
|
DetailType: "SalesItemLineDetail",
|
||||||
@@ -493,7 +491,7 @@ exports.default = function ({
|
|||||||
? { ClassRef: { value: classes[jobs_by_pk.class] } }
|
? { ClassRef: { value: classes[jobs_by_pk.class] } }
|
||||||
: {}),
|
: {}),
|
||||||
ItemRef: {
|
ItemRef: {
|
||||||
value: items[account.accountitem],
|
value: items[responsibilityCenters.refund.accountitem],
|
||||||
},
|
},
|
||||||
TaxCodeRef: {
|
TaxCodeRef: {
|
||||||
value: QboTaxId,
|
value: QboTaxId,
|
||||||
@@ -504,9 +502,7 @@ exports.default = function ({
|
|||||||
} else {
|
} else {
|
||||||
InvoiceLineAdd.push({
|
InvoiceLineAdd.push({
|
||||||
ItemRef: {
|
ItemRef: {
|
||||||
FullName: responsibilityCenters.profits.find(
|
FullName: responsibilityCenters.refund.accountitem,
|
||||||
(c) => c.name === responsibilityCenters.defaults.profits["PAO"]
|
|
||||||
).accountitem,
|
|
||||||
},
|
},
|
||||||
Desc: "Adjustment",
|
Desc: "Adjustment",
|
||||||
Quantity: 1,
|
Quantity: 1,
|
||||||
|
|||||||
Reference in New Issue
Block a user