From 25a4b50f8eae8f5b2d24e7f6bbcdd28b00ad386a Mon Sep 17 00:00:00 2001 From: Methapon2001 <61303214+Methapon2001@users.noreply.github.com> Date: Tue, 16 Sep 2025 10:11:02 +0700 Subject: [PATCH] fix: wrong condition --- src/services/flowaccount.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/services/flowaccount.ts b/src/services/flowaccount.ts index 31c2fd6..90eb5c0 100644 --- a/src/services/flowaccount.ts +++ b/src/services/flowaccount.ts @@ -379,7 +379,7 @@ const flowAccount = { quantity: v.amount, discountAmount: v.discount, total: - precisionRound(v.pricePerUnit * (1 + (v.vat === 0 ? VAT_DEFAULT : 0))) * v.amount - + precisionRound(v.pricePerUnit * (1 + (v.vat > 0 ? VAT_DEFAULT : 0))) * v.amount - (v.discount ?? 0), vatRate: v.vat === 0 ? 0 : Math.round(VAT_DEFAULT * 100), })),