From 0d8b420d4606c53c426e6a3f2b828637298f692f Mon Sep 17 00:00:00 2001 From: mohan Date: Mon, 9 Feb 2026 18:55:09 +0530 Subject: [PATCH] bs item card exp issue --- .../Components/BSItemCards/BSItemCard.jsx | 129 +++++++++--------- 1 file changed, 65 insertions(+), 64 deletions(-) diff --git a/src/Pages/BookingScreen/Components/BSItemCards/BSItemCard.jsx b/src/Pages/BookingScreen/Components/BSItemCards/BSItemCard.jsx index 86d9333..5dc266e 100644 --- a/src/Pages/BookingScreen/Components/BSItemCards/BSItemCard.jsx +++ b/src/Pages/BookingScreen/Components/BSItemCards/BSItemCard.jsx @@ -238,7 +238,10 @@ const BSItemCard = (props) => { SelectedGlobalCardColorDetail, shallowEqual ); - const GetmultipleSearchDatas = useSelector(GlobalGetmultipleSearchDatas, shallowEqual) + const GetmultipleSearchDatas = useSelector( + GlobalGetmultipleSearchDatas, + shallowEqual + ); const SelectedCardFont = useSelector(SelectedGlobalCardFont, shallowEqual); const CartOrderDetails = useSelector(GlobalOrderCardDetails, shallowEqual); const SelectedDatas = useSelector(GlobalSelectedDatas, shallowEqual); @@ -246,7 +249,7 @@ const BSItemCard = (props) => { const WSProductdata = useSelector(GlobalWSProduct, shallowEqual); const NewQrProductData = useSelector(GlobalNewQrProduct, shallowEqual); const ReportholdData = useSelector(GlobalReorderHoldDetails, shallowEqual); - console.log(GetmultipleSearchDatas, "GetmultipleSearchDatas") + console.log(GetmultipleSearchDatas, 'GetmultipleSearchDatas'); const ReorderProductData = useSelector( GlobalReorderProductDetails, shallowEqual @@ -315,6 +318,7 @@ const BSItemCard = (props) => { onOk: null, onCancel: null, }); + const salespagefields = appPreferences?.find( (pref) => pref?.PreferredCatName === 'Sales Page Fields' )?.PreferenceCatDetails; @@ -1030,7 +1034,7 @@ const BSItemCard = (props) => { useEffect(() => { if (AppId && CompId && BranchId) { fetchedit(); - GetmultipleSearchData() + GetmultipleSearchData(); } // dispatch(changepreOrder(false)); Commented to Add Normal Produts After Adding the Combo Pack !!!!!! Dont Touch Without Shifayath Permission @@ -1044,10 +1048,9 @@ const BSItemCard = (props) => { }; try { - const response = await dispatch(getmultipleSearch(data)) - + const response = await dispatch(getmultipleSearch(data)); } catch (error) { - console.error("Get Search Terms Error:", error); + console.error('Get Search Terms Error:', error); } }; @@ -1066,9 +1069,10 @@ const BSItemCard = (props) => { setNoSubcatCardData(); } - if (ProductSearch?.length > 5 && GetmultipleSearchDatas.some( - e => e.toLowerCase() === "qrcode" - )) { + if ( + ProductSearch?.length > 5 && + GetmultipleSearchDatas.some((e) => e.toLowerCase() === 'qrcode') + ) { setQuickAdd(true); } }, [ProductSearch, GetmultipleSearchDatas]); @@ -1741,7 +1745,7 @@ const BSItemCard = (props) => { onOk: () => expQtyFun(qtyExpData), onCancel: () => { setRepeatedModel(false); - (setProdexpir(false),closeExpireModal()); + (setProdexpir(false), closeExpireModal()); }, }); setQtyExpData(index); @@ -2049,7 +2053,7 @@ const BSItemCard = (props) => { if (modiffiedData.OverAllExpStatus === 'Y' && ExpiredProduct) { openExpireModal({ title: 'Product Expires', - onOk: () => expFun(Item), + onOk: () => expFun(modiffiedData), }); setItem(modiffiedData); } else if (modiffiedData) { @@ -5117,6 +5121,7 @@ const BSItemCard = (props) => { }, []); const expFun = (item) => { + console.log(item, 'itemitemitemitemitemitemitemitem'); let count = item?.ProductDetail?.length; if (count > 1) { Quantity(); @@ -5231,7 +5236,7 @@ const BSItemCard = (props) => { setQtyIndex(selectedProIndex); setRepeatedModel(true); - closeExpireModal() + closeExpireModal(); }; const expVerFun = (item) => { @@ -5285,8 +5290,6 @@ const BSItemCard = (props) => { }; }, []); - - // Example usage for checking the length of 'ProdVariantDetails' const widthBasedOnProdVariantDetails = getMaxBrandWidth(); const ExpDate = useSelector(GlobalExpDateforHeight); @@ -7245,64 +7248,62 @@ const BSItemCard = (props) => { - ) - - - : ProductSearch?.length > 5 && GetmultipleSearchDatas.some( - e => e.toLowerCase() === "qrcode" + ) : ProductSearch?.length > 5 && + GetmultipleSearchDatas.some( + (e) => e.toLowerCase() === 'qrcode' ) && - (cardData?.length == 0 || cardData == undefined) ? ( -
- {/* cardData mohan 18-04-2025 */} - -
- ) : ( - <> -
-
-
-
-
 
-
-
-
 
-
-
-
 
-
-
-
 
-
+ (cardData?.length == 0 || cardData == undefined) ? ( +
+ {/* cardData mohan 18-04-2025 */} + +
+ ) : ( + <> +
+
+
+
+
 
+
+
+
 
+
+
+
 
+
+
+
 
- - )} +
+ + )} {paymentloader === true && ( -
-
-
-
 
+
+
+
+
 
-
-
 
+
+
 
-
-
 
+
+
 
-
-
 
+
+
 

{' '}