Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I have developed a drupal module to add coupon functionality to civicrm event registrations. The project was proposed here http://civicrm.org/blogs/eparisiva . After i worked up with CiviCRM core developers, they advised to build a drupal module and use CiviCRM API to integrate with CiviCRM events. The whole coupon management is done in Drupal API and coupon implementation in CiviCRM API.
For coupon functionality there is already a drupal contrib module called uc_coupon, but it is only for ubercart pages. That module can't be extended to support CiviCRM because it has lot of dependencies on core ubercart module. So i decided to just copy the coupon forms from it, add the CiviCRM integration to it and make it independent from ubercart module.
For coupon functionality there is already a drupal contrib module called uc_coupon, but it is only for ubercart pages. That module can't be extended to support CiviCRM because it has lot of dependencies on core ubercart module. So i decided to just copy the coupon forms from it, add the CiviCRM integration to it and make it independent from ubercart module.
Comment | File | Size | Author |
---|---|---|---|
#4 | civicrm_coupon.tar_.gz | 8.36 KB | siva_epari |
#1 | civicrm_coupon.tar_.gz | 13.82 KB | siva_epari |
Comments
Comment #1
siva_epari CreditAttribution: siva_epari commentedThis module depends on CiviCRM and works fine with the latest release civicrm-3.2.5-drupal.tar.gz.
To verify the module:
1. Install CiviCRM following http://wiki.civicrm.org/confluence/display/CRMDOC32/Drupal+Installation+...
2. During installation of CiviCRM give the same databasename as given to drupal installation
3. After installation install civicrm_coupon module
4. Add a new coupon at admin/settings/coupon/add
5. Add a new Paid CiviCRM event at civicrm/event/add&reset=1&action=add
6. After filling all details, save it and edit the fees section
7. In the fees section, check "Enable Pay Later option" to avoid all payment integration fuss
8. Give a "Fee label" and "Amount" in "Regular Fees" section and save it
9. Now in the top menu button "Events links" select "Online Registration(Live)"
10. Give the coupon code and continue
11. The discount will be applied to the amount provided the event fees section
12. To check the usage reports goto admin/settings/coupon/reports
Thank you for reviewing
Regards
Siva
Comment #2
apadernoHello, and thank you for applying for a CVS account. I am adding the review tags, and some volunteers will report what needs to be changed in the code.
As per requirements, the motivation shouls also include a comparison with the existing solutions.
Comment #3
siva_epari CreditAttribution: siva_epari commentedThank you Kiamlaluno.
The existing module for coupons uc_coupon is not extensible for civicrm, because:
1. uc_coupon has dependency on ubercart module. So if somebody wants coupon with civicrm, he has to install the ubercart module for no reason.
2. uc_coupon has lot of additional fields which are required for commerce, but doesn't have fields which are required for civicrm events.
3. Most of the information for filtering coupons is coming from Civicrm which has a different api and database to integrate. This would not be useful who are installing uc_coupon for ubercart purposes.
I think these points are enough to explain why should go for a new module rather than re-using uc_coupon.
Comment #4
siva_epari CreditAttribution: siva_epari commentedI used coder to cleanup the code and rectify some bugs. Here's a fresh copy of the module.
Comment #5
siva_epari CreditAttribution: siva_epari commentedHi all
Can i get to know the status of this application?
Cheers
Siva
Comment #6
donSchoe CreditAttribution: donSchoe commentedOn top of your application is a table:
Comment #7
siva_epari CreditAttribution: siva_epari commentedHi donschoe,
Thanking you for your prompt reply.
I wanted to know if somebody is reviewing it or not, as i see the same status for past 10 days.
~Siva
Comment #8
snarklife CreditAttribution: snarklife commentedHi, Siva
First, thank you so much for creating this - it's a fantastic piece of work. However, I can' seem to getit to work with CiviEvent registrations. Is this because the event I'm testing on uses price sets? Do coupons only work with fixed price events?
Regards,
Snarklife
Comment #9
dharmatech CreditAttribution: dharmatech commentedWe've also created a module to support discount codes with CiviEvent. We wrote it from the ground up so it doesn't have all the uc_coupon code in it and it supports price sets.
http://drupal.org/project/civievent_discount
Comment #10
siva_epari CreditAttribution: siva_epari commentedHi dharmatech
Great job and nice effort. This module will help a lot of people who have been waiting for the same from many months. Thanks!
Comment #11
siva_epari CreditAttribution: siva_epari commentedHi snarklife
My client only required discounts on fixed price. Glad that dharmatech's module supports price set discounts
Comment #12
siva_epari CreditAttribution: siva_epari commentedCan anybody review my application? It's been lying around here for a month.
Comment #13
siva_epari CreditAttribution: siva_epari commentedCan anybody review my application? It's been lying around here from long time.
Comment #14
zzolo CreditAttribution: zzolo commentedHi. Please read all the following and the links provided as this is very important information about your CVS Application:
Drupal.org has moved from CVS to Git! This is a very significant change for the Drupal community and for your application. Please read the following documentation on how this affects and benefits you and the application process:
Migrating from CVS Applications to (Git) Full Project Applications
Comment #15
apadernoAs per previous comment, I am setting this issue as Won't fix.
Since new users can now create full projects, applications have a different purpose and they are handled on a different issue queue. See Apply for permission to opt into security advisory coverage for more information.
Comment #16
apaderno