Usecase related to CB activity

4 years 5 months ago #315400 by liaskas
Usecase related to CB activity was created by liaskas
Hello again...

How can we filter the activity posts by poster's user group?

Example:

User Groups:
  • Bronze
  • Silver
  • Gold

Filters:
  • Posts by Bronze members
  • Posts by Silver members
  • Posts by Gold members

Thank you in advance.

Please Log in to join the conversation.

4 years 5 months ago #315404 by krileon
Replied by krileon on topic Usecase related to CB activity
Filters will only filter by Asset and/or by User IDs. If those users posts have a unique asset then you can use that asset in your filter. If they don't have a unique asset then the only other way to accomplish that is a Query or Code field that returns a comma separated list of user ids that you can substitute into the User filter.


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.

4 years 5 months ago #315406 by liaskas
Replied by liaskas on topic Usecase related to CB activity
Please help me understand Kyle, as things that might seem very simple to you, but they are like making a tunnel with a spoon for me.

If those users posts have a unique asset then you can use that asset in your filter


Is there assets list somewhere so that i can search what kind of assets exist and i can use?

the only other way to accomplish that is a Query or Code field that returns a comma separated list of user ids that you can substitute into the User filter.


You mean that this list of user ids can be substituted and give filter results by user group? If so... is there a tutorial somewhere?

What i asked is for a way to filter by the group that the users belong to (registered, author, admin, etc) but i got no reply, or i got one but i did not understand.

So i remain on this part of your answer...

the only other way to accomplish that...


so there is a way to accomplish that! Can you please suggest a tutorial?

Thank you!

Please Log in to join the conversation.

4 years 5 months ago #315424 by krileon
Replied by krileon on topic Usecase related to CB activity
The best way to do this is to give each usergroup their own stream via the asset parameter so their activity is properly separated. For example lets assume you've a CB field to select what type of user they are. Lets call it cb_profiletype and lets assume its values are "bronze", "silver", and "gold". Now you'd edit the Activity tab in CB > Tab Management and set the Asset parameter to "profile.[user_id].[cb_profiletype]". What this would do is make sure all future posts by the user are linked to that specific asset. So if I'm a bronze user and I post on my activity stream then the activity will have an asset of "profile.42.bronze" for example. This will now allow you to filter by profile type since you could add a filter of "profile.%.bronze" to show all activity posts for bronze users.

There is no way to filter a stream directly by usergroup. The only way you'd be able to do that is as mentioned earlier by querying the database for that information and substituting that query field into a User filter, but if it returns too many users it could significantly hurt the performance of the stream.


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.

4 years 4 months ago #315445 by liaskas
Replied by liaskas on topic Usecase related to CB activity
Thank you for your reply Krileon.

This solution seems working when applied in profile activity Tab.

But we are interested to apply it in activity menu item activity. Tried it there (Action *: Recent Activity) but it is not working.

Any ideas?

Thank you!

Please Log in to join the conversation.

4 years 4 months ago #315458 by krileon
Replied by krileon on topic Usecase related to CB activity
You can't override the asset of Recent Activity. It will always be forced to "all". Instead change the Action from Recent Activity to just Activity for a fully customizable menu stream.


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: liaskas

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.286 seconds

Facebook Twitter LinkedIn