I'm considering using this module for an upcoming project and am wondering if anyone has every tried creating a coupon worth a set number of user points (in conjunction with the User Points and Commerce User Points modules).

The idea is the customer would redeem the coupon at checkout and the user points would be immediately added to their account and apply some or all of the points during the current transaction.

This doesn't sound super complicated to implement via a custom module, but I'm wondering if this idea has broader appeal for inclusion in this module or perhaps as a companion module.

All comments welcome.

Comments

jasen’s picture

Yes! Integration with user points would be awesome, I would totally use this.

pcambra’s picture

Status: Active » Postponed

I see the use case, agreed with it being useful for many things.

A "plug and play" approach should be in a separate module, but you can get into this quite straightforward for a basic integration with the current state of the things.

You'll need to create a new coupon type and in the rule regarding applying the coupon to the order, you just need to place the corresponding userpoints action (didn't try it but I'm quite sure userpoints has a rule action to apply points to a given user). What you need to add is a field to the coupon type that has the number of points assigned.

Setting this as postponed as this is a third party module material.

jasen’s picture

I ended up building this into a custom module if anybody is interested...

johnhanley’s picture

As the OP, I no longer have the need, but I think this would be very useful as a contributed module.

Anonymous’s picture

Hi Jasen,

I'm interested in the custom module that you created for converting userpoints into a coupon. I really could use something like this for a drupal commerce site I'm working on.

Thanks!

jasen’s picture

tuong88, mine is pretty heavily configured to the exact setup of my site and other custom modules. But here's a very similar one that would do pretty much the same thing:

http://drupal.org/sandbox/kimberlydb/1882566

kimberlydb’s picture

I have written a custom module, it does work, but as a warning it does require some coding/manipulation at the moment. I am working on getting it cleaned up and adding a UI config for easy usage. I am happy to share what I have now, but you'll have to take a look at how it works and see if you can manipulate it for your site. I don't have a timeline for completion, but hopefully in the next month or two.

It does a bit more than just give the user a # of points for entering a coupon. Each of my products had a value of points that a user would be awarded after purchase. The coupon can multiply this value. It also for specified products gives a bonus, and a bonus for an order (which would be the basic mode) where if a user reaches a certain minimum price it awards the points.

kimberlydb’s picture

I have completed a stripped down version of the module and applied for project status on it.

http://drupal.org/node/1984478

kimberlydb’s picture

Status: Postponed » Fixed
johnhanley’s picture

Kimberly, thanks for your time putting this together.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Chris747’s picture

Issue summary: View changes

Hi guys,

I would like to use this module in the registration form: The user can get e.g. 50 user points by registrating with the coupon code '50userpoints4free'. Can I do this with this module, or would i have to set it up differently?

Kind regards,
Chris

johnhanley’s picture

@Chris747, welcome to drupal.org.

This issue has been closed for 6 years. Also, this isn't the place to ask for help or opinions. That said, it sounds like @kimberlydb's module might suit your need. The best thing you can do is download the module and try it out.