FIX #57 Print header color issue Integration
This commit is contained in:
parent
3676a3f41d
commit
b2b86477ca
|
|
@ -470,6 +470,7 @@ const initialState = {
|
|||
notes: false,
|
||||
SignatureImage: '',
|
||||
BillName: '',
|
||||
SelectedHeaderColor: '#000000',
|
||||
allColors: [],
|
||||
allColorsCat: [],
|
||||
LayoutOverallColorsList: [],
|
||||
|
|
@ -2146,6 +2147,9 @@ const ThemeSlice = createSlice({
|
|||
changeBillName: (state, action) => {
|
||||
state.BillName = action?.payload;
|
||||
},
|
||||
changeSelectedHeaderColor: (state, action) => {
|
||||
state.SelectedHeaderColor = action?.payload;
|
||||
},
|
||||
changeCurrentColor: (state, action) => {
|
||||
const { color } = action?.payload;
|
||||
state.CurrentColor = color;
|
||||
|
|
@ -2690,6 +2694,7 @@ export const {
|
|||
changeOthersTheme,
|
||||
changeActiveTheme,
|
||||
changeScanTemplate,
|
||||
changeSelectedHeaderColor,
|
||||
} = ThemeSlice.actions;
|
||||
|
||||
export const GlobalPricingAppPricingName = (state) =>
|
||||
|
|
@ -2720,6 +2725,8 @@ export const GlobalthemeFormat = (state) => state.theme?.themeFormat;
|
|||
export const Globalnotes = (state) => state.theme?.notes;
|
||||
export const GlobalSignatureImage = (state) => state.theme?.SignatureImage;
|
||||
export const GlobalBillName = (state) => state.theme?.BillName;
|
||||
export const GlobalSelectedPrintHeaderColor = (state) =>
|
||||
state.theme?.SelectedHeaderColor;
|
||||
|
||||
export const changeCurrentColorValue = (state) => state.theme?.CurrentColor;
|
||||
export const changeCurrentTextValue = (state) => state.theme?.CurrentText;
|
||||
|
|
|
|||
|
|
@ -87,11 +87,13 @@ const BSBillingEditQuantity = (props) => {
|
|||
);
|
||||
const ReorderProductData = useSelector(GlobalReorderProductDetails);
|
||||
const templateData = useSelector(getTemplateData);
|
||||
const OfferCheckedInSetup = templateData?.BookingNavbar?.[1].some(
|
||||
(item) => item?.OptionName == 'Offer'
|
||||
) || (templateData?.BookingCombo1?.[1]?.some(
|
||||
(item) => item?.OptionName == 'Offer'
|
||||
));
|
||||
const OfferCheckedInSetup =
|
||||
templateData?.BookingNavbar?.[1].some(
|
||||
(item) => item?.OptionName == 'Offer'
|
||||
) ||
|
||||
templateData?.BookingCombo1?.[1]?.some(
|
||||
(item) => item?.OptionName == 'Offer'
|
||||
);
|
||||
const [ClearQuantity, setClearQuantity] = useState(false);
|
||||
const CartOrderDetails = useSelector(GlobalOrderCardDetails);
|
||||
const SettingDataSelector = useSelector(PreferenceData);
|
||||
|
|
@ -704,7 +706,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
return (
|
||||
cartItem?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
cartItem?.OfferMessage?.[0]?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
cartItem?.OfferMode === editedProduct?.OfferMode &&
|
||||
cartItem?.BookingTypeName !== editedProduct?.BookingTypeName
|
||||
);
|
||||
|
|
@ -838,7 +840,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
cartItem?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
cartItem?.OrderRate === editedProduct?.OrderRate &&
|
||||
cartItem?.BookingTypeName !==
|
||||
editedProduct?.BookingTypeName &&
|
||||
editedProduct?.BookingTypeName &&
|
||||
!cartItem?.OfferMode &&
|
||||
cartItem?.Offer === 0
|
||||
);
|
||||
|
|
@ -852,7 +854,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
cartItem?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
cartItem?.OrderRate === editedProduct?.OrderRate &&
|
||||
cartItem?.BookingTypeName !==
|
||||
editedProduct?.BookingTypeName &&
|
||||
editedProduct?.BookingTypeName &&
|
||||
cartItem?.OfferMode === editedProduct?.OfferMode &&
|
||||
cartItem?.Offer > 0
|
||||
);
|
||||
|
|
@ -985,7 +987,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
)
|
||||
) &&
|
||||
product?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
product?.OfferMode === editedProduct?.OfferMode
|
||||
) {
|
||||
const freeQty =
|
||||
|
|
@ -1018,7 +1020,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
offerProduct?.OfferMode === editedProduct?.OfferMode;
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
|
|
@ -1101,7 +1103,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
)
|
||||
) &&
|
||||
product?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
product?.OfferMode === editedProduct?.OfferMode
|
||||
) {
|
||||
return {
|
||||
|
|
@ -1131,7 +1133,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
offerProduct?.OfferMode === editedProduct?.OfferMode;
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
|
|
@ -1318,7 +1320,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
offerProduct?.OfferMode === editedProduct?.OfferMode;
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
|
|
@ -1420,7 +1422,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
editedProduct?.OfferMessage?.[0]?.OfferId &&
|
||||
offerProduct?.OfferMode === editedProduct?.OfferMode;
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
|
|
@ -1574,7 +1576,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
) &&
|
||||
cartItem?.Offer &&
|
||||
isFreeProductApplicable?.OfferId ===
|
||||
cartItem?.OfferMessage?.[0]?.OfferId
|
||||
cartItem?.OfferMessage?.[0]?.OfferId
|
||||
);
|
||||
}
|
||||
);
|
||||
|
|
@ -1863,11 +1865,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
product?.ProdId === editedProduct?.ProdId &&
|
||||
product?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
product?.OfferId ===
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]?.OfferId) &&
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]?.OfferId) &&
|
||||
product?.OfferMode ===
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode)
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode)
|
||||
) {
|
||||
return {
|
||||
...product,
|
||||
|
|
@ -1901,11 +1903,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]?.OfferId) &&
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]?.OfferId) &&
|
||||
offerProduct?.OfferMode ===
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode);
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode);
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
// Get loyalty points from the matching free product
|
||||
|
|
@ -2046,7 +2048,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
cartItem?.Offer > 0 &&
|
||||
isFreeProductApplicable?.OfferMode === cartItem?.OfferMode &&
|
||||
isFreeProductApplicable?.OfferId ===
|
||||
cartItem?.OfferMessage?.[0]?.OfferId
|
||||
cartItem?.OfferMessage?.[0]?.OfferId
|
||||
);
|
||||
}
|
||||
);
|
||||
|
|
@ -2149,11 +2151,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === otherBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2224,12 +2226,12 @@ const BSBillingEditQuantity = (props) => {
|
|||
product?.ProdId === editedProduct?.ProdId &&
|
||||
product?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
product?.OfferId ===
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
product?.OfferMode ===
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode)
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode)
|
||||
) {
|
||||
return {
|
||||
...product,
|
||||
|
|
@ -2263,13 +2265,13 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
offerProduct?.OfferMode ===
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode);
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode);
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
// Get loyalty points from the matching free product
|
||||
|
|
@ -2351,11 +2353,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === sameBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
sameBookingTypeProduct.InwardDtlId &&
|
||||
sameBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
sameBookingTypeProduct.BookingTypeName &&
|
||||
sameBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
sameBookingTypeProduct.OrderRate &&
|
||||
sameBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2408,11 +2410,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === sameBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
sameBookingTypeProduct.InwardDtlId &&
|
||||
sameBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
sameBookingTypeProduct.BookingTypeName &&
|
||||
sameBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
sameBookingTypeProduct.OrderRate &&
|
||||
sameBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2501,11 +2503,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === otherBookingTypeProduct.ProdId &&
|
||||
cartItem?.InwardDtlId ===
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
cartItem?.BookingTypeName ===
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
cartItem?.OrderRate ===
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
cartItem?.OfferMode &&
|
||||
cartItem?.Offer > 0
|
||||
) {
|
||||
|
|
@ -2534,11 +2536,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === otherBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2568,11 +2570,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === otherBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2671,12 +2673,12 @@ const BSBillingEditQuantity = (props) => {
|
|||
product?.ProdId === editedProduct?.ProdId &&
|
||||
product?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
product?.OfferId ===
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
product?.OfferMode ===
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode)
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode)
|
||||
) {
|
||||
return {
|
||||
...product,
|
||||
|
|
@ -2710,12 +2712,12 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
offerProduct?.OfferMode ===
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode);
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode);
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
// Get loyalty points from the matching free product
|
||||
|
|
@ -2794,11 +2796,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === sameBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
sameBookingTypeProduct.InwardDtlId &&
|
||||
sameBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
sameBookingTypeProduct.BookingTypeName &&
|
||||
sameBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
sameBookingTypeProduct.OrderRate &&
|
||||
sameBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2857,11 +2859,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
if (
|
||||
cartItem.ProdId === otherBookingTypeProduct.ProdId &&
|
||||
cartItem.InwardDtlId ===
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
otherBookingTypeProduct.InwardDtlId &&
|
||||
cartItem.BookingTypeName ===
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
otherBookingTypeProduct.BookingTypeName &&
|
||||
cartItem.OrderRate ===
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
otherBookingTypeProduct.OrderRate &&
|
||||
cartItem.OfferMode &&
|
||||
cartItem.Offer > 0
|
||||
) {
|
||||
|
|
@ -2933,12 +2935,12 @@ const BSBillingEditQuantity = (props) => {
|
|||
product?.ProdId === editedProduct?.ProdId &&
|
||||
product?.InwardDtlId === editedProduct?.InwardDtlId &&
|
||||
product?.OfferId ===
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
(sameBookingTypeFreeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeFreeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
product?.OfferMode ===
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode)
|
||||
(sameBookingTypeFreeProduct?.OfferMode ||
|
||||
otherBookingTypeFreeProduct?.OfferMode)
|
||||
) {
|
||||
return {
|
||||
...product,
|
||||
|
|
@ -2972,12 +2974,12 @@ const BSBillingEditQuantity = (props) => {
|
|||
// Also check main offer conditions
|
||||
const isMatchingOffer =
|
||||
offerProduct?.OfferId ===
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
(sameBookingTypeProduct?.OfferMessage?.[0]?.OfferId ||
|
||||
otherBookingTypeProduct?.OfferMessage?.[0]
|
||||
?.OfferId) &&
|
||||
offerProduct?.OfferMode ===
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode);
|
||||
(sameBookingTypeProduct?.OfferMode ||
|
||||
otherBookingTypeProduct?.OfferMode);
|
||||
|
||||
if (hasMatchingFreeProduct && isMatchingOffer) {
|
||||
// Get loyalty points from the matching free product
|
||||
|
|
@ -3131,17 +3133,17 @@ const BSBillingEditQuantity = (props) => {
|
|||
changeOrderCardDetails(
|
||||
CartOrderDetails?.map((i) =>
|
||||
i?.InwardDtlId == updatedProduct?.InwardDtlId &&
|
||||
i?.BookingTypeName == updatedProduct?.BookingTypeName &&
|
||||
i?.localId === updatedProduct?.localId
|
||||
i?.BookingTypeName == updatedProduct?.BookingTypeName &&
|
||||
i?.localId === updatedProduct?.localId
|
||||
? {
|
||||
...updatedProduct,
|
||||
Offer: 0,
|
||||
OfferType:
|
||||
updatedProduct?.Type === 'C'
|
||||
? updatedProduct?.OfferType
|
||||
: null,
|
||||
OfferMessage: null,
|
||||
}
|
||||
...updatedProduct,
|
||||
Offer: 0,
|
||||
OfferType:
|
||||
updatedProduct?.Type === 'C'
|
||||
? updatedProduct?.OfferType
|
||||
: null,
|
||||
OfferMessage: null,
|
||||
}
|
||||
: i
|
||||
)
|
||||
)
|
||||
|
|
@ -3158,9 +3160,10 @@ const BSBillingEditQuantity = (props) => {
|
|||
|
||||
const UpdatedCartItemWithOffer = {
|
||||
...updatedProduct,
|
||||
Offer: (bestOffer?.OfferMode === 'I' || bestOffer?.OfferMode === 'Q') ?
|
||||
bestOffer?.OfferAmount || updatedProduct.Offer :
|
||||
updatedProduct.Offer || bestOffer?.OfferAmount,
|
||||
Offer:
|
||||
bestOffer?.OfferMode === 'I' || bestOffer?.OfferMode === 'Q'
|
||||
? bestOffer?.OfferAmount || updatedProduct.Offer
|
||||
: updatedProduct.Offer || bestOffer?.OfferAmount,
|
||||
OfferType: updatedProduct?.OfferType || bestOffer?.OfferType,
|
||||
OfferMessage: updatedProduct?.OfferMessage || bestOffer?.OfferMessage,
|
||||
};
|
||||
|
|
@ -3175,10 +3178,11 @@ const BSBillingEditQuantity = (props) => {
|
|||
!c.SalesId &&
|
||||
((c?.OfferModeType && c?.OfferMode === 'B'
|
||||
? true
|
||||
: c?.OfferMode !== 'B')
|
||||
&& c?.OfferMode !== 'P'
|
||||
&& c?.OfferMode !== 'C' && c?.OfferMode !== 'O'
|
||||
&& c?.OfferMode !== 'L'
|
||||
: c?.OfferMode !== 'B') &&
|
||||
c?.OfferMode !== 'P' &&
|
||||
c?.OfferMode !== 'C' &&
|
||||
c?.OfferMode !== 'O' &&
|
||||
c?.OfferMode !== 'L'
|
||||
? true
|
||||
: c?.Offer === 0);
|
||||
|
||||
|
|
@ -3708,9 +3712,10 @@ const BSBillingEditQuantity = (props) => {
|
|||
/>
|
||||
<DefaultModal
|
||||
title={
|
||||
<div className="EditQuantity-title">
|
||||
<FormHeader title={'Change'} />
|
||||
</div>
|
||||
'Change'
|
||||
// <div className="EditQuantity-title">
|
||||
// <FormHeader title={'Change'} />
|
||||
// </div>
|
||||
}
|
||||
open={EditOpen}
|
||||
width={600}
|
||||
|
|
@ -3817,38 +3822,38 @@ const BSBillingEditQuantity = (props) => {
|
|||
✖
|
||||
</button>
|
||||
</div>
|
||||
<div className="grid-container">
|
||||
<div className="grid-item" onClick={() => AddQuantity(1)}>
|
||||
<div className="gridEQcontainer">
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(1)}>
|
||||
1
|
||||
</div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(2)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(2)}>
|
||||
2
|
||||
</div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(3)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(3)}>
|
||||
3
|
||||
</div>
|
||||
|
||||
<div className="grid-item" onClick={() => AddQuantity(4)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(4)}>
|
||||
4
|
||||
</div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(5)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(5)}>
|
||||
5
|
||||
</div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(6)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(6)}>
|
||||
6
|
||||
</div>
|
||||
|
||||
<div className="grid-item" onClick={() => AddQuantity(7)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(7)}>
|
||||
7
|
||||
</div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(8)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(8)}>
|
||||
8
|
||||
</div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(9)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(9)}>
|
||||
9
|
||||
</div>
|
||||
<div></div>
|
||||
<div className="grid-item" onClick={() => AddQuantity(0)}>
|
||||
<div className="gridEQitem" onClick={() => AddQuantity(0)}>
|
||||
0
|
||||
</div>
|
||||
<div></div>
|
||||
|
|
@ -3903,7 +3908,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
? `${parts[0]}.${parts.slice(1).join('')}`
|
||||
: cleanedValue;
|
||||
}}
|
||||
// isOnChange={formType == "edit" || formRef.current?.getFieldsValue()?.CustName ? true : false}
|
||||
// isOnChange={formType == "edit" || formRef.current?.getFieldsValue()?.CustName ? true : false}
|
||||
/>
|
||||
</Form.Item>
|
||||
)}
|
||||
|
|
@ -3966,7 +3971,7 @@ const BSBillingEditQuantity = (props) => {
|
|||
? `${parts[0]}.${parts.slice(1).join('')}`
|
||||
: cleanedValue;
|
||||
}}
|
||||
// isOnChange={formType == "edit" || formRef.current?.getFieldsValue()?.CustName ? true : false}
|
||||
// isOnChange={formType == "edit" || formRef.current?.getFieldsValue()?.CustName ? true : false}
|
||||
/>
|
||||
</Form.Item>
|
||||
{/* <input type="text"
|
||||
|
|
@ -4002,14 +4007,14 @@ const BSBillingEditQuantity = (props) => {
|
|||
<div style={{ display: 'flex', justifyContent: 'flex-end' }}>
|
||||
{((RadioBtnSelection == 'Price' && disableSubmitButton) ||
|
||||
RadioBtnSelection == 'Quantity') && (
|
||||
<Buttons
|
||||
buttonText="Submit"
|
||||
color="901D77"
|
||||
htmlType
|
||||
// handleSubmit={AddProductQuantity}
|
||||
icon={<ArrowRightOutlined />}
|
||||
></Buttons>
|
||||
)}
|
||||
<Buttons
|
||||
buttonText="Submit"
|
||||
color="901D77"
|
||||
htmlType
|
||||
// handleSubmit={AddProductQuantity}
|
||||
icon={<ArrowRightOutlined />}
|
||||
></Buttons>
|
||||
)}
|
||||
</div>
|
||||
</Form>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -68,6 +68,7 @@ import {
|
|||
changeSelectedLogo,
|
||||
changeSelectedCredit,
|
||||
changeSelectedTax,
|
||||
changeSelectedHeaderColor,
|
||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||
import '../../../../Styles/BookingScreen/Components/SelectionComponent/SelectionComponent.scss';
|
||||
import { useAuth } from '../../../../AuthContext.jsx';
|
||||
|
|
@ -732,6 +733,13 @@ const SelectionComponent = forwardRef((props, ref) => {
|
|||
)
|
||||
? dispatch(changeNotes(true))
|
||||
: dispatch(changeNotes(false));
|
||||
|
||||
checkedValues?.includes(
|
||||
sizeCheckList.find((item) => item.ConfigName === 'Header Colour')
|
||||
?.ConfigId
|
||||
)
|
||||
? setisheadercolour(true)
|
||||
: setisheadercolour(false);
|
||||
};
|
||||
|
||||
const handleOptions = async () => {
|
||||
|
|
@ -1278,12 +1286,7 @@ const SelectionComponent = forwardRef((props, ref) => {
|
|||
>
|
||||
<Row>
|
||||
{sizeCheckList
|
||||
?.filter(
|
||||
(item) =>
|
||||
item.ConfigName &&
|
||||
(SelectedStyleName == 'TaxInvoice' ||
|
||||
item.ConfigName != 'Header Colour')
|
||||
)
|
||||
?.filter((item) => item.ConfigName)
|
||||
?.map((value, key) => (
|
||||
<Checkbox
|
||||
style={{ padding: '12px' }}
|
||||
|
|
@ -1383,14 +1386,18 @@ const SelectionComponent = forwardRef((props, ref) => {
|
|||
</Modal>
|
||||
</div>
|
||||
)}
|
||||
{isheadercolour && SelectedStyleName == 'TaxInvoice' && (
|
||||
{isheadercolour && (
|
||||
// {isheadercolour && SelectedStyleName == 'TaxInvoice' && (
|
||||
<div style={{ marginTop: '1rem' }}>
|
||||
<Title level={5} style={{ marginBottom: 12 }}>
|
||||
Header Color
|
||||
</Title>
|
||||
<ColorPicker
|
||||
value={selectedColour}
|
||||
onChange={setSelectedColour}
|
||||
onChange={(color) => {
|
||||
setSelectedColour(color);
|
||||
dispatch(changeSelectedHeaderColor(color));
|
||||
}}
|
||||
placeholder="Select color"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
import React, { useState } from 'react';
|
||||
import { Modal, List, Typography, Tooltip } from 'antd';
|
||||
import { List, Typography, Tooltip } from 'antd';
|
||||
import { FaKeyboard } from 'react-icons/fa';
|
||||
import { DefaultModal } from '../../../../Components/Modal/DefaultModal';
|
||||
|
||||
const { Title, Text } = Typography;
|
||||
|
||||
|
|
@ -40,15 +41,15 @@ const ShortcutKeyHelper = ({}) => {
|
|||
</div>
|
||||
</Tooltip>
|
||||
|
||||
<Modal
|
||||
<DefaultModal
|
||||
title={
|
||||
<div style={{ display: 'flex', alignItems: 'center', gap: '8px' }}>
|
||||
<FaKeyboard />
|
||||
<Title level={4} style={{ margin: 0 }}>Keyboard Shortcuts</Title>
|
||||
Keyboard Shortcuts
|
||||
</div>
|
||||
}
|
||||
open={isModalOpen}
|
||||
onCancel={() => setIsModalOpen(false)}
|
||||
handleCancel={() => setIsModalOpen(false)}
|
||||
footer={null}
|
||||
width={500}
|
||||
>
|
||||
|
|
@ -65,7 +66,7 @@ const ShortcutKeyHelper = ({}) => {
|
|||
</List.Item>
|
||||
)}
|
||||
/>
|
||||
</Modal>
|
||||
</DefaultModal>
|
||||
</>
|
||||
);
|
||||
};
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -30,6 +30,7 @@ import {
|
|||
GlobalprintLogo,
|
||||
GlobalprintCredit,
|
||||
GlobalprintTax,
|
||||
GlobalSelectedPrintHeaderColor,
|
||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||
import '../../../../Styles/BookingScreen/PrintTemplates/ThermalPrinter/PrintStyle1.scss';
|
||||
import QRCode from 'react-qr-code';
|
||||
|
|
@ -95,6 +96,7 @@ const PrintStyle1 = ({
|
|||
const GlobalCashierName = useSelector(GlobalprintCashierName);
|
||||
const GlobalLogo = useSelector(GlobalprintLogo);
|
||||
const GlobalCredit = useSelector(GlobalprintCredit);
|
||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||
|
||||
const GlobaltermsAndConditions = useSelector(GlobalprinttermsAndConditions);
|
||||
const GlobalSignatureImages = useSelector(GlobalSignatureImage);
|
||||
|
|
@ -225,9 +227,12 @@ const PrintStyle1 = ({
|
|||
}
|
||||
});
|
||||
const hasMappedOffer = offers.some((offer) =>
|
||||
['ItemWiseOffers', 'BundleOffers', 'QuantityWiseOffers', 'MemberShip'].includes(
|
||||
offer.TableName
|
||||
)
|
||||
[
|
||||
'ItemWiseOffers',
|
||||
'BundleOffers',
|
||||
'QuantityWiseOffers',
|
||||
'MemberShip',
|
||||
].includes(offer.TableName)
|
||||
);
|
||||
|
||||
if (hasMappedOffer) {
|
||||
|
|
@ -436,6 +441,7 @@ const PrintStyle1 = ({
|
|||
style={{
|
||||
fontSize: 'clamp(2rem, 2.5vw, 2rem)',
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{' '}
|
||||
|
|
@ -3562,6 +3568,7 @@ const PrintStyle1 = ({
|
|||
style={{
|
||||
fontSize: 'clamp(2rem, 2.5vw, 2rem)',
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{' '}
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@ import {
|
|||
GlobalprintLogo,
|
||||
GlobalprintCredit,
|
||||
GlobalprintTax,
|
||||
GlobalSelectedPrintHeaderColor,
|
||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||
import {
|
||||
GlobalUpiIDprint,
|
||||
|
|
@ -121,6 +122,7 @@ const PrintStyle10 = ({
|
|||
const paymentTypeUPI = PaymentStatus?.find(
|
||||
(ps) => ps.PaymentTypeName === 'UPI'
|
||||
);
|
||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||
|
||||
let TermsAndConditions = printDatas?.TermsandConditions;
|
||||
let SignatureImg = printDatas?.Signature;
|
||||
|
|
@ -407,7 +409,13 @@ const PrintStyle10 = ({
|
|||
</div>
|
||||
|
||||
<div className="Address" style={{ fontWeight: '600' }}>
|
||||
<div className="ShopName" style={{ fontWeight: '600' }}>
|
||||
<div
|
||||
className="ShopName"
|
||||
style={{
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{GlobaldummyData
|
||||
? 'ABC Shop'
|
||||
: table2Data?.BrName}{' '}
|
||||
|
|
@ -2926,7 +2934,10 @@ const PrintStyle10 = ({
|
|||
</div>
|
||||
|
||||
<div className="Address" style={{ fontWeight: '600' }}>
|
||||
<div className="ShopName" style={{ fontWeight: '600' }}>
|
||||
<div
|
||||
className="ShopName"
|
||||
style={{ fontWeight: '600', color: SelectedHeaderColor }}
|
||||
>
|
||||
{GlobaldummyData ? 'ABC Shop' : table2Data?.BrName}{' '}
|
||||
</div>
|
||||
{GlobaldummyData
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -28,6 +28,7 @@ import {
|
|||
GlobalprintLogo,
|
||||
GlobalprintCredit,
|
||||
GlobalprintTax,
|
||||
GlobalSelectedPrintHeaderColor,
|
||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||
import Logo from '../../../../Images/Logo.jpg';
|
||||
import QRCode from 'react-qr-code';
|
||||
|
|
@ -93,6 +94,7 @@ const Printstyle2 = ({
|
|||
const paymentTypeUPI = PaymentStatus?.find(
|
||||
(ps) => ps.PaymentTypeName === 'UPI'
|
||||
);
|
||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||
console.log(Qrcodet, 'Qrcodet', paymentTypeUPI);
|
||||
const GlobalSignature = useSelector(GlobalprintSignature);
|
||||
const GlobaltermsAndConditions = useSelector(GlobalprinttermsAndConditions);
|
||||
|
|
@ -399,7 +401,13 @@ const Printstyle2 = ({
|
|||
fontWeight: '600',
|
||||
}}
|
||||
>
|
||||
<div style={{ fontSize: '18px', fontWeight: '600' }}>
|
||||
<div
|
||||
style={{
|
||||
fontSize: '18px',
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}
|
||||
</div>
|
||||
|
||||
|
|
@ -2937,7 +2945,13 @@ const Printstyle2 = ({
|
|||
fontWeight: '600',
|
||||
}}
|
||||
>
|
||||
<div style={{ fontSize: '18px', fontWeight: '600' }}>
|
||||
<div
|
||||
style={{
|
||||
fontSize: '18px',
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}
|
||||
</div>
|
||||
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -28,9 +28,13 @@ import {
|
|||
GlobalprintLogo,
|
||||
GlobalprintCredit,
|
||||
GlobalprintTax,
|
||||
GlobalSelectedPrintHeaderColor,
|
||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||
import '../../../../Styles/BookingScreen/PrintTemplates/ThermalPrinter/PrintStyle4.scss';
|
||||
import { GlobalUpiIDprint, PreferenceData } from '../../../../Features/BookingScreen/BookingData/BookingData';
|
||||
import {
|
||||
GlobalUpiIDprint,
|
||||
PreferenceData,
|
||||
} from '../../../../Features/BookingScreen/BookingData/BookingData';
|
||||
import QRCode from 'react-qr-code';
|
||||
import signature from '../../../../Images/signatureimage.jpg';
|
||||
import { ApplicationPreferences } from '../../../../Features/BrachLogin/BranchLogin';
|
||||
|
|
@ -131,6 +135,7 @@ const Printstyle4 = ({
|
|||
const paymentTypeUPI = PaymentStatus?.find(
|
||||
(ps) => ps.PaymentTypeName === 'UPI'
|
||||
);
|
||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||
|
||||
console.log(GlobalDiscount, Discount, 'Discount');
|
||||
|
||||
|
|
@ -244,7 +249,7 @@ const Printstyle4 = ({
|
|||
TotalAmt: 176,
|
||||
discount: 0,
|
||||
HSN: '01',
|
||||
},
|
||||
},
|
||||
{
|
||||
ProdName: 'ITEM 2',
|
||||
Rate: 300.0,
|
||||
|
|
@ -253,7 +258,7 @@ const Printstyle4 = ({
|
|||
TotalAmt: 300,
|
||||
discount: 0,
|
||||
HSN: '02',
|
||||
},
|
||||
},
|
||||
{
|
||||
ProdName: 'ITEM 3',
|
||||
Rate: 200.0,
|
||||
|
|
@ -412,6 +417,7 @@ const Printstyle4 = ({
|
|||
fontWeight: '600',
|
||||
width: '100%',
|
||||
textAlign: 'center',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}{' '}
|
||||
|
|
@ -559,7 +565,7 @@ const Printstyle4 = ({
|
|||
textAlign: 'right',
|
||||
}}
|
||||
>
|
||||
{WeightasKg ?'Qty/Kg' :'Qty'}
|
||||
{WeightasKg ? 'Qty/Kg' : 'Qty'}
|
||||
</th>
|
||||
)}
|
||||
{GlobaldummyData
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@ import {
|
|||
GlobalprintLogo,
|
||||
GlobalprintCredit,
|
||||
GlobalprintTax,
|
||||
GlobalSelectedPrintHeaderColor,
|
||||
} from '../../../../Features/ThemeChange/ThemeChange';
|
||||
import {
|
||||
GlobalUpiIDprint,
|
||||
|
|
@ -124,6 +125,8 @@ const PrintStyle5 = ({
|
|||
(ps) => ps.PaymentTypeName === 'UPI'
|
||||
);
|
||||
|
||||
const SelectedHeaderColor = useSelector(GlobalSelectedPrintHeaderColor);
|
||||
|
||||
console.log(GlobalDiscount, Discount, 'Discount');
|
||||
|
||||
let TermsAndConditions = printDatas?.TermsandConditions;
|
||||
|
|
@ -383,6 +386,7 @@ const PrintStyle5 = ({
|
|||
style={{
|
||||
fontSize: 'clamp(2rem, 2.5vw, 2rem)',
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}
|
||||
|
|
@ -2595,6 +2599,7 @@ const PrintStyle5 = ({
|
|||
style={{
|
||||
fontSize: 'clamp(2rem, 2.5vw, 2rem)',
|
||||
fontWeight: '600',
|
||||
color: SelectedHeaderColor,
|
||||
}}
|
||||
>
|
||||
{GlobaldummyData ? 'XYZ Shop' : table2Data?.BrName}
|
||||
|
|
|
|||
Loading…
Reference in New Issue