Discourse Topic Voting

I really enjoy this plugin - thank you to the developers who work on it, its a big boon to my Discourse community.

I’m curious about users gaining votes after using all their votes. I have increased the caps for user votes a few times because some of our most engaged community members vote on a lot of topics. I was wondering if votes could be re-generated for a given user over time up to a cap, or if there was another way to reward users with additional votes. It seems like the main mechanism for granting votes is a static number for an entire trust level, but I might be missing something.

Thanks!

2 Likes

Hey nivshah :waving_hand:

If I’d have to hazard a guess, the reason you can limit votes is so that your members use them wisely and don’t vote for everything else it kind of devalues a vote.


At the moment one way users can get their vote back is by closing the topic. Let’s say you decided to implement a voted feature into a game for example, you can close the topic and this will refund users that vote if you will and they will be able to use it on another topic.

4 Likes

Closing a topic is exactly what I needed here. Thank you.

2 Likes

:partying_face: This plugin is now bundled with Discourse core as part of Bundling more popular plugins with Discourse core. If you are self-hosting and use the plugin, you need to remove it from your app.yml before your next upgrade.

2 Likes

I might have missed this, but is it possible to change your vote once you’ve submitted it? Say a user accidentally votes for the wrong topic, or changes their mind - are they stuck w/ their mistake?

They are apparently able to be liked now according to this topic on a forum I am in: Suggestion Topics can be liked now - Not Terraria Related - Dark Gaming

I’m not sure this is intended but I just wanted you to know

I think it’s because the reaction plugin is enabled. The code from the topic voting plugin that hides the like button doesn’t hide the reaction button.

You’d need CSS that hides the reaction button and existing reactions. Something like

.topic-post.voting-post {
  .discourse-reactions-actions,
  .discourse-reactions-actions-button-shim {
    display: none;
  }
}
2 Likes

Hi,

We noticed the following site settings which control the active vote limit for each Trust Level:

  • topic voting tl0 vote limit

  • topic voting tl1 vote limit

  • topic voting tl2 vote limit

  • topic voting tl3 vote limit

  • topic voting tl4 vote limit

We would like to effectively remove or disable the vote limit for all or most Trust Levels (TLs), allowing users to have an unlimited number of active votes.

Could you please advise on the recommended way to achieve this?

Is there a specific value (e.g., setting it to 0 or -1) that signifies unlimited votes for these settings?

Thank you.

1 Like

That sounds handy in your case – but a topic creator may not always want to vote for that topic. A comment I made elsewhere:

1 Like

You can always un-vote a topic. Each user has limited votes at their disposal, so this is necessary.

Fair point. I’d love for it to be a configurable option, though.

1 Like

Is there a way to configure advanced search with topic voting? I saw this post, but it is closed: Is there a way to filter serach results based on Voting? , and I have users wondering. We only have a few places where you can vote, so would be great if you could limit the search in advanced search and sort by votes.

Advanced search won’t currently do it, but the filter parameters mentioned in the linked post might be more helpful than it seems at first glance. Not quite as handy as an advanced search option, but maybe better than nothing:

There are a few different voting factors you can filter on:

And depending on how you track things, you can either:

  • add status:open
  • exclude a tag with a “-” in front, like -tag:completed

So you can see the most popular open requests with a filter like:

  • category:feature status:open order:votes
  • category:feature -tag:completed order:votes

Then, for your users, you could save the filter URL to a sidebar link:

  • /filter?q=category%3Afeature%20status%3Aopen%20order%3Avotes%20
  • /filter?q=category%3Afeature%20-tag%3Acompleted%20order%3Avotes%20

When a filtered view is open, the filter parameters are shown, and a user can add additional keywords to narrow it down further:

Filter entry window with a keyword added to existing params.

1 Like

Not perfect, but looks like there is more possibility there than I realized. Thank you.

1 Like

In the update I just ran we lost the nice big button that says Vote, it’s now just a small arrow that’s easy to overlook.
My users are not tech savvy people for the most part and will not know that the arrow is where you click to vote.

Is there a way to revert back to the old visual layout?

1 Like

Hi, this morning, the ability to vote and the vote buttons have altogether vanished from my site… :roll_eyes:

No clue what happened… has there been any changed in the Topics voting plugin ?

I have these errors in the console, could it be linked ?

Also it happens only to one of my three Discourse sites.

Thanks.

Hello, I think I’ve figured out where the problem is coming from: categories that aren’t marked as “ideas” can’t display the vote button. I had removed the “ideas” type from all my categories—except, of course, the ones I wanted to treat as idea suggestions. Those categories still have the vote button, but the others, which are just for discussion, have lost theirs. I think this is a glitch.

1 Like

Can you expand on this a bit? If you remove the Ideas category type, which controls whether the category topics can be voted on, then it makes sense that you can no longer vote on these topics.

Or are you saying that topics in categories that you used to be able to vote on can no longer be voted on? If so can you please give some example categories & ids? In your site’s rails console you can do Category.can_vote?(cat.id) to see if a certain category should be able to vote.

1 Like

Long before the ability to assign different types to categories—such as support, ideas, or discussions—even existed, voting was already possible. Consequently, my site was configured so that voting was enabled in almost all categories, except for a few that I had excluded from this mechanism.

When the “idea” type was introduced for categories, if I remember correctly, it was automatically applied to all of my categories without me having to do anything. I found that a bit strange at the time. Of course, back then, I could still vote just like before since all my categories had been assigned the “idea” type.

Once I realized that the “idea” type was, by definition, meant only for ideas and excluded any other type of topic, I decided to make some changes. Since I didn’t want people to vote only on ideas, but also on other types like discussions or support, I removed the “idea” type from the majority of my categories—except, naturally, for those purely dedicated to ideas.

What seemed logical to me, however, completely broke the ability to vote in all the categories where I had removed the “idea” type. At no point did I realize that a category not set to the “idea” type would disallow voting. In my mind—and this is still the case—we should be able to vote on topic types that aren’t just ideas.

I understood a bit too late that this wasn’t how the platform developers had intended the “idea” category to work. As a result, I have since restored the “idea” type across all my categories, in addition to “discussion” or “support” where applicable, which resolved my issue. Unfortunately, it took a significant amount of time, as I had to restore this manually, category by category.

And yes, to be clear, the “ideas” category type that was automatically applied to all my categories during the updates—I assume to all categories where I had enabled voting—retained that voting feature but at the same time added a “ideas” category type to all my categories, which I didn’t want at all because most of them weren’t ideas at all… Seeing this, I removed the “idea” type from almost all of my categories, which at the same time disabled the voting feature. And it took me quite a while to figure this out.