[SOLVED] Cbsubs "group jive" integration plugin appears not to be working, . .

9 years 4 months ago #255891 by delhi-expat

krileon wrote: As GJ has not been upgraded for CB 2.x yet I can't really guarantee that's going to function. You can try using GJ Auto then acting on a CBSubs trigger to see if it'll function that way. Below is how you'd setup your GJ Auto.

Plan Active
Triggers: onCPayUserStateChange
User: Automatic
Access: Everybody
Conditional 1: [var3] Equal To PLAN_ID_HERE
Conditional 2: [var2] Equal To A

Plan Expired
Triggers: onCPayUserStateChange
User: Automatic
Access: Everybody
Conditional 1: [var3] Equal To PLAN_ID_HERE
Conditional 2: [var2] Equal To X

Replace PLAN_ID_HERE with the plan id you want to condition against. You can find your plan id within CBSubs > Plans under the Id column on the far right of the table.


Thanks for the suggestion krileon. Sorry for a question that might sound extremely silly, but what are [var3] and [var2]? Should I just enter them "as is"? I'm setting it up so that this should fire when the user selects a certain plan and registers. . .

Please Log in to join the conversation.

9 years 4 months ago #255892 by krileon
You enter the information exactly as I've provided except you need to replace PLAN_ID_HERE. var3 will substitute in the plan id. var2 will substitute in the plan state. That trigger fires when a plan subscription state changes.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

9 years 4 months ago #255896 by delhi-expat
Did that, but it did not seem to work. I used both onCPayAfterPlanSelected and onCPayUserStateChange ... :)

Please Log in to join the conversation.

9 years 4 months ago #255914 by delhi-expat
Hi Kyle

Quick question - - is it possible to use the cbsubsSQL plugin to accomplish what I'm trying to do i.e. add the user to a group depending upon plan chosen?

I think so, but I'm not comfortable enough with the SQL and/or CB database structure to attempt this. However, if you could provide me with a sample SQL statement (insert user into table if condition is met i.e. if planid = 1, or 2, or 3), I might attempt to do it this way (assuming this is doable via said plugin of course).

Cheers and thanks for all the help thus far - - much appreciated, and I'll install the latest nightly builds once you let me know how exactly to do it (I don't want to mess things up after all the configs I've made, so will wait for you to chime in on that one before making any changes).

:cheer: :cheer:

Please Log in to join the conversation.

9 years 4 months ago #255925 by krileon

Did that, but it did not seem to work. I used both onCPayAfterPlanSelected and onCPayUserStateChange ...

You need to use only onCPayUserStateChange trigger. What you're wanting will not happen when you click to select a plan though. It will happen after the subscription has become completely active (e.g. after they're registered). I'm still unsure if even this will work though as GJ hasn't gotten its CB 2.x upgrade yet.

Quick question - - is it possible to use the cbsubsSQL plugin to accomplish what I'm trying to do i.e. add the user to a group depending upon plan chosen?

Yes, it's possible to add a user to a GJ group using a query, but none of the GJ triggers or integrations that depend on those triggers will fire.

INSERT IGNORE INTO `#__groupjive_users` ( `user_id`, `group`, `date`, `status` ) VALUES ( '[user_id]', GROUP_ID_HERE, NOW(), 1 )

The above would add them to GROUP_ID_HERE as an active user of the group.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: marketsetc

Please Log in to join the conversation.

9 years 4 months ago - 9 years 4 months ago #255931 by marketsetc

krileon wrote: I'm still unsure if even this will work though as GJ hasn't gotten its CB 2.x upgrade yet.



Didn't work for me, but was worth a shot.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.505 seconds

Facebook Twitter LinkedIn