summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorit-fixcomart <it@fixcomart.co.id>2024-07-01 09:07:59 +0700
committerit-fixcomart <it@fixcomart.co.id>2024-07-01 09:07:59 +0700
commit703136862dc3d41d0a276c17fa7f4ecebd471527 (patch)
treef96c9b0ec8317d6e70cd5b7e6efc371d19514fcf /src
parentb992edcc7f1b7395dea0c8562ddf272df9fc6b7f (diff)
<iman> add flash sales to sales order
Diffstat (limited to 'src')
-rw-r--r--src/lib/checkout/components/Checkout.jsx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lib/checkout/components/Checkout.jsx b/src/lib/checkout/components/Checkout.jsx
index df1768fb..4aafdece 100644
--- a/src/lib/checkout/components/Checkout.jsx
+++ b/src/lib/checkout/components/Checkout.jsx
@@ -227,6 +227,7 @@ const Checkout = () => {
setTotalWeight(cartCheckout?.totalWeight.g);
setHasFlashSale(cartCheckout?.products[0]?.hasFlashsale ? cartCheckout.products[0].hasFlashsale : false);
}, [cartCheckout]);
+
useEffect(() => {
setCheckoutValidation(false);
@@ -345,7 +346,7 @@ const Checkout = () => {
carrier_id: selectedCarrierId,
estimated_arrival_days: splitDuration(etd),
delivery_service_type: selectedExpedisiService,
- flash_sale : !hasFlashSale, // dibuat negasi untuk ngetest kebalikan nilai false
+ flash_sale : hasFlashSale, // dibuat negasi untuk ngetest kebalikan nilai false
voucher: activeVoucher,
type: 'sale_order',
};
@@ -361,7 +362,7 @@ const Checkout = () => {
toast.error('Gagal melakukan transaksi, terjadi kesalahan internal');
return;
}
- console.log("isCheckouted",isCheckouted)
+
gtagPurchase(products, biayaKirim, isCheckouted.name);
const midtrans = async () => {