From 74d2d49135a039a7bf605cc60aff84e18bc30a32 Mon Sep 17 00:00:00 2001 From: Methapon2001 <61303214+Methapon2001@users.noreply.github.com> Date: Thu, 23 Jan 2025 11:51:56 +0700 Subject: [PATCH] fix: price --- src/controllers/05-quotation-controller.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/controllers/05-quotation-controller.ts b/src/controllers/05-quotation-controller.ts index 6f964d6..c621ac5 100644 --- a/src/controllers/05-quotation-controller.ts +++ b/src/controllers/05-quotation-controller.ts @@ -484,7 +484,7 @@ export class QuotationController extends Controller { ); const price = finalPriceWithVat; - const pricePerUnit = p.vatIncluded ? price / (1 + VAT_DEFAULT) : price; + const pricePerUnit = price / (1 + VAT_DEFAULT); const vat = p.calcVat ? (pricePerUnit * v.amount - (v.discount || 0)) * VAT_DEFAULT : 0; return { @@ -751,7 +751,7 @@ export class QuotationController extends Controller { ); const price = finalPriceWithVat; - const pricePerUnit = p.vatIncluded ? price / (1 + VAT_DEFAULT) : price; + const pricePerUnit = price / (1 + VAT_DEFAULT); const vat = p.calcVat ? (pricePerUnit * v.amount - (v.discount || 0)) * VAT_DEFAULT : 0; return {