Anonymous | Login
Project:
RSS
  
News | My View | View Issues | Roadmap | Summary

View Revisions: Issue #51848 Back to Issue ]
Summary 0051848: Js Error occurs on selecting discount in Gift Reminder Notification
Revision 2023-03-30 07:20 by prakashmurugesan88
Steps To Reproduce Configure Buy X Gift Y discount with 2 gift products with 1 gift product included in pricelist of the store and another not included in price list.

Now try to add the product so that Gift Reminder Notification is shown for the discount.

In following code it tries to fetch gift product details from db,
https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelection.jsx#L36 [^]

https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelection.jsx#L107 [^]

In given scenario though 2 gift products are configured but only one gift product is returned from BO

Therefore in following line it filters gift products based on gift product configuration and gift product info from BO,
https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelectionDialogContent/FeaturedDiscountProductSelectionDialogContent.jsx#L25 [^]

Here it iterates 2 items for both product in configuration as return productList as below,
productList = [{Object}, null]
Here for product info not received from db, it returns null.


Therefore in following line it throws error for the null product,
https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelectionDialogContent/FeaturedDiscountProductSelectionDialogContent.jsx#L32 [^]
Revision 2023-03-30 07:18 by prakashmurugesan88
Steps To Reproduce Configure Buy X Gift Y discount with 2 gift products with 1 gift product included in pricelist of the store and another not included in price list.

In following code it tries to fetch gift product details from db,
https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelection.jsx#L36 [^]

https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelection.jsx#L107 [^]

In given scenario though 2 gift products are configured but only one gift product is returned from BO

Therefore in following line it filters gift products based on gift product configuration and gift product info from BO,
https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelectionDialogContent/FeaturedDiscountProductSelectionDialogContent.jsx#L25 [^]

Here it iterates 2 items for both product in configuration as return productList as below,
productList = [{Object}, null]
Here for product info not received from db, it returns null.


Therefore in following line it throws error for the null product,
https://gitlab.com/openbravo/product/pmods/org.openbravo.pos2/-/blob/master/web-jspack/org.openbravo.pos2/src/components/Discounts/FeaturedDiscount/FeaturedDiscountProductSelection/FeaturedDiscountProductSelectionDialogContent/FeaturedDiscountProductSelectionDialogContent.jsx#L32 [^]
Revision 2023-03-14 11:02 by prakashmurugesan88
Steps To Reproduce Refer video:
https://drive.google.com/file/d/1M56eVmp_Awpcb3U5E2NTSET5n6YMnylF/view?usp=sharing [^]


Copyright © 2000 - 2009 MantisBT Group
Powered by Mantis Bugtracker