Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a Likes Block that shows the most liked and disliked items within a certain time period #1036

Closed
eSilverStrike opened this issue Feb 13, 2020 · 2 comments
Assignees
Labels
Feature Issues that describe new features.
Milestone

Comments

@eSilverStrike
Copy link
Member

eSilverStrike commented Feb 13, 2020

Figure out if this is possible for the current setup since we would have to run queries based on what the user has read access to and include the time period. Block should have a config item to include only certain item likes

It could get expensive if we have to loop through the list and then check permissions with something like PLG_getItemInfo so caching would be required.

Would it speed up queries if we added total count of likes and dislikes table columns to articles, staticpages etc and then use a plugin api to return the counts?

How about Comments and permissions?

How about different Likes blocks so you could show a likes block just for forum posts (when on a Forum page) (or Articles, Staticpages, etc...)

@eSilverStrike eSilverStrike added the Feature Issues that describe new features. label Feb 13, 2020
@eSilverStrike eSilverStrike added this to the 2.2.2 milestone Feb 13, 2020
@eSilverStrike eSilverStrike self-assigned this Apr 29, 2022
eSilverStrike added a commit that referenced this issue May 3, 2022
This is just the framework. Likes Dynamic Block is currently disabled as unfinished.

- plugin_getiteminfo_story can now check for likes enabled on article
- Added plugin_getiteminfo_comment
- Likes Library can now have dynamic blocks
- PLG_commentEnabled now can be passed uid so another user besides current can be checked
- PLG_typeLikesEnabled now can have Id of item passed if needed if likes are controlled at a per item level
- Fixed plugin_commentenabled_staticpages missing permissions for topic check

For feature #1036
@eSilverStrike
Copy link
Member Author

Framework is in place and proof of concept for Likes Block done.

  • plugin_getBlocks_likes and plugin_getBlocksConfig_likes need to be finished.
  • Figure out layout of block and best way to show top items with likes, or dislikes or both.
  • Proper config options and language variables need to be added for Likes dynamic block
  • Autotag to be added to allow block to be embedded in content.

eSilverStrike added a commit to Geeklog-Plugins/forum that referenced this issue May 3, 2022
eSilverStrike added a commit that referenced this issue May 5, 2022
eSilverStrike added a commit that referenced this issue May 6, 2022
For feature #1036

Likes Block display itself is feature complete.

Still need to do:
- Needs Autotag like polls block
- Needs to work as a phpblock_likes and as a dynamic block
- Needs likes block template for all themes
@eSilverStrike
Copy link
Member Author

Note: Install not tested with new Likes code yet. Not sure if likes code will work in config-install.php as is or if have to hard code Block Admin id of 4 into Likes Config option likes_block_group_id

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Issues that describe new features.
Projects
None yet
Development

No branches or pull requests

1 participant