From 423a82c646e6a4c7abcea7594ddb624cb4a685ed Mon Sep 17 00:00:00 2001 From: karthikalakshmi Date: Tue, 3 Mar 2026 10:01:38 +0530 Subject: [PATCH] Update src/Pages/BookingScreen/PrintTemplates/A4/PrintA4Style11.jsx --- .../PrintTemplates/A4/PrintA4Style11.jsx | 3348 ++++++++--------- 1 file changed, 1585 insertions(+), 1763 deletions(-) diff --git a/src/Pages/BookingScreen/PrintTemplates/A4/PrintA4Style11.jsx b/src/Pages/BookingScreen/PrintTemplates/A4/PrintA4Style11.jsx index b65f885..074d7ae 100644 --- a/src/Pages/BookingScreen/PrintTemplates/A4/PrintA4Style11.jsx +++ b/src/Pages/BookingScreen/PrintTemplates/A4/PrintA4Style11.jsx @@ -60,6 +60,7 @@ const PrintA4Style11 = ({ printDatas, sportsAppPreference, MembershipApplied = null, + SalesModePref, }) => { const GlobalthemeFormatr = useSelector(GlobalthemeFormat); const GlobalSignature = useSelector(GlobalprintSignature); @@ -111,7 +112,8 @@ const PrintA4Style11 = ({ )?.SettingValue === 'Y'; const estimateTitle = SettingData?.[0]?.SettingDtlDetails?.find( - (setting) => setting?.SettingIdName?.toLowerCase() === 'estimatetitle' + (setting) => + setting?.SettingIdName?.toLowerCase() === 'estimatetitle' )?.SettingValue === 'Y'; const currentDate = new Date(); console.log(OrderDetailGST, 'OrderDetailGST'); @@ -144,7 +146,7 @@ const PrintA4Style11 = ({ let PaymentStatusSuccess = PaymentStatus?.filter( (ps) => ps.PaymentStatus === 'S' ); - const isEditedBill = PaymentStatus?.some((payment) => { + const isEditedBill = PaymentStatus?.some(payment => { const type = payment?.AdjustmentType?.toLowerCase(); return ( (type === 'extra' || type === 'refund') && @@ -154,7 +156,7 @@ const PrintA4Style11 = ({ }); const lastTransaction = PaymentStatus?.find( (ps) => ps.PaymentStatus === 'S' && ps?.LastOrderTran === 'Y' - ); + ) const TakeawayTotal = TakeawayData?.reduce( (accumulator, currentValue) => accumulator + currentValue.TotalAmt, @@ -343,7 +345,7 @@ const PrintA4Style11 = ({ )} {base64Image && - (PrintLogo?.SettingValue === 'Y' || LogoField) ? ( + (PrintLogo?.SettingValue === 'Y' || LogoField) ? ( Mobile: +91{' '} {GlobaldummyData ? '986XXXXXXX' : table2Data?.BrMobile} @@ -401,19 +403,17 @@ const PrintA4Style11 = ({ )} - {!estimatePrintHeader && - table2Data?.OrderType === 'E' && - estimateTitle && ( -
- Estimate -
- )} + {!estimatePrintHeader && table2Data?.OrderType === 'E' && estimateTitle && ( +
+ Estimate +
+ )}
+ {' '} + Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '} +
} {GlobaldummyData && '685'}
@@ -449,10 +453,16 @@ const PrintA4Style11 = ({ justifyContent: 'space-between', padding: '0rem 1rem', fontSize: 'clamp(0.7rem, 2.5vw, 0.8rem)', + flexDirection: 'column', + textAlign: 'left' }} > {' '}
{Date1}
{' '} + {SalesModePref?.SettingValue == 'Y' &&
+ {' '} + Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '} +
}
@@ -506,176 +516,176 @@ const PrintA4Style11 = ({ > {GlobaldummyData ? GlobalSlNo && ( - - S.No - - ) + + S.No + + ) : SLNO == true && ( - - S.No - - )} + + S.No + + )} {GlobaldummyData ? GlobalItem && Item : Item == true && Item} {GlobaldummyData ? GlobalHsnCode && ( - - HSN - - ) + + HSN + + ) : HsnCode == true && ( - - HSN - - )} + + HSN + + )} {GlobaldummyData ? GlobalQuantity && ( - - Qty - - ) + + Qty + + ) : Quantity == true && ( - - {WeightasKg ? 'Qty/Kg' : 'Qty'} - - )} + + {WeightasKg ? 'Qty/Kg' : 'Qty'} + + )} {GlobaldummyData ? GlobalMRP && ( - - MRP - - ) + + MRP + + ) : MRP == true && ( - - MRP - - )} + + MRP + + )} {GlobaldummyData ? GlobalRate && ( - - Rate - - ) + + Rate + + ) : Rate == true && ( - - Rate - - )} + + Rate + + )} {GlobaldummyData ? GlobalDiscount && ( - - Dis{' '} - - ) + + Dis{' '} + + ) : Discount == true && ( - - Dis{' '} - - )} + + Dis{' '} + + )} {GlobaldummyData ? GlobalTax && ( - - Tax % - - ) + + Tax % + + ) : Tax && - table2Data?.OrderType !== 'E' && ( - - Tax % - - )} + table2Data?.OrderType !== 'E' && ( + + Tax % + + )} {GlobaldummyData ? GlobalAmount && ( - - Amt - - ) + + Amt + + ) : Amount == true && ( - - Amt - - )} + + Amt + + )} @@ -684,187 +694,173 @@ const PrintA4Style11 = ({ {GlobaldummyData ? GlobalSlNo && ( - - {index + 1} - - ) + + {index + 1} + + ) : SLNO == true && ( - - {chunkIndex * chunkSize + index + 1} - - )} - {GlobaldummyData - ? GlobalItem && {item?.name} - : Item == true && ( - -
{item?.ProdName}
- {PackageDetails?.filter( - (pkg) => - pkg.ProdId === item.ProdId - ).length > 0 ? ( -
- {PackageDetails?.filter( - (pkg) => - pkg.ProdId === item.ProdId - )?.map((item, index) => ( - - {item.ParcelCount} PCS{' '} - {item.ParcelQty} PACK ( - {item.ParcelType}) + + {chunkIndex * chunkSize + index + 1} + + )} + {GlobaldummyData ? ( + GlobalItem && {item?.name} + ) : ( + Item && ( + +
{item?.ProdName}
+ + {PackageDetails?.filter( + (pkg) => pkg.ProdId === item.ProdId + ).length > 0 ? ( +
+ {PackageDetails + ?.filter((pkg) => pkg.ProdId === item.ProdId) + ?.map((pkg, index) => ( + + {pkg.ParcelCount} PCS {pkg.ParcelQty} PACK ({pkg.ParcelType}) ))} +
+ ) : ( + UomPrint?.SettingValue === 'Y' && ( +
+ ({item?.Size || "1"}{" "} + {item?.SinglePc === "Y" + ? "PCS" + : item?.Type !== "C" + ? item?.UomName + : "COMBO"} + )
- ) : ( - UomPrint?.SettingValue === - 'Y' && ( -
- ( - {item?.Size - ? item?.Size - : '1'}{' '} - {item?.SinglePc == 'Y' - ? 'PCS' - : item?.Type != 'C' - ? item?.UomName - : 'COMBO'} - ) + ) + )} + + {item?.BrandName &&
{item.BrandName}
} + + {/* Serial Numbers */} + {item?.ProductIdentifierDtls?.map((id, index) => ( +
+ {id?.SerialNumber &&
{id.SerialNumber}
} +
+ ))} + + {/* IMEI */} + {item?.ProductIdentifierDtls?.map((id, index) => { + const imei1 = id?.IMEI1 || ""; + const imei2 = id?.IMEI2 || ""; + + return ( + (imei1 || imei2) && ( +
+ {[imei1, imei2].filter(Boolean).join(",")}
) - )} -  {' '} - {item?.BrandName !== null - ? item?.BrandName - : ''} -   - {item?.ProductIdentifierDtls - ?.length > 0 - ? item?.ProductIdentifierDtls?.filter( - (items) => - !( - items.SerialNumber == - '' || - items.SerialNumber == null - ) - )?.map((a) => { - return ( -
{a.SerialNumber}
- ); - }) - : ''}{' '} - {item?.ProductIdentifierDtls - ?.length > 0 - ? item?.ProductIdentifierDtls.filter( - (item1) => - item1.IMEI1 !== '' || - item1.IMEI2 !== '' - )?.map((item2) => { - const imei1 = - item2.IMEI1 || ''; - const imei2 = - item2.IMEI2 || ''; - return ( -
- {[imei1, imei2] - .filter(Boolean) - .join(',')} -
- ); - }) - : ''} - - )} + ); + })} + + {/* Description */} + {item?.ProductIdentifierDtls?.map((id, index) => ( + (id?.SerialNumber || id?.IMEI1 || id?.IMEI2) && + id?.Description && ( +
+ {id.Description} +
+ ) + ))} + + + ) + )} {GlobaldummyData ? GlobalHsnCode && ( - - {item?.discount} - - ) + + {item?.discount} + + ) : HsnCode == true && ( - - {item?.HSN} - - )} + + {item?.HSN} + + )} {GlobaldummyData ? GlobalQuantity && ( - - {item?.quantity} - - ) + + {item?.quantity} + + ) : Quantity == true && ( - - {item?.SalesQty} - - )} + + {item?.SalesQty} + + )} {GlobaldummyData ? GlobalMRP && ( - - {item?.mrp} - - ) + + {item?.mrp} + + ) : MRP == true && ( - - {item?.SinglePc === 'Y' - ? item?.Rate - : item?.MRP} - - )} + + {item?.SinglePc === 'Y' + ? item?.Rate + : item?.MRP} + + )} {GlobaldummyData ? GlobalRate && ( - - {item?.Rate} - - ) + + {item?.Rate} + + ) : Rate == true && ( - - {' '} - {item?.MRP} - - )} + + {' '} + {item?.MRP} + + )} {GlobaldummyData ? GlobalDiscount && ( - {item.discount} - ) + {item.discount} + ) : Discount == true && ( - - {item?.Type != 'C' - ? item?.OfferAmt || 0 - : item?.OfferValue || 0} - - )} + + {item?.Type != 'C' + ? item?.OfferAmt || 0 + : item?.OfferValue || 0} + + )} {GlobaldummyData ? GlobalTax && ( - {item.ProdTaxPercentage} - ) + {item.ProdTaxPercentage} + ) : Tax && - table2Data?.OrderType !== 'E' && ( - - {item?.ProdTaxPercentage || 0} - - )} + table2Data?.OrderType !== 'E' && ( + + {item?.ProdTaxPercentage || 0} + + )} {GlobaldummyData ? GlobalAmount && ( - - {item?.price} - - ) + + {item?.price} + + ) : Amount == true && ( - - {item?.Type != 'C' - ? item?.TotalAmt - - item?.OfferAmt || 0 - : item?.TotalAmt - - item?.OfferValue || 0} - - )} + + {item?.Type != 'C' + ? item?.TotalAmt - + item?.OfferAmt || 0 + : item?.TotalAmt - + item?.OfferValue || 0} + + )} ))} @@ -903,7 +899,7 @@ const PrintA4Style11 = ({
ITEMS
Qty
{TotalOfferAmount > 0 || - table2Data?.OverallDisc ? ( + table2Data?.OverallDisc ? (
OFFER
) : ( '' @@ -929,11 +925,11 @@ const PrintA4Style11 = ({ : totalQuantity}
{TotalOfferAmount > 0 || - table2Data?.OverallDisc ? ( + table2Data?.OverallDisc ? (
{Number( TotalOfferAmount + - table2Data?.OverallDisc + table2Data?.OverallDisc ).toFixed(2)}
) : ( @@ -956,50 +952,26 @@ const PrintA4Style11 = ({ {GlobaldummyData ? '1066' : Number( - table2Data?.NetAmount - ).toFixed(2)} + table2Data?.NetAmount + ).toFixed(2)}
{isEditedBill && lastTransaction && ( -
+
-
- - Bill Gross Amount - - - {( - lastTransaction?.BeforeAdjustment || - 0 - ).toFixed(2)} - +
+ Bill Gross Amount + {(lastTransaction?.BeforeAdjustment || 0).toFixed(2)}
{'Adjustment Amount'} - {lastTransaction?.AdjustmentType === - 'REFUND' - ? '-' - : '+'} - {Math.abs( - (lastTransaction?.BeforeAdjustment ?? - 0) - - (lastTransaction?.AfterAdjustment ?? - 0) - ).toFixed(2)} + {lastTransaction?.AdjustmentType === 'REFUND' ? '-' : '+'} + {Math.abs((lastTransaction?.BeforeAdjustment ?? 0) - + (lastTransaction?.AfterAdjustment ?? 0)).toFixed(2)}
-
- - Net Bill Amount - - - {( - lastTransaction?.AfterAdjustment || - 0 - ).toFixed(2)} - +
+ Net Bill Amount + {(lastTransaction?.AfterAdjustment || 0).toFixed(2)}
)} {GlobaldummyData ? GlobalCredit && ( -
-
Advance Amount:
-
Opening Balance:
-
- ) +
+
Advance Amount:
+
Opening Balance:
+
+ ) : CreditDetails && - table2Data?.CustomerDetails?.length > - 0 && ( -
- {/* OLD CREDIT BAL */} - {PaymentStatusSuccess?.[0] - ?.PaymentTypeName === - 'Credit' && ( + table2Data?.CustomerDetails?.length > + 0 && ( +
+ {/* OLD CREDIT BAL */} + {PaymentStatusSuccess?.[0] + ?.PaymentTypeName === + 'Credit' && ( <> {table2Data.CustomerDetails[0] .OldCreditBal > 0 ? ( @@ -1093,8 +1039,8 @@ const PrintA4Style11 = ({ }

) : table2Data - .CustomerDetails[0] - .OldCreditBal < 0 ? ( + .CustomerDetails[0] + .OldCreditBal < 0 ? (

{' '} Opening Balance:{' '} @@ -1108,30 +1054,30 @@ const PrintA4Style11 = ({ )} - {/* CURRENT CREDIT BAL */} - {table2Data.CustomerDetails[0] - .CurrentCreditBal > 0 ? ( -

- {' '} - Current Advance Amount:{' '} - { - table2Data.CustomerDetails[0] - .CurrentCreditBal - } -

- ) : table2Data.CustomerDetails[0] - .CurrentCreditBal < 0 ? ( -

- {' '} - Current Balance Amount:{' '} - {Math.abs( - table2Data.CustomerDetails[0] - .CurrentCreditBal - )} -

- ) : null} -
- )} + {/* CURRENT CREDIT BAL */} + {table2Data.CustomerDetails[0] + .CurrentCreditBal > 0 ? ( +

+ {' '} + Current Advance Amount:{' '} + { + table2Data.CustomerDetails[0] + .CurrentCreditBal + } +

+ ) : table2Data.CustomerDetails[0] + .CurrentCreditBal < 0 ? ( +

+ {' '} + Current Balance Amount:{' '} + {Math.abs( + table2Data.CustomerDetails[0] + .CurrentCreditBal + )} +

+ ) : null} +
+ )}
{table2Data?.OrderType !== 'E' && @@ -1282,58 +1228,58 @@ const PrintA4Style11 = ({ {GlobaldummyData ? GlobalQrcodet && ( -
- -
- Scan to Pay{' '} -
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number( - table2Data?.NetAmount - ).toFixed(2)} -
+
+ +
+ Scan to Pay{' '}
- ) +
+ ₹ + {GlobaldummyData + ? '1,066' + : Number( + table2Data?.NetAmount + ).toFixed(2)} +
+
+ ) : Qrcodet && - paymentTypeUPI && ( -
- -
- Scan to Pay{' '} -
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number( - table2Data?.NetAmount - ).toFixed(2)} -
+ paymentTypeUPI && ( +
+ +
+ Scan to Pay{' '}
- )} +
+ ₹ + {GlobaldummyData + ? '1,066' + : Number( + table2Data?.NetAmount + ).toFixed(2)} +
+
+ )}
-

- Notes : 10 days Return policy -

+
+

+ Notes : 10 days Return policy +

-
-
- ) +
+
+ ) : Notestext && ( -
-

- {Notestext} -

+
+

+ {Notestext} +

-
-
- )} +
+
+ )}
{GlobaldummyData ? GlobaltermsAndConditions && ( -
+

-

- Terms & Conditions -

-
    -
  1. - Once goods are sold, they are - not exchangeable or refundable. -
  2. -
  3. - Please check the product before - leaving the counter. -
  4. -
-
- ) + Terms & Conditions +

+
    +
  1. + Once goods are sold, they are + not exchangeable or refundable. +
  2. +
  3. + Please check the product before + leaving the counter. +
  4. +
+
+ ) : TermsnAdCondition == true && - TermsAndConditions?.length > 0 && ( -
0 && ( +
+

-

- Terms & Conditions -

-
    - {TermsAndConditions?.map( - (item) => ( -
  1. - {item?.TermsandConditions} -
  2. - ) - )} - {/*
  3. Please check the product before leaving the counter.
  4. */} -
-
- )} + Terms & Conditions +

+
    + {TermsAndConditions?.map( + (item) => ( +
  1. + {item?.TermsandConditions} +
  2. + ) + )} + {/*
  3. Please check the product before leaving the counter.
  4. */} +
+
+ )} {GlobaldummyData ? GlobalSignature && ( -
+

-

- Signature -

- -
- ) + Signature +

+ +
+ ) : Signature == true && ( -
+

-

- Signature -

- -
- )} + Signature +

+ +
+ )}
)} @@ -1626,178 +1572,178 @@ const PrintA4Style11 = ({ > {GlobaldummyData ? GlobalSlNo && ( - - S.No - - ) + + S.No + + ) : SLNO == true && ( - - S.No - - )} + + S.No + + )} {GlobaldummyData ? GlobalItem && Item : Item == true && Item} {GlobaldummyData ? GlobalHsnCode && ( - - HSN - - ) + + HSN + + ) : HsnCode == true && ( - - HSN - - )} + + HSN + + )} {GlobaldummyData ? GlobalQuantity && ( - - Qty - - ) + + Qty + + ) : Quantity == true && ( - - {WeightasKg ? 'Qty/Kg' : 'Qty'} - - )} + + {WeightasKg ? 'Qty/Kg' : 'Qty'} + + )} {GlobaldummyData ? GlobalMRP && ( - - MRP - - ) + + MRP + + ) : MRP == true && ( - - MRP - - )} + + MRP + + )} {GlobaldummyData ? GlobalRate && ( - - Rate - - ) + + Rate + + ) : Rate == true && ( - - Rate - - )} + + Rate + + )} {GlobaldummyData ? GlobalDiscount && ( - - Dis{' '} - - ) + + Dis{' '} + + ) : Discount == true && ( - - Dis{' '} - - )} + + Dis{' '} + + )} {GlobaldummyData ? GlobalTax && ( - - Tax % - - ) + + Tax % + + ) : Tax && - table2Data?.OrderType !== 'E' && ( - - Tax % - - )} + table2Data?.OrderType !== 'E' && ( + + Tax % + + )} {GlobaldummyData ? GlobalAmount && ( - - Amt - - ) + + Amt + + ) : Amount == true && ( - - Amt - - )} + + Amt + + )} @@ -1806,161 +1752,151 @@ const PrintA4Style11 = ({ {GlobaldummyData ? GlobalSlNo && ( - - {index + 1} - - ) + + {index + 1} + + ) : SLNO == true && ( - - {chunkIndex * chunkSize + index + 1} - - )} - {GlobaldummyData - ? GlobalItem && {item?.ProdName} - : Item == true && ( - -
{item?.ProdName}
- {UomPrint?.SettingValue === 'Y' && ( -
- ({item?.Size ? item?.Size : '1'}{' '} - {item?.SinglePc == 'Y' - ? 'PCS' - : item?.Type != 'C' - ? item?.UomName - : 'COMBO'} - ) -
- )} -  {' '} - {item?.BrandName !== null - ? item?.BrandName - : ''} -   - {item?.ProductIdentifierDtls - ?.length > 0 - ? item?.ProductIdentifierDtls?.filter( - (items) => - !( - items.SerialNumber == - '' || - items.SerialNumber == null - ) - )?.map((a) => { - return ( -
{a.SerialNumber}
- ); - }) - : ''}{' '} - {item?.ProductIdentifierDtls - ?.length > 0 - ? item?.ProductIdentifierDtls.filter( - (item1) => - item1.IMEI1 !== '' || - item1.IMEI2 !== '' - )?.map((item2) => { - const imei1 = - item2.IMEI1 || ''; - const imei2 = - item2.IMEI2 || ''; - return ( -
- {[imei1, imei2] - .filter(Boolean) - .join(',')} -
- ); - }) - : ''} - - )} + + {chunkIndex * chunkSize + index + 1} + + )} + {GlobaldummyData ? ( + GlobalItem && {item?.ProdName} + ) : ( + Item && ( + + {/* Product Name */} +
{item?.ProdName}
+ + {/* Size + UOM */} + {UomPrint?.SettingValue === 'Y' && ( +
+ ({item?.Size || "1"}{" "} + {item?.SinglePc === "Y" + ? "PCS" + : item?.Type !== "C" + ? item?.UomName + : "COMBO"} + ) +
+ )} + + {/* Brand */} + {item?.BrandName &&
{item.BrandName}
} + + {/* Identifiers */} + {item?.ProductIdentifierDtls?.map((id, index) => ( +
+ + {/* Serial Number */} + {id?.SerialNumber &&
{id.SerialNumber}
} + + {/* IMEI */} + {(id?.IMEI1 || id?.IMEI2) && ( +
+ {[id.IMEI1, id.IMEI2].filter(Boolean).join(",")} +
+ )} + + {/* Description */} + {(id?.SerialNumber || id?.IMEI1 || id?.IMEI2) && id?.Description && ( +
{id.Description}
+ )} + +
+ ))} + + ) + )} {GlobaldummyData ? GlobalHsnCode && ( - - {item?.HSN} - - ) + + {item?.HSN} + + ) : HsnCode == true && ( - - {item?.HSN} - - )} + + {item?.HSN} + + )} {GlobaldummyData ? GlobalQuantity && ( - - {item?.SalesQty} - - ) + + {item?.SalesQty} + + ) : Quantity == true && ( - - {item?.SalesQty} - - )} + + {item?.SalesQty} + + )} {GlobaldummyData ? GlobalMRP && ( - - {item?.MRP} - - ) + + {item?.MRP} + + ) : MRP == true && ( - - {item?.SinglePc === 'Y' - ? item?.Rate - : item?.MRP} - - )} + + {item?.SinglePc === 'Y' + ? item?.Rate + : item?.MRP} + + )} {GlobaldummyData ? GlobalRate && ( - - {item?.Rate} - - ) + + {item?.Rate} + + ) : Rate == true && ( - - {' '} - {item?.Rate} - - )} + + {' '} + {item?.Rate} + + )} {GlobaldummyData ? GlobalDiscount && ( - {item.discount} - ) + {item.discount} + ) : Discount == true && ( - - {item?.Type != 'C' - ? item?.OfferAmt || 0 - : item?.OfferValue || 0} - - )} + + {item?.Type != 'C' + ? item?.OfferAmt || 0 + : item?.OfferValue || 0} + + )} {GlobaldummyData ? GlobalTax && ( - {item.ProdTaxPercentage} - ) + {item.ProdTaxPercentage} + ) : Tax && - table2Data?.OrderType !== 'E' && ( - - {item?.ProdTaxPercentage || 0} - - )} + table2Data?.OrderType !== 'E' && ( + + {item?.ProdTaxPercentage || 0} + + )} {GlobaldummyData ? GlobalAmount && ( - - {item?.TotalAmt} - - ) + + {item?.TotalAmt} + + ) : Amount == true && ( - - {item?.Type != 'C' - ? item?.TotalAmt - - item?.OfferAmt || 0 - : item?.TotalAmt - - item?.OfferValue || 0} - - )} + + {item?.Type != 'C' + ? item?.TotalAmt - + item?.OfferAmt || 0 + : item?.TotalAmt - + item?.OfferValue || 0} + + )} ))} @@ -1999,7 +1935,7 @@ const PrintA4Style11 = ({
ITEMS
Qty
{TotalOfferAmount > 0 || - table2Data?.OverallDisc ? ( + table2Data?.OverallDisc ? (
OFFER
) : ( '' @@ -2025,11 +1961,11 @@ const PrintA4Style11 = ({ : totalQuantity} {TotalOfferAmount > 0 || - table2Data?.OverallDisc ? ( + table2Data?.OverallDisc ? (
{Number( TotalOfferAmount + - table2Data?.OverallDisc + table2Data?.OverallDisc ).toFixed(2)}
) : ( @@ -2052,50 +1988,26 @@ const PrintA4Style11 = ({ {GlobaldummyData ? '1066' : Number( - table2Data?.NetAmount - ).toFixed(2)} + table2Data?.NetAmount + ).toFixed(2)} {isEditedBill && lastTransaction && ( -
+
-
- - Bill Gross Amount - - - {( - lastTransaction?.BeforeAdjustment || - 0 - ).toFixed(2)} - +
+ Bill Gross Amount + {(lastTransaction?.BeforeAdjustment || 0).toFixed(2)}
{'Adjustment Amount'} - {lastTransaction?.AdjustmentType === - 'REFUND' - ? '-' - : '+'} - {Math.abs( - (lastTransaction?.BeforeAdjustment ?? - 0) - - (lastTransaction?.AfterAdjustment ?? - 0) - ).toFixed(2)} + {lastTransaction?.AdjustmentType === 'REFUND' ? '-' : '+'} + {Math.abs((lastTransaction?.BeforeAdjustment ?? 0) - + (lastTransaction?.AfterAdjustment ?? 0)).toFixed(2)}
-
- - Net Bill Amount - - - {( - lastTransaction?.AfterAdjustment || - 0 - ).toFixed(2)} - +
+ Net Bill Amount + {(lastTransaction?.AfterAdjustment || 0).toFixed(2)}
)} {GlobaldummyData ? GlobalCredit && ( -
-
Advance Amount:
-
Opening Balance:
-
- ) +
+
Advance Amount:
+
Opening Balance:
+
+ ) : CreditDetails && - table2Data?.CustomerDetails?.length > - 0 && ( -
- {/* OLD CREDIT BAL */} - {PaymentStatusSuccess?.[0] - ?.PaymentTypeName === - 'Credit' && ( + table2Data?.CustomerDetails?.length > + 0 && ( +
+ {/* OLD CREDIT BAL */} + {PaymentStatusSuccess?.[0] + ?.PaymentTypeName === + 'Credit' && ( <> {table2Data.CustomerDetails[0] .OldCreditBal > 0 ? ( @@ -2189,8 +2075,8 @@ const PrintA4Style11 = ({ }

) : table2Data - .CustomerDetails[0] - .OldCreditBal < 0 ? ( + .CustomerDetails[0] + .OldCreditBal < 0 ? (

{' '} Opening Balance:{' '} @@ -2204,30 +2090,30 @@ const PrintA4Style11 = ({ )} - {/* CURRENT CREDIT BAL */} - {table2Data.CustomerDetails[0] - .CurrentCreditBal > 0 ? ( -

- {' '} - Current Advance Amount:{' '} - { - table2Data.CustomerDetails[0] - .CurrentCreditBal - } -

- ) : table2Data.CustomerDetails[0] - .CurrentCreditBal < 0 ? ( -

- {' '} - Current Balance Amount:{' '} - {Math.abs( - table2Data.CustomerDetails[0] - .CurrentCreditBal - )} -

- ) : null} -
- )} + {/* CURRENT CREDIT BAL */} + {table2Data.CustomerDetails[0] + .CurrentCreditBal > 0 ? ( +

+ {' '} + Current Advance Amount:{' '} + { + table2Data.CustomerDetails[0] + .CurrentCreditBal + } +

+ ) : table2Data.CustomerDetails[0] + .CurrentCreditBal < 0 ? ( +

+ {' '} + Current Balance Amount:{' '} + {Math.abs( + table2Data.CustomerDetails[0] + .CurrentCreditBal + )} +

+ ) : null} +
+ )}
{table2Data?.OrderType !== 'E' && @@ -2376,58 +2262,58 @@ const PrintA4Style11 = ({ {GlobaldummyData ? GlobalQrcodet && ( -
- -
- Scan to Pay{' '} -
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number( - table2Data?.NetAmount - ).toFixed(2)} -
+
+ +
+ Scan to Pay{' '}
- ) +
+ ₹ + {GlobaldummyData + ? '1,066' + : Number( + table2Data?.NetAmount + ).toFixed(2)} +
+
+ ) : Qrcodet && - paymentTypeUPI && ( -
- -
- Scan to Pay{' '} -
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number( - table2Data?.NetAmount - ).toFixed(2)} -
+ paymentTypeUPI && ( +
+ +
+ Scan to Pay{' '}
- )} +
+ ₹ + {GlobaldummyData + ? '1,066' + : Number( + table2Data?.NetAmount + ).toFixed(2)} +
+
+ )}
-

- Notes : 10 days Return policy -

+
+

+ Notes : 10 days Return policy +

-
-
- ) +
+
+ ) : Notestext && ( -
-

- {Notestext} -

+
+

+ {Notestext} +

-
-
- )} +
+
+ )}
{GlobaldummyData ? GlobaltermsAndConditions && ( -
+

-

- Terms & Conditions -

-
    -
  1. - Once goods are sold, they are - not exchangeable or refundable. -
  2. -
  3. - Please check the product before - leaving the counter. -
  4. -
-
- ) + Terms & Conditions +

+
    +
  1. + Once goods are sold, they are + not exchangeable or refundable. +
  2. +
  3. + Please check the product before + leaving the counter. +
  4. +
+
+ ) : TermsnAdCondition == true && - TermsAndConditions?.length > 0 && ( -
0 && ( +
+

-

- Terms & Conditions -

-
    - {TermsAndConditions?.map( - (item) => ( -
  1. - {item?.TermsandConditions} -
  2. - ) - )} - {/*
  3. Please check the product before leaving the counter.
  4. */} -
-
- )} + Terms & Conditions +

+
    + {TermsAndConditions?.map( + (item) => ( +
  1. + {item?.TermsandConditions} +
  2. + ) + )} + {/*
  3. Please check the product before leaving the counter.
  4. */} +
+
+ )} {GlobaldummyData ? GlobalSignature && ( -
+

-

- Signature -

- -
- ) + Signature +

+ +
+ ) : Signature == true && ( -
+

-

- Signature -

- -
- )} + Signature +

+ +
+ )}
)} @@ -2664,7 +2550,7 @@ const PrintA4Style11 = ({ )} - {PaymentStatusSuccess?.length > 1 && !isEditedBill && ( + {(PaymentStatusSuccess?.length > 1 && !isEditedBill) && ( <> {/*

Split Payment:

*/} {Object.keys(aggregatedPayments).map((paymentType) => ( @@ -2762,38 +2648,20 @@ const PrintA4Style11 = ({ {isEditedBill && lastTransaction && ( -
+
-
- - Bill Gross Amount - - - {(lastTransaction?.BeforeAdjustment || 0).toFixed( - 2 - )} - +
+ Bill Gross Amount + {(lastTransaction?.BeforeAdjustment || 0).toFixed(2)}
{'Adjustment Amount'} - {lastTransaction?.AdjustmentType === 'REFUND' - ? '-' - : '+'} - {Math.abs( - (lastTransaction?.BeforeAdjustment ?? 0) - - (lastTransaction?.AfterAdjustment ?? 0) - ).toFixed(2)} + {lastTransaction?.AdjustmentType === 'REFUND' ? '-' : '+'} + {Math.abs((lastTransaction?.BeforeAdjustment ?? 0) - + (lastTransaction?.AfterAdjustment ?? 0)).toFixed(2)}
-
- - Net Bill Amount - - - {(lastTransaction?.AfterAdjustment || 0).toFixed( - 2 - )} - +
+ Net Bill Amount + {(lastTransaction?.AfterAdjustment || 0).toFixed(2)}
)} {GlobaldummyData ? GlobalCredit && ( -
-
Advance Amount:
-
Opening Balance:
-
- ) +
+
Advance Amount:
+
Opening Balance:
+
+ ) : CreditDetails && - table2Data?.CustomerDetails?.length > 0 && ( -
- {/* OLD CREDIT BAL */} - {PaymentStatusSuccess?.[0]?.PaymentTypeName === - 'Credit' && ( + table2Data?.CustomerDetails?.length > 0 && ( +
+ {/* OLD CREDIT BAL */} + {PaymentStatusSuccess?.[0]?.PaymentTypeName === + 'Credit' && ( <> {table2Data.CustomerDetails[0].OldCreditBal > - 0 ? ( + 0 ? (

Advance Amount: {table2Data.CustomerDetails[0].OldCreditBal} @@ -2883,26 +2735,26 @@ const PrintA4Style11 = ({ )} - {/* CURRENT CREDIT BAL */} - {table2Data.CustomerDetails[0].CurrentCreditBal > + {/* CURRENT CREDIT BAL */} + {table2Data.CustomerDetails[0].CurrentCreditBal > 0 ? ( -

- {' '} - Current Advance Amount:{' '} - {table2Data.CustomerDetails[0].CurrentCreditBal} -

- ) : table2Data.CustomerDetails[0].CurrentCreditBal < - 0 ? ( -

- {' '} - Current Balance Amount:{' '} - {Math.abs( - table2Data.CustomerDetails[0].CurrentCreditBal - )} -

- ) : null} -
- )} +

+ {' '} + Current Advance Amount:{' '} + {table2Data.CustomerDetails[0].CurrentCreditBal} +

+ ) : table2Data.CustomerDetails[0].CurrentCreditBal < + 0 ? ( +

+ {' '} + Current Balance Amount:{' '} + {Math.abs( + table2Data.CustomerDetails[0].CurrentCreditBal + )} +

+ ) : null} +
+ )}
{table2Data?.OrderType !== 'E' && @@ -3009,54 +2861,54 @@ const PrintA4Style11 = ({ {GlobaldummyData ? GlobalQrcodet && ( -
- -
- Scan to Pay{' '} -
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number(table2Data?.NetAmount).toFixed(2)} -
+
+ +
+ Scan to Pay{' '}
- ) +
+ ₹ + {GlobaldummyData + ? '1,066' + : Number(table2Data?.NetAmount).toFixed(2)} +
+
+ ) : Qrcodet && - paymentTypeUPI && ( -
- -
- Scan to Pay{' '} -
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number(table2Data?.NetAmount).toFixed(2)} -
+ paymentTypeUPI && ( +
+ +
+ Scan to Pay{' '}
- )} +
+ ₹ + {GlobaldummyData + ? '1,066' + : Number(table2Data?.NetAmount).toFixed(2)} +
+
+ )}
-

- Notes : 10 days Return policy -

+
+

+ Notes : 10 days Return policy +

-
-
- ) +
+
+ ) : Notestext && ( -
-

- {Notestext} -

+
+

+ {Notestext} +

-
-
- )} +
+
+ )}
{GlobaldummyData ? GlobaltermsAndConditions && ( -
+

-

- Terms & Conditions -

-
    -
  1. - Once goods are sold, they are not exchangeable - or refundable. -
  2. -
  3. - Please check the product before leaving the - counter. -
  4. -
-
- ) + Terms & Conditions +

+
    +
  1. + Once goods are sold, they are not exchangeable + or refundable. +
  2. +
  3. + Please check the product before leaving the + counter. +
  4. +
+
+ ) : TermsnAdCondition == true && - TermsAndConditions?.length > 0 && ( -
0 && ( +
+

-

- Terms & Conditions -

-
    - {TermsAndConditions?.map((item) => ( -
  1. - {item?.TermsandConditions} -
  2. - ))} - {/*
  3. Please check the product before leaving the counter.
  4. */} -
-
- )} + Terms & Conditions +

+
    + {TermsAndConditions?.map((item) => ( +
  1. + {item?.TermsandConditions} +
  2. + ))} + {/*
  3. Please check the product before leaving the counter.
  4. */} +
+
+ )} {GlobaldummyData ? GlobalSignature && ( -
+

-

- Signature -

- -
- ) + Signature +

+ +
+ ) : Signature == true && ( -
+

-

- Signature -

- -
- )} + Signature +

+ +
+ )}
)} @@ -3363,36 +3215,20 @@ const PrintA4Style11 = ({ {isEditedBill && lastTransaction && ( -
+
-
- - Bill Gross Amount - - - {(lastTransaction?.BeforeAdjustment || 0).toFixed(2)} - +
+ Bill Gross Amount + {(lastTransaction?.BeforeAdjustment || 0).toFixed(2)}
{'Adjustment Amount'} - {lastTransaction?.AdjustmentType === 'REFUND' - ? '-' - : '+'} - {Math.abs( - (lastTransaction?.BeforeAdjustment ?? 0) - - (lastTransaction?.AfterAdjustment ?? 0) - ).toFixed(2)} + {lastTransaction?.AdjustmentType === 'REFUND' ? '-' : '+'} + {Math.abs((lastTransaction?.BeforeAdjustment ?? 0) - + (lastTransaction?.AfterAdjustment ?? 0)).toFixed(2)}
-
- - Net Bill Amount - - - {(lastTransaction?.AfterAdjustment || 0).toFixed(2)} - +
+ Net Bill Amount + {(lastTransaction?.AfterAdjustment || 0).toFixed(2)}
)} {GlobaldummyData ? GlobalCredit && ( -
-
Advance Amount:
-
Opening Balance:
-
- ) +
+
Advance Amount:
+
Opening Balance:
+
+ ) : CreditDetails && - table2Data?.CustomerDetails?.length > 0 && ( -
- {/* OLD CREDIT BAL */} - {PaymentStatusSuccess?.[0]?.PaymentTypeName === - 'Credit' && ( + table2Data?.CustomerDetails?.length > 0 && ( +
+ {/* OLD CREDIT BAL */} + {PaymentStatusSuccess?.[0]?.PaymentTypeName === + 'Credit' && ( <> {table2Data.CustomerDetails[0].OldCreditBal > 0 ? (

@@ -3479,25 +3301,25 @@ const PrintA4Style11 = ({ )} - {/* CURRENT CREDIT BAL */} - {table2Data.CustomerDetails[0].CurrentCreditBal > 0 ? ( -

- {' '} - Current Advance Amount:{' '} - {table2Data.CustomerDetails[0].CurrentCreditBal} -

- ) : table2Data.CustomerDetails[0].CurrentCreditBal < - 0 ? ( -

- {' '} - Current Balance Amount:{' '} - {Math.abs( - table2Data.CustomerDetails[0].CurrentCreditBal - )} -

- ) : null} -
- )} + {/* CURRENT CREDIT BAL */} + {table2Data.CustomerDetails[0].CurrentCreditBal > 0 ? ( +

+ {' '} + Current Advance Amount:{' '} + {table2Data.CustomerDetails[0].CurrentCreditBal} +

+ ) : table2Data.CustomerDetails[0].CurrentCreditBal < + 0 ? ( +

+ {' '} + Current Balance Amount:{' '} + {Math.abs( + table2Data.CustomerDetails[0].CurrentCreditBal + )} +

+ ) : null} +
+ )}
{table2Data?.OrderType !== 'E' && @@ -3592,50 +3414,50 @@ const PrintA4Style11 = ({ {GlobaldummyData ? GlobalQrcodet && ( -
- -
Scan to Pay
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number(table2Data?.NetAmount).toFixed(2)} -
+
+ +
Scan to Pay
+
+ ₹ + {GlobaldummyData + ? '1,066' + : Number(table2Data?.NetAmount).toFixed(2)}
- ) +
+ ) : Qrcodet && - paymentTypeUPI && ( -
- -
Scan to Pay
-
- ₹ - {GlobaldummyData - ? '1,066' - : Number(table2Data?.NetAmount).toFixed(2)} -
+ paymentTypeUPI && ( +
+ +
Scan to Pay
+
+ ₹ + {GlobaldummyData + ? '1,066' + : Number(table2Data?.NetAmount).toFixed(2)}
- )} +
+ )}
-

- Notes : 10 days Return policy -

+
+

+ Notes : 10 days Return policy +

-
-
- ) +
+
+ ) : Notestext && ( -
-

- {Notestext} -

+
+

+ {Notestext} +

-
-
- )} +
+
+ )}
{GlobaldummyData ? GlobaltermsAndConditions && ( -
+

-

- Terms & Conditions -

-
    -
  1. - Once goods are sold, they are not exchangeable or - refundable. -
  2. -
  3. - Please check the product before leaving the counter. -
  4. -
-
- ) + Terms & Conditions +

+
    +
  1. + Once goods are sold, they are not exchangeable or + refundable. +
  2. +
  3. + Please check the product before leaving the counter. +
  4. +
+
+ ) : TermsnAdCondition == true && - TermsAndConditions?.length > 0 && ( -
0 && ( +
+

-

- Terms & Conditions -

-
    - {TermsAndConditions?.map((item) => ( -
  1. - {item?.TermsandConditions} -
  2. - ))} - {/*
  3. Please check the product before leaving the counter.
  4. */} -
-
- )} + Terms & Conditions +

+
    + {TermsAndConditions?.map((item) => ( +
  1. + {item?.TermsandConditions} +
  2. + ))} + {/*
  3. Please check the product before leaving the counter.
  4. */} +
+
+ )} {GlobaldummyData ? GlobalSignature && ( -
+

-

- Signature -

- -
- ) + Signature +

+ +
+ ) : Signature == true && ( -
+

-

- Signature -

- -
- )} + Signature +

+ +
+ )}