laravel/cashier-mollie

First 1500 customer one year €25 discount / Exclude customers from discount when they have already have one

jasperf opened this issue · 3 comments

What if we would like to give the first 1500 customers €25 off the first year they apply for certain subscriptions? This would not be a coupon code, but a sale or discount. One that is valid for one year only and for certain yearly packages only. Would I still need to make a coupon contract for this? It is a discount applied to the standard packages for one year.

It is not a coupon code we will hand it so wonder what the right way to go is here. We have built this in but now that we are planning to migrate to Cashier Mollie we would appreciate some pointers

Two, are there existing methods to apply coupons or discounts only when no other discounts are running? When a customer has a Halloween discount for example we would not want these guys to get another Christmas discount on top.

Thanks for your feedback. This package is really appreciated a lot.

To prevent nasty concurrency issues I'd:

  • apply the discount reactively by adding 25€ to their balance and not use a coupon

  • or switch them reactively to a dedicated discounted plan, and update the price on that plan after a year or switch them to the original plan.

Thanks for getting back on this @sandervanhooft . Sounds like solid approaches. As for discount or coupon discounts applying and excluding customers that already have a discount running, if you have pointers for that as well please let me know.

There are no methods available for this, as features like these tend to get very use case specific.

Best to start out by checking the RedeemedCoupon model and accompanying table.

Also note these related RedeemedCoupons are accessible through the billable model:

public function redeemedCoupons()

Closing this for now, let me know if it should be reopened.