removefromcartbugfixing

This commit is contained in:
unknown 2026-02-24 18:47:18 +05:30
parent 8cf58532a3
commit 2ea0a2bc9c
6 changed files with 1077 additions and 1038 deletions

View File

@ -1217,6 +1217,7 @@ const BSBillingTable1 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: isPaidproduct?.InwardDtlId, InwardDtlId: isPaidproduct?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
OrderRate: isPaidproduct?.OrderRate,
Offer: 0, Offer: 0,
}); });
} else if (isPaidproduct?.OrderQty > item?.OrderQty) { } else if (isPaidproduct?.OrderQty > item?.OrderQty) {
@ -1390,6 +1391,7 @@ const BSBillingTable1 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -1468,6 +1470,7 @@ const BSBillingTable1 = () => {
OrderQty: isPaidproduct?.OrderQty, OrderQty: isPaidproduct?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate:item?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
}); });
@ -1503,6 +1506,7 @@ const BSBillingTable1 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate,
}); });
await ChangeOfferAppliedProdsFn({ await ChangeOfferAppliedProdsFn({
inwardDtlId: item?.InwardDtlId, inwardDtlId: item?.InwardDtlId,
@ -1532,6 +1536,7 @@ const BSBillingTable1 = () => {
OrderQty: isPaidProductAvailableInCart?.OrderQty, OrderQty: isPaidProductAvailableInCart?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId, InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId,
OrderRate:isPaidProductAvailableInCart?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
}); });
@ -1617,6 +1622,7 @@ const BSBillingTable1 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1643,6 +1649,7 @@ const BSBillingTable1 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1975,6 +1982,7 @@ const BSBillingTable1 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
OrderRate:item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -1993,6 +2001,7 @@ const BSBillingTable1 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
OrderRate:item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -2243,8 +2252,7 @@ const BSBillingTable1 = () => {
{OldtableDataTakeAway?.map((item, index) => ( {OldtableDataTakeAway?.map((item, index) => (
<tr <tr
key={index} key={index}
className={`${ className={`${item?.SalesId && OrderType !== 'Hold'
item?.SalesId && OrderType !== 'Hold'
? 'Billing-Table1-row-disabled' ? 'Billing-Table1-row-disabled'
: 'Billing-Table1-row' : 'Billing-Table1-row'
} }
@ -2539,8 +2547,7 @@ const BSBillingTable1 = () => {
{OldtableDataDinein?.map((item, index) => ( {OldtableDataDinein?.map((item, index) => (
<tr <tr
key={OldtableDataTakeAway?.length + index} key={OldtableDataTakeAway?.length + index}
className={`${ className={`${item?.SalesId
item?.SalesId
? 'Billing-Table1-row-disabled' ? 'Billing-Table1-row-disabled'
: 'Billing-Table1-row' : 'Billing-Table1-row'
} }
@ -2836,8 +2843,7 @@ const BSBillingTable1 = () => {
OldtableDataTakeAway?.length + OldtableDataTakeAway?.length +
index index
} }
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'Billing-Table1-row-disabled' ? 'Billing-Table1-row-disabled'
: 'Billing-Table1-row' : 'Billing-Table1-row'
} }
@ -3182,8 +3188,7 @@ const BSBillingTable1 = () => {
tableDataTakeAway?.length + tableDataTakeAway?.length +
index index
} }
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'Billing-Table1-row-disabled' ? 'Billing-Table1-row-disabled'
: 'Billing-Table1-row' : 'Billing-Table1-row'
} }

View File

@ -1124,6 +1124,7 @@ const BSBillingTable4 = () => {
BookedDate: isPaidproduct?.BookedDate, BookedDate: isPaidproduct?.BookedDate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
OrderRate: isPaidproduct?.OrderRate,
}); });
} else if (isPaidproduct?.OrderQty > item?.OrderQty) { } else if (isPaidproduct?.OrderQty > item?.OrderQty) {
// Just Decrease Paid Qty // Just Decrease Paid Qty
@ -1302,6 +1303,7 @@ const BSBillingTable4 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -1381,6 +1383,7 @@ const BSBillingTable4 = () => {
OrderQty: isPaidproduct?.OrderQty, OrderQty: isPaidproduct?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
@ -1415,6 +1418,7 @@ const BSBillingTable4 = () => {
OrderQty: item?.OrderQty, OrderQty: item?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
@ -1448,6 +1452,7 @@ const BSBillingTable4 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId, InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId,
BookedDate: isPaidProductAvailableInCart?.BookedDate, BookedDate: isPaidProductAvailableInCart?.BookedDate,
OrderRate: isPaidProductAvailableInCart?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
}); });
@ -1536,6 +1541,7 @@ const BSBillingTable4 = () => {
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1561,6 +1567,7 @@ const BSBillingTable4 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
OrderRate: item?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
}); });
@ -1612,6 +1619,7 @@ const BSBillingTable4 = () => {
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate, OrderRate: item?.OrderRate,
}); });
} else { } else {
const isCheck = GlobalOfferAppliedProductsData?.find( const isCheck = GlobalOfferAppliedProductsData?.find(
@ -1919,6 +1927,7 @@ const BSBillingTable4 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -1938,6 +1947,7 @@ const BSBillingTable4 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
BookedDate: item?.BookedDate, BookedDate: item?.BookedDate,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -2390,8 +2400,7 @@ const BSBillingTable4 = () => {
{OldtableDataTakeAway?.map((item, index) => ( {OldtableDataTakeAway?.map((item, index) => (
<tr <tr
key={index} key={index}
className={`${ className={`${item?.SalesId && OrderType !== 'Hold'
item?.SalesId && OrderType !== 'Hold'
? 'BSBill-Table3-content-Disabled' ? 'BSBill-Table3-content-Disabled'
: 'BSBill-Table3-content' : 'BSBill-Table3-content'
} }
@ -2665,8 +2674,7 @@ const BSBillingTable4 = () => {
{OldtableDataDinein?.map((item, index) => ( {OldtableDataDinein?.map((item, index) => (
<tr <tr
key={OldtableDataTakeAway?.length + index} key={OldtableDataTakeAway?.length + index}
className={`${ className={`${item?.SalesId
item?.SalesId
? 'BSBill-Table3-content-Disabled' ? 'BSBill-Table3-content-Disabled'
: 'BSBill-Table3-content' : 'BSBill-Table3-content'
} }
@ -2941,8 +2949,7 @@ const BSBillingTable4 = () => {
OldtableDataTakeAway?.length + OldtableDataTakeAway?.length +
index index
} }
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'BSBill-Table3-content-Disabled' ? 'BSBill-Table3-content-Disabled'
: 'BSBill-Table3-content' : 'BSBill-Table3-content'
} }
@ -3267,8 +3274,7 @@ const BSBillingTable4 = () => {
OldtableDataTakeAway?.length + OldtableDataTakeAway?.length +
index index
} }
className={`${ className={`${item?.SalesId && OrderType !== 'Hold'
item?.SalesId && OrderType !== 'Hold'
? 'BSBill-Table3-content-Disabled' ? 'BSBill-Table3-content-Disabled'
: 'BSBill-Table3-content' : 'BSBill-Table3-content'
} }

View File

@ -1164,6 +1164,7 @@ const BSBillingTable6 = () => {
OrderQty: isPaidproduct?.OrderQty, OrderQty: isPaidproduct?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: isPaidproduct?.InwardDtlId, InwardDtlId: isPaidproduct?.InwardDtlId,
OrderRate: isPaidproduct?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
}); });
@ -1337,6 +1338,7 @@ const BSBillingTable6 = () => {
OrderQty: isPaidproduct?.OrderQty, OrderQty: isPaidproduct?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
}); });
@ -1416,6 +1418,7 @@ const BSBillingTable6 = () => {
OrderQty: isPaidproduct?.OrderQty, OrderQty: isPaidproduct?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
}); });
@ -1449,6 +1452,7 @@ const BSBillingTable6 = () => {
OrderQty: item?.OrderQty, OrderQty: item?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
}); });
@ -1481,6 +1485,7 @@ const BSBillingTable6 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId, InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
OrderRate:isPaidProductAvailableInCart?.OrderRate,
Offer: 0, Offer: 0,
}); });
} else if ( } else if (
@ -1565,6 +1570,7 @@ const BSBillingTable6 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1591,6 +1597,7 @@ const BSBillingTable6 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1638,6 +1645,7 @@ const BSBillingTable6 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate,
}); });
} else { } else {
const isCheck = GlobalOfferAppliedProductsData?.find( const isCheck = GlobalOfferAppliedProductsData?.find(
@ -1914,6 +1922,7 @@ const BSBillingTable6 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -1932,6 +1941,7 @@ const BSBillingTable6 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({

View File

@ -1044,6 +1044,7 @@ const BSBillingTable7 = () => {
InwardDtlId: isPaidproduct?.InwardDtlId, InwardDtlId: isPaidproduct?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
OrderRate: isPaidproduct?.OrderRate
}); });
} else if (isPaidproduct?.OrderQty > item?.OrderQty) { } else if (isPaidproduct?.OrderQty > item?.OrderQty) {
// Just Decrease Paid Qty // Just Decrease Paid Qty
@ -1217,6 +1218,7 @@ const BSBillingTable7 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty, OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty,
@ -1294,6 +1296,7 @@ const BSBillingTable7 = () => {
OrderQty: isPaidproduct?.OrderQty, OrderQty: isPaidproduct?.OrderQty,
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
}); });
@ -1326,6 +1329,7 @@ const BSBillingTable7 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeOfferAppliedProdsFn({ await ChangeOfferAppliedProdsFn({
inwardDtlId: item?.InwardDtlId, inwardDtlId: item?.InwardDtlId,
@ -1357,6 +1361,7 @@ const BSBillingTable7 = () => {
InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId, InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
OrderRate: isPaidProductAvailableInCart?.OrderRate
}); });
} else if ( } else if (
isPaidProductAvailableInCart?.OrderQty > item?.OrderQty isPaidProductAvailableInCart?.OrderQty > item?.OrderQty
@ -1440,6 +1445,7 @@ const BSBillingTable7 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1466,6 +1472,7 @@ const BSBillingTable7 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1792,6 +1799,7 @@ const BSBillingTable7 = () => {
CompleteRemove: true, CompleteRemove: true,
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
OrderRate: item?.OrderRate,
Offer: item?.Offer, Offer: item?.Offer,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
@ -1811,6 +1819,7 @@ const BSBillingTable7 = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: item?.OrderQty, OverAllFreeQty: item?.OrderQty,
@ -2178,8 +2187,7 @@ const BSBillingTable7 = () => {
} }
// onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""} // onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""}
className={`${ className={`${item?.SalesId && OrderType !== 'Hold'
item?.SalesId && OrderType !== 'Hold'
? 'BSBill-Table7-content-disabled' ? 'BSBill-Table7-content-disabled'
: 'BSBill-Table7-content' : 'BSBill-Table7-content'
} }
@ -2408,8 +2416,7 @@ const BSBillingTable7 = () => {
} }
// onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""} // onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""}
className={`${ className={`${item?.SalesId
item?.SalesId
? 'BSBill-Table7-content-disabled' ? 'BSBill-Table7-content-disabled'
: 'BSBill-Table7-content' : 'BSBill-Table7-content'
} }
@ -2677,8 +2684,7 @@ const BSBillingTable7 = () => {
} }
// onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""} // onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""}
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'BSBill-Table7-content-disabled' ? 'BSBill-Table7-content-disabled'
: 'BSBill-Table7-content' : 'BSBill-Table7-content'
} }
@ -2945,8 +2951,7 @@ const BSBillingTable7 = () => {
} }
// onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""} // onClick={editdelete === "Edit" ? () => handleEditQuantity(item) : editdelete === "Delete" ? () => removeFromCart(item) : ""}
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'BSBill-Table7-content-disabled' ? 'BSBill-Table7-content-disabled'
: 'BSBill-Table7-content' : 'BSBill-Table7-content'
} }

