When we apply discount coupon code at cart even though valid products are not present cart , but message shows coupon code applied
jithendraprasad9999 opened this issue · 3 comments
jithendraprasad9999 commented
In cart we have discount box where we add coupon codes, if we apply some random coupon codes which are not expired , we will get a message saying coupon code applied, This message leads lot of confusion to customer
KrzysztofPajak commented
Hi @jithendraprasad9999 Could you explain what does it means:
"if we apply some random coupon codes"
Is there possible to reproduce on the demo ?
jithendraprasad9999 commented
@KrzysztofPajak , Yes we can reproduce.
- Create a new discount with discount applied to products and pick few products in applied product list.
- Enable require coupon code bool and add coupon code say "testsale"
- Leave the requirements section untouched.
- Now you can choose any products which are not configured for the discount and add them to cart
- We can apply "testsale" coupon code to the cart and then will get a alert saying coupon code applied but discount will not get deducted
This leading a confusion to us
KrzysztofPajak commented
@jithendraprasad9999, we have decided to leave this feature open for customization by the customer. You can create a new validator for the DiscountCouponModel
and implement your own validation logic based on the contents of the cart.