Re: Re: Re: Re: Re: Re: Re: Re: Subscriptions

Joined: 09/11/2008
Juice: 163

You're welcome. I wanted to make one further caveat to what I said previously. I made the comment, "In 'Test Developer' mode, CIM (v0.90) works perfectly with uc_subscribe (2008-04-11)".

I wanted to add that it was necessary for me to create a couple of Workflow-ng business rules to really get it to work as I fully expected. The base rules come included with the uc_subscribe module. The two rules I created from these base rules are "Site subscription has begun" and "Site subscription has expired":

  • Rule: Site subscription has begun
    • Invoked on event: New subscription has been registered
    • Conditions: User has role(s); User to test: Customer; Select role(s): Authenticated
    • Actions: Add user role; User whose roles should be changed: Customer; Select role(s): Subscriber
  • Rule: Site subscription has expired
    • Invoked on event: Subscription has expired
    • Conditions: User has role(s); User to test: Customer; Select role(s): Subscriber
    • Actions: Remove user role; User whose roles should be changed: Customer; Select role(s): Subscriber
    • Second Action: Execute Custom PHP Code -- we give subscribers access to several "paid only" Drupal Simplenews newsletters. When the subscription ends, we need to ensure the user no longer has access to the newsletters. We run through some PHP code to delete records in the database.

When using the uc_recurring/uc_roles modules in place of uc_subscribe, I was able to replicate the same type of rules by pointing to the "order" rather than the "customer" data.

Expiring roles and recurring fees for subscriptions By: ron_s (53 replies) Sat, 10/04/2008 - 01:50