Experimental project

This is a sandbox project, which contains experimental code for developer use only.

Based on Commerce Coupon, you can now set user-based restrictions for your coupons !

You can play with 3 new fields :

  1. "Check for maximum number of uses per user ?" lets you set the user-based restrictions
  2. "Maximum number of uses per user" sets the restriction of uses per user
  3. "Users allowed" lets you define only some users who can redeem coupons

You can also now define a maximum number of uses to 0 (for original and per-user fields) for setting unlimited uses.

So if you want :

  • Coupons only for some users : set "maximum uses" to 0, "maximum uses per user" to 0, and "users allowed" set to your users (with the checkbox "check per user" checked)
  • Coupons only once per user : set "maximum uses" to 0, "maximum uses per user" to 1, and "users allowed" to nothing (with the checkbox "check per user" checked)
  • Unlimited coupons : set "maximum uses" to 0 (with the checkbox "check per user" unchecked), OR "maximum uses" to 0 (with the checkbox "check per user" checked) and "maximum uses per user" to 0, and no "users allowed"

Enjoy !

Project information

  • Created by rkcreation on , updated