| Project: | Ubercart Contributions |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Jump to:
I need an extend membership trigger.
Similar to when you edit a users profile you can add +1 month to the expiration of a role, I would like a trigger that is able to add 1 month on to the expiry of a user based on when an order receives a new payment.
The scenario:
I am using paypal button to set up a recurring payment from paypal. I have an ubercart product that is a role, called premium member, which has an expiry set to 1 month. The users are basically purchasing 1 month of access to the premium content on the site.
When the month membership is up paypals recurring payment sends a notification to the system which updates the order with a new payment, but because the payment is coming in before the role has actually expired, the renew trigger is not working. I need it to add one month on to the role not just change the status from non-member to member, which is what it appears to be trying to do. If the role expires before payment notification is received I think it appears to work ok, as it will give the user the required role.
I have thought about setting up a complex trigger process that recognises when a payment is received which triggers a change in the order which removes the role which triggers another change in the order which triggers the change back to the role, but I thought that the add one month on to the expiry trigger would be far simpler.
Any help would be appreciated.
