IO-256 Add description to receivables export.

This commit is contained in:
Patrick Fic
2021-10-13 21:22:38 -07:00
parent b56742bcb2
commit 1b885e4114

View File

@@ -315,8 +315,12 @@ exports.default = function ({
if (qbo) {
Object.keys(invoiceLineHash).forEach((key) => {
Object.keys(invoiceLineHash[key]).forEach((key2) => {
const account = responsibilityCenters.profits.find(
(p) => p.name === key
);
InvoiceLineAdd.push({
...invoiceLineHash[key][key2],
...(account ? { Description: account.accountdesc } : {}),
Amount: invoiceLineHash[key][key2].Amount.toFormat(DineroQbFormat),
});
});