Coupon as a Product

Categories

Component ID

897824

Component name

Coupon as a Product

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Downloads

1393

Component created

Component changed

Component body

There are a couple of coupon modules that I found and tried for Ubercart 2.x. However, I found that they are either too fancy, or hard to understand. Normally, a coupon (as advised by Ubercart) are relying on line items, here I take a different approach.

In this module I treat a coupon as a product node with a negative price. This gives several good things:

  • Since a coupon is a node (because products are nodes), you can have a themable page for a coupon, so you can print it out
  • Stock can be used to check if the coupon is (un)available
  • The coupon is attached directly to the order, so you don't need to mess around with the line items - the sum that goes to Paypal is already discounted (somehow with the line items the order lifecycle was quite obscure to me)

The other coupon modules that I've tried and didn't adopt are:

I'm looking forward to Drupal 7 and Drupal Commerce module, so if anyone is interested to take over the development of this module, you're more than welcome!