Reviewed-on: Pozomind/pozo-retail-app#263
This commit is contained in:
commit
f564bd3d1b
|
|
@ -142,22 +142,28 @@ const BSImeiDetails = (props) => {
|
||||||
}, []);
|
}, []);
|
||||||
const AddDeviceDetails = () => {
|
const AddDeviceDetails = () => {
|
||||||
console.log(
|
console.log(
|
||||||
formRef?.current?.getFieldsValue,
|
SerialNumberList.length, IMEINumberList.length,"SerialNumberList, IMEINumberList"
|
||||||
'formRef?.current?.getFieldsValue'
|
|
||||||
);
|
);
|
||||||
const maxLength = Math.max(SerialNumberList.length, IMEINumberList.length);
|
const description = formRef.current?.getFieldsValue()?.description || '';
|
||||||
// Create the new object array
|
|
||||||
|
const maxLength = Math.max(
|
||||||
|
SerialNumberList.length,
|
||||||
|
IMEINumberList.length,
|
||||||
|
description ? 1 : 0
|
||||||
|
);
|
||||||
|
|
||||||
const IdentifyDetails = Array.from({ length: maxLength }, (_, index) => {
|
const IdentifyDetails = Array.from({ length: maxLength }, (_, index) => {
|
||||||
const serial = SerialNumberList[index] || ''; // Use serial number or default to empty
|
const serial = SerialNumberList[index] || '';
|
||||||
const imeiPair = IMEINumberList[index]
|
const imeiPair = IMEINumberList[index]
|
||||||
? IMEINumberList[index].split(',')
|
? IMEINumberList[index].split(',')
|
||||||
: ['', '']; // Split IMEI numbers or default to empty strings
|
: ['', ''];
|
||||||
|
|
||||||
return {
|
return {
|
||||||
SerialNumber: serial,
|
SerialNumber: serial,
|
||||||
IMEI1: imeiPair[0] || '', // First IMEI number
|
IMEI1: imeiPair[0] || '',
|
||||||
IMEI2: imeiPair[1] || '', // Second IMEI number
|
IMEI2: imeiPair[1] || '',
|
||||||
MacId: '', // Default empty macid
|
MacId: '',
|
||||||
Description: formRef.current?.getFieldsValue()?.description || '',
|
Description: description || '',
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
console.log(IdentifyDetails, 'IdentifyDetails');
|
console.log(IdentifyDetails, 'IdentifyDetails');
|
||||||
|
|
@ -410,10 +416,10 @@ const BSImeiDetails = (props) => {
|
||||||
<div style={{ display: 'flex', marginTop: '10px' }}>
|
<div style={{ display: 'flex', marginTop: '10px' }}>
|
||||||
<Form.Item name="description">
|
<Form.Item name="description">
|
||||||
<TextAreaInput
|
<TextAreaInput
|
||||||
disabled={
|
// disabled={
|
||||||
IMEINumberList?.length === 0 &&
|
// IMEINumberList?.length === 0 &&
|
||||||
SerialNumberList?.length === 0
|
// SerialNumberList?.length === 0
|
||||||
}
|
// }
|
||||||
autoComplete="off"
|
autoComplete="off"
|
||||||
label={<label>Description..</label>}
|
label={<label>Description..</label>}
|
||||||
defaultValue=""
|
defaultValue=""
|
||||||
|
|
|
||||||
|
|
@ -4422,7 +4422,7 @@ const BSC1Payment = (props) => {
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && BSComboData?.BookingBilling?.[1]?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
|
|
|
||||||
|
|
@ -1061,12 +1061,10 @@ const InvoiceTemplate = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName +
|
: ' Bill')}
|
||||||
' Bill'
|
|
||||||
: ''}
|
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -2861,11 +2859,10 @@ const InvoiceTemplate = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}
|
: ' Bill')}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -522,11 +522,10 @@ const PrintA4Style11 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}
|
: ' Bill')}
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
|
|
@ -874,14 +873,13 @@ const PrintA4Style11 = ({
|
||||||
})}
|
})}
|
||||||
|
|
||||||
{/* Description */}
|
{/* Description */}
|
||||||
{item?.ProductIdentifierDtls?.map((id, index) => (
|
{
|
||||||
(id?.SerialNumber || id?.IMEI1 || id?.IMEI2) &&
|
|
||||||
id?.Description && (
|
id?.Description && (
|
||||||
<div key={`desc-${index}`}>
|
<div key={`desc-${index}`}>
|
||||||
{id.Description}
|
{id.Description}
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
))}
|
}
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -517,11 +517,10 @@ const PrintA5Style11 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}
|
: ' Bill')}
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
|
|
@ -847,7 +846,7 @@ const PrintA5Style11 = ({
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* Description */}
|
{/* Description */}
|
||||||
{(id?.SerialNumber || id?.IMEI1 || id?.IMEI2) &&
|
{
|
||||||
id?.Description && (
|
id?.Description && (
|
||||||
<div>{id.Description}</div>
|
<div>{id.Description}</div>
|
||||||
)}
|
)}
|
||||||
|
|
|
||||||
|
|
@ -944,11 +944,11 @@ const TaxInvoice = ({
|
||||||
|
|
||||||
{/* Description outside */}
|
{/* Description outside */}
|
||||||
{item?.ProductIdentifierDtls
|
{item?.ProductIdentifierDtls
|
||||||
?.find(d => d?.Description)
|
?.[0]
|
||||||
?.Description && (
|
?.Description && (
|
||||||
<div style={{ marginTop: "3px", wordBreak: "break-word" }}>
|
<div style={{ marginTop: "3px", wordBreak: "break-word" }}>
|
||||||
{item?.ProductIdentifierDtls
|
{item?.ProductIdentifierDtls
|
||||||
?.find(d => d?.Description)
|
?.[0]
|
||||||
?.Description}
|
?.Description}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
|
||||||
|
|
@ -597,12 +597,10 @@ const PrintStyle1 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName +
|
: ' Bill')}
|
||||||
' Bill'
|
|
||||||
: ''}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode})`} */}
|
`(${table2Data?.SalesMode})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -922,15 +920,9 @@ const PrintStyle1 = ({
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
{item?.ProductIdentifierDtls?.length > 0 &&
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
item?.ProductIdentifierDtls.find(
|
(
|
||||||
(items) =>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>{item.ProductIdentifierDtls.find(
|
|
||||||
(items) =>
|
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
@ -3911,11 +3903,10 @@ const PrintStyle1 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}
|
: ' Bill')}
|
||||||
{SalesModePref?.SettingValue == 'Y' &&
|
{SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode})`}
|
`(${table2Data?.SalesMode})`}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -4185,15 +4176,9 @@ const PrintStyle1 = ({
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
{item?.ProductIdentifierDtls?.length > 0 &&
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
item?.ProductIdentifierDtls.find(
|
(
|
||||||
(items) =>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>{item.ProductIdentifierDtls.find(
|
|
||||||
(items) =>
|
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
|
|
||||||
|
|
@ -550,11 +550,10 @@ const PrintStyle10 = ({
|
||||||
<div style={{ textTransform: 'uppercase' }}>
|
<div style={{ textTransform: 'uppercase' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -818,8 +817,8 @@ const PrintStyle10 = ({
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -840,8 +839,8 @@ const PrintStyle10 = ({
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3195,11 +3194,10 @@ const PrintStyle10 = ({
|
||||||
<div style={{ textTransform: 'uppercase' }}>
|
<div style={{ textTransform: 'uppercase' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3404,8 +3402,8 @@ const PrintStyle10 = ({
|
||||||
{(id.IMEI1 || id.IMEI2) && <div>{[id.IMEI1, id.IMEI2].filter(Boolean).join(', ')}</div>}
|
{(id.IMEI1 || id.IMEI2) && <div>{[id.IMEI1, id.IMEI2].filter(Boolean).join(', ')}</div>}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
) : (
|
) : (
|
||||||
|
|
@ -3450,8 +3448,8 @@ const PrintStyle10 = ({
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -538,11 +538,10 @@ const PrintStyle11 = ({
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'CASH'
|
? 'CASH'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode})`} */}
|
`(${table2Data?.SalesMode})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -791,8 +790,8 @@ const PrintStyle11 = ({
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -824,8 +823,8 @@ const PrintStyle11 = ({
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
</div>
|
</div>
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3191,11 +3190,10 @@ const PrintStyle11 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode})`} */}
|
`(${table2Data?.SalesMode})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3399,8 +3397,8 @@ const PrintStyle11 = ({
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
) : (
|
) : (
|
||||||
|
|
@ -3460,8 +3458,8 @@ const PrintStyle11 = ({
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -663,12 +663,10 @@ const Printstyle12 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName +
|
: ' Bill')}
|
||||||
' Bill'
|
|
||||||
: ''}
|
|
||||||
</div>
|
</div>
|
||||||
<div style={{ fontSize: 'clamp(0.75rem, 2.5vw, 1rem)' }}>
|
<div style={{ fontSize: 'clamp(0.75rem, 2.5vw, 1rem)' }}>
|
||||||
{' '}
|
{' '}
|
||||||
|
|
@ -944,8 +942,8 @@ const Printstyle12 = ({
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3658,8 +3656,8 @@ const Printstyle12 = ({
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -562,11 +562,10 @@ const Printstyle2 = ({
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
Bill{' '}
|
Bill{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`}{' '} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`}{' '} */}
|
||||||
|
|
@ -853,15 +852,9 @@ const Printstyle2 = ({
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
{item?.ProductIdentifierDtls?.length > 0 &&
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
item?.ProductIdentifierDtls.find(
|
(
|
||||||
(items) =>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>{item.ProductIdentifierDtls.find(
|
|
||||||
(items) =>
|
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
@ -3235,11 +3228,10 @@ const Printstyle2 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`}{' '} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`}{' '} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3467,15 +3459,9 @@ const Printstyle2 = ({
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
{item?.ProductIdentifierDtls?.length > 0 &&
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
item?.ProductIdentifierDtls.find(
|
(
|
||||||
(items) =>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>{item.ProductIdentifierDtls.find(
|
|
||||||
(items) =>
|
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -310,7 +310,11 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{table2Data?.OrderType === "E" && estimateTitle && <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>Estimate Bill
|
{table2Data?.OrderType === "E" && estimateTitle && <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>Estimate Bill
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>}
|
</div>}
|
||||||
{table2Data?.OrderType === "E" ? "" : <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>{GlobaldummyData ? 'Cash Bill' : BillName ? BillName : PaymentStatusSuccess?.length === 1 ? PaymentStatusSuccess?.[0]?.PaymentTypeName : ""}
|
{table2Data?.OrderType === "E" ? "" : <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>
|
||||||
|
{GlobaldummyData ? 'Cash Bill' : BillName ||
|
||||||
|
(PaymentStatusSuccess?.length === 1
|
||||||
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
|
: ' Bill')}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -411,15 +415,9 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
{item?.ProductIdentifierDtls?.length > 0 &&
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
item?.ProductIdentifierDtls.find(
|
(
|
||||||
(items) =>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>{item.ProductIdentifierDtls.find(
|
|
||||||
(items) =>
|
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1300,7 +1298,11 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{table2Data?.OrderType === "E" && estimateTitle && <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>Estimate Bill
|
{table2Data?.OrderType === "E" && estimateTitle && <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>Estimate Bill
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>}
|
</div>}
|
||||||
{table2Data?.OrderType === "E" ? "" : <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>{GlobaldummyData ? GlobalBilltext ? GlobalBilltext : "Cash" + ' Bill' : BillName ? BillName : PaymentStatusSuccess?.length === 1 ? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill' : ""}
|
{table2Data?.OrderType === "E" ? "" : <div style={{ fontSize: "14px", margin: "2px 0 0 0", padding: 0, fontWeight: 600 }}>
|
||||||
|
{GlobaldummyData ? GlobalBilltext ? GlobalBilltext : "Cash" + ' Bill' : BillName ||
|
||||||
|
(PaymentStatusSuccess?.length === 1
|
||||||
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
|
: 'Bill')}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
{/* {SalesModePref?.SettingValue == 'Y' && `(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1395,15 +1397,9 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
);
|
);
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
{item?.ProductIdentifierDtls?.length > 0 &&
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
item?.ProductIdentifierDtls.find(
|
(
|
||||||
(items) =>
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<span>{item.ProductIdentifierDtls.find(
|
|
||||||
(items) =>
|
|
||||||
items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}</span>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -112,16 +112,26 @@ const Printstyle4 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
const SelectedHeaderFontColor = useSelector(GlobalSelectedPrintHeaderFontColor);
|
const SelectedHeaderFontColor = useSelector(
|
||||||
|
GlobalSelectedPrintHeaderFontColor
|
||||||
|
);
|
||||||
const SelectedTableHeaderColor = useSelector(GlobalSelectedTableHeaderColor);
|
const SelectedTableHeaderColor = useSelector(GlobalSelectedTableHeaderColor);
|
||||||
const SelectedTableHeaderFontColor = useSelector(GlobalSelectedTableHeaderFontColor);
|
const SelectedTableHeaderFontColor = useSelector(
|
||||||
|
GlobalSelectedTableHeaderFontColor
|
||||||
|
);
|
||||||
const SelectedTableBodyColor = useSelector(GlobalSelectedTableBodyColor);
|
const SelectedTableBodyColor = useSelector(GlobalSelectedTableBodyColor);
|
||||||
const SelectedTableBodyFontColor = useSelector(GlobalSelectedTableBodyFontColor);
|
const SelectedTableBodyFontColor = useSelector(
|
||||||
|
GlobalSelectedTableBodyFontColor
|
||||||
|
);
|
||||||
const SelectedRowType = useSelector(GlobalRowType);
|
const SelectedRowType = useSelector(GlobalRowType);
|
||||||
const SelectedTableFooterColor = useSelector(GlobalSelectedFooterColor);
|
const SelectedTableFooterColor = useSelector(GlobalSelectedFooterColor);
|
||||||
const SelectedTableFooterFontColor = useSelector(GlobalSelectedFooterFontColor);
|
const SelectedTableFooterFontColor = useSelector(
|
||||||
|
GlobalSelectedFooterFontColor
|
||||||
|
);
|
||||||
const SelectedNetAmountColor = useSelector(GlobalSelectedNetAmountColor);
|
const SelectedNetAmountColor = useSelector(GlobalSelectedNetAmountColor);
|
||||||
const SelectedNetAmountFontColor = useSelector(GlobalSelectedNetAmountFontColor);
|
const SelectedNetAmountFontColor = useSelector(
|
||||||
|
GlobalSelectedNetAmountFontColor
|
||||||
|
);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
|
@ -172,11 +182,15 @@ const Printstyle4 = ({
|
||||||
);
|
);
|
||||||
|
|
||||||
let printColors = printDatas?.PrintColors;
|
let printColors = printDatas?.PrintColors;
|
||||||
const headerColor = printColors?.find(obj => obj.headerColor)?.headerColor;
|
const headerColor = printColors?.find((obj) => obj.headerColor)?.headerColor;
|
||||||
const tableHeaderColor = printColors?.find(obj => obj.tableHeaderColor)?.tableHeaderColor;
|
const tableHeaderColor = printColors?.find(
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
(obj) => obj.tableHeaderColor
|
||||||
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
)?.tableHeaderColor;
|
||||||
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
const tableBodyColor = printColors?.find(
|
||||||
|
(obj) => obj.tableBodyColor
|
||||||
|
)?.tableBodyColor;
|
||||||
|
const footerColor = printColors?.find((obj) => obj.footerColor)?.footerColor;
|
||||||
|
const netAmtColor = printColors?.find((obj) => obj.netAmtColor)?.netAmtColor;
|
||||||
|
|
||||||
let TermsAndConditions = printDatas?.TermsandConditions;
|
let TermsAndConditions = printDatas?.TermsandConditions;
|
||||||
let SignatureImg = printDatas?.Signature;
|
let SignatureImg = printDatas?.Signature;
|
||||||
|
|
@ -366,7 +380,7 @@ const Printstyle4 = ({
|
||||||
} else if (DineInData?.length > 0) {
|
} else if (DineInData?.length > 0) {
|
||||||
dataSource = DineInData;
|
dataSource = DineInData;
|
||||||
}
|
}
|
||||||
|
console.log(dataSource, 'dataSource');
|
||||||
// Paginate the data
|
// Paginate the data
|
||||||
const paginatedChunks = [];
|
const paginatedChunks = [];
|
||||||
for (let i = 0; i < dataSource.length; i += chunkSize) {
|
for (let i = 0; i < dataSource.length; i += chunkSize) {
|
||||||
|
|
@ -378,16 +392,14 @@ const Printstyle4 = ({
|
||||||
: 0;
|
: 0;
|
||||||
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 10);
|
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 10);
|
||||||
|
|
||||||
console.log(paginatedChunks, 'paginatedChunks')
|
console.log(paginatedChunks, 'paginatedChunks');
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData ? SelectedHeaderFontColor : headerColor?.font,
|
||||||
? SelectedHeaderFontColor
|
};
|
||||||
: headerColor?.font,
|
|
||||||
}
|
|
||||||
const tableHeaderStyle = {
|
const tableHeaderStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedTableHeaderColor
|
? SelectedTableHeaderColor
|
||||||
|
|
@ -396,34 +408,30 @@ const Printstyle4 = ({
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData
|
||||||
? SelectedTableHeaderFontColor
|
? SelectedTableHeaderFontColor
|
||||||
: tableHeaderColor?.font,
|
: tableHeaderColor?.font,
|
||||||
}
|
};
|
||||||
const tableBodyStyle = {
|
const tableBodyStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedTableBodyColor
|
? SelectedTableBodyColor
|
||||||
: tableBodyColor?.background,
|
: tableBodyColor?.background,
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData ? SelectedTableBodyFontColor : tableBodyColor?.font,
|
||||||
? SelectedTableBodyFontColor
|
};
|
||||||
: tableBodyColor?.font,
|
const rowtypeStyle = GlobaldummyData
|
||||||
}
|
? SelectedRowType
|
||||||
const rowtypeStyle = GlobaldummyData ? SelectedRowType : tableBodyColor?.rowType;
|
: tableBodyColor?.rowType;
|
||||||
const footerColorStyle = {
|
const footerColorStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedTableFooterColor
|
? SelectedTableFooterColor
|
||||||
: footerColor?.background,
|
: footerColor?.background,
|
||||||
|
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData ? SelectedTableFooterFontColor : footerColor?.font,
|
||||||
? SelectedTableFooterFontColor
|
};
|
||||||
: footerColor?.font,
|
|
||||||
}
|
|
||||||
const netAmountStyle = {
|
const netAmountStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedNetAmountColor
|
? SelectedNetAmountColor
|
||||||
: netAmtColor?.background,
|
: netAmtColor?.background,
|
||||||
|
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData ? SelectedNetAmountFontColor : netAmtColor?.font,
|
||||||
? SelectedNetAmountFontColor
|
};
|
||||||
: netAmtColor?.font,
|
|
||||||
}
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
{FormatTheme ? (
|
{FormatTheme ? (
|
||||||
|
|
@ -567,11 +575,15 @@ const Printstyle4 = ({
|
||||||
>
|
>
|
||||||
<div style={{ fontSize: '12px', fontWeight: '500' }}>
|
<div style={{ fontSize: '12px', fontWeight: '500' }}>
|
||||||
Dt: {GlobaldummyData ? formattedDate : Date1}
|
Dt: {GlobaldummyData ? formattedDate : Date1}
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
{SalesModePref?.SettingValue == 'Y' && (
|
||||||
|
<div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
Name :{' '}
|
||||||
|
{table2Data?.SalesMode == 'R'
|
||||||
</div>}
|
? Retailshortname?.Comments
|
||||||
|
: Wholesaleshortname?.Comments}{' '}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div style={{ fontSize: '12px', fontWeight: '500' }}>
|
<div style={{ fontSize: '12px', fontWeight: '500' }}>
|
||||||
|
|
@ -607,11 +619,10 @@ const Printstyle4 = ({
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash Bill'
|
? 'Cash Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -646,12 +657,32 @@ const Printstyle4 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px' }}>#</th>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
#
|
||||||
|
</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>#</th>}
|
: SLNO && (
|
||||||
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
#
|
||||||
|
</th>
|
||||||
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Item</th>
|
? GlobalItem && (
|
||||||
: Item && <th style={{ ...tableHeaderStyle, }}>Item</th>}
|
<th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
|
)
|
||||||
|
: Item && (
|
||||||
|
<th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
|
|
@ -728,6 +759,7 @@ const Printstyle4 = ({
|
||||||
...tableHeaderStyle,
|
...tableHeaderStyle,
|
||||||
width: '10px',
|
width: '10px',
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
|
marginRight: '4px',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
|
|
@ -739,6 +771,7 @@ const Printstyle4 = ({
|
||||||
...tableHeaderStyle,
|
...tableHeaderStyle,
|
||||||
width: '30px',
|
width: '30px',
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
|
marginRight: '4px',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
|
|
@ -810,26 +843,27 @@ const Printstyle4 = ({
|
||||||
const descriptions = identifiers
|
const descriptions = identifiers
|
||||||
.filter((d) => d.Description)
|
.filter((d) => d.Description)
|
||||||
.map((d) => d.Description);
|
.map((d) => d.Description);
|
||||||
|
console.log(descriptions,identifiers,'descriptions')
|
||||||
const packageList =
|
const packageList =
|
||||||
PackageDetails?.filter(
|
PackageDetails?.filter(
|
||||||
(pkg) => pkg.ProdId === item.ProdId
|
(pkg) => pkg.ProdId === item.ProdId
|
||||||
) ?? [];
|
) ?? [];
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<tr key={index}
|
<tr
|
||||||
|
key={index}
|
||||||
style={
|
style={
|
||||||
index % 2 !== 1 && rowtypeStyle === "even"
|
index % 2 !== 1 && rowtypeStyle === 'even'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: index % 2 === 1 && rowtypeStyle === 'odd'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: {}
|
: {}
|
||||||
}>
|
}
|
||||||
|
>
|
||||||
{/* SL NO */}
|
{/* SL NO */}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
|
|
@ -928,8 +962,10 @@ const Printstyle4 = ({
|
||||||
: Discount) && (
|
: Discount) && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
? item?.OfferAmt || item?.DiscountAmt || 0
|
||||||
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
: item?.OfferValue ||
|
||||||
|
item?.DiscountAmt ||
|
||||||
|
0}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
@ -976,12 +1012,32 @@ const Printstyle4 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px' }}>#</th>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
#
|
||||||
|
</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>#</th>}
|
: SLNO && (
|
||||||
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
#
|
||||||
|
</th>
|
||||||
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Item</th>
|
? GlobalItem && (
|
||||||
: Item && <th style={{ ...tableHeaderStyle, }}>Item</th>}
|
<th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
|
)
|
||||||
|
: Item && (
|
||||||
|
<th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
|
|
@ -1125,18 +1181,20 @@ const Printstyle4 = ({
|
||||||
<tbody>
|
<tbody>
|
||||||
{dataChunk?.map((item, index) => {
|
{dataChunk?.map((item, index) => {
|
||||||
return (
|
return (
|
||||||
<tr key={index}
|
<tr
|
||||||
|
key={index}
|
||||||
style={
|
style={
|
||||||
index % 2 !== 1 && rowtypeStyle === "even"
|
index % 2 !== 1 && rowtypeStyle === 'even'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: index % 2 === 1 && rowtypeStyle === 'odd'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: {}
|
: {}
|
||||||
}>
|
}
|
||||||
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && (
|
: SLNO && (
|
||||||
|
|
@ -1211,8 +1269,12 @@ const Printstyle4 = ({
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
? item?.OfferAmt ||
|
||||||
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
item?.DiscountAmt ||
|
||||||
|
0
|
||||||
|
: item?.OfferValue ||
|
||||||
|
item?.DiscountAmt ||
|
||||||
|
0}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1248,8 +1310,10 @@ const Printstyle4 = ({
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - (item?.OfferAmt || 0)
|
? item?.TotalAmt -
|
||||||
: item?.TotalAmt - (item?.OfferValue || 0)}
|
(item?.OfferAmt || 0)
|
||||||
|
: item?.TotalAmt -
|
||||||
|
(item?.OfferValue || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1291,7 +1355,7 @@ const Printstyle4 = ({
|
||||||
borderBottom: '1px dashed #000',
|
borderBottom: '1px dashed #000',
|
||||||
borderTop: '1px dashed #000',
|
borderTop: '1px dashed #000',
|
||||||
padding: '5px 0',
|
padding: '5px 0',
|
||||||
...netAmountStyle
|
...netAmountStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
|
|
@ -1422,7 +1486,6 @@ const Printstyle4 = ({
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
borderTop: '1px dashed #000',
|
borderTop: '1px dashed #000',
|
||||||
borderBottom: '1px dashed #000',
|
borderBottom: '1px dashed #000',
|
||||||
// color: '#e30c0c',
|
|
||||||
color: '#000',
|
color: '#000',
|
||||||
marginTop: '10px',
|
marginTop: '10px',
|
||||||
padding: '4px 0',
|
padding: '4px 0',
|
||||||
|
|
@ -2042,7 +2105,7 @@ const Printstyle4 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
|
|
@ -2283,7 +2346,7 @@ const Printstyle4 = ({
|
||||||
borderBottom: '1px dashed #000',
|
borderBottom: '1px dashed #000',
|
||||||
borderTop: '1px dashed #000',
|
borderTop: '1px dashed #000',
|
||||||
padding: '5px 0',
|
padding: '5px 0',
|
||||||
...netAmountStyle
|
...netAmountStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div>Sub Total</div>
|
<div>Sub Total</div>
|
||||||
|
|
@ -3019,7 +3082,7 @@ const Printstyle4 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
|
|
@ -3260,7 +3323,6 @@ const Printstyle4 = ({
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
width: '100%',
|
width: '100%',
|
||||||
textAlign: 'center',
|
textAlign: 'center',
|
||||||
// color: '#e30c0c',
|
|
||||||
color: '#000',
|
color: '#000',
|
||||||
lineHeight: '1',
|
lineHeight: '1',
|
||||||
letterSpacing: '-0.5px',
|
letterSpacing: '-0.5px',
|
||||||
|
|
@ -3321,11 +3383,15 @@ const Printstyle4 = ({
|
||||||
>
|
>
|
||||||
<div>
|
<div>
|
||||||
Dt: {GlobaldummyData ? formattedDate : Date1}
|
Dt: {GlobaldummyData ? formattedDate : Date1}
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
{SalesModePref?.SettingValue == 'Y' && (
|
||||||
|
<div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
Name :{' '}
|
||||||
|
{table2Data?.SalesMode == 'R'
|
||||||
</div>}
|
? Retailshortname?.Comments
|
||||||
|
: Wholesaleshortname?.Comments}{' '}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
|
|
@ -3362,11 +3428,10 @@ const Printstyle4 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3394,52 +3459,110 @@ const Printstyle4 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '10px' }}>#</th>
|
? GlobalSlNo && (
|
||||||
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>#</th>}
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
|
#
|
||||||
|
</th>
|
||||||
|
)
|
||||||
|
: SLNO && (
|
||||||
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
|
#
|
||||||
|
</th>
|
||||||
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Item</th>
|
? GlobalItem && (
|
||||||
: Item && <th style={{ ...tableHeaderStyle, }}>Item</th>}
|
<th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
|
)
|
||||||
|
: Item && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '30px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '30px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '30px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '30px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
textAlign: 'center',
|
||||||
|
}}
|
||||||
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '30px', textAlign: 'center' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '30px',
|
||||||
|
textAlign: 'center',
|
||||||
|
}}
|
||||||
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '25px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '25px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3467,23 +3590,47 @@ const Printstyle4 = ({
|
||||||
)} */}
|
)} */}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th
|
||||||
Amt
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '10px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '30px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '30px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{ ...tableHeaderStyle, width: '30px', textAlign: 'right' }}>
|
<th
|
||||||
|
style={{
|
||||||
|
...tableHeaderStyle,
|
||||||
|
width: '30px',
|
||||||
|
textAlign: 'right',
|
||||||
|
}}
|
||||||
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3493,18 +3640,20 @@ const Printstyle4 = ({
|
||||||
{(GlobaldummyData ? products : TakeawayData)?.map(
|
{(GlobaldummyData ? products : TakeawayData)?.map(
|
||||||
(item, index) => {
|
(item, index) => {
|
||||||
return (
|
return (
|
||||||
<tr key={index}
|
<tr
|
||||||
|
key={index}
|
||||||
style={
|
style={
|
||||||
index % 2 !== 1 && rowtypeStyle === "even"
|
index % 2 !== 1 && rowtypeStyle === 'even'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: index % 2 === 1 && rowtypeStyle === 'odd'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: {}
|
: {}
|
||||||
}>
|
}
|
||||||
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && <td>{index + 1}</td>}
|
: SLNO && <td>{index + 1}</td>}
|
||||||
|
|
@ -3540,20 +3689,9 @@ const Printstyle4 = ({
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{/* Description from first identifier */}
|
{/* Description from first identifier */}
|
||||||
{item?.ProductIdentifierDtls?.find(
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
(d) =>
|
(
|
||||||
d.SerialNumber || d.IMEI1 || d.IMEI2
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
)?.Description && (
|
|
||||||
<div>
|
|
||||||
{
|
|
||||||
item.ProductIdentifierDtls.find(
|
|
||||||
(d) =>
|
|
||||||
d.SerialNumber ||
|
|
||||||
d.IMEI1 ||
|
|
||||||
d.IMEI2
|
|
||||||
).Description
|
|
||||||
}
|
|
||||||
</div>
|
|
||||||
)}
|
)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3599,22 +3737,9 @@ const Printstyle4 = ({
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{/* Description from first identifier */}
|
{/* Description from first identifier */}
|
||||||
{item?.ProductIdentifierDtls?.find(
|
{(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
(d) =>
|
(
|
||||||
d.SerialNumber ||
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
d.IMEI1 ||
|
|
||||||
d.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>
|
|
||||||
{
|
|
||||||
item.ProductIdentifierDtls.find(
|
|
||||||
(d) =>
|
|
||||||
d.SerialNumber ||
|
|
||||||
d.IMEI1 ||
|
|
||||||
d.IMEI2
|
|
||||||
).Description
|
|
||||||
}
|
|
||||||
</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
) : (
|
) : (
|
||||||
|
|
@ -3677,7 +3802,6 @@ const Printstyle4 = ({
|
||||||
fontSize: '10px',
|
fontSize: '10px',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{/* <span style={{ color: '#e30c0c' }}> */}
|
|
||||||
<span
|
<span
|
||||||
style={{
|
style={{
|
||||||
color: '#000',
|
color: '#000',
|
||||||
|
|
@ -3721,8 +3845,10 @@ const Printstyle4 = ({
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
? item?.OfferAmt || item?.DiscountAmt || 0
|
||||||
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
: item?.OfferValue ||
|
||||||
|
item?.DiscountAmt ||
|
||||||
|
0}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
@ -3748,7 +3874,8 @@ const Printstyle4 = ({
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - (item?.OfferAmt || 0)
|
? item?.TotalAmt - (item?.OfferAmt || 0)
|
||||||
: item?.TotalAmt - (item?.OfferValue || 0)}
|
: item?.TotalAmt -
|
||||||
|
(item?.OfferValue || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3877,18 +4004,20 @@ const Printstyle4 = ({
|
||||||
{(GlobaldummyData ? products : DineInData)?.map(
|
{(GlobaldummyData ? products : DineInData)?.map(
|
||||||
(item, index) => {
|
(item, index) => {
|
||||||
return (
|
return (
|
||||||
<tr key={index}
|
<tr
|
||||||
|
key={index}
|
||||||
style={
|
style={
|
||||||
index % 2 !== 1 && rowtypeStyle === "even"
|
index % 2 !== 1 && rowtypeStyle === 'even'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: index % 2 === 1 && rowtypeStyle === 'odd'
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle,
|
||||||
}
|
}
|
||||||
: {}
|
: {}
|
||||||
}>
|
}
|
||||||
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && <td>{index + 1}</td>}
|
: SLNO && <td>{index + 1}</td>}
|
||||||
|
|
@ -3924,22 +4053,10 @@ const Printstyle4 = ({
|
||||||
})
|
})
|
||||||
.join('')
|
.join('')
|
||||||
: '') +
|
: '') +
|
||||||
(item?.ProductIdentifierDtls?.length >
|
(item?.ProductIdentifierDtls?.length > 0 && item.ProductIdentifierDtls?.[0]?.Description)&&
|
||||||
0 &&
|
(
|
||||||
item?.ProductIdentifierDtls.find(
|
<div>{item.ProductIdentifierDtls?.[0]?.Description}</div>
|
||||||
(item1) =>
|
)
|
||||||
item1.IMEI1 ||
|
|
||||||
item1.IMEI2 ||
|
|
||||||
item1.SerialNumber
|
|
||||||
)?.Description
|
|
||||||
? ` ${item.ProductIdentifierDtls.find(
|
|
||||||
(item1) =>
|
|
||||||
item1.IMEI1 ||
|
|
||||||
item1.IMEI2 ||
|
|
||||||
item1.SerialNumber
|
|
||||||
).Description
|
|
||||||
}`
|
|
||||||
: '')
|
|
||||||
).trim()}
|
).trim()}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
@ -4007,8 +4124,10 @@ const Printstyle4 = ({
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
? item?.OfferAmt || item?.DiscountAmt || 0
|
||||||
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
: item?.OfferValue ||
|
||||||
|
item?.DiscountAmt ||
|
||||||
|
0}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -4045,7 +4164,8 @@ const Printstyle4 = ({
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type !== 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - (item?.OfferAmt || 0)
|
? item?.TotalAmt - (item?.OfferAmt || 0)
|
||||||
: item?.TotalAmt - (item?.OfferValue || 0)}
|
: item?.TotalAmt -
|
||||||
|
(item?.OfferValue || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -4080,7 +4200,7 @@ const Printstyle4 = ({
|
||||||
borderBottom: '1px dashed #000',
|
borderBottom: '1px dashed #000',
|
||||||
borderTop: '1px dashed #000',
|
borderTop: '1px dashed #000',
|
||||||
padding: '5px 0',
|
padding: '5px 0',
|
||||||
...netAmountStyle
|
...netAmountStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div>Sub Total</div>
|
<div>Sub Total</div>
|
||||||
|
|
@ -4197,7 +4317,6 @@ const Printstyle4 = ({
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
borderTop: '1px dashed #000',
|
borderTop: '1px dashed #000',
|
||||||
borderBottom: '1px dashed #000',
|
borderBottom: '1px dashed #000',
|
||||||
// color: '#e30c0c',
|
|
||||||
color: '#000',
|
color: '#000',
|
||||||
marginTop: '10px',
|
marginTop: '10px',
|
||||||
padding: '4px 0',
|
padding: '4px 0',
|
||||||
|
|
@ -4205,7 +4324,7 @@ const Printstyle4 = ({
|
||||||
>
|
>
|
||||||
<div>Total Amount</div>
|
<div>Total Amount</div>
|
||||||
<div>
|
<div>
|
||||||
<span style={{ fontFamily: 'Inter' }}>
|
<span style={{ fontFamily: 'Poppins' }}>
|
||||||
₹
|
₹
|
||||||
</span>
|
</span>
|
||||||
{Number(table2Data?.NetAmount).toFixed(2)}
|
{Number(table2Data?.NetAmount).toFixed(2)}
|
||||||
|
|
@ -4771,7 +4890,7 @@ const Printstyle4 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
|
|
|
||||||
|
|
@ -523,11 +523,10 @@ const PrintStyle5 = ({
|
||||||
<div style={{ textTransform: 'uppercase' }}>
|
<div style={{ textTransform: 'uppercase' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -825,8 +824,8 @@ const PrintStyle5 = ({
|
||||||
})}
|
})}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* 🔢 Quantity */}
|
{/* 🔢 Quantity */}
|
||||||
|
|
@ -876,8 +875,8 @@ const PrintStyle5 = ({
|
||||||
})}
|
})}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* 🔢 Quantity */}
|
{/* 🔢 Quantity */}
|
||||||
|
|
@ -2870,11 +2869,10 @@ const PrintStyle5 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3161,12 +3159,10 @@ const PrintStyle5 = ({
|
||||||
})}
|
})}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* 🧪 Debug / Extra Text */}
|
|
||||||
<div>ssd3</div>
|
|
||||||
|
|
||||||
{/* 🔢 Quantity */}
|
{/* 🔢 Quantity */}
|
||||||
<div>
|
<div>
|
||||||
|
|
@ -3216,12 +3212,10 @@ const PrintStyle5 = ({
|
||||||
})}
|
})}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* 🧪 Debug / Extra Text */}
|
|
||||||
<div>ssd4</div>
|
|
||||||
|
|
||||||
{/* 🔢 Quantity */}
|
{/* 🔢 Quantity */}
|
||||||
<div>
|
<div>
|
||||||
|
|
|
||||||
|
|
@ -916,9 +916,9 @@ const Printstyle6 = ({
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>
|
<div>
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
@ -1304,9 +1304,9 @@ const Printstyle6 = ({
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.IMEI1 || d.IMEI2 || d.SerialNumber)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>
|
<div>
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.IMEI1 || d.IMEI2 || d.SerialNumber).Description}
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
@ -3488,11 +3488,10 @@ const Printstyle6 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -4050,10 +4049,8 @@ const Printstyle6 = ({
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}
|
|
||||||
</div>
|
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{/* 🔢 Quantity */}
|
{/* 🔢 Quantity */}
|
||||||
|
|
|
||||||
|
|
@ -562,11 +562,10 @@ const PrintStyle7 = ({
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -806,11 +805,9 @@ const PrintStyle7 = ({
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{(item?.ProductIdentifierDtls ?? [])
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
.find(items => items.SerialNumber || items.IMEI1 || items.IMEI2)?.Description && (
|
|
||||||
<div>
|
<div>
|
||||||
{(item?.ProductIdentifierDtls ?? [])
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
.find(items => items.SerialNumber || items.IMEI1 || items.IMEI2).Description}
|
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1072,9 +1069,9 @@ const PrintStyle7 = ({
|
||||||
})}
|
})}
|
||||||
|
|
||||||
{/* 📝 Description from first identifier */}
|
{/* 📝 Description from first identifier */}
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(data => data.SerialNumber || data.IMEI1 || data.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>
|
<div>
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(data => data.SerialNumber || data.IMEI1 || data.IMEI2).Description}
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3069,11 +3066,10 @@ const PrintStyle7 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3288,13 +3284,9 @@ const PrintStyle7 = ({
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
items => items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
)?.Description && (
|
|
||||||
<div>
|
<div>
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
items => items.SerialNumber || items.IMEI1 || items.IMEI2
|
|
||||||
).Description}
|
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3530,9 +3522,9 @@ const PrintStyle7 = ({
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(items => items.SerialNumber || items.IMEI1 || items.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>
|
<div>
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(items => items.SerialNumber || items.IMEI1 || items.IMEI2).Description}
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -576,11 +576,10 @@ const Printstyle8 = ({
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -910,8 +909,10 @@ const Printstyle8 = ({
|
||||||
})
|
})
|
||||||
: ''}
|
: ''}
|
||||||
</div>
|
</div>
|
||||||
{item?.ProductIdentifierDtls?.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{item.ProductIdentifierDtls.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>
|
||||||
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
|
</div>
|
||||||
)}
|
)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
@ -1277,8 +1278,10 @@ const Printstyle8 = ({
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>
|
||||||
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
|
</div>
|
||||||
)}
|
)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3444,11 +3447,10 @@ const Printstyle8 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3926,8 +3928,10 @@ const Printstyle8 = ({
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{item?.ProductIdentifierDtls?.[0]?.Description && (
|
||||||
<div>{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>
|
||||||
|
{item?.ProductIdentifierDtls?.[0]?.Description}
|
||||||
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
|
|
||||||
|
|
@ -581,11 +581,10 @@ const PrintStyle9 = ({
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? 'Cash'
|
? 'Cash'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName
|
: ' Bill')}{' '}
|
||||||
: ''}{' '}
|
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -830,8 +829,8 @@ const PrintStyle9 = ({
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -863,8 +862,8 @@ const PrintStyle9 = ({
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{identifiers.find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
@ -3316,11 +3315,10 @@ const PrintStyle9 = ({
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
? GlobalBilltext
|
? GlobalBilltext
|
||||||
: 'Cash' + ' Bill'
|
: 'Cash' + ' Bill'
|
||||||
: BillName
|
: BillName ||
|
||||||
? BillName
|
(PaymentStatusSuccess?.length === 1
|
||||||
: PaymentStatusSuccess?.length === 1
|
|
||||||
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
? PaymentStatusSuccess?.[0]?.PaymentTypeName + ' Bill'
|
||||||
: ''}{' '}
|
: ' Bill')}{' '}
|
||||||
{/* {SalesModePref?.SettingValue == 'Y' &&
|
{/* {SalesModePref?.SettingValue == 'Y' &&
|
||||||
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
`(${table2Data?.SalesMode ? table2Data?.SalesMode : 'R'})`} */}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3540,8 +3538,8 @@ const PrintStyle9 = ({
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
|
|
||||||
{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2)?.Description && (
|
{identifiers?.[0]?.Description && (
|
||||||
<div>{(item?.ProductIdentifierDtls ?? []).find(d => d.SerialNumber || d.IMEI1 || d.IMEI2).Description}</div>
|
<div>{identifiers?.[0]?.Description}</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue