Page 1 of 1

Coupon available for all products

Posted: 12 Jan 2018, 09:00
by t_csaba
Hello again,
I am having trouble implementing a global discount coupon. I have read some similar posts, but the solution wasn't clear. I have tried creating a custom coupon provider, but as i can see it, all the existing coupon providers work in a way, that they add an existing product with a modified price to the basket.

If i have a basket with multiple product types and multiple quantities, how should i add a discount? I have tried to create a new product "$this->createProduct(...)" , but it seems that i need the code of an existing product; I get this message: "No product with code "" found".
Could you give some detailed description? I know it's not a hard thing to do, but I'm stuck.
Thank you.


typo3 8.7.7
php 7.0.16
Linux 2.6

Re: Coupon available for all products

Posted: 12 Jan 2018, 10:38
by aimeos
You have to create a coupon product like a regular product in the admin interface but don't assign it to any category. Thus, customers won't be able to add it to the basket. Then, use this product code to create a new discount and add it to the basket. You can use the code from the existing coupon providers for this.

Re: Coupon available for all products

Posted: 12 Jan 2018, 11:00
by t_csaba
Easy solution, thank you.