You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
addToWishlist and addToCart buttons should work the same way for all items, those loaded from the server and after the 'load more' click event.
Actual Behaviour
For items loaded after the 'load more' click event, the buttons are not configured with the appropriate handlers, and the user is redirected to the product details page.
Reproduce Scenario (including but not limited to)
Configure a category page with 'Load more' option enabled.
Steps to Reproduce
Open a category page with products.
Click on the addToCart, on any of the initial products loaded from the server side. The product is added to the cart.
Click on the 'Load more' button.
Click on the addToCart, on any of the products added to the list. The user is redirected to the product details page.
(repeat same steps for addToWishlist)
Platform and Version
Last AaaCS instance. CIF 2.12.2
Sample Code that illustrates the problem
No custom code involved.
Logs taken while reproducing problem
No logs in the browser developer tools
Additional notes
When the new items are appended to the galleryItems, no event handler is added to the addToWishlist and addToCart buttons. Please check ui.apps\src\main\content\jcr_root\apps\core\cif\components\commerce\productcollection\v2\productcollection\clientlibs\js\productcollection.js, line 139:
galleryItems.append(...moreItems);
The text was updated successfully, but these errors were encountered:
Expected Behaviour
addToWishlist and addToCart buttons should work the same way for all items, those loaded from the server and after the 'load more' click event.
Actual Behaviour
For items loaded after the 'load more' click event, the buttons are not configured with the appropriate handlers, and the user is redirected to the product details page.
Reproduce Scenario (including but not limited to)
Configure a category page with 'Load more' option enabled.
Steps to Reproduce
Open a category page with products.
Click on the addToCart, on any of the initial products loaded from the server side. The product is added to the cart.
Click on the 'Load more' button.
Click on the addToCart, on any of the products added to the list. The user is redirected to the product details page.
(repeat same steps for addToWishlist)
Platform and Version
Last AaaCS instance. CIF 2.12.2
Sample Code that illustrates the problem
No custom code involved.
Logs taken while reproducing problem
No logs in the browser developer tools
Additional notes
When the new items are appended to the galleryItems, no event handler is added to the addToWishlist and addToCart buttons. Please check ui.apps\src\main\content\jcr_root\apps\core\cif\components\commerce\productcollection\v2\productcollection\clientlibs\js\productcollection.js, line 139:
galleryItems.append(...moreItems);
The text was updated successfully, but these errors were encountered: