From 0f7ce7842c70bc1fee1ae6f3cff0ccf7be8eaa6f Mon Sep 17 00:00:00 2001
From: it-fixcomart <it@fixcomart.co.id>
Date: Mon, 18 Nov 2024 10:55:34 +0700
Subject: <iman> update

---
 src/lib/transaction/components/Transaction.jsx | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

(limited to 'src/lib/transaction/components/Transaction.jsx')

diff --git a/src/lib/transaction/components/Transaction.jsx b/src/lib/transaction/components/Transaction.jsx
index d001c7f4..a6a9cf6b 100644
--- a/src/lib/transaction/components/Transaction.jsx
+++ b/src/lib/transaction/components/Transaction.jsx
@@ -46,7 +46,7 @@ const Transaction = ({ id }) => {
   const [reason, setReason] = useState('');
   const auth = useAuth();
   const { transaction } = useTransaction({ id });
-
+  console.log('transaction', transaction);
   const statusApprovalWeb = transaction.data?.approvalStep;
 
   const { queryAirwayBill } = useAirwayBill({ orderId: id });
@@ -779,8 +779,10 @@ const Transaction = ({ id }) => {
                                 : ''}
                             </div>
                             <div className='text-[10px] text-red-500 italic mt-2'>
-                              {product.availableQuantity} barang ini bisa di
-                              pickup maksimal pukul 16.00
+                              {product.soQty !== product.reservedStockQty
+                                ? 'Barang sedang disiapkan'
+                                : `${product.reservedStockQty} barang bisa di
+                              kirim/pickup`}
                             </div>
                           </div>
                         </td>
-- 
cgit v1.2.3


From 7faf56fa355fcb62df9ff2b4109dbbed8c8e4755 Mon Sep 17 00:00:00 2001
From: it-fixcomart <it@fixcomart.co.id>
Date: Mon, 18 Nov 2024 13:54:37 +0700
Subject: <iman> perbaiki code

---
 src/lib/transaction/components/Transaction.jsx | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

(limited to 'src/lib/transaction/components/Transaction.jsx')

diff --git a/src/lib/transaction/components/Transaction.jsx b/src/lib/transaction/components/Transaction.jsx
index a6a9cf6b..58c824f2 100644
--- a/src/lib/transaction/components/Transaction.jsx
+++ b/src/lib/transaction/components/Transaction.jsx
@@ -778,12 +778,14 @@ const Transaction = ({ id }) => {
                                 ? `| ${product?.attributes.join(', ')}`
                                 : ''}
                             </div>
-                            <div className='text-[10px] text-red-500 italic mt-2'>
-                              {product.soQty !== product.reservedStockQty
-                                ? 'Barang sedang disiapkan'
-                                : `${product.reservedStockQty} barang bisa di
+                            {product.soQty && product.reservedStockQty && (
+                              <div className='text-[10px] text-red-500 italic mt-2'>
+                                {product.soQty !== product.reservedStockQty
+                                  ? 'Barang sedang disiapkan'
+                                  : `${product.reservedStockQty} barang bisa di
                               kirim/pickup`}
-                            </div>
+                              </div>
+                            )}
                           </div>
                         </td>
                         {/* <td>
-- 
cgit v1.2.3


From f7a13c357a6d44f9fa6e0c034292ab782249731e Mon Sep 17 00:00:00 2001
From: it-fixcomart <it@fixcomart.co.id>
Date: Tue, 26 Nov 2024 16:56:03 +0700
Subject: <iman> update improv

---
 src/lib/transaction/components/Transaction.jsx | 1 -
 1 file changed, 1 deletion(-)

(limited to 'src/lib/transaction/components/Transaction.jsx')

diff --git a/src/lib/transaction/components/Transaction.jsx b/src/lib/transaction/components/Transaction.jsx
index 58c824f2..93887f4d 100644
--- a/src/lib/transaction/components/Transaction.jsx
+++ b/src/lib/transaction/components/Transaction.jsx
@@ -46,7 +46,6 @@ const Transaction = ({ id }) => {
   const [reason, setReason] = useState('');
   const auth = useAuth();
   const { transaction } = useTransaction({ id });
-  console.log('transaction', transaction);
   const statusApprovalWeb = transaction.data?.approvalStep;
 
   const { queryAirwayBill } = useAirwayBill({ orderId: id });
-- 
cgit v1.2.3

