Discourse Topic Voting

:discourse2: Summary Discourse Topic Voting gives the ability to vote on topics in a specified category.[1]
:open_book: Install Guide This plugin is bundled with Discourse core. There is no need to install the plugin separately.

Features

To enable it, edit any category, look on the settings tab for the “Allow users to vote on topics in this category” checkbox:

Once enabled, a “Votes” item is available in the top menu. The topics in that category can be voted on with the count of votes added next to the topic title.

The vote count is also included next to the title when scrolled.

To make it easier to see vote counts from a topic list, the vote count is also added under the topic titles.

Here are the views a user will see before and after voting in a topic:

Screenshot 2024-05-13 at 10.08.17 AM Screenshot 2024-05-13 at 10.10.13 AM

There is also a section in the user’s profile page that displays their active votes:

Active Votes

The term Active Votes refers to the votes a user has cast in topics that are currently available for voting. Limiting Active Votes encourages users to vote thoughtfully for the topics that matter most to them.

  • The number of Active Votes available to each user is configurable by Trust Level. Default values:

    • TL0: 2
    • TL1: 4
    • TL2: 6
    • TL3: 8
    • TL4: 10
  • Each user may cast only one vote per topic.

  • When a topic is closed or archived, the vote count on the topic remains unchanged. These votes are no longer considered Active. The users who cast these votes will have their one vote from that topic restored to their pool of available votes.

  • If a topic is re-opened or unarchived, the votes are reclaimed and applied back to the users’ Active Vote count.

  • If a topic reclaims the votes of a user, causing them to exceed their Active Vote limit, they simply need to wait until topics are closed or archived to allow them to vote again.

  • If an entire topic (Topic A) is merged into another Topic-Voting topic (Topic B), all the the following takes place:

    1. Unique votes from Topic A are added to Topic B.
    2. Duplicated votes (the same user voted in both topics) from Topic A will not be added to Topic B. Instead, the vote from Topic A will be restored to the user’s pool of available votes.
    3. Topic A’s vote count is set to zero and the topic is closed so that no further voting can take place in Topic A.

Settings

Name Description
topic voting alert votes left Alert user when this many votes are left
topic voting enabled Allow users to vote on topics?
topic voting show who voted Allow users to see who voted?
topic voting show votes on profile Allow users to see their votes in their activity feed?
topic voting tl0 vote limit How many active votes are TL0 users allowed?
topic voting tl1 vote limit How many active votes are TL1 users allowed?
topic voting tl2 vote limit How many active votes are TL2 users allowed?
topic voting tl3 vote limit How many active votes are TL3 users allowed?
topic voting tl4 vote limit How many active votes are TL4 users allowed?

Category Setting

topic voting category setting

EXTRAS

:information_source: In the categories where the Voting plugin is activated, Likes are automatically deactivated. Some sites may want to use both functions at the same time to like replies, see how to re-enable Likes.

Data Explorer Queries

List people who voted for a topic along with their email addresses:

--[params]
-- int :topic_id

SELECT
tvv.user_id,
email
FROM topic_voting_votes tvv
JOIN user_emails ue ON ue.user_id = tvv.user_id
WHERE topic_id = :topic_id
AND ue.primary = true

More explorer queries can be found in Data & reporting - Topics tagged topic-voting

:discourse2: Hosted by us? This plugin is available on our Business and Enterprise plans Topic Voting | Discourse - Civilized Discussion


  1. and is the result of this spec put together by @erlend_sh ↩︎

Last edited by @southpaw 2025-07-25T02:39:13Z

Check documentPerform check on document:
128 Me gusta

Como parte del cambio de nombre del plugin Discourse Post Voting, ahora también hemos cambiado el nombre de este para complementarlo. :partying_face: :slightly_smiling_face:

Así que, por la presente, les doy la bienvenida oficial a todos al plugin Discourse Topic Voting. :tada::balloon::champagne:

14 Me gusta

Realmente me gusta este plugin. Lo estoy usando para una categoría reservada para artículos de blog. Al ingresar a una categoría con este plugin habilitado, ¿sería posible ordenar la lista de temas por número de votos descendente?

¡Gracias de nuevo!

1 me gusta

2 publicaciones se dividieron en un nuevo tema: Votos no devueltos al cerrar tema

He notado que en la animación de

el usuario solo se entera de que

  • en realidad tiene un número limitado de votos
  • y que ahora le quedan xx votos
    después de hacer clic para votar.

Quizás debería enterarse de todo esto en el mouseover del botón de voto, antes de hacer clic.

3 Me gusta

2 publicaciones se dividieron en un nuevo tema: ‘See who voted’ display issue

Para hacerlo más oficial, las tablas de la base de datos de este plugin ahora se migran a topic_voting_ para que coincidan también con las de post_voting_, junto con la configuración del sitio.

Cuando los propietarios del sitio actualicen este plugin, las consultas existentes del explorador de datos que utilizan las tablas antiguas se actualizarán automáticamente para usar los nuevos nombres de tabla.

6 Me gusta

¿Cómo puedo volver a habilitar las reacciones de Discourse en la primera publicación de un tema de votación?

¿Intentaste el consejo para volver a habilitar los “Me gusta”?

2 Me gusta

Ah, lo siento, sí lo hice, pero pensé que no estaba funcionando hasta que me di cuenta de que estaba viendo mis propias publicaciones, así que no debería esperar ver un botón de “me gusta” :laughing:

2 Me gusta

¿Hay alguna forma de añadir el botón de votación directamente a la lista de temas?

1 me gusta

Creo que esto es lo que buscas:

3 Me gusta

¿Hay alguna forma de que el creador del tema vote automáticamente por su publicación? Tenemos muchos usuarios que crean estos temas pero se olvidan de votar, y es una pequeña molestia tener que recordarles cada vez. Solo me preguntaba :slight_smile:

¡Gracias por el plugin!

1 me gusta

Apoyo esto. Sin que los usuarios sepan que los votos son limitados, no pueden ajustar su comportamiento, por lo que el objetivo original de alentar a los usuarios a votar de manera reflexiva no se logra de manera efectiva.

¿Es posible desactivar la votación por tema en una categoría? Queremos que la mayoría de los temas en la categoría sean votables, pero a veces queremos publicar temas que no sean votables. Veo que hay una propiedad en los temas llamada can_vote, pero no parece que haya en la interfaz de usuario ni en ninguna llamada API para actualizar esto. Parece posible ya que el tema “Acerca de la categoría XYZ” que se crea inicialmente no es votable.

@tyler.lamparter ¿Quizás esta configuración en la configuración de la categoría?

@NateDhaliwal tenemos eso habilitado, pero me pregunto si algunos temas colocados en esa categoría pueden tenerlo deshabilitado. Por lo tanto, el 99% de los temas en nuestra categoría deberían tener votación de temas, pero unos pocos seleccionados no deberían.

Correcto. No creo que eso sea posible. Es posible que puedas ocultarlo con CSS, pero sería difícil ya que estos cambios serían en todo el sitio, no por tema…

La razón por la que parece posible es que hay una bandera can_vote en cada tema y ya está controlando lo que muestra la interfaz de usuario. Simplemente no veo ninguna forma de actualizar esta bandera a través de la API o establecerla a través de la interfaz de usuario.

El “Tema Acerca de esta categoría” que se crea cada vez que se crea una nueva categoría:

Un tema en el que uno de nuestros usuarios publicó en la categoría:

1 me gusta

Para la categoría Feature aquí, las opciones de votación e información están ocultas con un pequeño CSS basado en la etiqueta para los temas de feedback.

2 Me gusta