FriendsOfFlarum / gamification

Add upvotes, downvotes, and ranks to your Flarum Community
https://discuss.flarum.org/d/20671-friendsofflarum-gamification
MIT License
36 stars 17 forks source link
add-upvotes discussion downvotes flarum flarum-community friendsofflarum gamification hotness ranks

Gamification by FriendsOfFlarum

License Latest Stable Version OpenCollective

Extiverse

A Flarum extension. Add upvotes, downvotes, and ranks to your Flarum Community!

Upvote and downvote posts anonymously, and reward active users with ranks, and sort posts by hotness/popularity.

Installation

Install manually with composer:

composer require fof/gamification

You can optionally convert your likes into upvotes, as well as calculate the hotness of all previously existing discussions.

Updating

composer update fof/gamification
php flarum migrate
php flarum cache:clear

Commands

Gamification doesn't need any CRON job, every calculated value will update itself automatically as needed.

However, if the calculated values become out of date as a result of a database migration, due to the extension being temporarily disabled or to import existing data when first using the extension, you can use the following commands to fix the values.

The following commands can be run in the Flarum folder:

php flarum fof:gamification:assign-groups

Updates all users in the database to match the current "Automatically assigned groups" rules.

Even if a user was manually assigned to a group, the group will still be removed if it doesn't match the rules.

php flarum fof:gamification:resync

Updates all discussions with their total first post votes.

php flarum fof:gamification:resyncUsers

Updates all users with a forced recalculation of points.

Links

An extension by FriendsOfFlarum.