Feature proposal #3788
closed
Added by krileon almost 12 years ago.
Updated over 7 years ago.
Start date:
23 November 2012
Description
Implement the ability to like another asset. The base for this stream api should be the follow class. There should only need to be 2 endpoints. 1 for displaying the button(s) (which also includes the ajax) and 1 for saving the stream. When creating a likes stream the asset supplied is the asset to be liked.
For the button display endpoint it's probably best to reserve show/default for an actual view (e.g. if in the future there's a view to display all the assets the user liked) so use ->likes( 'button' ) instead.
A database table needs to be added to handle the storage of the likes and a table for storage of the various like buttons (e.g. just like Locations, Actions, etc..).
This will be ajax powered, so no page loads.
This should be an API that can be used by other plugins so it needs to be generalized. It should function like CB Captcha where it's based off a trigger call.
Example DB Structure:
ID, TYPE, SUBTYPE, ITEM, USER, STATUS, DATE
- Target version changed from 2.0.0 to 3.0.0
This will be new API Library in CB 2.0 for CB Activity to utilize.
A "Toasts" API should also be added so a user can say they basically read the activity, but don't like or dislike it.
- Target version changed from 3.0.0 to 616
- Target version changed from 616 to 3.0.0
- Target version changed from 3.0.0 to 4.0.0
First develop CB Thumbs API plugin to add a generic like/dislike/toast API then use it for the like/dislike feature.
- Target version changed from 4.0.0 to 722
This needs CB Thumbs API plugin.
- Target version changed from 722 to 708
- Target version changed from 708 to 4.0.0
This should be built into CB Activity. It needs to provide a sharing API and thumbs API as it does an activity and commenting API.
Like/Dislike will NOT post on the stream. Instead a separate tab will be provided to showcase someones likes. What will show on the stream is Share, which is really its intended purpose, but it'll allow sharing outside of the stream as well.
Optional system action to log likes could be fine as well. So this way it's up to the site.
Instead of Toast simply do: Like, Dislike, Thanks. This would be more universally understood. This really should be a new storage table though and work like Actions and such were you can specify custom usages. So you could have Love, Hate, etc..
Call this API "Reactions".
This should basically be designed directly after the follow API. The exception being instead of a static follow button we need to handle different button types as there could be a like, dislike, toast, etc.. usage available that needs to be accounted for, but that's entirely on the display aspect of the button.
- Subject changed from Implement like, dislike, and share buttons to Implement like buttons
- Description updated (diff)
- % Done changed from 0 to 60
- % Done changed from 60 to 70
- % Done changed from 70 to 90
Still needs content bot and module usage, but internal and field usage done.
- % Done changed from 90 to 80
Still needs types tooltip selector usage, whoops!
- % Done changed from 80 to 90
Type selector implemented.
- Status changed from Assigned to Resolved
- % Done changed from 90 to 100
- Status changed from Resolved to Closed
Also available in: Atom
PDF