From 3e2e9e6009301006be7c7e96444ff4bbf824358c Mon Sep 17 00:00:00 2001 From: Jonathan Bennetts Date: Tue, 20 Sep 2022 14:33:29 +0100 Subject: [PATCH] fix(xero Node): fix line amount types being ignored when creating new invoices (#4146) --- packages/nodes-base/nodes/Xero/InvoiceInterface.ts | 2 +- packages/nodes-base/nodes/Xero/Xero.node.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/nodes-base/nodes/Xero/InvoiceInterface.ts b/packages/nodes-base/nodes/Xero/InvoiceInterface.ts index 1c86f8b560..270ff9ec3f 100644 --- a/packages/nodes-base/nodes/Xero/InvoiceInterface.ts +++ b/packages/nodes-base/nodes/Xero/InvoiceInterface.ts @@ -20,7 +20,7 @@ export interface IInvoice extends ITenantId { Contact?: IDataObject; Date?: string; DueDate?: string; - LineAmountType?: string; + LineAmountTypes?: string; InvoiceNumber?: string; Reference?: string; BrandingThemeID?: string; diff --git a/packages/nodes-base/nodes/Xero/Xero.node.ts b/packages/nodes-base/nodes/Xero/Xero.node.ts index a971b7caf6..27efa06902 100644 --- a/packages/nodes-base/nodes/Xero/Xero.node.ts +++ b/packages/nodes-base/nodes/Xero/Xero.node.ts @@ -291,7 +291,7 @@ export class Xero implements INodeType { body.InvoiceNumber = additionalFields.invoiceNumber as string; } if (additionalFields.lineAmountType) { - body.LineAmountType = additionalFields.lineAmountType as string; + body.LineAmountTypes = additionalFields.lineAmountType as string; } if (additionalFields.plannedPaymentDate) { body.PlannedPaymentDate = additionalFields.plannedPaymentDate as string; @@ -388,7 +388,7 @@ export class Xero implements INodeType { body.InvoiceNumber = updateFields.invoiceNumber as string; } if (updateFields.lineAmountType) { - body.LineAmountType = updateFields.lineAmountType as string; + body.LineAmountTypes = updateFields.lineAmountType as string; } if (updateFields.plannedPaymentDate) { body.PlannedPaymentDate = updateFields.plannedPaymentDate as string;