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.
This module gives a way to provide a discount to a user for referring other users to your commerce site. The implementation is pretty simple.
- User A invites user B to our site using a unique invite URL (http://yoursite.com/invite/username).
- User B visits the site using this URL, and is taken to the registration form to create a new account.
- User B gets some discount amount (say $5) which he could use on his first purchase.
- After user B makes his first purchase, user A gets a discount amount (say $10), which could be used in the next purchase.
- Both discount amounts are configurable from the admin backend. To configure the discount amounts browse to /admin/config/referral-discount
Project page: https://www.drupal.org/sandbox/nikhilbanait/2752301
Git url: git clone --branch 7.x-1.x https://git.drupal.org/sandbox/nikhilbanait/2752301.git commerce_referral_discount
Manual review of other projects:
Comment | File | Size | Author |
---|---|---|---|
#3 | commerce-refferal-discount-1.png | 64.17 KB | manojapare |
Comments
Comment #2
PA robot CreditAttribution: PA robot commentedWe are currently quite busy with all the project applications and we prefer projects with a review bonus. Please help reviewing and put yourself on the high priority list, then we will take a look at your project right away :-)
Also, you should get your friends, colleagues or other community members involved to review this application. Let them go through the review checklist and post a comment that sets this issue to "needs work" (they found some problems with the project) or "reviewed & tested by the community" (they found no major flaws).
I'm a robot and this is an automated message from Project Applications Scraper.
Comment #3
manojapare CreditAttribution: manojapare as a volunteer and at Valuebound commentedHi @Nikhil Banait,
Manual Review
Individual user account
Yes: Follows the guidelines for individual user accounts.
No duplication
Yes: Does not cause module duplication and/or fragmentation.
Master Branch
Yes: Follows the guidelines for master branch.
Licensing
Yes: Follows the licensing requirements.
3rd party assets/code
Yes: Follows the guidelines for 3rd party assets/code.
README.txt/README.md
Yes: Follows the guidelines for in-project documentation and/or the README Template.
Code long/complex enough for review
Yes: Follows the guidelines for project length and complexity.
Secure code
Yes: Meets the security requirements.
Coding style & Drupal API usage
Additionally one suggestion:
Comment #4
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commented@manojapare thank you so much for reviewing and suggesting solution as well. I have fixed that PDOException issue.
Regarding title for invite link block, I feel admin can add title whatever he wants as per requirement.
Comment #5
yogeshmpawarHi Nikhil,
Manual Review
Individual user account
Yes: Follows the guidelines for individual user accounts.
No duplication
No: Causes module duplication and/or fragmentation.
Master Branch
Yes: Follows the guidelines for master branch.
Licensing
Yes: Follows the licensing requirements.
3rd party assets/code
Yes: Follows the guidelines for 3rd party assets/code.
README.txt/README.md
Yes: Follows the guidelines for in-project documentation and/or the README Template.
Code long/complex enough for review
Yes: Follows the guidelines for project length and complexity.
Secure code
Yes: Meets the security requirements.
Coding style & Drupal API usage
[List of identified issues in no particular order. Use (*) and (+) to indicate an issue importance. Replace the text below by the issues themselves:
(*) Nothing
(+) 1. you should add validations for configurations of commerce referral discount.
2. It would be good, if you implement hook_help & hook_permission in your module.
Just a recommendation
Nothing
The starred items (*) are fairly big issues and warrant going back to Needs Work. Items marked with a plus sign (+) are important and should be addressed before a stable project release. The rest of the comments in the code walkthrough are recommendations.
If added, please don't remove the security tag, we keep that for statistics and to show examples of security problems.
This review uses the Project Application Review Template.
Comment #6
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commentedComment #7
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commentedAdded the validations for admin configuration form. Implemented hook_help & hook_permission as well.
Comment #8
yogeshmpawarThis module looks good and working for me. also there are no blocker points left.
So i am marking this module as RTBC.
Comment #9
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commentedComment #10
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commentedComment #11
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commentedComment #12
apadernoI will update your account so you can promote this to a full project and also create new projects as either a sandbox or a "full" project.
Here are some recommended readings to help with excellent maintainership:
You can find lots more contributors chatting on IRC in #drupal-contribute. So, come hang out and stay involved!
Thank you, also, for your patience with the review process. Anyone is welcome to participate in the review process. Please consider reviewing other projects that are pending review. I encourage you to learn more about that process and join the group of reviewers.
Thanks go the dedicated reviewer(s) as well.
Comment #13
Nikhil Banait CreditAttribution: Nikhil Banait as a volunteer and at QED42 commentedThanks a lot @kiamlaluno for promoting this application.