summaryrefslogtreecommitdiff
path: root/src/core/utils
diff options
context:
space:
mode:
authorit-fixcomart <it@fixcomart.co.id>2025-01-13 17:08:44 +0700
committerit-fixcomart <it@fixcomart.co.id>2025-01-13 17:08:44 +0700
commite06905990de608585320754eb6a477cf32263595 (patch)
treec2ffa0b95bec6da309eebf852e5c181a8da6c285 /src/core/utils
parent40f762589601de0fe1d5b06164b2553ebdbf5ecd (diff)
parenta868498e7327593b40d1e02fd96531fefd9548d5 (diff)
Merge branch 'new-release' into Feature/pengajuan-tempo
# Conflicts: # src/core/components/elements/Navbar/NavbarDesktop.jsx
Diffstat (limited to 'src/core/utils')
-rw-r--r--src/core/utils/googleTag.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/utils/googleTag.js b/src/core/utils/googleTag.js
index 96a6bd2e..f1550071 100644
--- a/src/core/utils/googleTag.js
+++ b/src/core/utils/googleTag.js
@@ -1,3 +1,5 @@
+const PPN = process.env.NEXT_PUBLIC_PPN
+
const mapVariants = (variants) => {
return variants.map((variant) => {
const res = {
@@ -22,7 +24,7 @@ const sumTotal = (variants) => {
0
)
let subtotal = totalPurchase - totalDiscount
- let tax = Math.round(subtotal * 0.11)
+ let tax = Math.round(subtotal * (PPN - 1))
let grandTotal = subtotal + tax
return {
totalPurchase: totalPurchase,