From be85ae76e580071acd880a5280044eca364614bc Mon Sep 17 00:00:00 2001 From: saksham Date: Tue, 8 Aug 2023 16:59:52 +0530 Subject: [PATCH] fix: balance number in two points after point --- src/invoice/helper.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/invoice/helper.js b/src/invoice/helper.js index 794d1b8..eb7ebbf 100644 --- a/src/invoice/helper.js +++ b/src/invoice/helper.js @@ -39,7 +39,6 @@ function generatePDF(response) { } function getInvoiceObject(payload) { - console.log(payload); return { name: payload?.contactDetails?.first_name + @@ -82,7 +81,9 @@ function getInvoiceObject(payload) { 10 ) / 10 ).toFixed(2), - balance: payload?.invoiceData?.amount - payload?.invoiceData?.balance, + balance: ( + payload?.invoiceData?.amount - payload?.invoiceData?.balance + ).toFixed(2), earlyPayDate: new getEarlyPayData(payload?.invoiceData)?.date, earlyPayDiscount: getEarlyPayData(payload?.invoiceData)?.discount, earlyPayAmt: (