Merge pull request 'priceoverride' (#243) from priceoverride into main
Reviewed-on: Pozomind/pozo-retail-app#243
This commit is contained in:
commit
0ab58996a6
|
|
@ -22,3 +22,6 @@ dist-ssr
|
||||||
*.njsproj
|
*.njsproj
|
||||||
*.sln
|
*.sln
|
||||||
*.sw?
|
*.sw?
|
||||||
|
|
||||||
|
src/routesConfig.jsx
|
||||||
|
vite.config.js
|
||||||
|
|
@ -2454,12 +2454,12 @@ const BSBillingTable1 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${item.OfferPrice}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2745,12 +2745,12 @@ const BSBillingTable1 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${item.OfferPrice}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3090,12 +3090,12 @@ const BSBillingTable1 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${item.OfferPrice}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3413,15 +3413,16 @@ const BSBillingTable1 = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${item.OfferPrice}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
|
||||||
|
|
@ -260,7 +260,7 @@ export default function BST1Payment() {
|
||||||
const RetailWSSalesType = useSelector(GlobalRetailWSSalesType);
|
const RetailWSSalesType = useSelector(GlobalRetailWSSalesType);
|
||||||
const SelCustId = useSelector(GlobalSelCustId);
|
const SelCustId = useSelector(GlobalSelCustId);
|
||||||
const selOption = useSelector(GlobalSelOption);
|
const selOption = useSelector(GlobalSelOption);
|
||||||
console.log(selOption, 'selOptionbst234343',GetCustId);
|
console.log(selOption, 'selOptionbst234343', GetCustId);
|
||||||
|
|
||||||
const SelectedTableDetails = useSelector(GlobalSelectedTableDetails);
|
const SelectedTableDetails = useSelector(GlobalSelectedTableDetails);
|
||||||
const GlobalAddCustomerDetails1 = useSelector(GlobalAddCustomerDetails);
|
const GlobalAddCustomerDetails1 = useSelector(GlobalAddCustomerDetails);
|
||||||
|
|
@ -728,7 +728,7 @@ export default function BST1Payment() {
|
||||||
setEmpData(datas?.[0]);
|
setEmpData(datas?.[0]);
|
||||||
};
|
};
|
||||||
const getCustomerData = async () => {
|
const getCustomerData = async () => {
|
||||||
await dispatch(
|
await dispatch(
|
||||||
getAddCustomerDetails({
|
getAddCustomerDetails({
|
||||||
CompId: CompId,
|
CompId: CompId,
|
||||||
AppId: AppId,
|
AppId: AppId,
|
||||||
|
|
@ -905,7 +905,7 @@ export default function BST1Payment() {
|
||||||
|
|
||||||
const selectedStyle =
|
const selectedStyle =
|
||||||
stylesMap[
|
stylesMap[
|
||||||
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
||||||
];
|
];
|
||||||
|
|
||||||
if (selectedStyle) {
|
if (selectedStyle) {
|
||||||
|
|
@ -2026,15 +2026,15 @@ export default function BST1Payment() {
|
||||||
OrderStatus: 'O',
|
OrderStatus: 'O',
|
||||||
OrderType:
|
OrderType:
|
||||||
BookingType === 'Dine In' ||
|
BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
Estimation?.SettingValue == 'N'
|
Estimation?.SettingValue == 'N'
|
||||||
? 'S'
|
? 'S'
|
||||||
: GlobEstBooking === 'OvrAllEst'
|
: GlobEstBooking === 'OvrAllEst'
|
||||||
? 'E'
|
? 'E'
|
||||||
: GlobEstBooking === 'ParEst'
|
: GlobEstBooking === 'ParEst'
|
||||||
? GlobProdwisedata?.includes(
|
? GlobProdwisedata?.includes(
|
||||||
a.InwardDtlId + ' ' + a?.BookingTypeName
|
a.InwardDtlId + ' ' + a?.BookingTypeName
|
||||||
)
|
)
|
||||||
? 'E'
|
? 'E'
|
||||||
: 'S'
|
: 'S'
|
||||||
: 'S',
|
: 'S',
|
||||||
|
|
@ -2051,6 +2051,9 @@ export default function BST1Payment() {
|
||||||
BatchRef: a.BatchRef,
|
BatchRef: a.BatchRef,
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
SetCount: a.SetCount,
|
||||||
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt })
|
||||||
}));
|
}));
|
||||||
const NotSlectedTypeFind = temporderdetail?.find(
|
const NotSlectedTypeFind = temporderdetail?.find(
|
||||||
(a) => a?.BookingType != SelectedBookingType
|
(a) => a?.BookingType != SelectedBookingType
|
||||||
|
|
@ -2124,7 +2127,7 @@ export default function BST1Payment() {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
OrderDtlDetails:
|
OrderDtlDetails:
|
||||||
|
|
@ -2141,9 +2144,9 @@ export default function BST1Payment() {
|
||||||
? globalTipAmount === 0
|
? globalTipAmount === 0
|
||||||
? SelectedTableDetails
|
? SelectedTableDetails
|
||||||
: SelectedTableDetails?.map((item) => ({
|
: SelectedTableDetails?.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
TipsAmount: globalTipAmount,
|
TipsAmount: globalTipAmount,
|
||||||
}))
|
}))
|
||||||
: null,
|
: null,
|
||||||
|
|
||||||
SalesPaymentType: 'normal',
|
SalesPaymentType: 'normal',
|
||||||
|
|
@ -2159,8 +2162,8 @@ export default function BST1Payment() {
|
||||||
? PaymentgatewayUPI?.[0]?.ModeId
|
? PaymentgatewayUPI?.[0]?.ModeId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.ModeId
|
)?.ModeId
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
? paybtnselected
|
? paybtnselected
|
||||||
|
|
@ -2173,15 +2176,15 @@ export default function BST1Payment() {
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? null
|
? null
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'business'
|
SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
||||||
?.MerchantId
|
?.MerchantId
|
||||||
: null,
|
: null,
|
||||||
PaymentOptionType:
|
PaymentOptionType:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit')
|
refundPaySelectedName?.toLowerCase() === 'credit')
|
||||||
? 'PC'
|
? 'PC'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'cash'
|
: Paybtnnameselected?.toLowerCase() === 'cash'
|
||||||
? 'PC'
|
? 'PC'
|
||||||
|
|
@ -2201,29 +2204,29 @@ export default function BST1Payment() {
|
||||||
? null
|
? null
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
||||||
?.UPIDetailId
|
?.UPIDetailId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.MerchantUPIId
|
)?.MerchantUPIId
|
||||||
: null,
|
: null,
|
||||||
AccountDtl:
|
AccountDtl:
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? []
|
? []
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
||||||
(upipay) => upipay?.UPIId === UpiId
|
(upipay) => upipay?.UPIId === UpiId
|
||||||
)
|
)
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pd')
|
SelectedCardOption?.toLowerCase() === 'pd')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pg')
|
SelectedCardOption?.toLowerCase() === 'pg')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
||||||
: [],
|
: [],
|
||||||
PaymentStatus:
|
PaymentStatus:
|
||||||
|
|
@ -2234,13 +2237,13 @@ export default function BST1Payment() {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
Debit:
|
Debit:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit'
|
refundPaySelectedName?.toLowerCase() === 'credit'
|
||||||
? Math.round(previousNetAmount - currentOrderNetAmount)
|
? Math.round(previousNetAmount - currentOrderNetAmount)
|
||||||
: 0,
|
: 0,
|
||||||
Credit: salesBillEdit
|
Credit: salesBillEdit
|
||||||
|
|
@ -2316,14 +2319,14 @@ export default function BST1Payment() {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2480,14 +2483,14 @@ export default function BST1Payment() {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2588,14 +2591,14 @@ export default function BST1Payment() {
|
||||||
}
|
}
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
if (response?.data?.OrderDetails?.length > 0) {
|
if (response?.data?.OrderDetails?.length > 0) {
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2770,14 +2773,14 @@ export default function BST1Payment() {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
bookingpaymentupdate?.data?.response +
|
bookingpaymentupdate?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
||||||
? bookingpaymentupdate?.data?.OrderId &&
|
? bookingpaymentupdate?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
bookingpaymentupdate?.data?.OrderId,
|
bookingpaymentupdate?.data?.OrderId,
|
||||||
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
||||||
|
|
@ -2795,7 +2798,7 @@ export default function BST1Payment() {
|
||||||
if (
|
if (
|
||||||
Date.now() - startTime >
|
Date.now() - startTime >
|
||||||
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
||||||
60000
|
60000
|
||||||
) {
|
) {
|
||||||
// 60,000 ms = 1 minute
|
// 60,000 ms = 1 minute
|
||||||
|
|
||||||
|
|
@ -3575,31 +3578,31 @@ export default function BST1Payment() {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{paybtns?.length > 0 &&
|
{paybtns?.length > 0 &&
|
||||||
currentOrderNetAmount >= previousNetAmount ? (
|
currentOrderNetAmount >= previousNetAmount ? (
|
||||||
paybtns?.map((payment) => (
|
paybtns?.map((payment) => (
|
||||||
<div className="Table3-cash">
|
<div className="Table3-cash">
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
paybtnselected === payment.ModeId &&
|
paybtnselected === payment.ModeId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: paybtnselected === payment.ModeId &&
|
: paybtnselected === payment.ModeId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -3613,13 +3616,13 @@ export default function BST1Payment() {
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
||||||
? handleUPIButtonClick(
|
? handleUPIButtonClick(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
: handlePaymentMode(
|
: handlePaymentMode(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
{/* {UpiOption === "" && payment?.ModeName?.toLowerCase() === "upi" && <p> UPI</p>} */}
|
{/* {UpiOption === "" && payment?.ModeName?.toLowerCase() === "upi" && <p> UPI</p>} */}
|
||||||
|
|
@ -3678,10 +3681,10 @@ export default function BST1Payment() {
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
refundPaySelected === payment.ConfigId &&
|
refundPaySelected === payment.ConfigId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: refundPaySelected === payment.ConfigId &&
|
: refundPaySelected === payment.ConfigId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -3756,9 +3759,9 @@ export default function BST1Payment() {
|
||||||
OrderCardDetail?.length > 0 && 'not-allowed',
|
OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(selOption?.value === undefined &&
|
(selOption?.value === undefined &&
|
||||||
GlobalAddCustomerDetails1?.length === 0 &&
|
GlobalAddCustomerDetails1?.length === 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
|
|
@ -3808,16 +3811,16 @@ export default function BST1Payment() {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
}}
|
}}
|
||||||
|
|
@ -3836,14 +3839,14 @@ export default function BST1Payment() {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3860,39 +3863,39 @@ export default function BST1Payment() {
|
||||||
|
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(OrderCardDetail?.length > 0)
|
!(OrderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(OrderCardDetail?.length > 0 &&
|
(OrderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{OtherServicesglobal && OrderCardDetail.length >= 1 && (
|
{OtherServicesglobal && OrderCardDetail.length >= 1 && (
|
||||||
<TooltipWrapper title="Vehicle Number" isMobile={isMobile}>
|
<TooltipWrapper title="Vehicle Number" isMobile={isMobile}>
|
||||||
|
|
@ -3908,14 +3911,14 @@ export default function BST1Payment() {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3997,58 +4000,58 @@ export default function BST1Payment() {
|
||||||
<div>
|
<div>
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? holdCheckedSalesSetup &&
|
? holdCheckedSalesSetup &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
OrderCardDetail?.length != 0 &&
|
OrderCardDetail?.length != 0 &&
|
||||||
CheckOrderType?.length === 0 &&
|
CheckOrderType?.length === 0 &&
|
||||||
OrderType != 'Failed' &&
|
OrderType != 'Failed' &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<PozoHoldIcon
|
<PozoHoldIcon
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => AddBookingDetails('Hold')}
|
onClick={() => AddBookingDetails('Hold')}
|
||||||
style={{
|
style={{
|
||||||
fontSize: '30px',
|
fontSize: '30px',
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
color: '' ? '#52c41a' : '#1292EE',
|
color: '' ? '#52c41a' : '#1292EE',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? holdCheckedSalesSetup &&
|
? holdCheckedSalesSetup &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
Holddata?.length > 0 &&
|
Holddata?.length > 0 &&
|
||||||
OrderCardDetail?.length == 0 &&
|
OrderCardDetail?.length == 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper title={'Recall'} isMobile={isMobile}>
|
<TooltipWrapper title={'Recall'} isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<Badge
|
<Badge
|
||||||
count={Holddata?.length}
|
count={Holddata?.length}
|
||||||
size={'small'}
|
size={'small'}
|
||||||
offset={[0, 7]}
|
offset={[0, 7]}
|
||||||
>
|
>
|
||||||
<PozoHoldIcon
|
<PozoHoldIcon
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => HandleholdModelOpen()}
|
onClick={() => HandleholdModelOpen()}
|
||||||
style={{
|
style={{
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
color: Holddata ? '#52c41a' : 'default',
|
color: Holddata ? '#52c41a' : 'default',
|
||||||
pointerEvents:
|
pointerEvents:
|
||||||
OrderType === 'Failed' ? 'none' : 'auto',
|
OrderType === 'Failed' ? 'none' : 'auto',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</Badge>
|
</Badge>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
@ -4091,9 +4094,9 @@ export default function BST1Payment() {
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'price-button-disabled'
|
? 'price-button-disabled'
|
||||||
: FirstPaymentclick === false &&
|
: FirstPaymentclick === false &&
|
||||||
OrderCardDetail?.length > 0 &&
|
OrderCardDetail?.length > 0 &&
|
||||||
paybtnselected &&
|
paybtnselected &&
|
||||||
CheckBookingStatus != 'Close'
|
CheckBookingStatus != 'Close'
|
||||||
? !OrderStatus
|
? !OrderStatus
|
||||||
? salesBillEdit &&
|
? salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount
|
currentOrderNetAmount < previousNetAmount
|
||||||
|
|
@ -4115,7 +4118,7 @@ export default function BST1Payment() {
|
||||||
{isMobile ? (
|
{isMobile ? (
|
||||||
!OrderStatus ? (
|
!OrderStatus ? (
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount ? (
|
currentOrderNetAmount < previousNetAmount ? (
|
||||||
<div>
|
<div>
|
||||||
Refund: ₹
|
Refund: ₹
|
||||||
{(previousNetAmount || 0) -
|
{(previousNetAmount || 0) -
|
||||||
|
|
@ -4341,14 +4344,14 @@ export default function BST1Payment() {
|
||||||
OrderType === 'Failed'
|
OrderType === 'Failed'
|
||||||
? FailedTotalAmt
|
? FailedTotalAmt
|
||||||
: Math.round(
|
: Math.round(
|
||||||
OrderCardDetail?.reduce(
|
OrderCardDetail?.reduce(
|
||||||
(acc, data) => data?.TotalAmt + acc,
|
(acc, data) => data?.TotalAmt + acc,
|
||||||
0
|
0
|
||||||
) -
|
) -
|
||||||
((OverAllSales > 0 ? OverAllSales : 0) +
|
((OverAllSales > 0 ? OverAllSales : 0) +
|
||||||
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
||||||
(Discount > 0 ? Discount : 0))
|
(Discount > 0 ? Discount : 0))
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
failedOrderData={failedOrderData}
|
failedOrderData={failedOrderData}
|
||||||
/>
|
/>
|
||||||
|
|
@ -4481,9 +4484,9 @@ export default function BST1Payment() {
|
||||||
|
|
||||||
const qty = isGroup
|
const qty = isGroup
|
||||||
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
||||||
(sum, o) => sum + (o.OrderQty || 1),
|
(sum, o) => sum + (o.OrderQty || 1),
|
||||||
0
|
0
|
||||||
)
|
)
|
||||||
: item.OrderQty || 1;
|
: item.OrderQty || 1;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
||||||
|
|
@ -1545,7 +1545,7 @@ const BSBillingTable2 = () => {
|
||||||
|
|
||||||
const selectedStyle =
|
const selectedStyle =
|
||||||
stylesMap[
|
stylesMap[
|
||||||
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
||||||
];
|
];
|
||||||
|
|
||||||
if (selectedStyle) {
|
if (selectedStyle) {
|
||||||
|
|
@ -2106,15 +2106,15 @@ const BSBillingTable2 = () => {
|
||||||
OrderStatus: 'O',
|
OrderStatus: 'O',
|
||||||
OrderType:
|
OrderType:
|
||||||
BookingType === 'Dine In' ||
|
BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
Estimation?.SettingValue == 'N'
|
Estimation?.SettingValue == 'N'
|
||||||
? 'S'
|
? 'S'
|
||||||
: GlobEstBooking === 'OvrAllEst'
|
: GlobEstBooking === 'OvrAllEst'
|
||||||
? 'E'
|
? 'E'
|
||||||
: GlobEstBooking === 'ParEst'
|
: GlobEstBooking === 'ParEst'
|
||||||
? GlobProdwisedata?.includes(
|
? GlobProdwisedata?.includes(
|
||||||
a.InwardDtlId + ' ' + a?.BookingTypeName
|
a.InwardDtlId + ' ' + a?.BookingTypeName
|
||||||
)
|
)
|
||||||
? 'E'
|
? 'E'
|
||||||
: 'S'
|
: 'S'
|
||||||
: 'S',
|
: 'S',
|
||||||
|
|
@ -2130,7 +2130,9 @@ const BSBillingTable2 = () => {
|
||||||
ModelNumber: a.ModelNumber,
|
ModelNumber: a.ModelNumber,
|
||||||
BatchRef: a.BatchRef,
|
BatchRef: a.BatchRef,
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt })
|
||||||
}));
|
}));
|
||||||
const NotSlectedTypeFind = temporderdetail?.find(
|
const NotSlectedTypeFind = temporderdetail?.find(
|
||||||
(a) => a?.BookingType != SelectedBookingType
|
(a) => a?.BookingType != SelectedBookingType
|
||||||
|
|
@ -2206,7 +2208,7 @@ const BSBillingTable2 = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
OrderDtlDetails:
|
OrderDtlDetails:
|
||||||
|
|
@ -2223,9 +2225,9 @@ const BSBillingTable2 = () => {
|
||||||
? globalTipAmount === 0
|
? globalTipAmount === 0
|
||||||
? SelectedTableDetails
|
? SelectedTableDetails
|
||||||
: SelectedTableDetails?.map((item) => ({
|
: SelectedTableDetails?.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
TipsAmount: globalTipAmount,
|
TipsAmount: globalTipAmount,
|
||||||
}))
|
}))
|
||||||
: null,
|
: null,
|
||||||
// "Credit": TotalAmount,
|
// "Credit": TotalAmount,
|
||||||
// "Debit": 0,
|
// "Debit": 0,
|
||||||
|
|
@ -2242,8 +2244,8 @@ const BSBillingTable2 = () => {
|
||||||
? PaymentgatewayUPI?.[0]?.ModeId
|
? PaymentgatewayUPI?.[0]?.ModeId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.ModeId
|
)?.ModeId
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
? paybtnselected
|
? paybtnselected
|
||||||
|
|
@ -2256,15 +2258,15 @@ const BSBillingTable2 = () => {
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? null
|
? null
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'business'
|
SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
||||||
?.MerchantId
|
?.MerchantId
|
||||||
: null,
|
: null,
|
||||||
PaymentOptionType:
|
PaymentOptionType:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit')
|
refundPaySelectedName?.toLowerCase() === 'credit')
|
||||||
? 'PC'
|
? 'PC'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'cash'
|
: Paybtnnameselected?.toLowerCase() === 'cash'
|
||||||
? 'PC'
|
? 'PC'
|
||||||
|
|
@ -2284,29 +2286,29 @@ const BSBillingTable2 = () => {
|
||||||
? null
|
? null
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
||||||
?.UPIDetailId
|
?.UPIDetailId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.MerchantUPIId
|
)?.MerchantUPIId
|
||||||
: null,
|
: null,
|
||||||
AccountDtl:
|
AccountDtl:
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? []
|
? []
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
||||||
(upipay) => upipay?.UPIId === UpiId
|
(upipay) => upipay?.UPIId === UpiId
|
||||||
)
|
)
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pd')
|
SelectedCardOption?.toLowerCase() === 'pd')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pg')
|
SelectedCardOption?.toLowerCase() === 'pg')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
||||||
: [],
|
: [],
|
||||||
PaymentStatus:
|
PaymentStatus:
|
||||||
|
|
@ -2317,13 +2319,13 @@ const BSBillingTable2 = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
Debit:
|
Debit:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit'
|
refundPaySelectedName?.toLowerCase() === 'credit'
|
||||||
? Math.round(previousNetAmount - currentOrderNetAmount)
|
? Math.round(previousNetAmount - currentOrderNetAmount)
|
||||||
: 0,
|
: 0,
|
||||||
Credit: salesBillEdit
|
Credit: salesBillEdit
|
||||||
|
|
@ -2402,14 +2404,14 @@ const BSBillingTable2 = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2566,14 +2568,14 @@ const BSBillingTable2 = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2677,14 +2679,14 @@ const BSBillingTable2 = () => {
|
||||||
}
|
}
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
if (response?.data?.OrderDetails?.length > 0) {
|
if (response?.data?.OrderDetails?.length > 0) {
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2861,14 +2863,14 @@ const BSBillingTable2 = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
bookingpaymentupdate?.data?.response +
|
bookingpaymentupdate?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
||||||
? bookingpaymentupdate?.data?.OrderId &&
|
? bookingpaymentupdate?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
bookingpaymentupdate?.data?.OrderId,
|
bookingpaymentupdate?.data?.OrderId,
|
||||||
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
||||||
|
|
@ -2887,7 +2889,7 @@ const BSBillingTable2 = () => {
|
||||||
if (
|
if (
|
||||||
Date.now() - startTime >
|
Date.now() - startTime >
|
||||||
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
||||||
60000
|
60000
|
||||||
) {
|
) {
|
||||||
// 60,000 ms = 1 minute
|
// 60,000 ms = 1 minute
|
||||||
|
|
||||||
|
|
@ -3660,7 +3662,7 @@ const BSBillingTable2 = () => {
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
return (
|
return (
|
||||||
<Suspense fallback={<BillingTableSkeleton />}>
|
<Suspense fallback={<BillingTableSkeleton />}>
|
||||||
<div
|
<div
|
||||||
className={
|
className={
|
||||||
templateData?.BookingLayout?.[0] === 'Layout6'
|
templateData?.BookingLayout?.[0] === 'Layout6'
|
||||||
|
|
@ -3814,16 +3816,16 @@ const BSBillingTable2 = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
width: '2rem',
|
width: '2rem',
|
||||||
|
|
@ -3843,14 +3845,14 @@ const BSBillingTable2 = () => {
|
||||||
width: '1.6rem',
|
width: '1.6rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3876,14 +3878,14 @@ const BSBillingTable2 = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3985,31 +3987,31 @@ const BSBillingTable2 = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{paybtns?.length > 0 &&
|
{paybtns?.length > 0 &&
|
||||||
currentOrderNetAmount >= previousNetAmount ? (
|
currentOrderNetAmount >= previousNetAmount ? (
|
||||||
paybtns?.map((payment) => (
|
paybtns?.map((payment) => (
|
||||||
<div className="Table3-cash">
|
<div className="Table3-cash">
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
paybtnselected === payment.ModeId &&
|
paybtnselected === payment.ModeId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: paybtnselected === payment.ModeId &&
|
: paybtnselected === payment.ModeId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -4023,13 +4025,13 @@ const BSBillingTable2 = () => {
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
||||||
? handleUPIButtonClick(
|
? handleUPIButtonClick(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
: handlePaymentMode(
|
: handlePaymentMode(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
|
|
@ -4086,10 +4088,10 @@ const BSBillingTable2 = () => {
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
refundPaySelected === payment.ConfigId &&
|
refundPaySelected === payment.ConfigId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: refundPaySelected === payment.ConfigId &&
|
: refundPaySelected === payment.ConfigId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -4160,9 +4162,9 @@ const BSBillingTable2 = () => {
|
||||||
OrderCardDetail?.length > 0 && 'not-allowed',
|
OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(selOption?.value === undefined &&
|
(selOption?.value === undefined &&
|
||||||
GlobalAddCustomerDetails1?.length === 0 &&
|
GlobalAddCustomerDetails1?.length === 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
|
|
@ -4179,39 +4181,39 @@ const BSBillingTable2 = () => {
|
||||||
|
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(OrderCardDetail?.length > 0)
|
!(OrderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(OrderCardDetail?.length > 0 &&
|
(OrderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
{tabledata?.length > 0 && (
|
{tabledata?.length > 0 && (
|
||||||
<div style={{ width: '2rem' }}>
|
<div style={{ width: '2rem' }}>
|
||||||
{tableOptions
|
{tableOptions
|
||||||
|
|
@ -4280,68 +4282,68 @@ const BSBillingTable2 = () => {
|
||||||
<>
|
<>
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
OrderCardDetail?.length != 0 &&
|
OrderCardDetail?.length != 0 &&
|
||||||
!OrderStatus &&
|
!OrderStatus &&
|
||||||
OrderType != 'Failed' &&
|
OrderType != 'Failed' &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<>
|
<>
|
||||||
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
||||||
<button
|
<button
|
||||||
onClick={() => AddBookingDetails('Hold')}
|
onClick={() => AddBookingDetails('Hold')}
|
||||||
className={
|
className={
|
||||||
FirstPaymentclick === false
|
FirstPaymentclick === false
|
||||||
? 'hold-btn'
|
? 'hold-btn'
|
||||||
: 'hold-btn-disable'
|
: 'hold-btn-disable'
|
||||||
}
|
}
|
||||||
|
>
|
||||||
|
<BsPauseFill />
|
||||||
|
<p
|
||||||
|
className="hold-btn-txt"
|
||||||
|
style={{
|
||||||
|
fontFamily: FontFamily['para'],
|
||||||
|
}}
|
||||||
>
|
>
|
||||||
<BsPauseFill />
|
Hold
|
||||||
<p
|
</p>
|
||||||
className="hold-btn-txt"
|
</button>
|
||||||
style={{
|
</TooltipWrapper>
|
||||||
fontFamily: FontFamily['para'],
|
</>
|
||||||
}}
|
)
|
||||||
>
|
|
||||||
Hold
|
|
||||||
</p>
|
|
||||||
</button>
|
|
||||||
</TooltipWrapper>
|
|
||||||
</>
|
|
||||||
)
|
|
||||||
: ''}
|
: ''}
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
Holddata?.length > 0 &&
|
Holddata?.length > 0 &&
|
||||||
OrderCardDetail?.length == 0 &&
|
OrderCardDetail?.length == 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper title={'Recall'} isMobile={isMobile}>
|
<TooltipWrapper title={'Recall'} isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<Badge
|
<Badge
|
||||||
count={Holddata?.length}
|
count={Holddata?.length}
|
||||||
size={'small'}
|
size={'small'}
|
||||||
offset={[0, 7]}
|
offset={[0, 7]}
|
||||||
>
|
>
|
||||||
<PozoHoldIcon
|
<PozoHoldIcon
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => HandleholdModelOpen()}
|
onClick={() => HandleholdModelOpen()}
|
||||||
style={{
|
style={{
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
color: Holddata ? '#52c41a' : 'default',
|
color: Holddata ? '#52c41a' : 'default',
|
||||||
pointerEvents:
|
pointerEvents:
|
||||||
OrderType === 'Failed' ? 'none' : 'auto',
|
OrderType === 'Failed' ? 'none' : 'auto',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</Badge>
|
</Badge>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
</>
|
</>
|
||||||
))}
|
))}
|
||||||
|
|
@ -4357,9 +4359,9 @@ const BSBillingTable2 = () => {
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'billing-btn-deactive'
|
? 'billing-btn-deactive'
|
||||||
: FirstPaymentclick === false &&
|
: FirstPaymentclick === false &&
|
||||||
OrderCardDetail?.length > 0 &&
|
OrderCardDetail?.length > 0 &&
|
||||||
paybtnselected &&
|
paybtnselected &&
|
||||||
CheckBookingStatus != 'Close'
|
CheckBookingStatus != 'Close'
|
||||||
? salesBillEdit &&
|
? salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount
|
currentOrderNetAmount < previousNetAmount
|
||||||
? 'billing-btn'
|
? 'billing-btn'
|
||||||
|
|
@ -4610,14 +4612,14 @@ const BSBillingTable2 = () => {
|
||||||
OrderType === 'Failed'
|
OrderType === 'Failed'
|
||||||
? FailedTotalAmt
|
? FailedTotalAmt
|
||||||
: Math.round(
|
: Math.round(
|
||||||
OrderCardDetail?.reduce(
|
OrderCardDetail?.reduce(
|
||||||
(acc, data) => data?.TotalAmt + acc,
|
(acc, data) => data?.TotalAmt + acc,
|
||||||
0
|
0
|
||||||
) -
|
) -
|
||||||
((OverAllSales > 0 ? OverAllSales : 0) +
|
((OverAllSales > 0 ? OverAllSales : 0) +
|
||||||
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
||||||
(Discount > 0 ? Discount : 0))
|
(Discount > 0 ? Discount : 0))
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
failedOrderData={failedOrderData}
|
failedOrderData={failedOrderData}
|
||||||
/>
|
/>
|
||||||
|
|
@ -4752,9 +4754,9 @@ const BSBillingTable2 = () => {
|
||||||
|
|
||||||
const qty = isGroup
|
const qty = isGroup
|
||||||
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
||||||
(sum, o) => sum + (o.OrderQty || 1),
|
(sum, o) => sum + (o.OrderQty || 1),
|
||||||
0
|
0
|
||||||
)
|
)
|
||||||
: item.OrderQty || 1;
|
: item.OrderQty || 1;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
||||||
|
|
@ -2596,15 +2596,15 @@ const BSBillingTable3 = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
:item.DiscountAmt ? item.DiscountAmt : '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2881,7 +2881,7 @@ const BSBillingTable3 = () => {
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3206,7 +3206,7 @@ const BSBillingTable3 = () => {
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
@ -3516,7 +3516,7 @@ const BSBillingTable3 = () => {
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
|
||||||
|
|
@ -881,7 +881,7 @@ const BSBilling4Payment = () => {
|
||||||
|
|
||||||
const selectedStyle =
|
const selectedStyle =
|
||||||
stylesMap[
|
stylesMap[
|
||||||
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
||||||
];
|
];
|
||||||
console.log(selectedStyle, style, 'style');
|
console.log(selectedStyle, style, 'style');
|
||||||
if (selectedStyle) {
|
if (selectedStyle) {
|
||||||
|
|
@ -2128,15 +2128,15 @@ const BSBilling4Payment = () => {
|
||||||
OrderStatus: 'O',
|
OrderStatus: 'O',
|
||||||
OrderType:
|
OrderType:
|
||||||
BookingType === 'Dine In' ||
|
BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
Estimation?.SettingValue == 'N'
|
Estimation?.SettingValue == 'N'
|
||||||
? 'S'
|
? 'S'
|
||||||
: GlobEstBooking === 'OvrAllEst'
|
: GlobEstBooking === 'OvrAllEst'
|
||||||
? 'E'
|
? 'E'
|
||||||
: GlobEstBooking === 'ParEst'
|
: GlobEstBooking === 'ParEst'
|
||||||
? GlobProdwisedata?.includes(
|
? GlobProdwisedata?.includes(
|
||||||
a.InwardDtlId + ' ' + a?.BookingTypeName
|
a.InwardDtlId + ' ' + a?.BookingTypeName
|
||||||
)
|
)
|
||||||
? 'E'
|
? 'E'
|
||||||
: 'S'
|
: 'S'
|
||||||
: 'S',
|
: 'S',
|
||||||
|
|
@ -2154,6 +2154,9 @@ const BSBilling4Payment = () => {
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
SetCount: a.SetCount,
|
||||||
BookingDate: AvailableDate ? a.BookedDate : null,
|
BookingDate: AvailableDate ? a.BookedDate : null,
|
||||||
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt })
|
||||||
}));
|
}));
|
||||||
const NotSlectedTypeFind = temporderdetail?.find(
|
const NotSlectedTypeFind = temporderdetail?.find(
|
||||||
(a) => a?.BookingType != SelectedBookingType
|
(a) => a?.BookingType != SelectedBookingType
|
||||||
|
|
@ -2229,7 +2232,7 @@ const BSBilling4Payment = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
OrderDtlDetails:
|
OrderDtlDetails:
|
||||||
|
|
@ -2246,9 +2249,9 @@ const BSBilling4Payment = () => {
|
||||||
? globalTipAmount === 0
|
? globalTipAmount === 0
|
||||||
? SelectedTableDetails
|
? SelectedTableDetails
|
||||||
: SelectedTableDetails?.map((item) => ({
|
: SelectedTableDetails?.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
TipsAmount: globalTipAmount,
|
TipsAmount: globalTipAmount,
|
||||||
}))
|
}))
|
||||||
: null,
|
: null,
|
||||||
SalesPaymentType: 'normal',
|
SalesPaymentType: 'normal',
|
||||||
PaymentDetail: [
|
PaymentDetail: [
|
||||||
|
|
@ -2263,8 +2266,8 @@ const BSBilling4Payment = () => {
|
||||||
? PaymentgatewayUPI?.[0]?.ModeId
|
? PaymentgatewayUPI?.[0]?.ModeId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.ModeId
|
)?.ModeId
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
? paybtnselected
|
? paybtnselected
|
||||||
|
|
@ -2277,15 +2280,15 @@ const BSBilling4Payment = () => {
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? null
|
? null
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'business'
|
SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
||||||
?.MerchantId
|
?.MerchantId
|
||||||
: null,
|
: null,
|
||||||
PaymentOptionType:
|
PaymentOptionType:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit')
|
refundPaySelectedName?.toLowerCase() === 'credit')
|
||||||
? 'PC'
|
? 'PC'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'cash'
|
: Paybtnnameselected?.toLowerCase() === 'cash'
|
||||||
? 'PC'
|
? 'PC'
|
||||||
|
|
@ -2305,29 +2308,29 @@ const BSBilling4Payment = () => {
|
||||||
? null
|
? null
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
||||||
?.UPIDetailId
|
?.UPIDetailId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.MerchantUPIId
|
)?.MerchantUPIId
|
||||||
: null,
|
: null,
|
||||||
AccountDtl:
|
AccountDtl:
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? []
|
? []
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
||||||
(upipay) => upipay?.UPIId === UpiId
|
(upipay) => upipay?.UPIId === UpiId
|
||||||
)
|
)
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pd')
|
SelectedCardOption?.toLowerCase() === 'pd')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pg')
|
SelectedCardOption?.toLowerCase() === 'pg')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
||||||
: [],
|
: [],
|
||||||
PaymentStatus:
|
PaymentStatus:
|
||||||
|
|
@ -2338,13 +2341,13 @@ const BSBilling4Payment = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
Debit:
|
Debit:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit'
|
refundPaySelectedName?.toLowerCase() === 'credit'
|
||||||
? Math.round(previousNetAmount - currentOrderNetAmount)
|
? Math.round(previousNetAmount - currentOrderNetAmount)
|
||||||
: 0,
|
: 0,
|
||||||
Credit: salesBillEdit
|
Credit: salesBillEdit
|
||||||
|
|
@ -2422,14 +2425,14 @@ const BSBilling4Payment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2590,14 +2593,14 @@ const BSBilling4Payment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2704,14 +2707,14 @@ const BSBilling4Payment = () => {
|
||||||
}
|
}
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
if (response?.data?.OrderDetails?.length > 0) {
|
if (response?.data?.OrderDetails?.length > 0) {
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2887,14 +2890,14 @@ const BSBilling4Payment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
bookingpaymentupdate?.data?.response +
|
bookingpaymentupdate?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
||||||
? bookingpaymentupdate?.data?.OrderId &&
|
? bookingpaymentupdate?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
bookingpaymentupdate?.data?.OrderId,
|
bookingpaymentupdate?.data?.OrderId,
|
||||||
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
||||||
|
|
@ -2913,7 +2916,7 @@ const BSBilling4Payment = () => {
|
||||||
if (
|
if (
|
||||||
Date.now() - startTime >
|
Date.now() - startTime >
|
||||||
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
||||||
60000
|
60000
|
||||||
) {
|
) {
|
||||||
// 60,000 ms = 1 minute
|
// 60,000 ms = 1 minute
|
||||||
|
|
||||||
|
|
@ -3150,9 +3153,9 @@ const BSBilling4Payment = () => {
|
||||||
AppId: AppId,
|
AppId: AppId,
|
||||||
...(AvailableDate && selectedDate
|
...(AvailableDate && selectedDate
|
||||||
? {
|
? {
|
||||||
fromDate: selectedDate?.[0],
|
fromDate: selectedDate?.[0],
|
||||||
toDate: selectedDate?.[1],
|
toDate: selectedDate?.[1],
|
||||||
}
|
}
|
||||||
: {}),
|
: {}),
|
||||||
};
|
};
|
||||||
await dispatch(getSelectedFavItems(data)).unwrap();
|
await dispatch(getSelectedFavItems(data)).unwrap();
|
||||||
|
|
@ -3164,9 +3167,9 @@ const BSBilling4Payment = () => {
|
||||||
ProdSubCat: ProdSubCat,
|
ProdSubCat: ProdSubCat,
|
||||||
...(AvailableDate && selectedDate
|
...(AvailableDate && selectedDate
|
||||||
? {
|
? {
|
||||||
fromDate: selectedDate?.[0],
|
fromDate: selectedDate?.[0],
|
||||||
toDate: selectedDate?.[1],
|
toDate: selectedDate?.[1],
|
||||||
}
|
}
|
||||||
: {}),
|
: {}),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -3177,9 +3180,9 @@ const BSBilling4Payment = () => {
|
||||||
prodCat: prodCat,
|
prodCat: prodCat,
|
||||||
...(AvailableDate && selectedDate
|
...(AvailableDate && selectedDate
|
||||||
? {
|
? {
|
||||||
fromDate: selectedDate?.[0],
|
fromDate: selectedDate?.[0],
|
||||||
toDate: selectedDate?.[1],
|
toDate: selectedDate?.[1],
|
||||||
}
|
}
|
||||||
: {}),
|
: {}),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -3806,9 +3809,9 @@ const BSBilling4Payment = () => {
|
||||||
'not-allowed',
|
'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(selOption?.value === undefined &&
|
(selOption?.value === undefined &&
|
||||||
GlobalAddCustomerDetails1?.length === 0 &&
|
GlobalAddCustomerDetails1?.length === 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
|
|
@ -3829,16 +3832,16 @@ const BSBilling4Payment = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
width: '2rem',
|
width: '2rem',
|
||||||
|
|
@ -3859,14 +3862,14 @@ const BSBilling4Payment = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3896,14 +3899,14 @@ const BSBilling4Payment = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3921,39 +3924,39 @@ const BSBilling4Payment = () => {
|
||||||
|
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(OrderCardDetail?.length > 0)
|
!(OrderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(OrderCardDetail?.length > 0 &&
|
(OrderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
{tabledata?.length > 0 && (
|
{tabledata?.length > 0 && (
|
||||||
<div style={{ width: '2rem' }}>
|
<div style={{ width: '2rem' }}>
|
||||||
{tableOptions
|
{tableOptions
|
||||||
|
|
@ -4021,66 +4024,66 @@ const BSBilling4Payment = () => {
|
||||||
<>
|
<>
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
OrderCardDetail?.length != 0 &&
|
OrderCardDetail?.length != 0 &&
|
||||||
CheckOrderType?.length === 0 &&
|
CheckOrderType?.length === 0 &&
|
||||||
OrderType != 'Failed' &&
|
OrderType != 'Failed' &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper
|
<TooltipWrapper
|
||||||
title={'Hold'}
|
title={'Hold'}
|
||||||
isMobile={isMobile}
|
isMobile={isMobile}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
<PozoHoldIcon
|
<PozoHoldIcon
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => AddBookingDetails('Hold')}
|
onClick={() => AddBookingDetails('Hold')}
|
||||||
style={{
|
style={{
|
||||||
fontSize: '30px',
|
fontSize: '30px',
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
color: '' ? '#52c41a' : '#1292EE',
|
color: '' ? '#52c41a' : '#1292EE',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
Holddata?.length > 0 &&
|
Holddata?.length > 0 &&
|
||||||
OrderCardDetail?.length == 0 &&
|
OrderCardDetail?.length == 0 &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper
|
<TooltipWrapper
|
||||||
title={'Recall'}
|
title={'Recall'}
|
||||||
isMobile={isMobile}
|
isMobile={isMobile}
|
||||||
|
>
|
||||||
|
{' '}
|
||||||
|
<Badge
|
||||||
|
count={Holddata?.length}
|
||||||
|
size={'small'}
|
||||||
|
offset={[0, 7]}
|
||||||
>
|
>
|
||||||
{' '}
|
<PozoHoldIcon
|
||||||
<Badge
|
className="BSBillingNav-icon-table-icon"
|
||||||
count={Holddata?.length}
|
onClick={() => HandleholdModelOpen()}
|
||||||
size={'small'}
|
style={{
|
||||||
offset={[0, 7]}
|
fontSize: '28px',
|
||||||
>
|
cursor: 'pointer',
|
||||||
<PozoHoldIcon
|
color: Holddata ? '#52c41a' : 'default',
|
||||||
className="BSBillingNav-icon-table-icon"
|
pointerEvents:
|
||||||
onClick={() => HandleholdModelOpen()}
|
OrderType === 'Failed'
|
||||||
style={{
|
? 'none'
|
||||||
fontSize: '28px',
|
: 'auto',
|
||||||
cursor: 'pointer',
|
}}
|
||||||
color: Holddata ? '#52c41a' : 'default',
|
/>
|
||||||
pointerEvents:
|
</Badge>
|
||||||
OrderType === 'Failed'
|
</TooltipWrapper>
|
||||||
? 'none'
|
)
|
||||||
: 'auto',
|
|
||||||
}}
|
|
||||||
/>
|
|
||||||
</Badge>
|
|
||||||
</TooltipWrapper>
|
|
||||||
)
|
|
||||||
: ''}
|
: ''}
|
||||||
</>
|
</>
|
||||||
))}
|
))}
|
||||||
|
|
@ -4106,31 +4109,31 @@ const BSBilling4Payment = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{paybtns?.length > 0 &&
|
{paybtns?.length > 0 &&
|
||||||
currentOrderNetAmount >= previousNetAmount ? (
|
currentOrderNetAmount >= previousNetAmount ? (
|
||||||
paybtns?.map((payment) => (
|
paybtns?.map((payment) => (
|
||||||
<div className="Table3-cash">
|
<div className="Table3-cash">
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
paybtnselected === payment.ModeId &&
|
paybtnselected === payment.ModeId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: paybtnselected === payment.ModeId &&
|
: paybtnselected === payment.ModeId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -4144,13 +4147,13 @@ const BSBilling4Payment = () => {
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
||||||
? handleUPIButtonClick(
|
? handleUPIButtonClick(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
: handlePaymentMode(
|
: handlePaymentMode(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
{/* {UpiOption === "" && payment?.ModeName?.toLowerCase() === "upi" && <p> UPI</p>} */}
|
{/* {UpiOption === "" && payment?.ModeName?.toLowerCase() === "upi" && <p> UPI</p>} */}
|
||||||
|
|
@ -4209,10 +4212,10 @@ const BSBilling4Payment = () => {
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
refundPaySelected === payment.ConfigId &&
|
refundPaySelected === payment.ConfigId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: refundPaySelected === payment.ConfigId &&
|
: refundPaySelected === payment.ConfigId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -4476,9 +4479,9 @@ const BSBilling4Payment = () => {
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'Table4-Btn-final-price-disabled'
|
? 'Table4-Btn-final-price-disabled'
|
||||||
: FirstPaymentclick === false &&
|
: FirstPaymentclick === false &&
|
||||||
OrderCardDetail?.length > 0 &&
|
OrderCardDetail?.length > 0 &&
|
||||||
paybtnselected &&
|
paybtnselected &&
|
||||||
CheckBookingStatus != 'Close'
|
CheckBookingStatus != 'Close'
|
||||||
? !OrderStatus
|
? !OrderStatus
|
||||||
? salesBillEdit &&
|
? salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount
|
currentOrderNetAmount < previousNetAmount
|
||||||
|
|
@ -4498,7 +4501,7 @@ const BSBilling4Payment = () => {
|
||||||
>
|
>
|
||||||
{!OrderStatus ? (
|
{!OrderStatus ? (
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount ? (
|
currentOrderNetAmount < previousNetAmount ? (
|
||||||
<p className="Table4-Order">
|
<p className="Table4-Order">
|
||||||
Refund: ₹
|
Refund: ₹
|
||||||
{(previousNetAmount || 0) -
|
{(previousNetAmount || 0) -
|
||||||
|
|
@ -4509,7 +4512,7 @@ const BSBilling4Payment = () => {
|
||||||
<div
|
<div
|
||||||
className="Table4-rate"
|
className="Table4-rate"
|
||||||
style={{ fontFamily: FontFamily['head'] }}
|
style={{ fontFamily: FontFamily['head'] }}
|
||||||
// onClick={() => AddBookingDetails(BookingType, true)}
|
// onClick={() => AddBookingDetails(BookingType, true)}
|
||||||
>
|
>
|
||||||
{isMobile ? (
|
{isMobile ? (
|
||||||
`₹ ${Math.round(
|
`₹ ${Math.round(
|
||||||
|
|
@ -4530,9 +4533,9 @@ const BSBilling4Payment = () => {
|
||||||
? FailedTotalAmt
|
? FailedTotalAmt
|
||||||
: credit && overAllBal >= 0
|
: credit && overAllBal >= 0
|
||||||
? Math.max(
|
? Math.max(
|
||||||
0,
|
0,
|
||||||
TotalAmount - overAllBal
|
TotalAmount - overAllBal
|
||||||
)
|
)
|
||||||
: TotalAmount
|
: TotalAmount
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
|
|
@ -4708,8 +4711,8 @@ const BSBilling4Payment = () => {
|
||||||
columns={columns}
|
columns={columns}
|
||||||
data={TableData}
|
data={TableData}
|
||||||
dataSource={TableData}
|
dataSource={TableData}
|
||||||
// pagination={handlePageChange}
|
// pagination={handlePageChange}
|
||||||
// onChange={handleChange}
|
// onChange={handleChange}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
|
@ -4740,14 +4743,14 @@ const BSBilling4Payment = () => {
|
||||||
OrderType === 'Failed'
|
OrderType === 'Failed'
|
||||||
? FailedTotalAmt
|
? FailedTotalAmt
|
||||||
: Math.round(
|
: Math.round(
|
||||||
OrderCardDetail?.reduce(
|
OrderCardDetail?.reduce(
|
||||||
(acc, data) => data?.TotalAmt + acc,
|
(acc, data) => data?.TotalAmt + acc,
|
||||||
0
|
0
|
||||||
) -
|
) -
|
||||||
((OverAllSales > 0 ? OverAllSales : 0) +
|
((OverAllSales > 0 ? OverAllSales : 0) +
|
||||||
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
||||||
(Discount > 0 ? Discount : 0))
|
(Discount > 0 ? Discount : 0))
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
failedOrderData={failedOrderData}
|
failedOrderData={failedOrderData}
|
||||||
/>
|
/>
|
||||||
|
|
@ -4825,9 +4828,9 @@ const BSBilling4Payment = () => {
|
||||||
|
|
||||||
const qty = isGroup
|
const qty = isGroup
|
||||||
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
||||||
(sum, o) => sum + (o.OrderQty || 1),
|
(sum, o) => sum + (o.OrderQty || 1),
|
||||||
0
|
0
|
||||||
)
|
)
|
||||||
: item.OrderQty || 1;
|
: item.OrderQty || 1;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
||||||
|
|
@ -2594,12 +2594,12 @@ const BSBillingTable4 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2865,12 +2865,12 @@ const BSBillingTable4 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3189,12 +3189,12 @@ const BSBillingTable4 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3491,12 +3491,12 @@ const BSBillingTable4 = () => {
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
|
||||||
|
|
@ -1166,7 +1166,7 @@ const BSBillingTable5 = () => {
|
||||||
|
|
||||||
const selectedStyle =
|
const selectedStyle =
|
||||||
stylesMap[
|
stylesMap[
|
||||||
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
||||||
];
|
];
|
||||||
|
|
||||||
if (selectedStyle) {
|
if (selectedStyle) {
|
||||||
|
|
@ -2122,15 +2122,15 @@ const BSBillingTable5 = () => {
|
||||||
OrderStatus: 'O',
|
OrderStatus: 'O',
|
||||||
OrderType:
|
OrderType:
|
||||||
BookingType === 'Dine In' ||
|
BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
Estimation?.SettingValue == 'N'
|
Estimation?.SettingValue == 'N'
|
||||||
? 'S'
|
? 'S'
|
||||||
: GlobEstBooking === 'OvrAllEst'
|
: GlobEstBooking === 'OvrAllEst'
|
||||||
? 'E'
|
? 'E'
|
||||||
: GlobEstBooking === 'ParEst'
|
: GlobEstBooking === 'ParEst'
|
||||||
? GlobProdwisedata?.includes(
|
? GlobProdwisedata?.includes(
|
||||||
a.InwardDtlId + ' ' + a?.BookingTypeName
|
a.InwardDtlId + ' ' + a?.BookingTypeName
|
||||||
)
|
)
|
||||||
? 'E'
|
? 'E'
|
||||||
: 'S'
|
: 'S'
|
||||||
: 'S',
|
: 'S',
|
||||||
|
|
@ -2147,6 +2147,9 @@ const BSBillingTable5 = () => {
|
||||||
BatchRef: a.BatchRef,
|
BatchRef: a.BatchRef,
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
SetCount: a.SetCount,
|
||||||
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt })
|
||||||
}));
|
}));
|
||||||
const NotSlectedTypeFind = temporderdetail?.find(
|
const NotSlectedTypeFind = temporderdetail?.find(
|
||||||
(a) => a?.BookingType != SelectedBookingType
|
(a) => a?.BookingType != SelectedBookingType
|
||||||
|
|
@ -2221,7 +2224,7 @@ const BSBillingTable5 = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
OrderDtlDetails:
|
OrderDtlDetails:
|
||||||
|
|
@ -2238,9 +2241,9 @@ const BSBillingTable5 = () => {
|
||||||
? globalTipAmount === 0
|
? globalTipAmount === 0
|
||||||
? SelectedTableDetails
|
? SelectedTableDetails
|
||||||
: SelectedTableDetails?.map((item) => ({
|
: SelectedTableDetails?.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
TipsAmount: globalTipAmount,
|
TipsAmount: globalTipAmount,
|
||||||
}))
|
}))
|
||||||
: null,
|
: null,
|
||||||
SalesPaymentType: 'normal',
|
SalesPaymentType: 'normal',
|
||||||
PaymentDetail: [
|
PaymentDetail: [
|
||||||
|
|
@ -2255,8 +2258,8 @@ const BSBillingTable5 = () => {
|
||||||
? PaymentgatewayUPI?.[0]?.ModeId
|
? PaymentgatewayUPI?.[0]?.ModeId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.ModeId
|
)?.ModeId
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
? paybtnselected
|
? paybtnselected
|
||||||
|
|
@ -2269,15 +2272,15 @@ const BSBillingTable5 = () => {
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? null
|
? null
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'business'
|
SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
||||||
?.MerchantId
|
?.MerchantId
|
||||||
: null,
|
: null,
|
||||||
PaymentOptionType:
|
PaymentOptionType:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit')
|
refundPaySelectedName?.toLowerCase() === 'credit')
|
||||||
? 'PC'
|
? 'PC'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'cash'
|
: Paybtnnameselected?.toLowerCase() === 'cash'
|
||||||
? 'PC'
|
? 'PC'
|
||||||
|
|
@ -2297,29 +2300,29 @@ const BSBillingTable5 = () => {
|
||||||
? null
|
? null
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
||||||
?.UPIDetailId
|
?.UPIDetailId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.MerchantUPIId
|
)?.MerchantUPIId
|
||||||
: null,
|
: null,
|
||||||
AccountDtl:
|
AccountDtl:
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? []
|
? []
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
||||||
(upipay) => upipay?.UPIId === UpiId
|
(upipay) => upipay?.UPIId === UpiId
|
||||||
)
|
)
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pd')
|
SelectedCardOption?.toLowerCase() === 'pd')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pg')
|
SelectedCardOption?.toLowerCase() === 'pg')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
||||||
: [],
|
: [],
|
||||||
PaymentStatus:
|
PaymentStatus:
|
||||||
|
|
@ -2330,13 +2333,13 @@ const BSBillingTable5 = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
Debit:
|
Debit:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit'
|
refundPaySelectedName?.toLowerCase() === 'credit'
|
||||||
? Math.round(previousNetAmount - currentOrderNetAmount)
|
? Math.round(previousNetAmount - currentOrderNetAmount)
|
||||||
: 0,
|
: 0,
|
||||||
Credit: salesBillEdit
|
Credit: salesBillEdit
|
||||||
|
|
@ -2411,14 +2414,14 @@ const BSBillingTable5 = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2577,14 +2580,14 @@ const BSBillingTable5 = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2691,14 +2694,14 @@ const BSBillingTable5 = () => {
|
||||||
}
|
}
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
if (response?.data?.OrderDetails?.length > 0) {
|
if (response?.data?.OrderDetails?.length > 0) {
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2874,14 +2877,14 @@ const BSBillingTable5 = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
bookingpaymentupdate?.data?.response +
|
bookingpaymentupdate?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
||||||
? bookingpaymentupdate?.data?.OrderId &&
|
? bookingpaymentupdate?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
bookingpaymentupdate?.data?.OrderId,
|
bookingpaymentupdate?.data?.OrderId,
|
||||||
rbookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
rbookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
||||||
|
|
@ -2900,7 +2903,7 @@ const BSBillingTable5 = () => {
|
||||||
if (
|
if (
|
||||||
Date.now() - startTime >
|
Date.now() - startTime >
|
||||||
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
||||||
60000
|
60000
|
||||||
) {
|
) {
|
||||||
// 60,000 ms = 1 minute
|
// 60,000 ms = 1 minute
|
||||||
|
|
||||||
|
|
@ -3746,32 +3749,32 @@ const BSBillingTable5 = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{paybtns?.length > 0 &&
|
{paybtns?.length > 0 &&
|
||||||
currentOrderNetAmount >= previousNetAmount ? (
|
currentOrderNetAmount >= previousNetAmount ? (
|
||||||
paybtns?.map((payment) => (
|
paybtns?.map((payment) => (
|
||||||
<div className="Table3-cash">
|
<div className="Table3-cash">
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
paybtnselected === payment.ModeId &&
|
paybtnselected === payment.ModeId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: paybtnselected === payment.ModeId &&
|
: paybtnselected === payment.ModeId &&
|
||||||
(!UpinotSelected ||
|
(!UpinotSelected ||
|
||||||
!CardoptionnotSelected)
|
!CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -3785,13 +3788,13 @@ const BSBillingTable5 = () => {
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
||||||
? handleUPIButtonClick(
|
? handleUPIButtonClick(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
: handlePaymentMode(
|
: handlePaymentMode(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
|
|
@ -3804,16 +3807,16 @@ const BSBillingTable5 = () => {
|
||||||
{payment.ModeName}
|
{payment.ModeName}
|
||||||
{payment?.ModeName?.toLowerCase() ===
|
{payment?.ModeName?.toLowerCase() ===
|
||||||
'card' && (
|
'card' && (
|
||||||
<CardPopover
|
<CardPopover
|
||||||
CardPayOption={CardPayOption}
|
CardPayOption={CardPayOption}
|
||||||
SelectedCardOption={SelectedCardOption}
|
SelectedCardOption={SelectedCardOption}
|
||||||
AddCardOption={AddCardOption}
|
AddCardOption={AddCardOption}
|
||||||
CardOptionOpen={CardOptionOpen}
|
CardOptionOpen={CardOptionOpen}
|
||||||
EnableCardOptions={EnableCardOptions}
|
EnableCardOptions={EnableCardOptions}
|
||||||
paygate={paygate}
|
paygate={paygate}
|
||||||
paydevice={paydevice}
|
paydevice={paydevice}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
{payment?.ModeName?.toLowerCase() === 'upi' && (
|
{payment?.ModeName?.toLowerCase() === 'upi' && (
|
||||||
<UpiPopover
|
<UpiPopover
|
||||||
defaultPaymentMode={defaultPaymentMode}
|
defaultPaymentMode={defaultPaymentMode}
|
||||||
|
|
@ -3849,11 +3852,11 @@ const BSBillingTable5 = () => {
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
refundPaySelected === payment.ConfigId &&
|
refundPaySelected === payment.ConfigId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: refundPaySelected === payment.ConfigId &&
|
: refundPaySelected === payment.ConfigId &&
|
||||||
(!UpinotSelected ||
|
(!UpinotSelected ||
|
||||||
!CardoptionnotSelected)
|
!CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -4064,16 +4067,16 @@ const BSBillingTable5 = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
width: '2rem',
|
width: '2rem',
|
||||||
|
|
@ -4093,14 +4096,14 @@ const BSBillingTable5 = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -4147,9 +4150,9 @@ const BSBillingTable5 = () => {
|
||||||
OrderCardDetail?.length > 0 && 'not-allowed',
|
OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(selOption?.value === undefined &&
|
(selOption?.value === undefined &&
|
||||||
GlobalAddCustomerDetails1?.length === 0 &&
|
GlobalAddCustomerDetails1?.length === 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
|
|
@ -4165,38 +4168,38 @@ const BSBillingTable5 = () => {
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(OrderCardDetail?.length > 0)
|
!(OrderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(OrderCardDetail?.length > 0 &&
|
(OrderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
{tabledata?.length > 0 && dinePreference && (
|
{tabledata?.length > 0 && dinePreference && (
|
||||||
<div style={{ width: '2rem' }}>
|
<div style={{ width: '2rem' }}>
|
||||||
{tableOptions
|
{tableOptions
|
||||||
|
|
@ -4240,14 +4243,14 @@ const BSBillingTable5 = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -4297,28 +4300,28 @@ const BSBillingTable5 = () => {
|
||||||
<>
|
<>
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
OrderCardDetail?.length != 0 &&
|
OrderCardDetail?.length != 0 &&
|
||||||
CheckOrderType?.length === 0 &&
|
CheckOrderType?.length === 0 &&
|
||||||
OrderType != 'Failed' &&
|
OrderType != 'Failed' &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
||||||
<button
|
<button
|
||||||
className="BSBIllingTable5-cnclbtn"
|
className="BSBIllingTable5-cnclbtn"
|
||||||
onClick={() => AddBookingDetails('Hold')}
|
onClick={() => AddBookingDetails('Hold')}
|
||||||
style={{
|
style={{
|
||||||
color: 'default',
|
color: 'default',
|
||||||
backgroundColor: '#eef3f3',
|
backgroundColor: '#eef3f3',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<p className="BigScreen">HOLD ✋</p>
|
<p className="BigScreen">HOLD ✋</p>
|
||||||
<span className="SmallScreen">✋</span>
|
<span className="SmallScreen">✋</span>
|
||||||
</button>
|
</button>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
{unpaidFlow === false &&
|
{unpaidFlow === false &&
|
||||||
item?.OptionName === 'Hold' &&
|
item?.OptionName === 'Hold' &&
|
||||||
|
|
@ -4357,9 +4360,9 @@ const BSBillingTable5 = () => {
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'BSBIllingTable5-paybtn-noitems-disable'
|
? 'BSBIllingTable5-paybtn-noitems-disable'
|
||||||
: FirstPaymentclick === false &&
|
: FirstPaymentclick === false &&
|
||||||
OrderCardDetail?.length > 0 &&
|
OrderCardDetail?.length > 0 &&
|
||||||
paybtnselected &&
|
paybtnselected &&
|
||||||
CheckBookingStatus != 'Close'
|
CheckBookingStatus != 'Close'
|
||||||
? !OrderStatus
|
? !OrderStatus
|
||||||
? salesBillEdit &&
|
? salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount
|
currentOrderNetAmount < previousNetAmount
|
||||||
|
|
@ -4378,7 +4381,7 @@ const BSBillingTable5 = () => {
|
||||||
>
|
>
|
||||||
{!OrderStatus ? (
|
{!OrderStatus ? (
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount ? (
|
currentOrderNetAmount < previousNetAmount ? (
|
||||||
<div>
|
<div>
|
||||||
Refund: ₹
|
Refund: ₹
|
||||||
{(previousNetAmount || 0) -
|
{(previousNetAmount || 0) -
|
||||||
|
|
@ -4601,14 +4604,14 @@ const BSBillingTable5 = () => {
|
||||||
OrderType === 'Failed'
|
OrderType === 'Failed'
|
||||||
? FailedTotalAmt
|
? FailedTotalAmt
|
||||||
: Math.round(
|
: Math.round(
|
||||||
OrderCardDetail?.reduce(
|
OrderCardDetail?.reduce(
|
||||||
(acc, data) => data?.TotalAmt + acc,
|
(acc, data) => data?.TotalAmt + acc,
|
||||||
0
|
0
|
||||||
) -
|
) -
|
||||||
((OverAllSales > 0 ? OverAllSales : 0) +
|
((OverAllSales > 0 ? OverAllSales : 0) +
|
||||||
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
||||||
(Discount > 0 ? Discount : 0))
|
(Discount > 0 ? Discount : 0))
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
failedOrderData={failedOrderData}
|
failedOrderData={failedOrderData}
|
||||||
/>
|
/>
|
||||||
|
|
@ -4636,14 +4639,14 @@ const BSBillingTable5 = () => {
|
||||||
{(filteredSettingNames?.includes('Print') ||
|
{(filteredSettingNames?.includes('Print') ||
|
||||||
!MobileNoWhatsApp ||
|
!MobileNoWhatsApp ||
|
||||||
!MobileNoWhatsApp.value) && (
|
!MobileNoWhatsApp.value) && (
|
||||||
<FaPrint
|
<FaPrint
|
||||||
size={32}
|
size={32}
|
||||||
color="#1292EE"
|
color="#1292EE"
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
onClick={handlePrintOrToken}
|
onClick={handlePrintOrToken}
|
||||||
title="Print"
|
title="Print"
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{filteredSettingNames?.includes('SMS') && isMobile && (
|
{filteredSettingNames?.includes('SMS') && isMobile && (
|
||||||
<MdSms
|
<MdSms
|
||||||
|
|
@ -4726,9 +4729,9 @@ const BSBillingTable5 = () => {
|
||||||
|
|
||||||
const qty = isGroup
|
const qty = isGroup
|
||||||
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
||||||
(sum, o) => sum + (o.OrderQty || 1),
|
(sum, o) => sum + (o.OrderQty || 1),
|
||||||
0
|
0
|
||||||
)
|
)
|
||||||
: item.OrderQty || 1;
|
: item.OrderQty || 1;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
||||||
|
|
@ -2397,15 +2397,15 @@ const BSBillingTable6 = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2652,15 +2652,15 @@ const BSBillingTable6 = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2954,14 +2954,14 @@ const BSBillingTable6 = () => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3237,15 +3237,16 @@ const BSBillingTable6 = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
import React, { useEffect, useState, useRef, lazy ,Suspense } from 'react';
|
import React, { useEffect, useState, useRef, lazy, Suspense } from 'react';
|
||||||
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
|
import { shallowEqual, useDispatch, useSelector } from 'react-redux';
|
||||||
import { useNavigate } from 'react-router-dom';
|
import { useNavigate } from 'react-router-dom';
|
||||||
import moment from 'moment';
|
import moment from 'moment';
|
||||||
|
|
@ -469,7 +469,7 @@ const BST6Payment = () => {
|
||||||
// for customised invoice number
|
// for customised invoice number
|
||||||
const { invoiceDate, clearInvoiceDate } = useDateStore();
|
const { invoiceDate, clearInvoiceDate } = useDateStore();
|
||||||
const CurrentOrderId = useSelector(GlobalCurrentOrderId);
|
const CurrentOrderId = useSelector(GlobalCurrentOrderId);
|
||||||
const holdCheckedSalesSetup = tableOptions?.some(
|
const holdCheckedSalesSetup = tableOptions?.some(
|
||||||
(item) => item?.OptionName === 'Hold'
|
(item) => item?.OptionName === 'Hold'
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -759,7 +759,7 @@ const BST6Payment = () => {
|
||||||
|
|
||||||
const selectedStyle =
|
const selectedStyle =
|
||||||
stylesMap[
|
stylesMap[
|
||||||
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
||||||
];
|
];
|
||||||
|
|
||||||
if (selectedStyle) {
|
if (selectedStyle) {
|
||||||
|
|
@ -2112,15 +2112,15 @@ const BST6Payment = () => {
|
||||||
OrderStatus: 'O',
|
OrderStatus: 'O',
|
||||||
OrderType:
|
OrderType:
|
||||||
BookingType === 'Dine In' ||
|
BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
Estimation?.SettingValue == 'N'
|
Estimation?.SettingValue == 'N'
|
||||||
? 'S'
|
? 'S'
|
||||||
: GlobEstBooking === 'OvrAllEst'
|
: GlobEstBooking === 'OvrAllEst'
|
||||||
? 'E'
|
? 'E'
|
||||||
: GlobEstBooking === 'ParEst'
|
: GlobEstBooking === 'ParEst'
|
||||||
? GlobProdwisedata?.includes(
|
? GlobProdwisedata?.includes(
|
||||||
a.InwardDtlId + ' ' + a?.BookingTypeName
|
a.InwardDtlId + ' ' + a?.BookingTypeName
|
||||||
)
|
)
|
||||||
? 'E'
|
? 'E'
|
||||||
: 'S'
|
: 'S'
|
||||||
: 'S',
|
: 'S',
|
||||||
|
|
@ -2137,6 +2137,9 @@ const BST6Payment = () => {
|
||||||
BatchRef: a.BatchRef,
|
BatchRef: a.BatchRef,
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
SetCount: a.SetCount,
|
||||||
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt })
|
||||||
}));
|
}));
|
||||||
const NotSlectedTypeFind = temporderdetail?.find(
|
const NotSlectedTypeFind = temporderdetail?.find(
|
||||||
(a) => a?.BookingType != SelectedBookingType
|
(a) => a?.BookingType != SelectedBookingType
|
||||||
|
|
@ -2210,7 +2213,7 @@ const BST6Payment = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
OrderDtlDetails:
|
OrderDtlDetails:
|
||||||
|
|
@ -2227,9 +2230,9 @@ const BST6Payment = () => {
|
||||||
? globalTipAmount === 0
|
? globalTipAmount === 0
|
||||||
? SelectedTableDetails
|
? SelectedTableDetails
|
||||||
: SelectedTableDetails?.map((item) => ({
|
: SelectedTableDetails?.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
TipsAmount: globalTipAmount,
|
TipsAmount: globalTipAmount,
|
||||||
}))
|
}))
|
||||||
: null,
|
: null,
|
||||||
SalesPaymentType: 'normal',
|
SalesPaymentType: 'normal',
|
||||||
PaymentDetail: [
|
PaymentDetail: [
|
||||||
|
|
@ -2244,8 +2247,8 @@ const BST6Payment = () => {
|
||||||
? PaymentgatewayUPI?.[0]?.ModeId
|
? PaymentgatewayUPI?.[0]?.ModeId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.ModeId
|
)?.ModeId
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
? paybtnselected
|
? paybtnselected
|
||||||
|
|
@ -2258,15 +2261,15 @@ const BST6Payment = () => {
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? null
|
? null
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'business'
|
SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
||||||
?.MerchantId
|
?.MerchantId
|
||||||
: null,
|
: null,
|
||||||
PaymentOptionType:
|
PaymentOptionType:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit')
|
refundPaySelectedName?.toLowerCase() === 'credit')
|
||||||
? 'PC'
|
? 'PC'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'cash'
|
: Paybtnnameselected?.toLowerCase() === 'cash'
|
||||||
? 'PC'
|
? 'PC'
|
||||||
|
|
@ -2286,29 +2289,29 @@ const BST6Payment = () => {
|
||||||
? null
|
? null
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
||||||
?.UPIDetailId
|
?.UPIDetailId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.MerchantUPIId
|
)?.MerchantUPIId
|
||||||
: null,
|
: null,
|
||||||
AccountDtl:
|
AccountDtl:
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? []
|
? []
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
||||||
(upipay) => upipay?.UPIId === UpiId
|
(upipay) => upipay?.UPIId === UpiId
|
||||||
)
|
)
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pd')
|
SelectedCardOption?.toLowerCase() === 'pd')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pg')
|
SelectedCardOption?.toLowerCase() === 'pg')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
||||||
: [],
|
: [],
|
||||||
PaymentStatus:
|
PaymentStatus:
|
||||||
|
|
@ -2319,13 +2322,13 @@ const BST6Payment = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
Debit:
|
Debit:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit'
|
refundPaySelectedName?.toLowerCase() === 'credit'
|
||||||
? Math.round(previousNetAmount - currentOrderNetAmount)
|
? Math.round(previousNetAmount - currentOrderNetAmount)
|
||||||
: 0,
|
: 0,
|
||||||
Credit: salesBillEdit
|
Credit: salesBillEdit
|
||||||
|
|
@ -2402,14 +2405,14 @@ const BST6Payment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2570,14 +2573,14 @@ const BST6Payment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2684,14 +2687,14 @@ const BST6Payment = () => {
|
||||||
}
|
}
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
if (response?.data?.OrderDetails?.length > 0) {
|
if (response?.data?.OrderDetails?.length > 0) {
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2867,14 +2870,14 @@ const BST6Payment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
bookingpaymentupdate?.data?.response +
|
bookingpaymentupdate?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
||||||
? bookingpaymentupdate?.data?.OrderId &&
|
? bookingpaymentupdate?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
bookingpaymentupdate?.data?.OrderId,
|
bookingpaymentupdate?.data?.OrderId,
|
||||||
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
||||||
|
|
@ -2893,7 +2896,7 @@ const BST6Payment = () => {
|
||||||
if (
|
if (
|
||||||
Date.now() - startTime >
|
Date.now() - startTime >
|
||||||
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
||||||
60000
|
60000
|
||||||
) {
|
) {
|
||||||
// 60,000 ms = 1 minute
|
// 60,000 ms = 1 minute
|
||||||
|
|
||||||
|
|
@ -3596,59 +3599,59 @@ const BST6Payment = () => {
|
||||||
<>
|
<>
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
OrderCardDetail?.length != 0 &&
|
OrderCardDetail?.length != 0 &&
|
||||||
CheckOrderType?.length === 0 &&
|
CheckOrderType?.length === 0 &&
|
||||||
OrderType != 'Failed' &&
|
OrderType != 'Failed' &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
!addnewAccess && (
|
!addnewAccess && (
|
||||||
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
<TooltipWrapper title={'Hold'} isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<PozoHoldIcon
|
<PozoHoldIcon
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => AddBookingDetails('Hold')}
|
onClick={() => AddBookingDetails('Hold')}
|
||||||
style={{
|
style={{
|
||||||
fontSize: '30px',
|
fontSize: '30px',
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
color: '' ? '#52c41a' : '#1292EE',
|
color: '' ? '#52c41a' : '#1292EE',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
{unpaidFlow == false
|
{unpaidFlow == false
|
||||||
? item?.OptionName == 'Hold' &&
|
? item?.OptionName == 'Hold' &&
|
||||||
BookingType !== 'Dine In' &&
|
BookingType !== 'Dine In' &&
|
||||||
!BookingTypeBoth &&
|
!BookingTypeBoth &&
|
||||||
Holddata?.length > 0 &&
|
Holddata?.length > 0 &&
|
||||||
OrderCardDetail?.length == 0 &&
|
OrderCardDetail?.length == 0 &&
|
||||||
CheckBookingStatus != 'Close' &&
|
CheckBookingStatus != 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
paybtns?.length > 0 &&
|
paybtns?.length > 0 &&
|
||||||
!OtherServicesglobal && (
|
!OtherServicesglobal && (
|
||||||
<TooltipWrapper title={'Recall'} isMobile={isMobile}>
|
<TooltipWrapper title={'Recall'} isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<Badge
|
<Badge
|
||||||
count={Holddata?.length}
|
count={Holddata?.length}
|
||||||
size={'small'}
|
size={'small'}
|
||||||
offset={[0, 7]}
|
offset={[0, 7]}
|
||||||
>
|
>
|
||||||
<PozoHoldIcon
|
<PozoHoldIcon
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => HandleholdModelOpen()}
|
onClick={() => HandleholdModelOpen()}
|
||||||
style={{
|
style={{
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
cursor: 'pointer',
|
cursor: 'pointer',
|
||||||
color: Holddata ? '#52c41a' : 'default',
|
color: Holddata ? '#52c41a' : 'default',
|
||||||
pointerEvents:
|
pointerEvents:
|
||||||
OrderType === 'Failed' ? 'none' : 'auto',
|
OrderType === 'Failed' ? 'none' : 'auto',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</Badge>
|
</Badge>
|
||||||
</TooltipWrapper>
|
</TooltipWrapper>
|
||||||
)
|
)
|
||||||
: ''}
|
: ''}
|
||||||
</>
|
</>
|
||||||
))}
|
))}
|
||||||
|
|
@ -3659,16 +3662,16 @@ const BST6Payment = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
width: '2rem',
|
width: '2rem',
|
||||||
|
|
@ -3688,14 +3691,14 @@ const BST6Payment = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3761,31 +3764,31 @@ const BST6Payment = () => {
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 'none'
|
? 'none'
|
||||||
: 'auto',
|
: 'auto',
|
||||||
opacity:
|
opacity:
|
||||||
(BookingType === 'Dine In' ||
|
(BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
CheckOrderType?.length > 0) &&
|
CheckOrderType?.length > 0) &&
|
||||||
!unpaidFlow &&
|
!unpaidFlow &&
|
||||||
OrderStatus
|
OrderStatus
|
||||||
? 0.5
|
? 0.5
|
||||||
: 1,
|
: 1,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{paybtns?.length > 0 &&
|
{paybtns?.length > 0 &&
|
||||||
currentOrderNetAmount >= previousNetAmount ? (
|
currentOrderNetAmount >= previousNetAmount ? (
|
||||||
paybtns?.map((payment) => (
|
paybtns?.map((payment) => (
|
||||||
<div className="Table6-cash">
|
<div className="Table6-cash">
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
paybtnselected === payment.ModeId &&
|
paybtnselected === payment.ModeId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: paybtnselected === payment.ModeId &&
|
: paybtnselected === payment.ModeId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -3799,13 +3802,13 @@ const BST6Payment = () => {
|
||||||
onClick={() =>
|
onClick={() =>
|
||||||
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
payment?.ModeName?.toLowerCase() === 'upi' // Change the condition to payment.Id
|
||||||
? handleUPIButtonClick(
|
? handleUPIButtonClick(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
: handlePaymentMode(
|
: handlePaymentMode(
|
||||||
payment.ModeId,
|
payment.ModeId,
|
||||||
payment.ModeName
|
payment.ModeName
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
{/* {UpiOption === "" && payment?.Name?.toLowerCase() === "upi" && <p> UPI</p>} */}
|
{/* {UpiOption === "" && payment?.Name?.toLowerCase() === "upi" && <p> UPI</p>} */}
|
||||||
|
|
@ -3864,10 +3867,10 @@ const BST6Payment = () => {
|
||||||
<button
|
<button
|
||||||
className={
|
className={
|
||||||
refundPaySelected === payment.ConfigId &&
|
refundPaySelected === payment.ConfigId &&
|
||||||
(UpinotSelected || CardoptionnotSelected)
|
(UpinotSelected || CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode-notupisel'
|
? 'Btn-payment-mode-notupisel'
|
||||||
: refundPaySelected === payment.ConfigId &&
|
: refundPaySelected === payment.ConfigId &&
|
||||||
(!UpinotSelected || !CardoptionnotSelected)
|
(!UpinotSelected || !CardoptionnotSelected)
|
||||||
? 'Btn-payment-mode'
|
? 'Btn-payment-mode'
|
||||||
: 'Btn-payment-mode-sel'
|
: 'Btn-payment-mode-sel'
|
||||||
}
|
}
|
||||||
|
|
@ -3918,9 +3921,9 @@ const BST6Payment = () => {
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'BST6Payment-Button-pay-disabled'
|
? 'BST6Payment-Button-pay-disabled'
|
||||||
: FirstPaymentclick === false &&
|
: FirstPaymentclick === false &&
|
||||||
OrderCardDetail?.length > 0 &&
|
OrderCardDetail?.length > 0 &&
|
||||||
paybtnselected &&
|
paybtnselected &&
|
||||||
CheckBookingStatus != 'Close'
|
CheckBookingStatus != 'Close'
|
||||||
? !OrderStatus
|
? !OrderStatus
|
||||||
? salesBillEdit &&
|
? salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount
|
currentOrderNetAmount < previousNetAmount
|
||||||
|
|
@ -3942,7 +3945,7 @@ const BST6Payment = () => {
|
||||||
>
|
>
|
||||||
{!OrderStatus ? (
|
{!OrderStatus ? (
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount ? (
|
currentOrderNetAmount < previousNetAmount ? (
|
||||||
<div>
|
<div>
|
||||||
Refund: ₹
|
Refund: ₹
|
||||||
{(previousNetAmount || 0) -
|
{(previousNetAmount || 0) -
|
||||||
|
|
@ -4094,9 +4097,9 @@ const BST6Payment = () => {
|
||||||
>
|
>
|
||||||
<div className="BST6Payment-buttons">
|
<div className="BST6Payment-buttons">
|
||||||
{paybtnselected ==
|
{paybtnselected ==
|
||||||
paybtns?.filter(
|
paybtns?.filter(
|
||||||
(item) => item?.ModeName?.toLowerCase() === 'cash'
|
(item) => item?.ModeName?.toLowerCase() === 'cash'
|
||||||
)?.[0]?.ModeId ? (
|
)?.[0]?.ModeId ? (
|
||||||
<PaymentInput
|
<PaymentInput
|
||||||
totalAmount={TotalAmount}
|
totalAmount={TotalAmount}
|
||||||
BillingTableName="BillingTable6"
|
BillingTableName="BillingTable6"
|
||||||
|
|
@ -4135,9 +4138,9 @@ const BST6Payment = () => {
|
||||||
OrderCardDetail?.length > 0 && 'not-allowed',
|
OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(selOption?.value === undefined &&
|
(selOption?.value === undefined &&
|
||||||
GlobalAddCustomerDetails1?.length === 0 &&
|
GlobalAddCustomerDetails1?.length === 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
|
|
@ -4154,38 +4157,38 @@ const BST6Payment = () => {
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(OrderCardDetail?.length > 0)
|
!(OrderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(OrderCardDetail?.length > 0 &&
|
(OrderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
{tabledata?.length > 0 && dinePreference && (
|
{tabledata?.length > 0 && dinePreference && (
|
||||||
<div style={{ width: '2rem' }}>
|
<div style={{ width: '2rem' }}>
|
||||||
{tableOptions
|
{tableOptions
|
||||||
|
|
@ -4229,14 +4232,14 @@ const BST6Payment = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length === 0 ||
|
OrderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -4474,14 +4477,14 @@ const BST6Payment = () => {
|
||||||
OrderType === 'Failed'
|
OrderType === 'Failed'
|
||||||
? FailedTotalAmt
|
? FailedTotalAmt
|
||||||
: Math.round(
|
: Math.round(
|
||||||
OrderCardDetail?.reduce(
|
OrderCardDetail?.reduce(
|
||||||
(acc, data) => data?.TotalAmt + acc,
|
(acc, data) => data?.TotalAmt + acc,
|
||||||
0
|
0
|
||||||
) -
|
) -
|
||||||
((OverAllSales > 0 ? OverAllSales : 0) +
|
((OverAllSales > 0 ? OverAllSales : 0) +
|
||||||
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
||||||
(Discount > 0 ? Discount : 0))
|
(Discount > 0 ? Discount : 0))
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
failedOrderData={failedOrderData}
|
failedOrderData={failedOrderData}
|
||||||
/>
|
/>
|
||||||
|
|
@ -4588,9 +4591,9 @@ const BST6Payment = () => {
|
||||||
|
|
||||||
const qty = isGroup
|
const qty = isGroup
|
||||||
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
||||||
(sum, o) => sum + (o.OrderQty || 1),
|
(sum, o) => sum + (o.OrderQty || 1),
|
||||||
0
|
0
|
||||||
)
|
)
|
||||||
: item.OrderQty || 1;
|
: item.OrderQty || 1;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
@ -4781,9 +4784,9 @@ const BST6Payment = () => {
|
||||||
|
|
||||||
const qty = isGroup
|
const qty = isGroup
|
||||||
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
? OrderCardDetail.filter((o) => o.id === groupKey).reduce(
|
||||||
(sum, o) => sum + (o.OrderQty || 1),
|
(sum, o) => sum + (o.OrderQty || 1),
|
||||||
0
|
0
|
||||||
)
|
)
|
||||||
: item.OrderQty || 1;
|
: item.OrderQty || 1;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
||||||
|
|
@ -240,7 +240,7 @@ const BSBilling7Payment = () => {
|
||||||
const screenwidth = useSelector(GlobalScreenSize);
|
const screenwidth = useSelector(GlobalScreenSize);
|
||||||
const defaultBookingType = useSelector(GlobalDefaultBookingType);
|
const defaultBookingType = useSelector(GlobalDefaultBookingType);
|
||||||
const printerTemplateStyle = useSelector(SelectedPrintTemplate);
|
const printerTemplateStyle = useSelector(SelectedPrintTemplate);
|
||||||
const AllBookingType=useSelector(GlobalAllBookingType)
|
const AllBookingType = useSelector(GlobalAllBookingType)
|
||||||
const FontFamily = useSelector(GlobalSelectedFont);
|
const FontFamily = useSelector(GlobalSelectedFont);
|
||||||
const OrderCardDetail = useSelector(GlobalOrderCardDetails);
|
const OrderCardDetail = useSelector(GlobalOrderCardDetails);
|
||||||
const GetCustId = useSelector(GlobalCustId);
|
const GetCustId = useSelector(GlobalCustId);
|
||||||
|
|
@ -471,7 +471,7 @@ const BSBilling7Payment = () => {
|
||||||
// for customised invoice number
|
// for customised invoice number
|
||||||
const { invoiceDate, clearInvoiceDate } = useDateStore();
|
const { invoiceDate, clearInvoiceDate } = useDateStore();
|
||||||
const CurrentOrderId = useSelector(GlobalCurrentOrderId);
|
const CurrentOrderId = useSelector(GlobalCurrentOrderId);
|
||||||
const holdCheckedSalesSetup = tableOptions?.some(
|
const holdCheckedSalesSetup = tableOptions?.some(
|
||||||
(item) => item?.OptionName === 'Hold'
|
(item) => item?.OptionName === 'Hold'
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -696,9 +696,8 @@ const BSBilling7Payment = () => {
|
||||||
}, []);
|
}, []);
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (CompId && BranchId && AppId) {
|
if (CompId && BranchId && AppId) {
|
||||||
if(holdCheckedSalesSetup)
|
if (holdCheckedSalesSetup) {
|
||||||
{
|
getHolddata();
|
||||||
getHolddata();
|
|
||||||
}
|
}
|
||||||
// getUnpaiddatas();
|
// getUnpaiddatas();
|
||||||
getCustomerData();
|
getCustomerData();
|
||||||
|
|
@ -1627,14 +1626,14 @@ const BSBilling7Payment = () => {
|
||||||
};
|
};
|
||||||
|
|
||||||
const getBookingTypeId = async () => {
|
const getBookingTypeId = async () => {
|
||||||
setConfigDataList(AllBookingType);
|
setConfigDataList(AllBookingType);
|
||||||
let configdata = AllBookingType;
|
let configdata = AllBookingType;
|
||||||
let checkName = BookingTypeBoth ? 'DineIn,TakeAway' : BookingType;
|
let checkName = BookingTypeBoth ? 'DineIn,TakeAway' : BookingType;
|
||||||
|
|
||||||
let filterconfigdata = configdata?.find(
|
let filterconfigdata = configdata?.find(
|
||||||
(a) => a?.ConfigName === checkName
|
(a) => a?.ConfigName === checkName
|
||||||
);
|
);
|
||||||
setSelectedBookingType(filterconfigdata?.ConfigId);
|
setSelectedBookingType(filterconfigdata?.ConfigId);
|
||||||
};
|
};
|
||||||
const gettodaydate = () => {
|
const gettodaydate = () => {
|
||||||
const currentDate = new Date();
|
const currentDate = new Date();
|
||||||
|
|
@ -1926,9 +1925,8 @@ const BSBilling7Payment = () => {
|
||||||
setCurrentOrderNetAmount(0);
|
setCurrentOrderNetAmount(0);
|
||||||
setPreviousNetAmount(0);
|
setPreviousNetAmount(0);
|
||||||
setUpinotSelected(false);
|
setUpinotSelected(false);
|
||||||
if(holdCheckedSalesSetup)
|
if (holdCheckedSalesSetup) {
|
||||||
{
|
getHolddata();
|
||||||
getHolddata();
|
|
||||||
}
|
}
|
||||||
if (defaultBookingType === 'Both') {
|
if (defaultBookingType === 'Both') {
|
||||||
await dispatch(changeBookingType('TakeAway'));
|
await dispatch(changeBookingType('TakeAway'));
|
||||||
|
|
@ -2122,6 +2120,9 @@ const BSBilling7Payment = () => {
|
||||||
BatchRef: a.BatchRef,
|
BatchRef: a.BatchRef,
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
SetCount: a.SetCount,
|
||||||
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt })
|
||||||
}));
|
}));
|
||||||
const NotSlectedTypeFind = temporderdetail?.find(
|
const NotSlectedTypeFind = temporderdetail?.find(
|
||||||
(a) => a?.BookingType != SelectedBookingType
|
(a) => a?.BookingType != SelectedBookingType
|
||||||
|
|
@ -3328,10 +3329,10 @@ const BSBilling7Payment = () => {
|
||||||
setDefaultPaymentMode([]);
|
setDefaultPaymentMode([]);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
if(salesBillEdit){
|
if (salesBillEdit) {
|
||||||
setDefaultPaymentOption();
|
setDefaultPaymentOption();
|
||||||
}
|
}
|
||||||
}, [defaultPaymentTrigger,salesBillEdit]);
|
}, [defaultPaymentTrigger, salesBillEdit]);
|
||||||
|
|
||||||
const Otherserviceprint = async () => {
|
const Otherserviceprint = async () => {
|
||||||
if (OtherServicesPrintDetails?.length > 0) {
|
if (OtherServicesPrintDetails?.length > 0) {
|
||||||
|
|
@ -3652,39 +3653,39 @@ const BSBilling7Payment = () => {
|
||||||
|
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(OrderCardDetail?.length > 0)
|
!(OrderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
cursor: OrderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
OrderCardDetail?.length > 0 ||
|
OrderCardDetail?.length > 0 ||
|
||||||
(OrderCardDetail?.length > 0 &&
|
(OrderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
{tabledata?.length > 0 && dinePreference && (
|
{tabledata?.length > 0 && dinePreference && (
|
||||||
<div style={{ width: '2rem' }}>
|
<div style={{ width: '2rem' }}>
|
||||||
{tableOptions
|
{tableOptions
|
||||||
|
|
|
||||||
|
|
@ -2312,15 +2312,15 @@ const BSBillingTable7 = () => {
|
||||||
fontFamily: 'Poppins',
|
fontFamily: 'Poppins',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
? item.Offer
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: '-'
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
? item?.OfferType === 'F'
|
||||||
? item?.OfferType === 'F'
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
: `${item.OfferPrice}%`
|
||||||
: `${item.OfferPrice}%`
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
: '-'}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2539,14 +2539,14 @@ const BSBillingTable7 = () => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
? item.Offer
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: '-'
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
? item?.OfferType === 'F'
|
||||||
? item?.OfferType === 'F'
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
: `${item.OfferPrice}%`
|
||||||
: `${item.OfferPrice}%`
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
: '-'}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2822,15 +2822,15 @@ const BSBillingTable7 = () => {
|
||||||
fontFamily: 'Poppins',
|
fontFamily: 'Poppins',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
? item.Offer
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: '-'
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
? item?.OfferType === 'F'
|
||||||
? item?.OfferType === 'F'
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
: `${item.OfferPrice}%`
|
||||||
: `${item.OfferPrice}%`
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
: '-'}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3079,15 +3079,15 @@ const BSBillingTable7 = () => {
|
||||||
fontFamily: 'Poppins',
|
fontFamily: 'Poppins',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
? item.Offer
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: '-'
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
? item?.OfferType === 'F'
|
||||||
? item?.OfferType === 'F'
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
: `${item.OfferPrice}%`
|
||||||
: `${item.OfferPrice}%`
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
: '-'}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
|
||||||
|
|
@ -2616,15 +2616,15 @@ const StandardTable = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -2940,15 +2940,15 @@ const StandardTable = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
@ -3317,14 +3317,14 @@ const StandardTable = () => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
@ -3673,15 +3673,15 @@ const StandardTable = () => {
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type != 'C'
|
||||||
? item.Offer && item.Offer > 0
|
? item.Offer && item.Offer > 0
|
||||||
? item.Offer
|
? item.Offer
|
||||||
: '-'
|
: item.DiscountAmt ? item.DiscountAmt : '-'
|
||||||
: item?.OfferPrice && item?.OfferPrice > 0
|
: item?.OfferPrice && item?.OfferPrice > 0
|
||||||
? item?.OfferType === 'F'
|
? item?.OfferType === 'F'
|
||||||
? `₹${safeRound(item.OfferPrice)}`
|
? `₹${safeRound(item.OfferPrice)}`
|
||||||
: `${item.OfferPrice}%`
|
: `${item.OfferPrice}%`
|
||||||
: '-'}
|
: item.DiscountAmt ? item.DiscountAmt : '-'}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{tableitem.OptionName == 'Quantity' && (
|
{tableitem.OptionName == 'Quantity' && (
|
||||||
|
|
|
||||||
|
|
@ -1420,15 +1420,15 @@ const StandardTablePayment = () => {
|
||||||
OrderStatus: 'O',
|
OrderStatus: 'O',
|
||||||
OrderType:
|
OrderType:
|
||||||
BookingType === 'Dine In' ||
|
BookingType === 'Dine In' ||
|
||||||
BookingTypeBoth ||
|
BookingTypeBoth ||
|
||||||
Estimation?.SettingValue == 'N'
|
Estimation?.SettingValue == 'N'
|
||||||
? 'S'
|
? 'S'
|
||||||
: GlobEstBooking === 'OvrAllEst'
|
: GlobEstBooking === 'OvrAllEst'
|
||||||
? 'E'
|
? 'E'
|
||||||
: GlobEstBooking === 'ParEst'
|
: GlobEstBooking === 'ParEst'
|
||||||
? GlobProdwisedata?.includes(
|
? GlobProdwisedata?.includes(
|
||||||
a.InwardDtlId + ' ' + a?.BookingTypeName
|
a.InwardDtlId + ' ' + a?.BookingTypeName
|
||||||
)
|
)
|
||||||
? 'E'
|
? 'E'
|
||||||
: 'S'
|
: 'S'
|
||||||
: 'S',
|
: 'S',
|
||||||
|
|
@ -1445,6 +1445,9 @@ const StandardTablePayment = () => {
|
||||||
BatchRef: a.BatchRef,
|
BatchRef: a.BatchRef,
|
||||||
PackageDtl: a.PackageDtl,
|
PackageDtl: a.PackageDtl,
|
||||||
SetCount: a.SetCount,
|
SetCount: a.SetCount,
|
||||||
|
...(a?.DiscountValue && { DiscountValue: a.DiscountValue }),
|
||||||
|
...(a?.DiscountType && { DiscountType: a.DiscountType }),
|
||||||
|
...(a?.DiscountAmt && { DiscountAmt: a.DiscountAmt }),
|
||||||
BookingDate: AvailableDate
|
BookingDate: AvailableDate
|
||||||
? Object.keys(ReportholdData)?.length > 0
|
? Object.keys(ReportholdData)?.length > 0
|
||||||
? a?.BookingDate
|
? a?.BookingDate
|
||||||
|
|
@ -1524,7 +1527,7 @@ const StandardTablePayment = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
OrderDtlDetails:
|
OrderDtlDetails:
|
||||||
|
|
@ -1541,9 +1544,9 @@ const StandardTablePayment = () => {
|
||||||
? globalTipAmount === 0
|
? globalTipAmount === 0
|
||||||
? SelectedTableDetails
|
? SelectedTableDetails
|
||||||
: SelectedTableDetails?.map((item) => ({
|
: SelectedTableDetails?.map((item) => ({
|
||||||
...item,
|
...item,
|
||||||
TipsAmount: globalTipAmount,
|
TipsAmount: globalTipAmount,
|
||||||
}))
|
}))
|
||||||
: null,
|
: null,
|
||||||
|
|
||||||
SalesPaymentType: 'normal',
|
SalesPaymentType: 'normal',
|
||||||
|
|
@ -1559,8 +1562,8 @@ const StandardTablePayment = () => {
|
||||||
? PaymentgatewayUPI?.[0]?.ModeId
|
? PaymentgatewayUPI?.[0]?.ModeId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.ModeId
|
)?.ModeId
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
: paybtnselected
|
: paybtnselected
|
||||||
? paybtnselected
|
? paybtnselected
|
||||||
|
|
@ -1573,15 +1576,15 @@ const StandardTablePayment = () => {
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? null
|
? null
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'business'
|
SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
? BusinessPayOption?.find((busupi) => busupi?.ModeId === UpiId)
|
||||||
?.MerchantId
|
?.MerchantId
|
||||||
: null,
|
: null,
|
||||||
PaymentOptionType:
|
PaymentOptionType:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
(refundPaySelectedName?.toLowerCase() === 'cash' ||
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit')
|
refundPaySelectedName?.toLowerCase() === 'credit')
|
||||||
? 'PC'
|
? 'PC'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'cash'
|
: Paybtnnameselected?.toLowerCase() === 'cash'
|
||||||
? 'PC'
|
? 'PC'
|
||||||
|
|
@ -1601,29 +1604,29 @@ const StandardTablePayment = () => {
|
||||||
? null
|
? null
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
: SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
? PaymentUpiOptions?.find((upipay) => upipay?.UPIId === UpiId)
|
||||||
?.UPIDetailId
|
?.UPIDetailId
|
||||||
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
: SelectedUPIPayOption?.toLowerCase() === 'business'
|
||||||
? BusinessPayOption?.find(
|
? BusinessPayOption?.find(
|
||||||
(busupi) => busupi?.ModeId === UpiId
|
(busupi) => busupi?.ModeId === UpiId
|
||||||
)?.MerchantUPIId
|
)?.MerchantUPIId
|
||||||
: null,
|
: null,
|
||||||
AccountDtl:
|
AccountDtl:
|
||||||
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? []
|
? []
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
? useOptions?.[0]?.PaymentDetails?.Payatthecounter?.find(
|
||||||
(upipay) => upipay?.UPIId === UpiId
|
(upipay) => upipay?.UPIId === UpiId
|
||||||
)
|
)
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pd') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pd')
|
SelectedCardOption?.toLowerCase() === 'pd')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
? useOptions?.[0]?.PaymentDetails?.PaymentDevice
|
||||||
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: (Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
SelectedUPIPayOption?.toLowerCase() === 'pg') ||
|
||||||
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
(Paybtnnameselected?.toLowerCase() === 'card' &&
|
||||||
SelectedCardOption?.toLowerCase() === 'pg')
|
SelectedCardOption?.toLowerCase() === 'pg')
|
||||||
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
? useOptions?.[0]?.PaymentDetails?.PaymentGateway
|
||||||
: [],
|
: [],
|
||||||
PaymentStatus:
|
PaymentStatus:
|
||||||
|
|
@ -1634,13 +1637,13 @@ const StandardTablePayment = () => {
|
||||||
: Paybtnnameselected?.toLowerCase() === 'credit'
|
: Paybtnnameselected?.toLowerCase() === 'credit'
|
||||||
? 'S'
|
? 'S'
|
||||||
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
: Paybtnnameselected?.toLowerCase() === 'upi' &&
|
||||||
SelectedUPIPayOption?.toLowerCase() === 'default'
|
SelectedUPIPayOption?.toLowerCase() === 'default'
|
||||||
? 'S'
|
? 'S'
|
||||||
: 'P',
|
: 'P',
|
||||||
Debit:
|
Debit:
|
||||||
salesBillEdit &&
|
salesBillEdit &&
|
||||||
currentOrderNetAmount < previousNetAmount &&
|
currentOrderNetAmount < previousNetAmount &&
|
||||||
refundPaySelectedName?.toLowerCase() === 'credit'
|
refundPaySelectedName?.toLowerCase() === 'credit'
|
||||||
? Math.round(previousNetAmount - currentOrderNetAmount)
|
? Math.round(previousNetAmount - currentOrderNetAmount)
|
||||||
: 0,
|
: 0,
|
||||||
Credit: salesBillEdit
|
Credit: salesBillEdit
|
||||||
|
|
@ -1742,14 +1745,14 @@ const StandardTablePayment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -1908,14 +1911,14 @@ const StandardTablePayment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
response?.data?.OrderDetails?.length > 0 &&
|
response?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2020,14 +2023,14 @@ const StandardTablePayment = () => {
|
||||||
}
|
}
|
||||||
setMessageData(
|
setMessageData(
|
||||||
response?.data?.response +
|
response?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(response?.data?.OrderDetails?.length > 0
|
(response?.data?.OrderDetails?.length > 0
|
||||||
? response?.data?.OrderId &&
|
? response?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
response?.data?.OrderId,
|
response?.data?.OrderId,
|
||||||
response?.data?.OrderDetails?.[0]?.FYStatus
|
response?.data?.OrderDetails?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
if (response?.data?.OrderDetails?.length > 0) {
|
if (response?.data?.OrderDetails?.length > 0) {
|
||||||
setPrintOrderDetails([response?.data]);
|
setPrintOrderDetails([response?.data]);
|
||||||
|
|
@ -2101,9 +2104,9 @@ const StandardTablePayment = () => {
|
||||||
AppId: AppId,
|
AppId: AppId,
|
||||||
...(AvailableDate && selectedDate
|
...(AvailableDate && selectedDate
|
||||||
? {
|
? {
|
||||||
fromDate: selectedDate?.[0],
|
fromDate: selectedDate?.[0],
|
||||||
toDate: selectedDate?.[1],
|
toDate: selectedDate?.[1],
|
||||||
}
|
}
|
||||||
: {}),
|
: {}),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -2116,9 +2119,9 @@ const StandardTablePayment = () => {
|
||||||
ProdSubCat: ProdSubCat,
|
ProdSubCat: ProdSubCat,
|
||||||
...(AvailableDate && selectedDate
|
...(AvailableDate && selectedDate
|
||||||
? {
|
? {
|
||||||
fromDate: selectedDate?.[0],
|
fromDate: selectedDate?.[0],
|
||||||
toDate: selectedDate?.[1],
|
toDate: selectedDate?.[1],
|
||||||
}
|
}
|
||||||
: {}),
|
: {}),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -2129,9 +2132,9 @@ const StandardTablePayment = () => {
|
||||||
prodCat: prodCat,
|
prodCat: prodCat,
|
||||||
...(AvailableDate && selectedDate
|
...(AvailableDate && selectedDate
|
||||||
? {
|
? {
|
||||||
fromDate: selectedDate?.[0],
|
fromDate: selectedDate?.[0],
|
||||||
toDate: selectedDate?.[1],
|
toDate: selectedDate?.[1],
|
||||||
}
|
}
|
||||||
: {}),
|
: {}),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -2311,14 +2314,14 @@ const StandardTablePayment = () => {
|
||||||
setMessageType('success');
|
setMessageType('success');
|
||||||
setMessageData(
|
setMessageData(
|
||||||
bookingpaymentupdate?.data?.response +
|
bookingpaymentupdate?.data?.response +
|
||||||
' ' +
|
' ' +
|
||||||
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
(bookingpaymentupdate?.data?.OrderDetails?.length > 0
|
||||||
? bookingpaymentupdate?.data?.OrderId &&
|
? bookingpaymentupdate?.data?.OrderId &&
|
||||||
extractLastNumberOrderId(
|
extractLastNumberOrderId(
|
||||||
bookingpaymentupdate?.data?.OrderId,
|
bookingpaymentupdate?.data?.OrderId,
|
||||||
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
bookingpaymentupdate?.data?.OrderDetail?.[0]?.FYStatus
|
||||||
)
|
)
|
||||||
: '')
|
: '')
|
||||||
);
|
);
|
||||||
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
bookingpaymentupdate?.data?.OrderDetails?.length > 0 &&
|
||||||
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
setPrintOrderDetails([bookingpaymentupdate?.data]);
|
||||||
|
|
@ -2336,7 +2339,7 @@ const StandardTablePayment = () => {
|
||||||
if (
|
if (
|
||||||
Date.now() - startTime >
|
Date.now() - startTime >
|
||||||
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
useOptions?.[0]?.PDConfigDetails?.[0]?.AutoCancelDurationInMinutes *
|
||||||
60000
|
60000
|
||||||
) {
|
) {
|
||||||
// 60,000 ms = 1 minute
|
// 60,000 ms = 1 minute
|
||||||
|
|
||||||
|
|
@ -2975,7 +2978,7 @@ const StandardTablePayment = () => {
|
||||||
|
|
||||||
const selectedStyle =
|
const selectedStyle =
|
||||||
stylesMap[
|
stylesMap[
|
||||||
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
printerTemplateStyle == undefined ? 'Style 13' : printerTemplateStyle
|
||||||
];
|
];
|
||||||
|
|
||||||
if (selectedStyle) {
|
if (selectedStyle) {
|
||||||
|
|
@ -3479,9 +3482,9 @@ const StandardTablePayment = () => {
|
||||||
cursor: orderCardDetail?.length > 0 && 'not-allowed',
|
cursor: orderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
orderCardDetail?.length > 0 ||
|
orderCardDetail?.length > 0 ||
|
||||||
(selOption?.value === undefined &&
|
(selOption?.value === undefined &&
|
||||||
GlobalAddCustomerDetails1?.length === 0 &&
|
GlobalAddCustomerDetails1?.length === 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '28px',
|
fontSize: '28px',
|
||||||
|
|
@ -3504,14 +3507,14 @@ const StandardTablePayment = () => {
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
cursor:
|
cursor:
|
||||||
orderCardDetail?.length === 0 ||
|
orderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'not-allowed'
|
? 'not-allowed'
|
||||||
: 'pointer',
|
: 'pointer',
|
||||||
color:
|
color:
|
||||||
orderCardDetail?.length === 0 ||
|
orderCardDetail?.length === 0 ||
|
||||||
CheckBookingStatus == 'Close' ||
|
CheckBookingStatus == 'Close' ||
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3526,39 +3529,39 @@ const StandardTablePayment = () => {
|
||||||
|
|
||||||
{/* Customer Orders */}
|
{/* Customer Orders */}
|
||||||
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
{(SelCustId && tableOptions?.filter((item) => item.OptionName === 'PreviousBillFetch')
|
||||||
.length === 1) && (
|
.length === 1) && (
|
||||||
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
<Tooltip title="Customer Orders" isMobile={isMobile}>
|
||||||
{' '}
|
{' '}
|
||||||
<div
|
<div
|
||||||
className="BSBillingNav-icon-table-icon"
|
className="BSBillingNav-icon-table-icon"
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
if (
|
if (
|
||||||
CheckBookingStatus !== 'Close' &&
|
CheckBookingStatus !== 'Close' &&
|
||||||
!addnewAccess &&
|
!addnewAccess &&
|
||||||
!(orderCardDetail?.length > 0)
|
!(orderCardDetail?.length > 0)
|
||||||
) {
|
) {
|
||||||
setCustomerPreviesOrders(true);
|
setCustomerPreviesOrders(true);
|
||||||
}
|
}
|
||||||
}}
|
}}
|
||||||
style={{
|
style={{
|
||||||
cursor: orderCardDetail?.length > 0 && 'not-allowed',
|
cursor: orderCardDetail?.length > 0 && 'not-allowed',
|
||||||
color:
|
color:
|
||||||
orderCardDetail?.length > 0 ||
|
orderCardDetail?.length > 0 ||
|
||||||
(orderCardDetail?.length > 0 &&
|
(orderCardDetail?.length > 0 &&
|
||||||
GetCustId?.CustMobile === undefined)
|
GetCustId?.CustMobile === undefined)
|
||||||
? 'gray'
|
? 'gray'
|
||||||
: 'rgb(18, 146, 238)',
|
: 'rgb(18, 146, 238)',
|
||||||
fontSize: '25px',
|
fontSize: '25px',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: '2.46rem',
|
height: '2.46rem',
|
||||||
width: '1.5rem',
|
width: '1.5rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<FaCartPlus />
|
<FaCartPlus />
|
||||||
</div>
|
</div>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{tabledata?.length > 0 && dinePreference && (
|
{tabledata?.length > 0 && dinePreference && (
|
||||||
<div style={{ width: '2rem' }}>
|
<div style={{ width: '2rem' }}>
|
||||||
|
|
@ -3612,14 +3615,14 @@ const StandardTablePayment = () => {
|
||||||
{(filteredSettingNames?.includes('Print') ||
|
{(filteredSettingNames?.includes('Print') ||
|
||||||
!MobileNoWhatsApp ||
|
!MobileNoWhatsApp ||
|
||||||
!MobileNoWhatsApp.value) && (
|
!MobileNoWhatsApp.value) && (
|
||||||
<FaPrint
|
<FaPrint
|
||||||
size={32}
|
size={32}
|
||||||
color="#1292EE"
|
color="#1292EE"
|
||||||
style={{ cursor: 'pointer' }}
|
style={{ cursor: 'pointer' }}
|
||||||
onClick={handlePrintOrToken}
|
onClick={handlePrintOrToken}
|
||||||
title="Print"
|
title="Print"
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{filteredSettingNames?.includes('SMS') && isMobile && (
|
{filteredSettingNames?.includes('SMS') && isMobile && (
|
||||||
<MdSms
|
<MdSms
|
||||||
|
|
@ -3702,7 +3705,7 @@ const StandardTablePayment = () => {
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{payBtns?.length > 0 &&
|
{payBtns?.length > 0 &&
|
||||||
currentOrderNetAmount >= previousNetAmount ? (
|
currentOrderNetAmount >= previousNetAmount ? (
|
||||||
payBtns.map((payment) => {
|
payBtns.map((payment) => {
|
||||||
const mode = payment?.ModeName?.toLowerCase();
|
const mode = payment?.ModeName?.toLowerCase();
|
||||||
const isSelected = paybtnselected === payment?.ModeId;
|
const isSelected = paybtnselected === payment?.ModeId;
|
||||||
|
|
@ -3713,9 +3716,9 @@ const StandardTablePayment = () => {
|
||||||
const handleClick =
|
const handleClick =
|
||||||
mode === 'upi'
|
mode === 'upi'
|
||||||
? () =>
|
? () =>
|
||||||
handleUPIButtonClick(payment?.ModeId, payment?.ModeName)
|
handleUPIButtonClick(payment?.ModeId, payment?.ModeName)
|
||||||
: () =>
|
: () =>
|
||||||
handlePaymentMode(payment?.ModeId, payment?.ModeName);
|
handlePaymentMode(payment?.ModeId, payment?.ModeName);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="standard-pay-btns" key={payment?.ModeId}>
|
<div className="standard-pay-btns" key={payment?.ModeId}>
|
||||||
|
|
@ -3867,9 +3870,9 @@ const StandardTablePayment = () => {
|
||||||
addnewAccess
|
addnewAccess
|
||||||
? 'standard-pay-btn-disabled'
|
? 'standard-pay-btn-disabled'
|
||||||
: FirstPaymentclick === false &&
|
: FirstPaymentclick === false &&
|
||||||
orderCardDetail?.length > 0 &&
|
orderCardDetail?.length > 0 &&
|
||||||
paybtnselected &&
|
paybtnselected &&
|
||||||
CheckBookingStatus !== 'Close'
|
CheckBookingStatus !== 'Close'
|
||||||
? !OrderStatus
|
? !OrderStatus
|
||||||
? salesBillEdit && currentOrderNetAmount < previousNetAmount
|
? salesBillEdit && currentOrderNetAmount < previousNetAmount
|
||||||
? 'standard-pay-btn-refund'
|
? 'standard-pay-btn-refund'
|
||||||
|
|
@ -3942,8 +3945,8 @@ const StandardTablePayment = () => {
|
||||||
columns={columns}
|
columns={columns}
|
||||||
data={TableData}
|
data={TableData}
|
||||||
dataSource={TableData}
|
dataSource={TableData}
|
||||||
// pagination={handlePageChange}
|
// pagination={handlePageChange}
|
||||||
// onChange={handleChange}
|
// onChange={handleChange}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
|
|
@ -4109,11 +4112,11 @@ const StandardTablePayment = () => {
|
||||||
handlesplitpaymentclose={handlesplitpaymentclose}
|
handlesplitpaymentclose={handlesplitpaymentclose}
|
||||||
TotalNetAmount={Math.round(
|
TotalNetAmount={Math.round(
|
||||||
orderCardDetail?.reduce((acc, data) => data?.TotalAmt + acc, 0) -
|
orderCardDetail?.reduce((acc, data) => data?.TotalAmt + acc, 0) -
|
||||||
((OverAllSales > 0 ? OverAllSales : 0) +
|
((OverAllSales > 0 ? OverAllSales : 0) +
|
||||||
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
(OverAllEstimate > 0 ? OverAllEstimate : 0) +
|
||||||
(Discount > 0 ? Discount : 0))
|
(Discount > 0 ? Discount : 0))
|
||||||
)}
|
)}
|
||||||
// failedOrderData={failedOrderData}
|
// failedOrderData={failedOrderData}
|
||||||
/>
|
/>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -27,17 +27,17 @@ import {
|
||||||
GlobalprintCashierName,
|
GlobalprintCashierName,
|
||||||
GlobalprintLogo,
|
GlobalprintLogo,
|
||||||
GlobalprintTax,
|
GlobalprintTax,
|
||||||
GlobalSelectedPrintHeaderColor,
|
GlobalSelectedPrintHeaderColor,
|
||||||
GlobalSelectedPrintHeaderFontColor,
|
GlobalSelectedPrintHeaderFontColor,
|
||||||
GlobalSelectedTableHeaderColor,
|
GlobalSelectedTableHeaderColor,
|
||||||
GlobalSelectedTableHeaderFontColor,
|
GlobalSelectedTableHeaderFontColor,
|
||||||
GlobalSelectedTableBodyFontColor,
|
GlobalSelectedTableBodyFontColor,
|
||||||
GlobalSelectedTableBodyColor,
|
GlobalSelectedTableBodyColor,
|
||||||
GlobalRowType,
|
GlobalRowType,
|
||||||
GlobalSelectedFooterColor,
|
GlobalSelectedFooterColor,
|
||||||
GlobalSelectedFooterFontColor,
|
GlobalSelectedFooterFontColor,
|
||||||
GlobalSelectedNetAmountColor,
|
GlobalSelectedNetAmountColor,
|
||||||
GlobalSelectedNetAmountFontColor,
|
GlobalSelectedNetAmountFontColor,
|
||||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||||
import '../../../../Styles/BookingScreen/PrintTemplates/ThermalPrinter/PrintStyle1.scss';
|
import '../../../../Styles/BookingScreen/PrintTemplates/ThermalPrinter/PrintStyle1.scss';
|
||||||
import QRCode from 'react-qr-code';
|
import QRCode from 'react-qr-code';
|
||||||
|
|
@ -105,6 +105,12 @@ const InvoiceTemplate = ({
|
||||||
const GlobalBilltext = useSelector(GlobalBillName);
|
const GlobalBilltext = useSelector(GlobalBillName);
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -120,7 +126,7 @@ const InvoiceTemplate = ({
|
||||||
)?.SettingValue === 'Y';
|
)?.SettingValue === 'Y';
|
||||||
const keysLength = Object.keys(table2Data ?? {}).length;
|
const keysLength = Object.keys(table2Data ?? {}).length;
|
||||||
console.log(GlobalDiscount, Discount, 'Discount');
|
console.log(GlobalDiscount, Discount, 'Discount');
|
||||||
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);
|
||||||
|
|
@ -516,7 +522,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
@ -952,7 +958,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="header-section" style={{...headerStyle}}>
|
<div className="header-section" style={{ ...headerStyle }}>
|
||||||
<div>
|
<div>
|
||||||
<div
|
<div
|
||||||
style={{ display: 'flex', alignItems: 'center' }}
|
style={{ display: 'flex', alignItems: 'center' }}
|
||||||
|
|
@ -1018,9 +1024,10 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
table2Data?.FYStatus
|
table2Data?.FYStatus
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '13px', margin: '0rem 0rem', fontWeight: '600' }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
@ -1160,7 +1167,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<thead>
|
<thead>
|
||||||
<tr className="table-header" style={{...tableHeaderStyle}}>
|
<tr className="table-header" style={{ ...tableHeaderStyle }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th className="table-header-cell">S.No</th>
|
<th className="table-header-cell">S.No</th>
|
||||||
|
|
@ -1309,17 +1316,17 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
{((GlobaldummyData ? products : dataChunk) || []).map(
|
{((GlobaldummyData ? products : dataChunk) || []).map(
|
||||||
(item, idx) => (
|
(item, idx) => (
|
||||||
<tr key={idx} className="table-row"
|
<tr key={idx} className="table-row"
|
||||||
style={
|
style={
|
||||||
idx % 2 !== 1 && rowtypeStyle === "even"
|
idx % 2 !== 1 && rowtypeStyle === "even"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: idx % 2 === 1 && rowtypeStyle === "odd"
|
: idx % 2 === 1 && rowtypeStyle === "odd"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: {}
|
: {}
|
||||||
}>
|
}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<td
|
<td
|
||||||
|
|
@ -1508,9 +1515,9 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
fontFamily: 'sans-serif',
|
fontFamily: 'sans-serif',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1548,10 +1555,9 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
fontFamily: 'sans-serif',
|
fontFamily: 'sans-serif',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1988,7 +1994,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Footer */}
|
{/* Footer */}
|
||||||
<div className="footer-grid" style={{...footerColorStyle}}>
|
<div className="footer-grid" style={{ ...footerColorStyle }}>
|
||||||
<div className="footer-left">
|
<div className="footer-left">
|
||||||
{BankDetails?.length > 0 && (
|
{BankDetails?.length > 0 && (
|
||||||
<>
|
<>
|
||||||
|
|
@ -2251,7 +2257,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
alignItems: 'flex-end',
|
alignItems: 'flex-end',
|
||||||
justifyContent: 'space-around',
|
justifyContent: 'space-around',
|
||||||
width: '100%',
|
width: '100%',
|
||||||
padding: '0 10px',
|
padding: '0 10px',
|
||||||
padding: '0 10px',
|
padding: '0 10px',
|
||||||
whiteSpace: 'nowrap',
|
whiteSpace: 'nowrap',
|
||||||
fontSize: '10px',
|
fontSize: '10px',
|
||||||
|
|
@ -2551,7 +2557,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Footer */}
|
{/* Footer */}
|
||||||
<div className="footer-grid" style={{...footerColorStyle}}>
|
<div className="footer-grid" style={{ ...footerColorStyle }}>
|
||||||
<div className="footer-left">
|
<div className="footer-left">
|
||||||
{BankDetails?.length > 0 && (
|
{BankDetails?.length > 0 && (
|
||||||
<>
|
<>
|
||||||
|
|
@ -2773,7 +2779,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="header-section" style={{...headerStyle}}>
|
<div className="header-section" style={{ ...headerStyle }}>
|
||||||
<div>
|
<div>
|
||||||
<div style={{ display: 'flex', alignItems: 'center' }}>
|
<div style={{ display: 'flex', alignItems: 'center' }}>
|
||||||
{GlobalLogo && GlobaldummyData && (
|
{GlobalLogo && GlobaldummyData && (
|
||||||
|
|
@ -2936,7 +2942,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
style={{ borderTop: '1px solid black' }}
|
style={{ borderTop: '1px solid black' }}
|
||||||
>
|
>
|
||||||
<thead>
|
<thead>
|
||||||
<tr className="table-header" style={{...tableHeaderStyle}}>
|
<tr className="table-header" style={{ ...tableHeaderStyle }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th className="table-header-cell">S.No</th>
|
<th className="table-header-cell">S.No</th>
|
||||||
|
|
@ -3047,17 +3053,17 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
{((GlobaldummyData ? products : productsData) || []).map(
|
{((GlobaldummyData ? products : productsData) || []).map(
|
||||||
(item, idx) => (
|
(item, idx) => (
|
||||||
<tr key={idx} className="table-row"
|
<tr key={idx} className="table-row"
|
||||||
style={
|
style={
|
||||||
idx % 2 !== 1 && rowtypeStyle === "even"
|
idx % 2 !== 1 && rowtypeStyle === "even"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: idx % 2 === 1 && rowtypeStyle === "odd"
|
: idx % 2 === 1 && rowtypeStyle === "odd"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: {}
|
: {}
|
||||||
}>
|
}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<td
|
<td
|
||||||
|
|
@ -3224,9 +3230,9 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
className="table-header-cell"
|
className="table-header-cell"
|
||||||
style={{ textAlign: 'right' }}
|
style={{ textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3261,9 +3267,9 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
className="table-header-cell"
|
className="table-header-cell"
|
||||||
style={{ textAlign: 'right' }}
|
style={{ textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3279,7 +3285,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
alignItems: 'flex-start',
|
alignItems: 'flex-start',
|
||||||
justifyContent: 'space-around',
|
justifyContent: 'space-around',
|
||||||
width: '100%',
|
width: '100%',
|
||||||
padding: '0 10px',
|
padding: '0 10px',
|
||||||
whiteSpace: 'nowrap',
|
whiteSpace: 'nowrap',
|
||||||
fontSize: '10px',
|
fontSize: '10px',
|
||||||
flexWrap: 'wrap',
|
flexWrap: 'wrap',
|
||||||
|
|
@ -3539,7 +3545,7 @@ const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{/* Footer */}
|
{/* Footer */}
|
||||||
<div className="footer-grid" style={{...footerColorStyle}}>
|
<div className="footer-grid" style={{ ...footerColorStyle }}>
|
||||||
<div className="footer-left">
|
<div className="footer-left">
|
||||||
{(BankDetails?.length > 0 || GlobaldummyData) && (
|
{(BankDetails?.length > 0 || GlobaldummyData) && (
|
||||||
<>
|
<>
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -130,6 +130,12 @@ const PrintA5Style11 = ({
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
||||||
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
||||||
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const estimatePrintHeader =
|
const estimatePrintHeader =
|
||||||
SettingData?.[0]?.SettingDtlDetails?.find(
|
SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
(setting) =>
|
(setting) =>
|
||||||
|
|
@ -529,9 +535,10 @@ const PrintA5Style11 = ({
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
<div>{Date1}</div>{' '}
|
<div>{Date1}</div>{' '}
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '13px', margin: '0rem 0.5rem', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -764,7 +771,7 @@ const PrintA5Style11 = ({
|
||||||
<tbody>
|
<tbody>
|
||||||
{dataChunk?.map((item, index) => (
|
{dataChunk?.map((item, index) => (
|
||||||
<tr key={index}
|
<tr key={index}
|
||||||
style={
|
style={
|
||||||
index % 2 !== 1 && rowtypeStyle === "even"
|
index % 2 !== 1 && rowtypeStyle === "even"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
|
|
@ -905,9 +912,9 @@ const PrintA5Style11 = ({
|
||||||
)
|
)
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -927,11 +934,9 @@ const PrintA5Style11 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt -
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
item?.OfferAmt || 0
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
: item?.TotalAmt -
|
|
||||||
item?.OfferValue || 0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1765,7 +1770,7 @@ const PrintA5Style11 = ({
|
||||||
<tbody>
|
<tbody>
|
||||||
{dataChunk?.map((item, index) => (
|
{dataChunk?.map((item, index) => (
|
||||||
<tr key={index}
|
<tr key={index}
|
||||||
style={
|
style={
|
||||||
index % 2 !== 1 && rowtypeStyle === "even"
|
index % 2 !== 1 && rowtypeStyle === "even"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
|
|
@ -1882,9 +1887,9 @@ const PrintA5Style11 = ({
|
||||||
)
|
)
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1904,11 +1909,9 @@ const PrintA5Style11 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt -
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
item?.OfferAmt || 0
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
: item?.TotalAmt -
|
|
||||||
item?.OfferValue || 0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -2929,179 +2932,179 @@ const PrintA5Style11 = ({
|
||||||
>{`*** Membership ${table2Data?.NetAmount === 0 ? 'Free Hours' : 'Discount'} Utilized - ${MembershipApplied?.Detail?.[0]?.MembershipName} ***`}</div>
|
>{`*** Membership ${table2Data?.NetAmount === 0 ? 'Free Hours' : 'Discount'} Utilized - ${MembershipApplied?.Detail?.[0]?.MembershipName} ***`}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
<div style={{...footerColorStyle}}>
|
<div style={{ ...footerColorStyle }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalIsnotes && (
|
? GlobalIsnotes && (
|
||||||
<div>
|
<div>
|
||||||
<p style={{ padding: '0rem 1rem' }}>
|
<p style={{ padding: '0rem 1rem' }}>
|
||||||
Notes : 10 days Return policy
|
Notes : 10 days Return policy
|
||||||
</p>
|
|
||||||
|
|
||||||
<hr className="PrintA4Style11-print-dottline" />
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
: Notestext && (
|
|
||||||
<div>
|
|
||||||
<p
|
|
||||||
style={{
|
|
||||||
padding: '0rem 1rem',
|
|
||||||
textAlign: 'center',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
{Notestext}
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<hr className="PrintA4Style11-print-dottline" />
|
|
||||||
</div>
|
|
||||||
)}
|
|
||||||
|
|
||||||
<div
|
|
||||||
style={{
|
|
||||||
display: 'flex',
|
|
||||||
width: '90%',
|
|
||||||
padding: '0 1rem',
|
|
||||||
justifyContent: GlobaltermsAndConditions
|
|
||||||
? 'space-between'
|
|
||||||
: 'flex-end',
|
|
||||||
alignItems: 'center',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
{GlobaldummyData
|
|
||||||
? GlobaltermsAndConditions && (
|
|
||||||
<div
|
|
||||||
style={{
|
|
||||||
margin: '8px 0',
|
|
||||||
padding: '8px',
|
|
||||||
fontFamily: 'sans-serif',
|
|
||||||
width: '100%',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
|
||||||
fontSize: '13px',
|
|
||||||
fontWeight: 'bold',
|
|
||||||
marginBottom: '6px',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Terms & Conditions
|
|
||||||
</p>
|
</p>
|
||||||
<ol
|
|
||||||
style={{
|
<hr className="PrintA4Style11-print-dottline" />
|
||||||
fontSize: '12px',
|
|
||||||
paddingLeft: '18px',
|
|
||||||
margin: 0,
|
|
||||||
lineHeight: '1',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<li>
|
|
||||||
Once goods are sold, they are not exchangeable
|
|
||||||
or refundable.
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
Please check the product before leaving the
|
|
||||||
counter.
|
|
||||||
</li>
|
|
||||||
</ol>
|
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
: TermsnAdCondition == true &&
|
: Notestext && (
|
||||||
TermsAndConditions?.length > 0 && (
|
<div>
|
||||||
<div
|
|
||||||
style={{
|
|
||||||
margin: '8px 0',
|
|
||||||
fontFamily: 'sans-serif',
|
|
||||||
width: '100%',
|
|
||||||
display: 'flex',
|
|
||||||
flexDirection: 'column',
|
|
||||||
alignItems: 'flex-start',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<p
|
<p
|
||||||
style={{
|
style={{
|
||||||
fontSize: '13px',
|
padding: '0rem 1rem',
|
||||||
fontWeight: 'bold',
|
textAlign: 'center',
|
||||||
marginBottom: '6px',
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Terms & Conditions
|
{Notestext}
|
||||||
</p>
|
</p>
|
||||||
<ol
|
|
||||||
|
<hr className="PrintA4Style11-print-dottline" />
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
display: 'flex',
|
||||||
|
width: '90%',
|
||||||
|
padding: '0 1rem',
|
||||||
|
justifyContent: GlobaltermsAndConditions
|
||||||
|
? 'space-between'
|
||||||
|
: 'flex-end',
|
||||||
|
alignItems: 'center',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{GlobaldummyData
|
||||||
|
? GlobaltermsAndConditions && (
|
||||||
|
<div
|
||||||
style={{
|
style={{
|
||||||
fontSize: '12px',
|
margin: '8px 0',
|
||||||
paddingLeft: '18px',
|
padding: '8px',
|
||||||
margin: 0,
|
fontFamily: 'sans-serif',
|
||||||
lineHeight: '1',
|
width: '100%',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{TermsAndConditions?.map((item) => (
|
<p
|
||||||
<li style={{ textAlign: 'start' }}>
|
style={{
|
||||||
{item?.TermsandConditions}
|
fontSize: '13px',
|
||||||
|
fontWeight: 'bold',
|
||||||
|
marginBottom: '6px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Terms & Conditions
|
||||||
|
</p>
|
||||||
|
<ol
|
||||||
|
style={{
|
||||||
|
fontSize: '12px',
|
||||||
|
paddingLeft: '18px',
|
||||||
|
margin: 0,
|
||||||
|
lineHeight: '1',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<li>
|
||||||
|
Once goods are sold, they are not exchangeable
|
||||||
|
or refundable.
|
||||||
</li>
|
</li>
|
||||||
))}
|
<li>
|
||||||
{/* <li>Please check the product before leaving the counter.</li> */}
|
Please check the product before leaving the
|
||||||
</ol>
|
counter.
|
||||||
</div>
|
</li>
|
||||||
)}
|
</ol>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
: TermsnAdCondition == true &&
|
||||||
|
TermsAndConditions?.length > 0 && (
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
margin: '8px 0',
|
||||||
|
fontFamily: 'sans-serif',
|
||||||
|
width: '100%',
|
||||||
|
display: 'flex',
|
||||||
|
flexDirection: 'column',
|
||||||
|
alignItems: 'flex-start',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<p
|
||||||
|
style={{
|
||||||
|
fontSize: '13px',
|
||||||
|
fontWeight: 'bold',
|
||||||
|
marginBottom: '6px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Terms & Conditions
|
||||||
|
</p>
|
||||||
|
<ol
|
||||||
|
style={{
|
||||||
|
fontSize: '12px',
|
||||||
|
paddingLeft: '18px',
|
||||||
|
margin: 0,
|
||||||
|
lineHeight: '1',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{TermsAndConditions?.map((item) => (
|
||||||
|
<li style={{ textAlign: 'start' }}>
|
||||||
|
{item?.TermsandConditions}
|
||||||
|
</li>
|
||||||
|
))}
|
||||||
|
{/* <li>Please check the product before leaving the counter.</li> */}
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSignature && (
|
? GlobalSignature && (
|
||||||
<div
|
<div
|
||||||
style={{
|
|
||||||
display: 'flex',
|
|
||||||
flexDirection: 'column',
|
|
||||||
alignItems: 'flex-end',
|
|
||||||
paddingBottom: '1rem',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
style={{
|
||||||
fontSize: '13px',
|
display: 'flex',
|
||||||
fontWeight: 'bold',
|
flexDirection: 'column',
|
||||||
marginBottom: '6px',
|
alignItems: 'flex-end',
|
||||||
|
paddingBottom: '1rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Signature
|
<p
|
||||||
</p>
|
style={{
|
||||||
<img
|
fontSize: '13px',
|
||||||
style={{ width: '70px', height: '40px' }}
|
fontWeight: 'bold',
|
||||||
src={
|
marginBottom: '6px',
|
||||||
GlobalSignatureImages
|
}}
|
||||||
? GlobalSignatureImages
|
>
|
||||||
: signature
|
Signature
|
||||||
}
|
</p>
|
||||||
alt=""
|
<img
|
||||||
/>
|
style={{ width: '70px', height: '40px' }}
|
||||||
</div>
|
src={
|
||||||
)
|
GlobalSignatureImages
|
||||||
: Signature == true && (
|
? GlobalSignatureImages
|
||||||
<div
|
: signature
|
||||||
style={{
|
}
|
||||||
display: 'flex',
|
alt=""
|
||||||
flexDirection: 'column',
|
/>
|
||||||
alignItems: 'center',
|
</div>
|
||||||
marginTop: '1rem',
|
)
|
||||||
paddingBottom: '1rem',
|
: Signature == true && (
|
||||||
}}
|
<div
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
style={{
|
||||||
fontSize: '13px',
|
display: 'flex',
|
||||||
fontWeight: 'bold',
|
flexDirection: 'column',
|
||||||
marginBottom: '6px',
|
alignItems: 'center',
|
||||||
|
marginTop: '1rem',
|
||||||
|
paddingBottom: '1rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Signature
|
<p
|
||||||
</p>
|
style={{
|
||||||
<img
|
fontSize: '13px',
|
||||||
style={{ width: '100px', height: '60px' }}
|
fontWeight: 'bold',
|
||||||
src={SignatureImg}
|
marginBottom: '6px',
|
||||||
alt=""
|
}}
|
||||||
/>
|
>
|
||||||
</div>
|
Signature
|
||||||
)}
|
</p>
|
||||||
|
<img
|
||||||
|
style={{ width: '100px', height: '60px' }}
|
||||||
|
src={SignatureImg}
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
|
|
@ -3515,173 +3518,173 @@ const PrintA5Style11 = ({
|
||||||
>{`*** Membership ${table2Data?.NetAmount === 0 ? 'Free Hours' : 'Discount'} Utilized - ${MembershipApplied?.Detail?.[0]?.MembershipName} ***`}</div>
|
>{`*** Membership ${table2Data?.NetAmount === 0 ? 'Free Hours' : 'Discount'} Utilized - ${MembershipApplied?.Detail?.[0]?.MembershipName} ***`}</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
<div style={{...footerColorStyle}}>
|
<div style={{ ...footerColorStyle }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalIsnotes && (
|
? GlobalIsnotes && (
|
||||||
<div>
|
<div>
|
||||||
<p style={{ padding: '0rem 1rem' }}>
|
<p style={{ padding: '0rem 1rem' }}>
|
||||||
Notes : 10 days Return policy
|
Notes : 10 days Return policy
|
||||||
</p>
|
|
||||||
|
|
||||||
<hr className="PrintA4Style11-print-dottline" />
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
: Notestext && (
|
|
||||||
<div>
|
|
||||||
<p style={{ padding: '0rem 1rem', textAlign: 'center' }}>
|
|
||||||
{Notestext}
|
|
||||||
</p>
|
|
||||||
|
|
||||||
<hr className="PrintA4Style11-print-dottline" />
|
|
||||||
</div>
|
|
||||||
)}
|
|
||||||
|
|
||||||
<div
|
|
||||||
style={{
|
|
||||||
display: 'flex',
|
|
||||||
width: '90%',
|
|
||||||
padding: '0 1rem',
|
|
||||||
justifyContent: GlobaltermsAndConditions
|
|
||||||
? 'space-between'
|
|
||||||
: 'flex-end',
|
|
||||||
alignItems: 'center',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
{GlobaldummyData
|
|
||||||
? GlobaltermsAndConditions && (
|
|
||||||
<div
|
|
||||||
style={{
|
|
||||||
margin: '8px 0',
|
|
||||||
padding: '8px',
|
|
||||||
fontFamily: 'sans-serif',
|
|
||||||
width: '100%',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
|
||||||
fontSize: '13px',
|
|
||||||
fontWeight: 'bold',
|
|
||||||
marginBottom: '6px',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Terms & Conditions
|
|
||||||
</p>
|
</p>
|
||||||
<ol
|
|
||||||
style={{
|
<hr className="PrintA4Style11-print-dottline" />
|
||||||
fontSize: '12px',
|
|
||||||
paddingLeft: '18px',
|
|
||||||
margin: 0,
|
|
||||||
lineHeight: '1',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<li>
|
|
||||||
Once goods are sold, they are not exchangeable or
|
|
||||||
refundable.
|
|
||||||
</li>
|
|
||||||
<li>
|
|
||||||
Please check the product before leaving the counter.
|
|
||||||
</li>
|
|
||||||
</ol>
|
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
: TermsnAdCondition == true &&
|
: Notestext && (
|
||||||
TermsAndConditions?.length > 0 && (
|
<div>
|
||||||
<div
|
<p style={{ padding: '0rem 1rem', textAlign: 'center' }}>
|
||||||
style={{
|
{Notestext}
|
||||||
margin: '8px 0',
|
|
||||||
fontFamily: 'sans-serif',
|
|
||||||
width: '100%',
|
|
||||||
display: 'flex',
|
|
||||||
flexDirection: 'column',
|
|
||||||
alignItems: 'flex-start',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
|
||||||
fontSize: '13px',
|
|
||||||
fontWeight: 'bold',
|
|
||||||
marginBottom: '6px',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Terms & Conditions
|
|
||||||
</p>
|
</p>
|
||||||
<ol
|
|
||||||
|
<hr className="PrintA4Style11-print-dottline" />
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
display: 'flex',
|
||||||
|
width: '90%',
|
||||||
|
padding: '0 1rem',
|
||||||
|
justifyContent: GlobaltermsAndConditions
|
||||||
|
? 'space-between'
|
||||||
|
: 'flex-end',
|
||||||
|
alignItems: 'center',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{GlobaldummyData
|
||||||
|
? GlobaltermsAndConditions && (
|
||||||
|
<div
|
||||||
style={{
|
style={{
|
||||||
fontSize: '12px',
|
margin: '8px 0',
|
||||||
paddingLeft: '18px',
|
padding: '8px',
|
||||||
margin: 0,
|
fontFamily: 'sans-serif',
|
||||||
lineHeight: '1',
|
width: '100%',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{TermsAndConditions?.map((item) => (
|
<p
|
||||||
<li style={{ textAlign: 'start' }}>
|
style={{
|
||||||
{item?.TermsandConditions}
|
fontSize: '13px',
|
||||||
|
fontWeight: 'bold',
|
||||||
|
marginBottom: '6px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Terms & Conditions
|
||||||
|
</p>
|
||||||
|
<ol
|
||||||
|
style={{
|
||||||
|
fontSize: '12px',
|
||||||
|
paddingLeft: '18px',
|
||||||
|
margin: 0,
|
||||||
|
lineHeight: '1',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<li>
|
||||||
|
Once goods are sold, they are not exchangeable or
|
||||||
|
refundable.
|
||||||
</li>
|
</li>
|
||||||
))}
|
<li>
|
||||||
{/* <li>Please check the product before leaving the counter.</li> */}
|
Please check the product before leaving the counter.
|
||||||
</ol>
|
</li>
|
||||||
</div>
|
</ol>
|
||||||
)}
|
</div>
|
||||||
|
)
|
||||||
|
: TermsnAdCondition == true &&
|
||||||
|
TermsAndConditions?.length > 0 && (
|
||||||
|
<div
|
||||||
|
style={{
|
||||||
|
margin: '8px 0',
|
||||||
|
fontFamily: 'sans-serif',
|
||||||
|
width: '100%',
|
||||||
|
display: 'flex',
|
||||||
|
flexDirection: 'column',
|
||||||
|
alignItems: 'flex-start',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<p
|
||||||
|
style={{
|
||||||
|
fontSize: '13px',
|
||||||
|
fontWeight: 'bold',
|
||||||
|
marginBottom: '6px',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
Terms & Conditions
|
||||||
|
</p>
|
||||||
|
<ol
|
||||||
|
style={{
|
||||||
|
fontSize: '12px',
|
||||||
|
paddingLeft: '18px',
|
||||||
|
margin: 0,
|
||||||
|
lineHeight: '1',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{TermsAndConditions?.map((item) => (
|
||||||
|
<li style={{ textAlign: 'start' }}>
|
||||||
|
{item?.TermsandConditions}
|
||||||
|
</li>
|
||||||
|
))}
|
||||||
|
{/* <li>Please check the product before leaving the counter.</li> */}
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSignature && (
|
? GlobalSignature && (
|
||||||
<div
|
<div
|
||||||
style={{
|
|
||||||
display: 'flex',
|
|
||||||
flexDirection: 'column',
|
|
||||||
alignItems: 'flex-end',
|
|
||||||
paddingBottom: '1rem',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
style={{
|
||||||
fontSize: '13px',
|
display: 'flex',
|
||||||
fontWeight: 'bold',
|
flexDirection: 'column',
|
||||||
marginBottom: '6px',
|
alignItems: 'flex-end',
|
||||||
|
paddingBottom: '1rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Signature
|
<p
|
||||||
</p>
|
style={{
|
||||||
<img
|
fontSize: '13px',
|
||||||
style={{ width: '70px', height: '40px' }}
|
fontWeight: 'bold',
|
||||||
src={
|
marginBottom: '6px',
|
||||||
GlobalSignatureImages
|
}}
|
||||||
? GlobalSignatureImages
|
>
|
||||||
: signature
|
Signature
|
||||||
}
|
</p>
|
||||||
alt=""
|
<img
|
||||||
/>
|
style={{ width: '70px', height: '40px' }}
|
||||||
</div>
|
src={
|
||||||
)
|
GlobalSignatureImages
|
||||||
: Signature == true && (
|
? GlobalSignatureImages
|
||||||
<div
|
: signature
|
||||||
style={{
|
}
|
||||||
display: 'flex',
|
alt=""
|
||||||
flexDirection: 'column',
|
/>
|
||||||
alignItems: 'center',
|
</div>
|
||||||
marginTop: '1rem',
|
)
|
||||||
paddingBottom: '1rem',
|
: Signature == true && (
|
||||||
}}
|
<div
|
||||||
>
|
|
||||||
<p
|
|
||||||
style={{
|
style={{
|
||||||
fontSize: '13px',
|
display: 'flex',
|
||||||
fontWeight: 'bold',
|
flexDirection: 'column',
|
||||||
marginBottom: '6px',
|
alignItems: 'center',
|
||||||
|
marginTop: '1rem',
|
||||||
|
paddingBottom: '1rem',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Signature
|
<p
|
||||||
</p>
|
style={{
|
||||||
<img
|
fontSize: '13px',
|
||||||
style={{ width: '100px', height: '60px' }}
|
fontWeight: 'bold',
|
||||||
src={SignatureImg}
|
marginBottom: '6px',
|
||||||
alt=""
|
}}
|
||||||
/>
|
>
|
||||||
</div>
|
Signature
|
||||||
)}
|
</p>
|
||||||
|
<img
|
||||||
|
style={{ width: '100px', height: '60px' }}
|
||||||
|
src={SignatureImg}
|
||||||
|
alt=""
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -47,6 +47,12 @@ const TaxInvoice = ({
|
||||||
setting?.SettingIdName?.toLowerCase() === 'estimatetitle'
|
setting?.SettingIdName?.toLowerCase() === 'estimatetitle'
|
||||||
)?.SettingValue === 'Y';
|
)?.SettingValue === 'Y';
|
||||||
let BillName = printDatas?.PrintHdrName;
|
let BillName = printDatas?.PrintHdrName;
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||||
const SelectedHeaderFontColor = useSelector(GlobalSelectedPrintHeaderFontColor);
|
const SelectedHeaderFontColor = useSelector(GlobalSelectedPrintHeaderFontColor);
|
||||||
const SelectedTableHeaderColor = useSelector(GlobalSelectedTableHeaderColor);
|
const SelectedTableHeaderColor = useSelector(GlobalSelectedTableHeaderColor);
|
||||||
|
|
@ -496,7 +502,7 @@ const TaxInvoice = ({
|
||||||
style={{
|
style={{
|
||||||
fontWeight: '700',
|
fontWeight: '700',
|
||||||
fontSize: '15px',
|
fontSize: '15px',
|
||||||
color: headerColor?.font
|
color: headerColor?.font
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{invoiceData.companyName}
|
{invoiceData.companyName}
|
||||||
|
|
|
||||||
|
|
@ -128,6 +128,13 @@ const PrintStyle1 = ({
|
||||||
const GlobalBilltext = useSelector(GlobalBillName);
|
const GlobalBilltext = useSelector(GlobalBillName);
|
||||||
const appPreferences = useSelector(ApplicationPreferences);
|
const appPreferences = useSelector(ApplicationPreferences);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
|
|
||||||
const bookingTypePreference = appPreferences?.find(
|
const bookingTypePreference = appPreferences?.find(
|
||||||
(preference) => preference?.PreferredCatName === 'Booking Type'
|
(preference) => preference?.PreferredCatName === 'Booking Type'
|
||||||
)?.PreferenceCatDetails;
|
)?.PreferenceCatDetails;
|
||||||
|
|
@ -494,15 +501,17 @@ const PrintStyle1 = ({
|
||||||
width: '100%',
|
width: '100%',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div style={{ display: 'flex', justifyContent: 'center', ...(GlobaldummyData
|
<div style={{
|
||||||
? {
|
display: 'flex', justifyContent: 'center', ...(GlobaldummyData
|
||||||
color: SelectedHeaderFontColor,
|
? {
|
||||||
backgroundColor: SelectedHeaderColor,
|
color: SelectedHeaderFontColor,
|
||||||
}
|
backgroundColor: SelectedHeaderColor,
|
||||||
: {
|
}
|
||||||
color: headerColor?.font,
|
: {
|
||||||
backgroundColor: headerColor?.background,
|
color: headerColor?.font,
|
||||||
}), }}>
|
backgroundColor: headerColor?.background,
|
||||||
|
}),
|
||||||
|
}}>
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
GlobalLogo && (
|
GlobalLogo && (
|
||||||
<img
|
<img
|
||||||
|
|
@ -527,12 +536,12 @@ const PrintStyle1 = ({
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle1-print"
|
<div className="PrintStyle1-print"
|
||||||
style={{
|
style={{
|
||||||
fontSize: 'clamp(2rem, 2.5vw, 2rem)',
|
fontSize: 'clamp(2rem, 2.5vw, 2rem)',
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
color: GlobaldummyData ? SelectedHeaderFontColor : headerColor?.font,
|
color: GlobaldummyData ? SelectedHeaderFontColor : headerColor?.font,
|
||||||
backgroundColor: GlobaldummyData ? SelectedHeaderColor : headerColor?.background,
|
backgroundColor: GlobaldummyData ? SelectedHeaderColor : headerColor?.background,
|
||||||
}}>
|
}}>
|
||||||
<div>
|
<div>
|
||||||
{' '}
|
{' '}
|
||||||
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}
|
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}
|
||||||
|
|
@ -679,9 +688,10 @@ const PrintStyle1 = ({
|
||||||
{' '}
|
{' '}
|
||||||
Date : {GlobaldummyData ? formattedDate : Date1}{' '}
|
Date : {GlobaldummyData ? formattedDate : Date1}{' '}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
|
|
||||||
|
|
@ -977,9 +987,9 @@ const PrintStyle1 = ({
|
||||||
? GlobalDiscount && <td>{item.discount}</td>
|
? GlobalDiscount && <td>{item.discount}</td>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1002,10 +1012,9 @@ const PrintStyle1 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== "C"
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt ?? item?.DiscountAmt ?? 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue ?? item?.DiscountAmt ?? 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1216,9 +1225,9 @@ const PrintStyle1 = ({
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td>
|
<td>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1241,10 +1250,9 @@ const PrintStyle1 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== "C"
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt ?? item?.DiscountAmt ?? 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue ?? item?.DiscountAmt ?? 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -4241,9 +4249,9 @@ const PrintStyle1 = ({
|
||||||
? GlobalDiscount && <td>{item.discount}</td>
|
? GlobalDiscount && <td>{item.discount}</td>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -4266,9 +4274,10 @@ const PrintStyle1 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
{item?.Type !== "C"
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
? item?.TotalAmt - (item?.OfferAmt ?? item?.DiscountAmt ?? 0)
|
||||||
|
: item?.TotalAmt - (item?.OfferValue ?? item?.DiscountAmt ?? 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -4459,9 +4468,10 @@ const PrintStyle1 = ({
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td>
|
<td>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -4478,15 +4488,15 @@ const PrintStyle1 = ({
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: "right" }}>
|
||||||
{item?.TotalAmt}
|
{item?.TotalAmt}
|
||||||
</td>
|
</td>
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount === true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: "right" }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== "C"
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt ?? item?.DiscountAmt ?? 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue ?? item?.DiscountAmt ?? 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
||||||
|
|
@ -111,6 +111,12 @@ const PrintStyle10 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -577,9 +583,10 @@ const PrintStyle10 = ({
|
||||||
{' '}
|
{' '}
|
||||||
{GlobaldummyData ? formattedDate : Date1}{' '}
|
{GlobaldummyData ? formattedDate : Date1}{' '}
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '13px', fontWeight: 600, textAlign: 'right' }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
<hr class="straightline" />
|
<hr class="straightline" />
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -883,9 +890,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -919,10 +926,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1180,9 +1186,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1216,10 +1222,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3496,9 +3501,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3532,9 +3537,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3753,9 +3758,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3789,9 +3794,9 @@ const PrintStyle10 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
||||||
|
|
@ -131,6 +131,12 @@ const PrintStyle11 = ({
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
||||||
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
||||||
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -868,9 +874,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -904,10 +910,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -937,25 +942,25 @@ const PrintStyle11 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.N</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.N</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.N</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.N</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && (
|
? GlobalItem && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Item</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>
|
||||||
)
|
)
|
||||||
: Item && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
|
|
@ -964,14 +969,14 @@ const PrintStyle11 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -979,14 +984,14 @@ const PrintStyle11 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -994,14 +999,14 @@ const PrintStyle11 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1009,7 +1014,7 @@ const PrintStyle11 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Tax %{' '}
|
Tax %{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1017,7 +1022,7 @@ const PrintStyle11 = ({
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Tax %{' '}
|
Tax %{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1025,14 +1030,14 @@ const PrintStyle11 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1040,14 +1045,14 @@ const PrintStyle11 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1058,17 +1063,17 @@ const PrintStyle11 = ({
|
||||||
{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 && (
|
||||||
|
|
@ -1140,9 +1145,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1176,10 +1181,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1283,7 +1287,7 @@ const PrintStyle11 = ({
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
fontSize: '18px',
|
fontSize: '18px',
|
||||||
...netAmountStyle
|
...netAmountStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Amount :
|
Amount :
|
||||||
|
|
@ -2255,7 +2259,7 @@ const PrintStyle11 = ({
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
fontWeight: '600',
|
fontWeight: '600',
|
||||||
fontSize: '18px',
|
fontSize: '18px',
|
||||||
...netAmountStyle
|
...netAmountStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Amount :
|
Amount :
|
||||||
|
|
@ -3211,9 +3215,10 @@ const PrintStyle11 = ({
|
||||||
table2Data?.FYStatus
|
table2Data?.FYStatus
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '13px', margin: '0rem 0.5rem', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3505,9 +3510,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3541,9 +3546,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3744,9 +3749,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3780,9 +3785,9 @@ const PrintStyle11 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
||||||
|
|
@ -31,16 +31,16 @@ import {
|
||||||
GlobalprintCredit,
|
GlobalprintCredit,
|
||||||
GlobalprintTax,
|
GlobalprintTax,
|
||||||
GlobalSelectedPrintHeaderColor,
|
GlobalSelectedPrintHeaderColor,
|
||||||
GlobalSelectedPrintHeaderFontColor,
|
GlobalSelectedPrintHeaderFontColor,
|
||||||
GlobalSelectedTableHeaderColor,
|
GlobalSelectedTableHeaderColor,
|
||||||
GlobalSelectedTableHeaderFontColor,
|
GlobalSelectedTableHeaderFontColor,
|
||||||
GlobalSelectedTableBodyFontColor,
|
GlobalSelectedTableBodyFontColor,
|
||||||
GlobalSelectedTableBodyColor,
|
GlobalSelectedTableBodyColor,
|
||||||
GlobalRowType,
|
GlobalRowType,
|
||||||
GlobalSelectedFooterColor,
|
GlobalSelectedFooterColor,
|
||||||
GlobalSelectedFooterFontColor,
|
GlobalSelectedFooterFontColor,
|
||||||
GlobalSelectedNetAmountColor,
|
GlobalSelectedNetAmountColor,
|
||||||
GlobalSelectedNetAmountFontColor,
|
GlobalSelectedNetAmountFontColor,
|
||||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||||
import {
|
import {
|
||||||
GlobalUpiIDprint,
|
GlobalUpiIDprint,
|
||||||
|
|
@ -114,25 +114,31 @@ const Printstyle12 = ({
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
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);
|
||||||
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(obj => obj.tableHeaderColor)?.tableHeaderColor;
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
||||||
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
const footerColor = printColors?.find(obj => obj.footerColor)?.footerColor;
|
||||||
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
const netAmtColor = printColors?.find(obj => obj.netAmtColor)?.netAmtColor;
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const estimatePrintHeader =
|
const estimatePrintHeader =
|
||||||
SettingData?.[0]?.SettingDtlDetails?.find(
|
SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
(setting) =>
|
(setting) =>
|
||||||
|
|
@ -504,7 +510,7 @@ const Printstyle12 = ({
|
||||||
await printDiv('PrintStyle12', style12, 'FontApply');
|
await printDiv('PrintStyle12', style12, 'FontApply');
|
||||||
};
|
};
|
||||||
|
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
@ -810,67 +816,67 @@ const Printstyle12 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle}}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle}}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Description</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Description</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Des</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{ ...tableHeaderStyle,textAlign: 'right' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
Tax (%)
|
Tax (%)
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
Tax (%)
|
Tax (%)
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{ ...tableHeaderStyle,textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|
@ -878,17 +884,17 @@ const Printstyle12 = ({
|
||||||
{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 && (
|
||||||
|
|
@ -1049,9 +1055,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1074,10 +1080,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1107,67 +1112,67 @@ const Printstyle12 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle,}}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle,}}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle,}}>Description</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Description</th>
|
||||||
: Item && <th style={{...tableHeaderStyle,}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle, }}>Des</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{ ...tableHeaderStyle,textAlign: 'right' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
Tax (%)
|
Tax (%)
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
Tax (%)
|
Tax (%)
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{ ...tableHeaderStyle,textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|
@ -1175,17 +1180,17 @@ const Printstyle12 = ({
|
||||||
{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 && (
|
||||||
|
|
@ -1269,9 +1274,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1294,10 +1299,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3290,7 +3294,7 @@ const Printstyle12 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle12-firstDiv" style={{...headerStyle}}>
|
<div className="PrintStyle12-firstDiv" style={{ ...headerStyle }}>
|
||||||
{/* <h3>{table2Data?.BrName}</h3> */}
|
{/* <h3>{table2Data?.BrName}</h3> */}
|
||||||
<div style={{ display: 'flex', flexDirection: 'column' }}>
|
<div style={{ display: 'flex', flexDirection: 'column' }}>
|
||||||
<hr
|
<hr
|
||||||
|
|
@ -3466,58 +3470,58 @@ const Printstyle12 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle}}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle}}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Description</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Description</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Des</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{ ...tableHeaderStyle,textAlign: 'right' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
||||||
)
|
)
|
||||||
: MRP && <th style={{ ...tableHeaderStyle,textAlign: 'right' }}>MRP</th>}
|
: MRP && <th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate && <th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>}
|
: Rate && <th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{ ...tableHeaderStyle,textAlign: 'right' }}>Tax (%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Tax (%)</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Tax (%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Tax (%)</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)
|
)
|
||||||
: Amount && <th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>}
|
: Amount && <th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>}
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
|
@ -3525,17 +3529,17 @@ const Printstyle12 = ({
|
||||||
(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>}
|
||||||
|
|
@ -3716,9 +3720,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3741,9 +3745,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3774,44 +3778,44 @@ const Printstyle12 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle}}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle}}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Description</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Description</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Des</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>
|
||||||
)
|
)
|
||||||
: MRP && <th style={{...tableHeaderStyle, textAlign: 'right' }}>MRP</th>}
|
: MRP && <th style={{ ...tableHeaderStyle, textAlign: 'right' }}>MRP</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate && <th style={{...tableHeaderStyle, textAlign: 'right' }}>Rate</th>}
|
: Rate && <th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Rate</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>(%)</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
|
|
@ -3819,13 +3823,13 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Tax (%)</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Tax (%)</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)
|
)
|
||||||
: Amount && <th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>}
|
: Amount && <th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>}
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
|
@ -3833,17 +3837,17 @@ const Printstyle12 = ({
|
||||||
(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>}
|
||||||
|
|
@ -3923,9 +3927,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3948,9 +3952,9 @@ const Printstyle12 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -4094,7 +4098,7 @@ const Printstyle12 = ({
|
||||||
)}
|
)}
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
<div style={{ display: 'flex', justifyContent: 'space-between',...netAmountStyle }}>
|
<div style={{ display: 'flex', justifyContent: 'space-between', ...netAmountStyle }}>
|
||||||
<div style={{ width: '45%', fontWeight: '600' }}>Amount</div>
|
<div style={{ width: '45%', fontWeight: '600' }}>Amount</div>
|
||||||
<div> : </div>
|
<div> : </div>
|
||||||
<div
|
<div
|
||||||
|
|
|
||||||
|
|
@ -105,16 +105,16 @@ const Printstyle2 = ({
|
||||||
(ps) => ps.PaymentTypeName === 'UPI'
|
(ps) => ps.PaymentTypeName === 'UPI'
|
||||||
);
|
);
|
||||||
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 GlobalSignature = useSelector(GlobalprintSignature);
|
const GlobalSignature = useSelector(GlobalprintSignature);
|
||||||
const GlobaltermsAndConditions = useSelector(GlobalprinttermsAndConditions);
|
const GlobaltermsAndConditions = useSelector(GlobalprinttermsAndConditions);
|
||||||
const GlobalSignatureImages = useSelector(GlobalSignatureImage);
|
const GlobalSignatureImages = useSelector(GlobalSignatureImage);
|
||||||
|
|
@ -126,7 +126,13 @@ const Printstyle2 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
const estimatePrintHeader =
|
const estimatePrintHeader =
|
||||||
|
|
@ -364,50 +370,50 @@ const Printstyle2 = ({
|
||||||
: 0;
|
: 0;
|
||||||
|
|
||||||
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 13);
|
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 13);
|
||||||
const headerStyle ={
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData
|
||||||
? SelectedHeaderFontColor
|
? SelectedHeaderFontColor
|
||||||
: headerColor?.font,
|
: headerColor?.font,
|
||||||
}
|
}
|
||||||
const tableHeaderStyle ={
|
const tableHeaderStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedTableHeaderColor
|
? SelectedTableHeaderColor
|
||||||
: tableHeaderColor?.background,
|
: tableHeaderColor?.background,
|
||||||
|
|
||||||
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
|
? SelectedTableBodyFontColor
|
||||||
: tableBodyColor?.font,
|
: tableBodyColor?.font,
|
||||||
}
|
}
|
||||||
const rowtypeStyle = GlobaldummyData? SelectedRowType: tableBodyColor?.rowType;
|
const rowtypeStyle = GlobaldummyData ? SelectedRowType : tableBodyColor?.rowType;
|
||||||
const footerColorStyle ={
|
const footerColorStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedTableFooterColor
|
? SelectedTableFooterColor
|
||||||
: footerColor?.background,
|
: footerColor?.background,
|
||||||
|
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData
|
||||||
? SelectedTableFooterFontColor
|
? SelectedTableFooterFontColor
|
||||||
: footerColor?.font,
|
: footerColor?.font,
|
||||||
}
|
}
|
||||||
const netAmountStyle ={
|
const netAmountStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedNetAmountColor
|
? SelectedNetAmountColor
|
||||||
: netAmtColor?.background,
|
: netAmtColor?.background,
|
||||||
|
|
||||||
color: GlobaldummyData
|
color: GlobaldummyData
|
||||||
? SelectedNetAmountFontColor
|
? SelectedNetAmountFontColor
|
||||||
: netAmtColor?.font,
|
: netAmtColor?.font,
|
||||||
}
|
}
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
|
|
@ -461,7 +467,7 @@ const Printstyle2 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle2-fistDiv" style={{...headerStyle }}>
|
<div className="PrintStyle2-fistDiv" style={{ ...headerStyle }}>
|
||||||
<div style={{ display: 'flex', flexDirection: 'row' }}>
|
<div style={{ display: 'flex', flexDirection: 'row' }}>
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
GlobalLogo && (
|
GlobalLogo && (
|
||||||
|
|
@ -584,7 +590,7 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData ? formattedDate : Date1}
|
{GlobaldummyData ? formattedDate : Date1}
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -615,23 +621,23 @@ const Printstyle2 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -639,14 +645,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -654,14 +660,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -669,14 +675,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -684,14 +690,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -723,14 +729,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -741,17 +747,17 @@ const Printstyle2 = ({
|
||||||
{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
|
|
||||||
}
|
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: {}
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
}>
|
? {
|
||||||
|
...tableBodyStyle
|
||||||
|
}
|
||||||
|
: {}
|
||||||
|
}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<td className="Re-print-body-Rate">
|
<td className="Re-print-body-Rate">
|
||||||
|
|
@ -797,7 +803,7 @@ const Printstyle2 = ({
|
||||||
</span>
|
</span>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
) : UomPrint?.SettingValue === 'Y' && (
|
) : UomPrint?.SettingValue === 'Y' && (
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
({item?.Size ? item?.Size : '1'}{' '}
|
({item?.Size ? item?.Size : '1'}{' '}
|
||||||
|
|
@ -814,7 +820,7 @@ const Printstyle2 = ({
|
||||||
? item?.BrandName
|
? item?.BrandName
|
||||||
: ''}
|
: ''}
|
||||||
|
|
||||||
<div style={{ display: "flex", gap: "3px" ,flexDirection:"column"}}>
|
<div style={{ display: "flex", gap: "3px", flexDirection: "column" }}>
|
||||||
{item?.ProductIdentifierDtls?.length >
|
{item?.ProductIdentifierDtls?.length >
|
||||||
0
|
0
|
||||||
? item?.ProductIdentifierDtls?.filter(
|
? item?.ProductIdentifierDtls?.filter(
|
||||||
|
|
@ -1000,23 +1006,23 @@ const Printstyle2 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{ ...tableHeaderStyle,width: '8px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1024,14 +1030,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1039,14 +1045,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1054,14 +1060,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1069,14 +1075,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1084,7 +1090,8 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th
|
<th
|
||||||
style={{ width: '10px',textAlign: 'center',...tableHeaderStyle,
|
style={{
|
||||||
|
width: '10px', textAlign: 'center', ...tableHeaderStyle,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
Tax %
|
Tax %
|
||||||
|
|
@ -1093,7 +1100,7 @@ const Printstyle2 = ({
|
||||||
: Tax == true &&
|
: Tax == true &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'center',}}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center', }}
|
||||||
>
|
>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1101,14 +1108,14 @@ const Printstyle2 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1119,17 +1126,17 @@ const Printstyle2 = ({
|
||||||
{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
|
|
||||||
}
|
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: {}
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
}>
|
? {
|
||||||
|
...tableBodyStyle
|
||||||
|
}
|
||||||
|
: {}
|
||||||
|
}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<td className="Re-print-body-Rate">
|
<td className="Re-print-body-Rate">
|
||||||
|
|
@ -1156,17 +1163,17 @@ const Printstyle2 = ({
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div>{item?.ProdName}</div>
|
<div>{item?.ProdName}</div>
|
||||||
{UomPrint?.SettingValue === 'Y' &&
|
{UomPrint?.SettingValue === 'Y' &&
|
||||||
<div>
|
<div>
|
||||||
({item?.Size ? item?.Size : '1'}{' '}
|
({item?.Size ? item?.Size : '1'}{' '}
|
||||||
{item?.SinglePc == 'Y'
|
{item?.SinglePc == 'Y'
|
||||||
? 'PCS'
|
? 'PCS'
|
||||||
: item?.Type != 'C'
|
: item?.Type != 'C'
|
||||||
? item?.UomName
|
? item?.UomName
|
||||||
: 'COMBO'}
|
: 'COMBO'}
|
||||||
)
|
)
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1393,7 +1400,7 @@ const Printstyle2 = ({
|
||||||
!shouldFooterBeOnNewPage &&
|
!shouldFooterBeOnNewPage &&
|
||||||
FormatTheme && (
|
FormatTheme && (
|
||||||
<>
|
<>
|
||||||
<div className="PrintStyle2-ThirdDivMaster" style={{...netAmountStyle}}>
|
<div className="PrintStyle2-ThirdDivMaster" style={{ ...netAmountStyle }}>
|
||||||
<div className="PrintStyle2-ThirdP">
|
<div className="PrintStyle2-ThirdP">
|
||||||
<div>
|
<div>
|
||||||
<div style={{ textAlign: 'left', fontWeight: '600' }}>
|
<div style={{ textAlign: 'left', fontWeight: '600' }}>
|
||||||
|
|
@ -2061,7 +2068,7 @@ const Printstyle2 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -2274,11 +2281,11 @@ const Printstyle2 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<>
|
<>
|
||||||
<div className="PrintStyle2-ThirdDivMaster" style={{...netAmountStyle}}>
|
<div className="PrintStyle2-ThirdDivMaster" style={{ ...netAmountStyle }}>
|
||||||
<div className="PrintStyle2-ThirdP">
|
<div className="PrintStyle2-ThirdP">
|
||||||
<div>
|
<div>
|
||||||
<div style={{ textAlign: 'left', fontWeight: '600' }}>
|
<div style={{ textAlign: 'left', fontWeight: '600' }}>
|
||||||
|
|
@ -2932,7 +2939,7 @@ const Printstyle2 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3130,8 +3137,8 @@ const Printstyle2 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle2-fistDiv" style={{...headerStyle }}>
|
<div className="PrintStyle2-fistDiv" style={{ ...headerStyle }}>
|
||||||
<div style={{ display: 'flex', flexDirection: 'row'}}>
|
<div style={{ display: 'flex', flexDirection: 'row' }}>
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
GlobalLogo && (
|
GlobalLogo && (
|
||||||
<img
|
<img
|
||||||
|
|
@ -3274,86 +3281,86 @@ const Printstyle2 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle,width: '8px' }}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax == true &&
|
: Tax == true &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3364,17 +3371,17 @@ const Printstyle2 = ({
|
||||||
(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
|
||||||
|
}
|
||||||
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: {}
|
||||||
? {
|
}>
|
||||||
...tableBodyStyle
|
|
||||||
}
|
|
||||||
: {}
|
|
||||||
}>
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<td className="Re-print-body-Rate">
|
<td className="Re-print-body-Rate">
|
||||||
|
|
@ -3419,7 +3426,7 @@ const Printstyle2 = ({
|
||||||
</span>
|
</span>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
) : UomPrint?.SettingValue === 'Y' && (
|
) : UomPrint?.SettingValue === 'Y' && (
|
||||||
<div>
|
<div>
|
||||||
({item?.Size ? item?.Size : '1'}{' '}
|
({item?.Size ? item?.Size : '1'}{' '}
|
||||||
{item?.SinglePc == 'Y'
|
{item?.SinglePc == 'Y'
|
||||||
|
|
@ -3435,7 +3442,7 @@ const Printstyle2 = ({
|
||||||
? item?.BrandName
|
? item?.BrandName
|
||||||
: ''}
|
: ''}
|
||||||
|
|
||||||
<div style={{ display: 'flex', gap: "3px",flexDirection:"column" }}>
|
<div style={{ display: 'flex', gap: "3px", flexDirection: "column" }}>
|
||||||
{item?.ProductIdentifierDtls?.length > 0
|
{item?.ProductIdentifierDtls?.length > 0
|
||||||
? item?.ProductIdentifierDtls.filter(
|
? item?.ProductIdentifierDtls.filter(
|
||||||
(items) =>
|
(items) =>
|
||||||
|
|
@ -3611,86 +3618,86 @@ const Printstyle2 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle, width: '8px' }}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '8px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
: Item && <th style={{...tableHeaderStyle}}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax == true &&
|
: Tax == true &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{ ...tableHeaderStyle,width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th style={{...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '8px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3701,17 +3708,17 @@ const Printstyle2 = ({
|
||||||
(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
|
||||||
|
}
|
||||||
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: {}
|
||||||
? {
|
}>
|
||||||
...tableBodyStyle
|
|
||||||
}
|
|
||||||
: {}
|
|
||||||
}>
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<td className="Re-print-body-Rate">
|
<td className="Re-print-body-Rate">
|
||||||
|
|
@ -3738,17 +3745,17 @@ const Printstyle2 = ({
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div>{item?.ProdName}</div>
|
<div>{item?.ProdName}</div>
|
||||||
{UomPrint?.SettingValue === 'Y' &&
|
{UomPrint?.SettingValue === 'Y' &&
|
||||||
<div>
|
<div>
|
||||||
({item?.Size ? item?.Size : '1'}{' '}
|
({item?.Size ? item?.Size : '1'}{' '}
|
||||||
{item?.SinglePc == 'Y'
|
{item?.SinglePc == 'Y'
|
||||||
? 'PCS'
|
? 'PCS'
|
||||||
: item?.Type != 'C'
|
: item?.Type != 'C'
|
||||||
? item?.UomName
|
? item?.UomName
|
||||||
: 'COMBO'}
|
: 'COMBO'}
|
||||||
)
|
)
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3885,7 +3892,7 @@ const Printstyle2 = ({
|
||||||
<hr className="PrintStyle2-print-dottline" />
|
<hr className="PrintStyle2-print-dottline" />
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<div className="PrintStyle2-ThirdDivMaster" style={{...netAmountStyle}}>
|
<div className="PrintStyle2-ThirdDivMaster" style={{ ...netAmountStyle }}>
|
||||||
<div className="PrintStyle2-ThirdP">
|
<div className="PrintStyle2-ThirdP">
|
||||||
<div>
|
<div>
|
||||||
<div style={{ textAlign: 'left', fontWeight: '600' }}>Qty</div>
|
<div style={{ textAlign: 'left', fontWeight: '600' }}>Qty</div>
|
||||||
|
|
@ -4499,7 +4506,7 @@ const Printstyle2 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
|
||||||
|
|
@ -101,6 +101,12 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
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(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -200,7 +206,7 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
|
|
||||||
if (hasMappedOffer) {
|
if (hasMappedOffer) {
|
||||||
|
|
||||||
const productTotal = productsData?.reduce((acc, item) => acc + (item?.Type != "C" ? item.OfferAmt : item.OfferValue || 0), 0);
|
const productTotal = productsData?.reduce((acc, item) => acc + (item?.Type !== 'C' ? (item?.OfferAmt || item?.DiscountAmt || 0) : (item?.OfferValue || item?.DiscountAmt || 0)), 0);
|
||||||
TotalOfferAmount += productTotal;
|
TotalOfferAmount += productTotal;
|
||||||
} else {
|
} else {
|
||||||
const Combothere = productsData?.filter(item => item?.Type == "C")
|
const Combothere = productsData?.filter(item => item?.Type == "C")
|
||||||
|
|
@ -289,7 +295,7 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
|
|
||||||
{/* <div className="header" style={{ position: isMobile ? "" : GlobaldummyData ? "absolute" : "fixed", top: 0, width: "100%" }}> */}
|
{/* <div className="header" style={{ position: isMobile ? "" : GlobaldummyData ? "absolute" : "fixed", top: 0, width: "100%" }}> */}
|
||||||
<div className="header" style={{ position: isMobile ? "" : GlobaldummyData ? "absolute" : isPdf ? "static" : "fixed", top: 0, width: "100%" }}>
|
<div className="header" style={{ position: isMobile ? "" : GlobaldummyData ? "absolute" : isPdf ? "static" : "fixed", top: 0, width: "100%" }}>
|
||||||
{((!estimatePrintHeader && table2Data?.OrderType === "E") ? '' : <div className="PrintStyle3-print" style={{ ...headerStyle,}} >
|
{((!estimatePrintHeader && table2Data?.OrderType === "E") ? '' : <div className="PrintStyle3-print" style={{ ...headerStyle, }} >
|
||||||
<div style={{ display: 'flex', flexDirection: 'row', alignItems: 'center' }}>
|
<div style={{ display: 'flex', flexDirection: 'row', alignItems: 'center' }}>
|
||||||
{GlobaldummyData && GlobalLogo ? <img className='PrintStyle2-BrandImage' src={Logo} alt='image' width={100} /> : null}
|
{GlobaldummyData && GlobalLogo ? <img className='PrintStyle2-BrandImage' src={Logo} alt='image' width={100} /> : null}
|
||||||
{(base64Image && (PrintLogo?.SettingValue === "Y" || LogoField)) ? <img className='PrintStyle2-BrandImage' src={base64Image} alt='image' width={100} /> : null}
|
{(base64Image && (PrintLogo?.SettingValue === "Y" || LogoField)) ? <img className='PrintStyle2-BrandImage' src={base64Image} alt='image' width={100} /> : null}
|
||||||
|
|
@ -319,9 +325,10 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
<div className="PrintStyle3-print-ordr-dtls">
|
<div className="PrintStyle3-print-ordr-dtls">
|
||||||
<div style={{ lineheight: '50px' }}>
|
<div style={{ lineheight: '50px' }}>
|
||||||
<div style={{ fontSize: '14px', fontWeight: 600 }} > BILL NO :{GlobaldummyData ? '51' : table2Data?.OrderId && extractLastNumberOrderId(table2Data?.OrderId, table2Data?.FYStatus)} </div>
|
<div style={{ fontSize: '14px', fontWeight: 600 }} > BILL NO :{GlobaldummyData ? '51' : table2Data?.OrderId && extractLastNumberOrderId(table2Data?.OrderId, table2Data?.FYStatus)} </div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '14px', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
<div style={{ fontSize: '14px', fontWeight: 600 }} > {GlobaldummyData ? formattedDate : Date1}</div>
|
<div style={{ fontSize: '14px', fontWeight: 600 }} > {GlobaldummyData ? formattedDate : Date1}</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -421,9 +428,15 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
||||||
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'center' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'center' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
||||||
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
||||||
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Type != "C" ? item?.OfferAmt || 0 : item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>
|
||||||
|
{item?.Type !== 'C'
|
||||||
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
|
: (item?.OfferValue || item?.DiscountAmt || 0)}</div>
|
||||||
|
}
|
||||||
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
||||||
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type != "C" ? item?.TotalAmt - item?.OfferAmt || 0 : item?.TotalAmt - item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} >
|
||||||
|
{item?.Type !== 'C' ? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0) : item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -464,9 +477,11 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
||||||
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'right' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'right' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
||||||
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
||||||
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Type != "C" ? item?.OfferAmt || 0 : item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Type !== 'C'
|
||||||
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
|
: (item?.OfferValue || item?.DiscountAmt || 0)}</div>}
|
||||||
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
||||||
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type != "C" ? item?.TotalAmt - item?.OfferAmt || 0 : item?.TotalAmt - item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type !== 'C' ? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0) : item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}</div>}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -488,7 +503,7 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{((chunkIndex === paginatedChunks.length - 1) && (!shouldFooterBeOnNewPage)) && FormatTheme &&
|
{((chunkIndex === paginatedChunks.length - 1) && (!shouldFooterBeOnNewPage)) && FormatTheme &&
|
||||||
|
|
||||||
<>
|
<>
|
||||||
<div className="PrintStyle3-print-ttlovrl" style={{...netAmountStyle}}>
|
<div className="PrintStyle3-print-ttlovrl" style={{ ...netAmountStyle }}>
|
||||||
<div>
|
<div>
|
||||||
<div style={{ fontWeight: '600' }}> Items : </div>
|
<div style={{ fontWeight: '600' }}> Items : </div>
|
||||||
<div style={{ fontWeight: '600' }}> Qty : </div>
|
<div style={{ fontWeight: '600' }}> Qty : </div>
|
||||||
|
|
@ -889,7 +904,7 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<>
|
<>
|
||||||
<div className="PrintStyle3-print-ttlovrl" style={{...netAmountStyle}}>
|
<div className="PrintStyle3-print-ttlovrl" style={{ ...netAmountStyle }}>
|
||||||
<div>
|
<div>
|
||||||
<div style={{ fontWeight: '600' }}> Items : </div>
|
<div style={{ fontWeight: '600' }}> Items : </div>
|
||||||
<div style={{ fontWeight: '600' }}> Qty : </div>
|
<div style={{ fontWeight: '600' }}> Qty : </div>
|
||||||
|
|
@ -1397,9 +1412,11 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
||||||
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'center' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'center' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
||||||
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
||||||
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Type != "C" ? item?.OfferAmt || 0 : item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Type !== 'C'
|
||||||
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
|
: (item?.OfferValue || item?.DiscountAmt || 0)}</div>}
|
||||||
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
||||||
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type != "C" ? item?.TotalAmt - item?.OfferAmt || 0 : item?.TotalAmt - item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type !== 'C' ? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0) : item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}</div>}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1440,9 +1457,13 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
{GlobaldummyData ? GlobalMRP && <div style={{ width: '100%', textAlign: 'right', }}>{item?.MRP}</div> : MRP && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SinglePc === 'Y' ? item?.Rate : item?.MRP}</div>}
|
||||||
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'right' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
{GlobaldummyData ? GlobalQuantity && <div style={{ width: '100%', textAlign: 'right' }}>{item?.SalesQty}</div> : Quantity && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.SalesQty}</div>}
|
||||||
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
{GlobaldummyData ? GlobalRate && <div style={{ width: '100%', textAlign: 'right' }}>{item?.Rate}</div> : Rate && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Rate}</div>}
|
||||||
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.Type != "C" ? item?.OfferAmt || 0 : item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalDiscount && <div style={{ width: '100%', textAlign: 'right' }}>{item?.discount}</div> : Discount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>
|
||||||
|
{item?.Type !== 'C'
|
||||||
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
|
</div>}
|
||||||
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
{GlobaldummyData ? GlobalTax && <div style={{ width: '100%', textAlign: 'right' }}>{item?.ProdTaxPercentage || 0}</div> : (Tax == true && table2Data?.OrderType !== 'E') && (<div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }}>{item?.ProdTaxPercentage || 0}</div>)}
|
||||||
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type != "C" ? item?.TotalAmt - item?.OfferAmt || 0 : item?.TotalAmt - item?.OfferValue || 0}</div>}
|
{GlobaldummyData ? GlobalAmount && <div style={{ width: '100%', textAlign: 'right' }} >{item?.TotalAmt}</div> : Amount && <div style={{ width: '100%', textAlign: 'right', fontWeight: 600 }} > {item?.Type !== 'C' ? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0) : item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}</div>}
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1459,7 +1480,7 @@ const PrintStyle3 = ({ index, totalQuantityFilter, Date1, CashierName, totalQuan
|
||||||
</div>
|
</div>
|
||||||
}
|
}
|
||||||
{/* <br/> */}
|
{/* <br/> */}
|
||||||
<div className="PrintStyle3-print-ttlovrl" style={{...netAmountStyle}}>
|
<div className="PrintStyle3-print-ttlovrl" style={{ ...netAmountStyle }}>
|
||||||
<div>
|
<div>
|
||||||
<div style={{ fontWeight: '600' }}> Items : </div>
|
<div style={{ fontWeight: '600' }}> Items : </div>
|
||||||
<div style={{ fontWeight: '600' }}> Qty : </div>
|
<div style={{ fontWeight: '600' }}> Qty : </div>
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -123,6 +123,12 @@ const PrintStyle5 = ({
|
||||||
const SelectedNetAmountColor = useSelector(GlobalSelectedNetAmountColor);
|
const SelectedNetAmountColor = useSelector(GlobalSelectedNetAmountColor);
|
||||||
const SelectedNetAmountFontColor = useSelector(GlobalSelectedNetAmountFontColor);
|
const SelectedNetAmountFontColor = useSelector(GlobalSelectedNetAmountFontColor);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -949,9 +955,9 @@ const PrintStyle5 = ({
|
||||||
<div
|
<div
|
||||||
style={{ width: '100%', textAlign: 'right' }}
|
style={{ width: '100%', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -983,9 +989,9 @@ const PrintStyle5 = ({
|
||||||
style={{ width: '100%', textAlign: 'right' }}
|
style={{ width: '100%', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1272,9 +1278,9 @@ const PrintStyle5 = ({
|
||||||
<div
|
<div
|
||||||
style={{ width: '100%', textAlign: 'right' }}
|
style={{ width: '100%', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1306,9 +1312,9 @@ const PrintStyle5 = ({
|
||||||
style={{ width: '100%', textAlign: 'right' }}
|
style={{ width: '100%', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -1523,7 +1529,7 @@ const PrintStyle5 = ({
|
||||||
|
|
||||||
<div
|
<div
|
||||||
className="align-style"
|
className="align-style"
|
||||||
style={{ fontWeight: '600', fontSize: '19px',...netAmountStyle, }}
|
style={{ fontWeight: '600', fontSize: '19px', ...netAmountStyle, }}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
<div>Amount </div> <div> : </div>{' '}
|
<div>Amount </div> <div> : </div>{' '}
|
||||||
|
|
@ -2271,7 +2277,7 @@ const PrintStyle5 = ({
|
||||||
|
|
||||||
<div
|
<div
|
||||||
className="align-style"
|
className="align-style"
|
||||||
style={{ fontWeight: '600', fontSize: '19px',...netAmountStyle, }}
|
style={{ fontWeight: '600', fontSize: '19px', ...netAmountStyle, }}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
<div>Amount </div> <div> : </div>{' '}
|
<div>Amount </div> <div> : </div>{' '}
|
||||||
|
|
@ -2895,9 +2901,10 @@ const PrintStyle5 = ({
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
<div> {GlobaldummyData ? formattedDate : Date1}
|
<div> {GlobaldummyData ? formattedDate : Date1}
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '14px', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
</div>{' '}
|
</div>{' '}
|
||||||
<div>
|
<div>
|
||||||
|
|
@ -3270,9 +3277,9 @@ const PrintStyle5 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<div style={{ width: '100%', textAlign: 'right' }}>
|
<div style={{ width: '100%', textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3296,9 +3303,9 @@ const PrintStyle5 = ({
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<div style={{ width: '100%', textAlign: 'right' }}>
|
<div style={{ width: '100%', textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3561,9 +3568,9 @@ const PrintStyle5 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<div style={{ width: '100%', textAlign: 'right' }}>
|
<div style={{ width: '100%', textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3587,9 +3594,9 @@ const PrintStyle5 = ({
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<div style={{ width: '100%', textAlign: 'right' }}>
|
<div style={{ width: '100%', textAlign: 'right' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -3775,7 +3782,7 @@ const PrintStyle5 = ({
|
||||||
|
|
||||||
<div
|
<div
|
||||||
className="align-style"
|
className="align-style"
|
||||||
style={{...netAmountStyle, fontWeight: '600', fontSize: '19px' }}
|
style={{ ...netAmountStyle, fontWeight: '600', fontSize: '19px' }}
|
||||||
>
|
>
|
||||||
{' '}
|
{' '}
|
||||||
<div>Amount </div> <div> : </div>{' '}
|
<div>Amount </div> <div> : </div>{' '}
|
||||||
|
|
|
||||||
|
|
@ -29,17 +29,17 @@ import {
|
||||||
GlobalprintLogo,
|
GlobalprintLogo,
|
||||||
GlobalprintCredit,
|
GlobalprintCredit,
|
||||||
GlobalprintTax,
|
GlobalprintTax,
|
||||||
GlobalSelectedPrintHeaderColor,
|
GlobalSelectedPrintHeaderColor,
|
||||||
GlobalSelectedPrintHeaderFontColor,
|
GlobalSelectedPrintHeaderFontColor,
|
||||||
GlobalSelectedTableHeaderColor,
|
GlobalSelectedTableHeaderColor,
|
||||||
GlobalSelectedTableHeaderFontColor,
|
GlobalSelectedTableHeaderFontColor,
|
||||||
GlobalSelectedTableBodyFontColor,
|
GlobalSelectedTableBodyFontColor,
|
||||||
GlobalSelectedTableBodyColor,
|
GlobalSelectedTableBodyColor,
|
||||||
GlobalRowType,
|
GlobalRowType,
|
||||||
GlobalSelectedFooterColor,
|
GlobalSelectedFooterColor,
|
||||||
GlobalSelectedFooterFontColor,
|
GlobalSelectedFooterFontColor,
|
||||||
GlobalSelectedNetAmountColor,
|
GlobalSelectedNetAmountColor,
|
||||||
GlobalSelectedNetAmountFontColor,
|
GlobalSelectedNetAmountFontColor,
|
||||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||||
import {
|
import {
|
||||||
GlobalUpiIDprint,
|
GlobalUpiIDprint,
|
||||||
|
|
@ -113,17 +113,23 @@ const Printstyle6 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
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 Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
console.log(CashierNameField, "GlobaldummyData")
|
console.log(CashierNameField, "GlobaldummyData")
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
|
|
@ -356,7 +362,7 @@ const Printstyle6 = ({
|
||||||
? paginatedChunks[paginatedChunks.length - 1].length
|
? paginatedChunks[paginatedChunks.length - 1].length
|
||||||
: 0;
|
: 0;
|
||||||
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 13);
|
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 13);
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
@ -458,7 +464,7 @@ const Printstyle6 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle6-firstDiv" style={{...headerStyle}}>
|
<div className="PrintStyle6-firstDiv" style={{ ...headerStyle }}>
|
||||||
<div
|
<div
|
||||||
className="P6HdBrnchName"
|
className="P6HdBrnchName"
|
||||||
style={{
|
style={{
|
||||||
|
|
@ -620,12 +626,12 @@ const Printstyle6 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
(GlobalItem || GlobalQuantity) && (
|
(GlobalItem || GlobalQuantity) && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: 'ITEM /DES/'}{' '}
|
: 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -635,7 +641,7 @@ const Printstyle6 = ({
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
) : (
|
) : (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: Item && 'ITEM /DES/'}{' '}
|
: Item && 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -789,17 +795,17 @@ const Printstyle6 = ({
|
||||||
{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
|
|
||||||
}
|
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: {}
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
}>
|
? {
|
||||||
|
...tableBodyStyle
|
||||||
|
}
|
||||||
|
: {}
|
||||||
|
}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && (
|
: SLNO && (
|
||||||
|
|
@ -957,9 +963,9 @@ const Printstyle6 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1005,10 +1011,9 @@ const Printstyle6 = ({
|
||||||
// paddingRight: "20px",
|
// paddingRight: "20px",
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1038,12 +1043,12 @@ const Printstyle6 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
(GlobalItem || GlobalQuantity) && (
|
(GlobalItem || GlobalQuantity) && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: 'ITEM /DES/'}{' '}
|
: 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -1053,7 +1058,7 @@ const Printstyle6 = ({
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
) : (
|
) : (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: Item && 'ITEM /DES/'}{' '}
|
: Item && 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -1207,17 +1212,17 @@ const Printstyle6 = ({
|
||||||
{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
|
|
||||||
}
|
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: {}
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
}>
|
? {
|
||||||
|
...tableBodyStyle
|
||||||
|
}
|
||||||
|
: {}
|
||||||
|
}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && (
|
: SLNO && (
|
||||||
|
|
@ -1345,9 +1350,9 @@ const Printstyle6 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1393,10 +1398,9 @@ const Printstyle6 = ({
|
||||||
// paddingRight: "20px",
|
// paddingRight: "20px",
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1797,7 +1801,7 @@ const Printstyle6 = ({
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<div className="PrintStyle6-secondDiv" style={{...netAmountStyle}}>
|
<div className="PrintStyle6-secondDiv" style={{ ...netAmountStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
textAlign: 'left',
|
textAlign: 'left',
|
||||||
|
|
@ -2197,7 +2201,7 @@ const Printstyle6 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
|
|
@ -2799,7 +2803,7 @@ const Printstyle6 = ({
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<div className="PrintStyle6-secondDiv" style={{...netAmountStyle}}>
|
<div className="PrintStyle6-secondDiv" style={{ ...netAmountStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
textAlign: 'left',
|
textAlign: 'left',
|
||||||
|
|
@ -3193,7 +3197,7 @@ const Printstyle6 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
|
|
@ -3400,7 +3404,7 @@ const Printstyle6 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle6-firstDiv" style={{...headerStyle}}>
|
<div className="PrintStyle6-firstDiv" style={{ ...headerStyle }}>
|
||||||
<div
|
<div
|
||||||
className="P6HdBrnchName"
|
className="P6HdBrnchName"
|
||||||
style={{
|
style={{
|
||||||
|
|
@ -3526,9 +3530,10 @@ const Printstyle6 = ({
|
||||||
table2Data?.FYStatus
|
table2Data?.FYStatus
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '10px', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
|
|
||||||
<div style={{ fontSize: '12px' }}>{Date1}</div>
|
<div style={{ fontSize: '12px' }}>{Date1}</div>
|
||||||
|
|
@ -3553,11 +3558,11 @@ const Printstyle6 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
(GlobalItem || GlobalQuantity) && (
|
(GlobalItem || GlobalQuantity) && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: 'ITEM /DES/'}{' '}
|
: 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -3565,7 +3570,7 @@ const Printstyle6 = ({
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
) : (
|
) : (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: Item && 'ITEM /DES/'}{' '}
|
: Item && 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -3576,68 +3581,68 @@ const Printstyle6 = ({
|
||||||
)}
|
)}
|
||||||
{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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{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 style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
AMt
|
AMt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3648,17 +3653,17 @@ const Printstyle6 = ({
|
||||||
(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
|
||||||
|
}
|
||||||
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: {}
|
||||||
? {
|
}>
|
||||||
...tableBodyStyle
|
|
||||||
}
|
|
||||||
: {}
|
|
||||||
}>
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && <td>{index + 1}</td>}
|
: SLNO && <td>{index + 1}</td>}
|
||||||
|
|
@ -3775,9 +3780,9 @@ const Printstyle6 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3823,9 +3828,9 @@ const Printstyle6 = ({
|
||||||
// paddingRight: "20px",
|
// paddingRight: "20px",
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3855,11 +3860,11 @@ const Printstyle6 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData ? (
|
{GlobaldummyData ? (
|
||||||
(GlobalItem || GlobalQuantity) && (
|
(GlobalItem || GlobalQuantity) && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: 'ITEM /DES/'}{' '}
|
: 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -3867,7 +3872,7 @@ const Printstyle6 = ({
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
) : (
|
) : (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && 'ITEM /DES/'
|
? GlobalItem && 'ITEM /DES/'
|
||||||
: Item && 'ITEM /DES/'}{' '}
|
: Item && 'ITEM /DES/'}{' '}
|
||||||
|
|
@ -3878,34 +3883,34 @@ const Printstyle6 = ({
|
||||||
)}
|
)}
|
||||||
{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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3917,29 +3922,29 @@ const Printstyle6 = ({
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{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 style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
AMt
|
AMt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3950,17 +3955,17 @@ const Printstyle6 = ({
|
||||||
(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
|
||||||
|
}
|
||||||
|
: index % 2 === 1 && rowtypeStyle === "odd"
|
||||||
? {
|
? {
|
||||||
...tableBodyStyle
|
...tableBodyStyle
|
||||||
}
|
}
|
||||||
: index % 2 === 1 && rowtypeStyle === "odd"
|
: {}
|
||||||
? {
|
}>
|
||||||
...tableBodyStyle
|
|
||||||
}
|
|
||||||
: {}
|
|
||||||
}>
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <td>{index + 1}</td>
|
? GlobalSlNo && <td>{index + 1}</td>
|
||||||
: SLNO && <td>{index + 1}</td>}
|
: SLNO && <td>{index + 1}</td>}
|
||||||
|
|
@ -4094,9 +4099,9 @@ const Printstyle6 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -4142,9 +4147,9 @@ const Printstyle6 = ({
|
||||||
// paddingRight: "20px",
|
// paddingRight: "20px",
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -4519,7 +4524,7 @@ const Printstyle6 = ({
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
<div className="PrintStyle6-secondDiv" style={{...netAmountStyle}}>
|
<div className="PrintStyle6-secondDiv" style={{ ...netAmountStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
textAlign: 'left',
|
textAlign: 'left',
|
||||||
|
|
@ -4896,7 +4901,7 @@ const Printstyle6 = ({
|
||||||
pageBreakBefore: 'avoid',
|
pageBreakBefore: 'avoid',
|
||||||
pageBreakInside: 'avoid',
|
pageBreakInside: 'avoid',
|
||||||
minHeight: 'auto',
|
minHeight: 'auto',
|
||||||
...footerColorStyle
|
...footerColorStyle
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
|
|
|
||||||
|
|
@ -109,18 +109,18 @@ const PrintStyle7 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
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);
|
||||||
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(obj => obj.tableHeaderColor)?.tableHeaderColor;
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
||||||
|
|
@ -129,6 +129,12 @@ const PrintStyle7 = ({
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const estimatePrintHeader =
|
const estimatePrintHeader =
|
||||||
SettingData?.[0]?.SettingDtlDetails?.find(
|
SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
(setting) =>
|
(setting) =>
|
||||||
|
|
@ -375,7 +381,7 @@ const PrintStyle7 = ({
|
||||||
? paginatedChunks[paginatedChunks.length - 1].length
|
? paginatedChunks[paginatedChunks.length - 1].length
|
||||||
: 0;
|
: 0;
|
||||||
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 10);
|
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 10);
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
@ -478,7 +484,7 @@ const PrintStyle7 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle7-print" style={{...headerStyle}}>
|
<div className="PrintStyle7-print" style={{ ...headerStyle }}>
|
||||||
{/* <div style={{ fontSize: '16px', fontWeight: '600' }}> {GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}</div> */}
|
{/* <div style={{ fontSize: '16px', fontWeight: '600' }}> {GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}</div> */}
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
|
|
@ -644,58 +650,58 @@ const PrintStyle7 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S</th>
|
||||||
)
|
)
|
||||||
: SLNO == true && (
|
: SLNO == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle,}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Item</th>
|
||||||
: Item == true && <th style={{...tableHeaderStyle,}}>Item</th>}
|
: Item == true && <th style={{ ...tableHeaderStyle, }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode == true && (
|
: HsnCode == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity == true && (
|
: Quantity == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
)
|
)
|
||||||
: MRP == true && (
|
: MRP == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate == true && (
|
: Rate == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)
|
)
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
|
|
@ -725,17 +731,17 @@ const PrintStyle7 = ({
|
||||||
<tbody>
|
<tbody>
|
||||||
{dataChunk?.map((item, index) => (
|
{dataChunk?.map((item, index) => (
|
||||||
<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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -859,9 +865,9 @@ const PrintStyle7 = ({
|
||||||
? GlobalDiscount && <td>{item.discount}</td>
|
? GlobalDiscount && <td>{item.discount}</td>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -884,10 +890,9 @@ const PrintStyle7 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -918,58 +923,58 @@ const PrintStyle7 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO == true && (
|
: SLNO == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.NO</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.NO</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle,}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Item</th>
|
||||||
: Item == true && <th style={{...tableHeaderStyle,}}>Item</th>}
|
: Item == true && <th style={{ ...tableHeaderStyle, }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode == true && (
|
: HsnCode == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity == true && (
|
: Quantity == true && (
|
||||||
<th style={{ ...tableHeaderStyle,width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
)
|
)
|
||||||
: MRP == true && (
|
: MRP == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate == true && (
|
: Rate == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)
|
)
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
|
|
@ -999,17 +1004,17 @@ const PrintStyle7 = ({
|
||||||
<tbody>
|
<tbody>
|
||||||
{dataChunk?.map((item, index) => (
|
{dataChunk?.map((item, index) => (
|
||||||
<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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -1125,9 +1130,9 @@ const PrintStyle7 = ({
|
||||||
? GlobalDiscount && <td>{item.discount}</td>
|
? GlobalDiscount && <td>{item.discount}</td>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1150,10 +1155,9 @@ const PrintStyle7 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -2984,7 +2988,7 @@ const PrintStyle7 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle7-print" style={{...headerStyle}}>
|
<div className="PrintStyle7-print" style={{ ...headerStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3108,9 +3112,10 @@ const PrintStyle7 = ({
|
||||||
)}
|
)}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '10px', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
</div>
|
</div>
|
||||||
<div className="PrintStyle7-SecondDiv2">
|
<div className="PrintStyle7-SecondDiv2">
|
||||||
|
|
@ -3150,58 +3155,58 @@ const PrintStyle7 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle, width: '10%' }}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '10%' }}>S.No</th>
|
||||||
: SLNO == true && (
|
: SLNO == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && (
|
? GlobalItem && (
|
||||||
<th style={{...tableHeaderStyle, width: '30%', textAlign: 'left' }}>
|
<th style={{ ...tableHeaderStyle, width: '30%', textAlign: 'left' }}>
|
||||||
Item
|
Item
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Item == true && <th style={{...tableHeaderStyle}}>Item</th>}
|
: Item == true && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && <th style={{...tableHeaderStyle}}>HSN</th>
|
? GlobalHsnCode && <th style={{ ...tableHeaderStyle }}>HSN</th>
|
||||||
: HsnCode == true && (
|
: HsnCode == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && <th style={{...tableHeaderStyle}}>Qty</th>
|
? GlobalQuantity && <th style={{ ...tableHeaderStyle }}>Qty</th>
|
||||||
: Quantity == true && (
|
: Quantity == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && <th style={{...tableHeaderStyle}}>MRP</th>
|
? GlobalMRP && <th style={{ ...tableHeaderStyle }}>MRP</th>
|
||||||
: MRP == true && (
|
: MRP == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && <th style={{...tableHeaderStyle}}>Rate</th>
|
? GlobalRate && <th style={{ ...tableHeaderStyle }}>Rate</th>
|
||||||
: Rate == true && (
|
: Rate == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && <th style={{...tableHeaderStyle,}}>Dis </th>
|
? GlobalDiscount && <th style={{ ...tableHeaderStyle, }}>Dis </th>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'right' }}>Amt</th>
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3211,17 +3216,17 @@ const PrintStyle7 = ({
|
||||||
{(GlobaldummyData ? products : TakeawayData)?.map(
|
{(GlobaldummyData ? products : TakeawayData)?.map(
|
||||||
(item, index) => (
|
(item, index) => (
|
||||||
<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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -3344,9 +3349,9 @@ const PrintStyle7 = ({
|
||||||
? GlobalDiscount && <td>{item.discount}</td>
|
? GlobalDiscount && <td>{item.discount}</td>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3369,9 +3374,9 @@ const PrintStyle7 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3402,64 +3407,64 @@ const PrintStyle7 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle, width: '10px' }}>S</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '10px' }}>S</th>
|
||||||
: SLNO == true && (
|
: SLNO == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle}}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle }}>Item</th>
|
||||||
: Item == true && <th style={{...tableHeaderStyle}}>Item</th>}
|
: Item == true && <th style={{ ...tableHeaderStyle }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)
|
)
|
||||||
: HsnCode == true && (
|
: HsnCode == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>HSN</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>HSN</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Qty</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Qty</th>
|
||||||
)
|
)
|
||||||
: Quantity == true && (
|
: Quantity == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && <th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
? GlobalMRP && <th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
: MRP == true && (
|
: MRP == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>MRP</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>MRP</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)
|
)
|
||||||
: Rate == true && (
|
: Rate == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Rate</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Rate</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)
|
)
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Dis </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Dis </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Tax % </th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3469,17 +3474,17 @@ const PrintStyle7 = ({
|
||||||
{(GlobaldummyData ? products : DineInData)?.map(
|
{(GlobaldummyData ? products : DineInData)?.map(
|
||||||
(item, index) => (
|
(item, index) => (
|
||||||
<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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -3583,9 +3588,9 @@ const PrintStyle7 = ({
|
||||||
? GlobalDiscount && <td>{item.discount}</td>
|
? GlobalDiscount && <td>{item.discount}</td>
|
||||||
: Discount == true && (
|
: Discount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3608,9 +3613,9 @@ const PrintStyle7 = ({
|
||||||
)
|
)
|
||||||
: Amount == true && (
|
: Amount == true && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
||||||
|
|
@ -30,15 +30,15 @@ import {
|
||||||
GlobalprintTax,
|
GlobalprintTax,
|
||||||
GlobalSelectedPrintHeaderColor,
|
GlobalSelectedPrintHeaderColor,
|
||||||
GlobalSelectedPrintHeaderFontColor,
|
GlobalSelectedPrintHeaderFontColor,
|
||||||
GlobalSelectedTableHeaderColor,
|
GlobalSelectedTableHeaderColor,
|
||||||
GlobalSelectedTableHeaderFontColor,
|
GlobalSelectedTableHeaderFontColor,
|
||||||
GlobalSelectedTableBodyFontColor,
|
GlobalSelectedTableBodyFontColor,
|
||||||
GlobalSelectedTableBodyColor,
|
GlobalSelectedTableBodyColor,
|
||||||
GlobalRowType,
|
GlobalRowType,
|
||||||
GlobalSelectedFooterColor,
|
GlobalSelectedFooterColor,
|
||||||
GlobalSelectedFooterFontColor,
|
GlobalSelectedFooterFontColor,
|
||||||
GlobalSelectedNetAmountColor,
|
GlobalSelectedNetAmountColor,
|
||||||
GlobalSelectedNetAmountFontColor,
|
GlobalSelectedNetAmountFontColor,
|
||||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||||
import Logo from '../../../../Images/Logo.jpg';
|
import Logo from '../../../../Images/Logo.jpg';
|
||||||
import {
|
import {
|
||||||
|
|
@ -115,6 +115,12 @@ const Printstyle8 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -160,17 +166,17 @@ const Printstyle8 = ({
|
||||||
);
|
);
|
||||||
|
|
||||||
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);
|
||||||
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(obj => obj.tableHeaderColor)?.tableHeaderColor;
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
||||||
|
|
@ -387,7 +393,7 @@ const Printstyle8 = ({
|
||||||
? paginatedChunks[paginatedChunks.length - 1].length
|
? paginatedChunks[paginatedChunks.length - 1].length
|
||||||
: 0;
|
: 0;
|
||||||
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 13);
|
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 13);
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
@ -489,7 +495,7 @@ const Printstyle8 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle8-fistDiv" style={{...headerStyle}}>
|
<div className="PrintStyle8-fistDiv" style={{ ...headerStyle }}>
|
||||||
{/* <h3>{table2Data?.BrName}</h3> */}
|
{/* <h3>{table2Data?.BrName}</h3> */}
|
||||||
|
|
||||||
<div
|
<div
|
||||||
|
|
@ -651,8 +657,8 @@ const Printstyle8 = ({
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle,}}>Dis</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Dis</th>
|
||||||
: Item && <th style={{...tableHeaderStyle,}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle, }}>Des</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
|
|
@ -821,17 +827,17 @@ const Printstyle8 = ({
|
||||||
{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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -944,9 +950,9 @@ const Printstyle8 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -990,10 +996,9 @@ const Printstyle8 = ({
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1047,8 +1052,8 @@ const Printstyle8 = ({
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle,}}>Dis</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Dis</th>
|
||||||
: Item && <th style={{...tableHeaderStyle,}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle, }}>Des</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
|
|
@ -1217,17 +1222,17 @@ const Printstyle8 = ({
|
||||||
{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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -1312,9 +1317,9 @@ const Printstyle8 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1358,10 +1363,9 @@ const Printstyle8 = ({
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -1379,7 +1383,7 @@ const Printstyle8 = ({
|
||||||
FormatTheme && (
|
FormatTheme && (
|
||||||
<>
|
<>
|
||||||
<hr className="PrintStyle8-print-dottline" />
|
<hr className="PrintStyle8-print-dottline" />
|
||||||
<div style={{ fontSize: '12px',...netAmountStyle }}>
|
<div style={{ fontSize: '12px', ...netAmountStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -2386,7 +2390,7 @@ const Printstyle8 = ({
|
||||||
>
|
>
|
||||||
<>
|
<>
|
||||||
<hr className="PrintStyle8-print-dottline" />
|
<hr className="PrintStyle8-print-dottline" />
|
||||||
<div style={{ fontSize: '12px',...netAmountStyle }}>
|
<div style={{ fontSize: '12px', ...netAmountStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3359,7 +3363,7 @@ const Printstyle8 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle8-fistDiv" style={{...headerStyle}}>
|
<div className="PrintStyle8-fistDiv" style={{ ...headerStyle }}>
|
||||||
{/* <h3>{table2Data?.BrName}</h3> */}
|
{/* <h3>{table2Data?.BrName}</h3> */}
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
|
|
@ -3461,9 +3465,10 @@ const Printstyle8 = ({
|
||||||
table2Data?.FYStatus
|
table2Data?.FYStatus
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '10px', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
|
|
||||||
</div>}
|
</div>}
|
||||||
<div style={{ fontSize: "10px" }}>
|
<div style={{ fontSize: "10px" }}>
|
||||||
{GlobaldummyData ? formattedDate : Date1}
|
{GlobaldummyData ? formattedDate : Date1}
|
||||||
|
|
@ -3494,95 +3499,95 @@ const Printstyle8 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
S.No
|
S.No
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: SLNO && (
|
: SLNO && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
S.No
|
S.No
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && (
|
? GlobalItem && (
|
||||||
<th style={{...tableHeaderStyle, textAlign: 'left' }}>Dis</th>
|
<th style={{ ...tableHeaderStyle, textAlign: 'left' }}>Dis</th>
|
||||||
)
|
)
|
||||||
: Item && <th style={{...tableHeaderStyle,}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle, }}>Des</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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{ ...tableHeaderStyle,width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{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 style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Rt
|
Rt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
(%)
|
(%)
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
(%)
|
(%)
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3593,17 +3598,17 @@ const Printstyle8 = ({
|
||||||
(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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -3686,9 +3691,9 @@ const Printstyle8 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3732,9 +3737,9 @@ const Printstyle8 = ({
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3767,93 +3772,93 @@ const Printstyle8 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
S.No
|
S.No
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: SLNO && (
|
: SLNO && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'center' }}>
|
||||||
S.No
|
S.No
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle,}}>Dis</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, }}>Dis</th>
|
||||||
: Item && <th style={{...tableHeaderStyle,}}>Des</th>}
|
: Item && <th style={{ ...tableHeaderStyle, }}>Des</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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{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 style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Rt
|
Rt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
(%)
|
(%)
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
(%)
|
(%)
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3864,17 +3869,17 @@ const Printstyle8 = ({
|
||||||
(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 && (
|
? GlobalSlNo && (
|
||||||
<td style={{ textAlign: 'center' }}>
|
<td style={{ textAlign: 'center' }}>
|
||||||
|
|
@ -3963,9 +3968,9 @@ const Printstyle8 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -4009,9 +4014,9 @@ const Printstyle8 = ({
|
||||||
textAlign: 'right',
|
textAlign: 'right',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -4024,7 +4029,7 @@ const Printstyle8 = ({
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
<hr className="PrintStyle8-print-dottline" />
|
<hr className="PrintStyle8-print-dottline" />
|
||||||
<div style={{ fontSize: '12px',...netAmountStyle }}>
|
<div style={{ fontSize: '12px', ...netAmountStyle }}>
|
||||||
<div style={{ display: 'flex', justifyContent: 'space-between' }}>
|
<div style={{ display: 'flex', justifyContent: 'space-between' }}>
|
||||||
<div style={{ width: '40%' }}>Items </div>
|
<div style={{ width: '40%' }}>Items </div>
|
||||||
<div> : </div>
|
<div> : </div>
|
||||||
|
|
|
||||||
|
|
@ -30,15 +30,15 @@ import {
|
||||||
GlobalprintTax,
|
GlobalprintTax,
|
||||||
GlobalSelectedPrintHeaderColor,
|
GlobalSelectedPrintHeaderColor,
|
||||||
GlobalSelectedPrintHeaderFontColor,
|
GlobalSelectedPrintHeaderFontColor,
|
||||||
GlobalSelectedTableHeaderColor,
|
GlobalSelectedTableHeaderColor,
|
||||||
GlobalSelectedTableHeaderFontColor,
|
GlobalSelectedTableHeaderFontColor,
|
||||||
GlobalSelectedTableBodyFontColor,
|
GlobalSelectedTableBodyFontColor,
|
||||||
GlobalSelectedTableBodyColor,
|
GlobalSelectedTableBodyColor,
|
||||||
GlobalRowType,
|
GlobalRowType,
|
||||||
GlobalSelectedFooterColor,
|
GlobalSelectedFooterColor,
|
||||||
GlobalSelectedFooterFontColor,
|
GlobalSelectedFooterFontColor,
|
||||||
GlobalSelectedNetAmountColor,
|
GlobalSelectedNetAmountColor,
|
||||||
GlobalSelectedNetAmountFontColor,
|
GlobalSelectedNetAmountFontColor,
|
||||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||||
import Logo from '../../../../Images/Logo.jpg';
|
import Logo from '../../../../Images/Logo.jpg';
|
||||||
import {
|
import {
|
||||||
|
|
@ -112,6 +112,12 @@ const PrintStyle9 = ({
|
||||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||||
const SettingData = useSelector(PreferenceData);
|
const SettingData = useSelector(PreferenceData);
|
||||||
|
const Retailshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'retailshortname'
|
||||||
|
);
|
||||||
|
const Wholesaleshortname = SettingData?.[0]?.SettingDtlDetails?.find(
|
||||||
|
(setting) => setting?.SettingIdName?.toLowerCase() === 'wholesaleshortname'
|
||||||
|
);
|
||||||
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
const UomPrint = SettingData?.[0]?.SettingDtlDetails?.filter(
|
||||||
(i) => i.SettingIdName === 'PrintUom'
|
(i) => i.SettingIdName === 'PrintUom'
|
||||||
)?.[0];
|
)?.[0];
|
||||||
|
|
@ -154,18 +160,18 @@ const PrintStyle9 = ({
|
||||||
(ps) => ps.PaymentStatus === 'S' && ps?.LastOrderTran === 'Y'
|
(ps) => ps.PaymentStatus === 'S' && ps?.LastOrderTran === 'Y'
|
||||||
);
|
);
|
||||||
|
|
||||||
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);
|
||||||
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(obj => obj.tableHeaderColor)?.tableHeaderColor;
|
||||||
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
const tableBodyColor = printColors?.find(obj => obj.tableBodyColor)?.tableBodyColor;
|
||||||
|
|
@ -377,7 +383,7 @@ const PrintStyle9 = ({
|
||||||
? paginatedChunks[paginatedChunks.length - 1].length
|
? paginatedChunks[paginatedChunks.length - 1].length
|
||||||
: 0;
|
: 0;
|
||||||
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 10);
|
const shouldFooterBeOnNewPage = lastChunkRows > (PageSize == 'A5' ? 5 : 10);
|
||||||
const headerStyle = {
|
const headerStyle = {
|
||||||
backgroundColor: GlobaldummyData
|
backgroundColor: GlobaldummyData
|
||||||
? SelectedHeaderColor
|
? SelectedHeaderColor
|
||||||
: headerColor?.background,
|
: headerColor?.background,
|
||||||
|
|
@ -479,7 +485,7 @@ const PrintStyle9 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle9-print" style={{...headerStyle}}>
|
<div className="PrintStyle9-print" style={{ ...headerStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -651,25 +657,25 @@ const PrintStyle9 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && (
|
? GlobalItem && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Item</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>
|
||||||
)
|
)
|
||||||
: Item && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -677,14 +683,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -692,14 +698,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -707,14 +713,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -722,7 +728,7 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -730,7 +736,7 @@ const PrintStyle9 = ({
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -738,14 +744,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -753,14 +759,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -771,17 +777,17 @@ const PrintStyle9 = ({
|
||||||
{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 && (
|
||||||
|
|
@ -907,9 +913,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -943,10 +949,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -975,25 +980,25 @@ const PrintStyle9 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && (
|
? GlobalItem && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px' }}>Item</th>
|
<th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>
|
||||||
)
|
)
|
||||||
: Item && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalQuantity && (
|
? GlobalQuantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Qty
|
Qty
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Quantity && (
|
: Quantity && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1001,14 +1006,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalHsnCode && (
|
? GlobalHsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: HsnCode && (
|
: HsnCode && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1016,14 +1021,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1031,14 +1036,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalDiscount && (
|
? GlobalDiscount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1046,7 +1051,7 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1054,7 +1059,7 @@ const PrintStyle9 = ({
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1062,14 +1067,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalRate && (
|
? GlobalRate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Rate && (
|
: Rate && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1077,14 +1082,14 @@ const PrintStyle9 = ({
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th
|
<th
|
||||||
style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}
|
||||||
>
|
>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
|
|
@ -1095,17 +1100,17 @@ const PrintStyle9 = ({
|
||||||
{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 && (
|
||||||
|
|
@ -1179,9 +1184,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -1215,10 +1220,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue ||
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
0}
|
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -2338,7 +2342,7 @@ const PrintStyle9 = ({
|
||||||
<hr className="PrintStyle9-print-dottline" />
|
<hr className="PrintStyle9-print-dottline" />
|
||||||
|
|
||||||
<div
|
<div
|
||||||
style={{ display: 'flex', justifyContent: 'space-between',...netAmountStyle }}
|
style={{ display: 'flex', justifyContent: 'space-between', ...netAmountStyle }}
|
||||||
>
|
>
|
||||||
<div style={{ fontWeight: '700' }}>Net Amount:</div>
|
<div style={{ fontWeight: '700' }}>Net Amount:</div>
|
||||||
<div style={{ fontWeight: '700', marginRight: '0.5rem' }}>
|
<div style={{ fontWeight: '700', marginRight: '0.5rem' }}>
|
||||||
|
|
@ -3212,7 +3216,7 @@ const PrintStyle9 = ({
|
||||||
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
{!estimatePrintHeader && table2Data?.OrderType === 'E' ? (
|
||||||
''
|
''
|
||||||
) : (
|
) : (
|
||||||
<div className="PrintStyle9-print" style={{...headerStyle}}>
|
<div className="PrintStyle9-print" style={{ ...headerStyle }}>
|
||||||
<div
|
<div
|
||||||
style={{
|
style={{
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
|
@ -3338,10 +3342,11 @@ const PrintStyle9 = ({
|
||||||
table2Data?.FYStatus
|
table2Data?.FYStatus
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontSize: '13px', fontWeight: 600 }}>
|
{SalesModePref?.SettingValue == 'Y' && <div style={{ fontWeight: '600' }}>
|
||||||
{' '}
|
{' '}
|
||||||
Name : {table2Data?.SalesMode == "R" ? "RT" : "WS"}{' '}
|
Name : {table2Data?.SalesMode == "R" ? Retailshortname?.Comments : Wholesaleshortname?.Comments}{' '}
|
||||||
</div>}
|
|
||||||
|
</div>}
|
||||||
<div style={{ fontSize: '12px', fontWeight: '400' }}>
|
<div style={{ fontSize: '12px', fontWeight: '400' }}>
|
||||||
{' '}
|
{' '}
|
||||||
{GlobaldummyData ? formattedDate : Date1}{' '}
|
{GlobaldummyData ? formattedDate : Date1}{' '}
|
||||||
|
|
@ -3389,89 +3394,89 @@ const PrintStyle9 = ({
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && (
|
? GlobalSlNo && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'left' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'left' }}>
|
||||||
S.No
|
S.No
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>
|
||||||
: Item && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle, width: '10px' }}>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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : '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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{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 style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3482,17 +3487,17 @@ const PrintStyle9 = ({
|
||||||
(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>}
|
||||||
|
|
@ -3583,11 +3588,12 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
|
|
@ -3619,9 +3625,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3650,86 +3656,86 @@ const PrintStyle9 = ({
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalSlNo && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>
|
? GlobalSlNo && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>
|
||||||
: SLNO && <th style={{...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
: SLNO && <th style={{ ...tableHeaderStyle, width: '10px' }}>S.No</th>}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalItem && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>
|
? GlobalItem && <th style={{ ...tableHeaderStyle, width: '10px' }}>Item</th>
|
||||||
: Item && <th style={{...tableHeaderStyle, width: '10px' }}>Item</th>}
|
: Item && <th style={{ ...tableHeaderStyle, width: '10px' }}>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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
{WeightasKg ? 'Qty/Kg' : '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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
HSN
|
HSN
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalMRP && (
|
? GlobalMRP && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
MRP
|
MRP
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: MRP && (
|
: MRP && (
|
||||||
<th style={{...tableHeaderStyle,width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
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: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Dis{' '}
|
Dis{' '}
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalTax && (
|
? GlobalTax && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Tax &&
|
: Tax &&
|
||||||
table2Data?.OrderType !== 'E' && (
|
table2Data?.OrderType !== 'E' && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Tax %
|
Tax %
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{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 style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Rate
|
Rate
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
? GlobalAmount && (
|
? GlobalAmount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<th style={{...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
<th style={{ ...tableHeaderStyle, width: '10px', textAlign: 'right' }}>
|
||||||
Amt
|
Amt
|
||||||
</th>
|
</th>
|
||||||
)}
|
)}
|
||||||
|
|
@ -3740,17 +3746,17 @@ const PrintStyle9 = ({
|
||||||
(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>}
|
||||||
|
|
@ -3818,9 +3824,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Discount && (
|
: Discount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.OfferAmt || 0
|
? (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.OfferValue || 0}
|
: (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
@ -3854,9 +3860,9 @@ const PrintStyle9 = ({
|
||||||
)
|
)
|
||||||
: Amount && (
|
: Amount && (
|
||||||
<td style={{ textAlign: 'right' }}>
|
<td style={{ textAlign: 'right' }}>
|
||||||
{item?.Type != 'C'
|
{item?.Type !== 'C'
|
||||||
? item?.TotalAmt - item?.OfferAmt || 0
|
? item?.TotalAmt - (item?.OfferAmt || item?.DiscountAmt || 0)
|
||||||
: item?.TotalAmt - item?.OfferValue || 0}
|
: item?.TotalAmt - (item?.OfferValue || item?.DiscountAmt || 0)}
|
||||||
</td>
|
</td>
|
||||||
)}
|
)}
|
||||||
</tr>
|
</tr>
|
||||||
|
|
@ -3961,7 +3967,7 @@ const PrintStyle9 = ({
|
||||||
|
|
||||||
<hr className="PrintStyle9-print-dottline" />
|
<hr className="PrintStyle9-print-dottline" />
|
||||||
|
|
||||||
<div style={{ display: 'flex', justifyContent: 'space-between',...netAmountStyle }}>
|
<div style={{ display: 'flex', justifyContent: 'space-between', ...netAmountStyle }}>
|
||||||
<div style={{ fontWeight: '700' }}>Net Amount:</div>
|
<div style={{ fontWeight: '700' }}>Net Amount:</div>
|
||||||
<div style={{ fontWeight: '700', marginRight: '0.5rem' }}>
|
<div style={{ fontWeight: '700', marginRight: '0.5rem' }}>
|
||||||
{GlobaldummyData
|
{GlobaldummyData
|
||||||
|
|
|
||||||
1993
src/routesConfig.jsx
1993
src/routesConfig.jsx
File diff suppressed because it is too large
Load Diff
|
|
@ -1,34 +0,0 @@
|
||||||
import { defineConfig } from "vite";
|
|
||||||
import react from "@vitejs/plugin-react";
|
|
||||||
import { terser } from "rollup-plugin-terser";
|
|
||||||
|
|
||||||
export default defineConfig(({ command, mode }) => {
|
|
||||||
if (mode === "production") {
|
|
||||||
return {
|
|
||||||
plugins: [
|
|
||||||
react(),
|
|
||||||
// terser({ // Add terser plugin for production
|
|
||||||
// compress: {
|
|
||||||
// drop_console: true, // This removes all console.* statements
|
|
||||||
// },
|
|
||||||
// }),
|
|
||||||
],
|
|
||||||
base: "/apps/retail/",
|
|
||||||
envDir: "src",
|
|
||||||
envPrefix: "ENV_",
|
|
||||||
};
|
|
||||||
} else {
|
|
||||||
return {
|
|
||||||
plugins: [react()],
|
|
||||||
envDir: "src",
|
|
||||||
envPrefix: "ENV_",
|
|
||||||
server: {
|
|
||||||
host: "192.168.1.50",
|
|
||||||
port: process.env.PORT || 3015,
|
|
||||||
},
|
|
||||||
optimizeDeps: {
|
|
||||||
exclude: ["console.log"],
|
|
||||||
},
|
|
||||||
};
|
|
||||||
}
|
|
||||||
});
|
|
||||||
Loading…
Reference in New Issue