DiegolPerez Posted March 19, 2020 Share Posted March 19, 2020 Hi community, I'm working with prestashop 1.7.6 with classic theme. I'm working in processChangeProductInCart() function of CartController.php, for my own functionality but the errors notifications of this controller not show in my store, for example this error of availability of product: if ('update' !== $mode && $this->shouldAvailabilityErrorBeRaised($product, $qty_to_check)) { $this->{$ErrorKey}[] = $this->trans( 'The item %product% in your cart is no longer available in this quantity. You cannot proceed with your order until the quantity is adjusted.', array('%product%' => $product->name), 'Shop.Notifications.Error' ); } In debug mode of Firefox in JSON response I get it: {"JSON" :{"hasError":true,"errors":["The item Mug the best in your cart is no longer available in this quantity. You cannot proceed with your order until the quantity is adjusted."],"quantity":5000} } but not show error notification in store, how do I show this errors in my store? or its a bug? Link to comment Share on other sites More sharing options...
Jonathan Elias Posted July 31, 2020 Share Posted July 31, 2020 I have the same problem : no popup when an error occurs while adding a product to the cart... Can anyone help with this ? Link to comment Share on other sites More sharing options...
Dhara1510 Posted October 26, 2020 Share Posted October 26, 2020 I have same issue. Can please anyone tell me how to show error messages when product added to the cart. Link to comment Share on other sites More sharing options...
Akaru Posted November 20, 2020 Share Posted November 20, 2020 Catch error byself: prestashop.on('updateCart',function(e) { console.log(e); //resp.errors }); Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now