View File

@ -1349,6 +1349,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: isPaidproduct?.InwardDtlId, InwardDtlId: isPaidproduct?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
OrderRate:isPaidproduct?.OrderRate
}); });
} else if (isPaidproduct?.OrderQty > item?.OrderQty) { } else if (isPaidproduct?.OrderQty > item?.OrderQty) {
// Just Decrease Paid Qty // Just Decrease Paid Qty
@ -1520,6 +1521,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty, OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty,
@ -1598,6 +1600,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty, OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty,
@ -1631,6 +1634,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate:item?.OrderRate
}); });
await ChangeOfferAppliedProdsFn({ await ChangeOfferAppliedProdsFn({
inwardDtlId: item?.InwardDtlId, inwardDtlId: item?.InwardDtlId,
@ -1662,6 +1666,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId, InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
OrderRate:isPaidProductAvailableInCart?.OrderRate
}); });
} else if ( } else if (
isPaidProductAvailableInCart?.OrderQty > item?.OrderQty isPaidProductAvailableInCart?.OrderQty > item?.OrderQty
@ -1745,6 +1750,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1771,6 +1777,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -2107,6 +2114,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: FreeProd?.OverAllFreeQty - item?.OrderQty, OverAllFreeQty: FreeProd?.OverAllFreeQty - item?.OrderQty,
@ -2125,6 +2133,7 @@ const ComboSalesBillTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
Offer: item?.Offer, Offer: item?.Offer,
OrderRate: item?.OrderRate
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: item?.OrderQty, OverAllFreeQty: item?.OrderQty,
@ -2591,8 +2600,7 @@ const ComboSalesBillTable = () => {
}} }}
key={`qty-${index}`} key={`qty-${index}`}
tabIndex={0} tabIndex={0}
className={`${ className={`${EditQtyCombo && row?.localId === Index
EditQtyCombo && row?.localId === Index
? 'EditQTYcomboTD' ? 'EditQTYcomboTD'
: 'qtyTd' : 'qtyTd'
} ${isActiveCell ? 'active-cell' : ''}`} } ${isActiveCell ? 'active-cell' : ''}`}

View File

@ -1237,6 +1237,7 @@ const StandardTable = () => {
InwardDtlId: isPaidproduct?.InwardDtlId, InwardDtlId: isPaidproduct?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
localid: isPaidproduct?.localid
}); });
} else if (isPaidproduct?.OrderQty > item?.OrderQty) { } else if (isPaidproduct?.OrderQty > item?.OrderQty) {
// Just Decrease Paid Qty // Just Decrease Paid Qty
@ -1410,6 +1411,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localid
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty, OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty,
@ -1489,6 +1491,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localid
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty, OverAllFreeQty: isCheckFreeProduct?.OverAllFreeQty,
@ -1522,6 +1525,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localid,
}); });
await ChangeOfferAppliedProdsFn({ await ChangeOfferAppliedProdsFn({
inwardDtlId: item?.InwardDtlId, inwardDtlId: item?.InwardDtlId,
@ -1553,6 +1557,7 @@ const StandardTable = () => {
InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId, InwardDtlId: isPaidProductAvailableInCart?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: 0, Offer: 0,
localid: isPaidProductAvailableInCart?.localId,
}); });
} else if ( } else if (
isPaidProductAvailableInCart?.OrderQty > item?.OrderQty isPaidProductAvailableInCart?.OrderQty > item?.OrderQty
@ -1636,6 +1641,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localId,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1662,6 +1668,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: null, BuyInwardDtlId: null,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localId,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: freeProdList?.OverAllFreeQty, OverAllFreeQty: freeProdList?.OverAllFreeQty,
@ -1997,6 +2004,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localId,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: FreeProd?.OverAllFreeQty - item?.OrderQty, OverAllFreeQty: FreeProd?.OverAllFreeQty - item?.OrderQty,
@ -2015,6 +2023,7 @@ const StandardTable = () => {
InwardDtlId: item?.InwardDtlId, InwardDtlId: item?.InwardDtlId,
BuyInwardDtlId: item?.InwardDtlId, BuyInwardDtlId: item?.InwardDtlId,
Offer: item?.Offer, Offer: item?.Offer,
localid: item?.localId,
}); });
await ChangeFreeprodlistFn({ await ChangeFreeprodlistFn({
OverAllFreeQty: item?.OrderQty, OverAllFreeQty: item?.OrderQty,
@ -2379,8 +2388,7 @@ const StandardTable = () => {
{OldtableDataTakeAway?.map((item, index) => ( {OldtableDataTakeAway?.map((item, index) => (
<tr <tr
key={index} key={index}
className={`${ className={`${item?.SalesId && OrderType !== 'Hold'
item?.SalesId && OrderType !== 'Hold'
? 'booking-billing-table-row-disabled' ? 'booking-billing-table-row-disabled'
: 'booking-billing-table-row' : 'booking-billing-table-row'
}`} }`}
@ -2711,8 +2719,7 @@ const StandardTable = () => {
{OldtableDataDinein?.map((item, index) => ( {OldtableDataDinein?.map((item, index) => (
<tr <tr
key={OldtableDataTakeAway?.length + index} key={OldtableDataTakeAway?.length + index}
className={`${ className={`${item?.SalesId
item?.SalesId
? 'booking-billing-table-row-disabled' ? 'booking-billing-table-row-disabled'
: 'booking-billing-table-row' : 'booking-billing-table-row'
} }
@ -3041,8 +3048,7 @@ const StandardTable = () => {
OldtableDataTakeAway?.length + OldtableDataTakeAway?.length +
index index
} }
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'booking-billing-table-row-disabled' ? 'booking-billing-table-row-disabled'
: 'booking-billing-table-row' : 'booking-billing-table-row'
} }
@ -3419,8 +3425,7 @@ const StandardTable = () => {
tableDataTakeAway?.length + tableDataTakeAway?.length +
index index
} }
className={`${ className={`${BookingType === 'Dine In' && item?.SalesId
BookingType === 'Dine In' && item?.SalesId
? 'booking-billing-table-row-disabled' ? 'booking-billing-table-row-disabled'
: 'booking-billing-table-row' : 'booking-billing-table-row'
} }