Skip to Content Skip to Menu

order of execution of integration plugins in CBSubs

  • dhphllps
  • dhphllps
  • OFFLINE
  • Posts: 63
  • Thanks: 5
  • Karma: 1
6 years 5 months ago #299632 by dhphllps
Does changing the order in which CBSubs integration plugins are listed in the CB plugins list change the order of their execution? If not, in what order are they executed? Is that configurable?

When adding new users in the back end and assigning a CBSubs plan, I am using the SQL plugin to change the username from "_new_" to the user_id, and using the CBSubs email integration to send a welcome message. If I include the [USERNAME] placeholder in the welcome email, will it be replaced with _new_ or with the user_id?

Thanks

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 68606
  • Thanks: 9108
  • Karma: 1434
6 years 5 months ago #299635 by krileon

Does changing the order in which CBSubs integration plugins are listed in the CB plugins list change the order of their execution?

Yes, load order will change the order of execution if the integrations are acting on the same trigger (most of them are).

When adding new users in the back end and assigning a CBSubs plan, I am using the SQL plugin to change the username from "_new_" to the user_id, and using the CBSubs email integration to send a welcome message. If I include the [USERNAME] placeholder in the welcome email, will it be replaced with _new_ or with the user_id?

Both use the same trigger so changing their order will change their execution order, but won't resolve your issue since the SQL action does not update the user object. You'd probably need to use CB Auto Actions and for your Email action under Parameters set Reload User to Enabled. You can use the below to perform various actions in CB Auto Actions based off subscription state.

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

Plan Expired
Global
Triggers: onCPayUserStateChange
User: Automatic
Access: Everybody
Conditions
1: [var3] Equal To PLAN_ID_HERE
2: [var2] Not Equal To A


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 or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum

Facebook Twitter LinkedIn