Coupon related to a product?

Questions around the TYPO3 integration and plugins
Forum rules
Always add your TYPO3, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Stefan80
Posts: 42
Joined: 27 Nov 2017, 09:57

Coupon related to a product?

Post by Stefan80 » 12 Mar 2018, 11:42

Hello,

I want to use the coupons-option , but where can I link a product to coupon-code?

And: every coupon-code should be only used once by a Account/email - which code I use?

Thank you

User avatar
aimeos
Administrator
Posts: 7836
Joined: 01 Jan 1970, 00:00

Re: Coupon related to a product?

Post by aimeos » 13 Mar 2018, 13:01

There are two decorators you can apply to a coupon provider in the admin panel ("+" symbol in detail view):

Require a specific product:
https://github.com/aimeos/aimeos-core/b ... quired.php

Allow coupon once per customer e-mail:
https://github.com/aimeos/aimeos-core/b ... r/Once.php
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Stefan80
Posts: 42
Joined: 27 Nov 2017, 09:57

Re: Coupon related to a product?

Post by Stefan80 » 14 Mar 2018, 10:29

Thanks,

but is there no interface-option in the Aimeos-backend to link a product to a coupon-key?

User avatar
aimeos
Administrator
Posts: 7836
Joined: 01 Jan 1970, 00:00

Re: Coupon related to a product?

Post by aimeos » 14 Mar 2018, 10:52

The "Required" decorator allows you to specify a product that must be in the basket of the customer so the coupon is valid: https://aimeos.org/docs/User_Manual/Adm ... s#Required

The other way round (configure in the product panel that this product belongs to a coupon) isn't possible.

Does this answer your question or is there a misunderstanding? What do you want to achieve?
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Stefan80
Posts: 42
Joined: 27 Nov 2017, 09:57

Re: Coupon related to a product?

Post by Stefan80 » 14 Mar 2018, 10:58

Yes, i can use required.productcode, but I have so much products to insert manually ... there is no code for alle products?

for example: required.productcode = all ?

User avatar
aimeos
Administrator
Posts: 7836
Joined: 01 Jan 1970, 00:00

Re: Coupon related to a product?

Post by aimeos » 14 Mar 2018, 11:19

It's not necessary to configure that at least one product is necessary. This is the default.
You can configure a minium basket value if you want: https://aimeos.org/docs/User_Manual/Adm ... sketValues
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Stefan80
Posts: 42
Joined: 27 Nov 2017, 09:57

Re: Coupon related to a product?

Post by Stefan80 » 14 Mar 2018, 12:16

When I use for example the demo Coupon ( "demo-rebate" ,see image 2) I get the error "No product with code "demo-rebate" found" (see image 1).
Attachments
percent2.png
percent2.png (41.29 KiB) Viewed 3929 times
percent1.png
percent1.png (24.51 KiB) Viewed 3929 times

User avatar
aimeos
Administrator
Posts: 7836
Joined: 01 Jan 1970, 00:00

Re: Coupon related to a product?

Post by aimeos » 14 Mar 2018, 19:39

The FixedRebate and PercentRebate coupon providers need a product that will be added to the basket when the coupon is applied. This product will then show up in the basket and a negative price is added to that product in the basket by the providers.

You've deleted the demo rebate product (code: "demo-rebate") so you get the error from your screenshot. Add a new rebate product (normal article not associated to a category) and use its code in the coupon configuration. Then, it will work again.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

Stefan80
Posts: 42
Joined: 27 Nov 2017, 09:57

Re: Coupon related to a product?

Post by Stefan80 » 15 Mar 2018, 09:38

Now I understand.

Thank you !

Stefan80
Posts: 42
Joined: 27 Nov 2017, 09:57

Re: Coupon related to a product?

Post by Stefan80 » 20 Sep 2019, 07:45

Hello,

is it possible to show the used coupon-code in the customer Email?

Post Reply