Skip to Content Skip to Menu

Send invitation to group from GJ backend

  • krileon
  • krileon
  • ONLINE
  • Posts: 48479
  • Thanks: 8283
  • Karma: 1443
10 years 4 weeks ago #249988 by krileon
Replied by krileon on topic Send invitation to group from GJ backend
I see, you want to send an email to an entire ACL group on an event. That's not really possible without custom coding, because the recipients email addressed are not available from substitutions. I guess one way to do it would be a CB Query Field that queries for all the users in the Editor ACL group, concat the results as comma separated, then supply that query field as a substitution for the To parameter.


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.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48479
  • Thanks: 8283
  • Karma: 1443
10 years 4 weeks ago #250067 by krileon
Replied by krileon on topic Send invitation to group from GJ backend
The below query could be used in a CB Query Field to grab a comma separated list of email addresses for all users in a specific usergroup.

Code:
SELECT GROUP_CONCAT( u.`email` SEPARATOR ', ' ) FROM `#__users` AS u LEFT JOIN `#__user_usergroup_map` AS g ON g.`user_id` = u.`id` WHERE g.`group_id` = GROUP_ID_HERE

With the above replace GROUP_ID_HERE with the usergroup id you want to check for. For example 2 is generally Registered.


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: nant, devodave

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

  • devodave
  • devodave
  • OFFLINE
  • Posts: 68
  • Thanks: 5
  • Karma: 0
10 years 4 weeks ago #250083 by devodave
Replied by devodave on topic Send invitation to group from GJ backend
Thank you very much,

can you just clarify what you mean by "For example 2" ?

Thanks again

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

  • nant
  • nant
  • OFFLINE
  • Posts: 12339
  • Thanks: 1467
  • Karma: 877
10 years 4 weeks ago #250084 by nant
Replied by nant on topic Send invitation to group from GJ backend

devodave wrote: Thank you very much,

can you just clarify what you mean by "For example 2" ?

Thanks again


In Kyle's SQL code you see:

WHERE g.`group_id` = GROUP_ID_HERE

and his comment stating:

With the above replace GROUP_ID_HERE with the usergroup id

2 is the number you should use for the registered user group.

But you should really verify this from your Joomla usergroups table.
The following user(s) said Thank You: devodave

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

  • devodave
  • devodave
  • OFFLINE
  • Posts: 68
  • Thanks: 5
  • Karma: 0
10 years 4 weeks ago #250115 by devodave
Replied by devodave on topic Send invitation to group from GJ backend
Thank you guys for your help,

So if I understood correctly:
1) create field - for example- UE_publisherCAT with above query
2) create auto action with [UE_publisherCAT] for the 'to' parameter

Is this right, or there is another way to supply the query field as a substitution for the To parameter?

Thanks for your assistance

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48479
  • Thanks: 8283
  • Karma: 1443
10 years 3 weeks ago #250245 by krileon
Replied by krileon on topic Send invitation to group from GJ backend

So if I understood correctly:
1) create field - for example- UE_publisherCAT with above query
2) create auto action with [UE_publisherCAT] for the 'to' parameter

Is this right, or there is another way to supply the query field as a substitution for the To parameter?

Yes, your steps are correct. You create the query field then substitute it in as the To.


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