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

Define initial models and migrations #111

Closed
Tracked by #110
microstudi opened this issue Oct 6, 2023 · 1 comment
Closed
Tracked by #110

Define initial models and migrations #111

microstudi opened this issue Oct 6, 2023 · 1 comment
Assignees
Labels

Comments

@microstudi
Copy link
Contributor

microstudi commented Oct 6, 2023

This task introduces 2 new models and migrations for decidim awesome:

  • vote_types: Adds a "grade" for each vote. A grade is just an integer that can be used for weighting later on. This is a one-to-one relationship with a proposal vote. A presentation class will use this information to show the results. The vote action will be tampered in order to introduce this gradation in this table. This also depends on the presentation class (that will be coded with different implementations in mind, using a manifest). Note that removing the awesome module will leave the standard decidim voting results and decidim won't be broken.
  • grades_cache: Will be used to cache all the sums from each grade, the count json field could containa a summary of each votes, in this example the "grade" 1 will have 12 votes:
      {
        "1": 12,
        "2": 52,
        "3": 21
      }

image

@microstudi
Copy link
Contributor Author

PR #111

@microstudi microstudi self-assigned this Oct 6, 2023
@microstudi microstudi moved this from In Progress to Done in Weighted voting Oct 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done
Development

No branches or pull requests

2 participants