Skip to Content Skip to Menu

[SOLVED] Activity feeds for specific Assets

  • aybarra
  • aybarra
  • OFFLINE
  • Posts: 17
  • Thanks: 3
  • Karma: 0
2 years 11 months ago - 2 years 11 months ago #327115 by aybarra
I’m having trouble understanding how to create activity feeds properly for my situation.

I have several Joomla Categories (for example, Dalmatians, Huskies, Chihuahuas). I want to create Joomla pages for activity feeds specific to each category. The feed should allow comments and should also have posts for when blogs are created in the corresponding category.

I’ve been able to create the menu links with Menu Item Type: CB Plugin, Plugin: CB Activity, Action: Recent Activity. I set the Activity Asset and Comments Asset to a value corresponding to the Joomla Category ID (topic.11, etc.)

I’ve also created Auto Actions to log a new blog post as:

Conditions: Query, SELECT `catid` FROM`#__content` where id=[var2_id];

Action: Mode: Activity, Method: Create, Published: [var1_published], Asset: topic.11.blog.[var2_id], Owner [var1_user]

1. Comments entered on the page show in CB Activity: Activity with Asset profile.[user_id]. What is the purpose of specifying the Comments Asset when setting up the menu item? How can I get the comments to have the proper Asset?

2. I had to create a filter in order to display only activity with the asset topic.11.*. Using a filter forces the user to have to click on the filter and defeats the point of having a page for each category. How can I get an activity feed for one asset?

3. The Auto Action I created works, but I don’t know how to format a link to the blog article. How is this done in the System Action “CB Blogs – Create"?

4. Is using a Query for the Condition the best way to accomplish this or is there something better?
Last edit: 2 years 11 months ago by krileon. Reason: Added [SOLVED] tag to subject

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48424
  • Thanks: 8274
  • Karma: 1443
2 years 11 months ago #327117 by krileon
Replied by krileon on topic Activity feeds for specific Assets

I’ve been able to create the menu links with Menu Item Type: CB Plugin, Plugin: CB Activity, Action: Recent Activity. I set the Activity Asset and Comments Asset to a value corresponding to the Joomla Category ID (topic.11, etc.)

Don't use Recent Activity. That is a specific page for showing all activity and it will override your asset. Set Action to Activity. You can ignore the parameters under the Comments tab as that's for comment streams. So you should have the following within your menu item.

Action: Activity
Activity
Asset: YOUR_ASSET_HERE

1. Comments entered on the page show in CB Activity: Activity with Asset profile.[user_id]. What is the purpose of specifying the Comments Asset when setting up the menu item?

It doesn't have a purpose for your usage. Those parameters are for comment streams under the Comments tab.

How can I get the comments to have the proper Asset?

You can override the comment asset for an activity entry on activity create. Within your auto action you should see a fieldset titled "Overrides". Under the Comments tab under "Overrides" you can specify the asset you want to use for that activities comments there.

2. I had to create a filter in order to display only activity with the asset topic.11.*. Using a filter forces the user to have to click on the filter and defeats the point of having a page for each category. How can I get an activity feed for one asset?

You only had to create a field because you're using Recent Activity. Adjusting your menu to the above suggestion will avoid needing a filter.

3. The Auto Action I created works, but I don’t know how to format a link to the blog article. How is this done in the System Action “CB Blogs – Create"?

There's specific parsing functionality built in for that. I doesn't accept custom prefixes. So a blog entry is only parsed if it the asset begins with "blog.BLOG_ID". Note you shouldn't be using a blog activity entry in this case, but an article activity entry which has same asset restriction of "article.ARTICLE_ID" so they are going to be difficult for you to filter to a specific category since they don't contain category information. Will review supporting custom prefixes for CB Activity 6.0.0 for article and blog activity to allow for categorization.

4. Is using a Query for the Condition the best way to accomplish this or is there something better?

Depends on what trigger you're using. If acting on Joomla article create you shouldn't need a query condition and should be able to condition against the category id using [var2_catid] since var2 should be the article object. I suggest using a copy of "CB Articles - Create" for your activity creation.


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.

  • aybarra
  • aybarra
  • OFFLINE
  • Posts: 17
  • Thanks: 3
  • Karma: 0
2 years 11 months ago - 2 years 11 months ago #327125 by aybarra
Replied by aybarra on topic Activity feeds for specific Assets

Don't use Recent Activity. That is a specific page for showing all activity and it will override your asset. Set Action to Activity. You can ignore the parameters under the Comments tab as that's for comment streams. So you should have the following within your menu item.

Thank you for the direction with using the Action Activity.

You can override the comment asset for an activity entry on activity create. Within your auto action you should see a fieldset titled "Overrides". Under the Comments tab under "Overrides" you can specify the asset you want to use for that activities comments there.

I think I was using the term "Comments" incorrectly. What's the correct term for the the text area with the placeholder of "What's on your mind?"

There's specific parsing functionality built in for that. I doesn't accept custom prefixes. So a blog entry is only parsed if it the asset begins with "blog.BLOG_ID". Note you shouldn't be using a blog activity entry in this case, but an article activity entry which has same asset restriction of "article.ARTICLE_ID" so they are going to be difficult for you to filter to a specific category since they don't contain category information. Will review supporting custom prefixes for CB Activity 6.0.0 for article and blog activity to allow for categorization.

It appears that custom prefix functionality would not be needed in this case as I can set the Auto Activity Asset as article.[var2_id].topic[var2_catid] and for the menu item, set the Asset as article.%.topic.x,topic.x.%.

Thank you for the direction to look at the Auto Actions for CB Articles. The built in parsing to show the article in the feed is a very nice feature.
Last edit: 2 years 11 months ago by aybarra.
The following user(s) said Thank You: krileon

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48424
  • Thanks: 8274
  • Karma: 1443
2 years 11 months ago #327130 by krileon
Replied by krileon on topic Activity feeds for specific Assets

I think I was using the term "Comments" incorrectly. What's the correct term for the the text area with the placeholder of "What's on your mind?"

That's the message box for activity streams.

It appears that custom prefix functionality would not be needed in this case as I can set the Auto Activity Asset as article.[var2_id].topic[var2_catid] and for the menu item, set the Asset as article.%.topic.x,topic.x.%.

Yup, that will absolutely work.


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