Adds Maximum amount of yes votes to polls#6309
Open
potatojuicemachine wants to merge 10 commits into
Open
Conversation
* implement new data model * uncommment/remove old code * create approval/selection vote method things * add new `translationKey` pipe
* Display special state for finished + published * Hide single poll projection if not available * Remove hasVoted from view model * fix autoupdate subscription for voting not closed OpenSlides#5425 * Add topic approval votes
* Fix score vote per option amount validation * Use total ballots from result * Fix approval result chart * Poll ballot papers * Add result display option to poll form * Cleanup poll detail views * Fix single votes list sometimes empty * Fix model subscriptions for detail view * Fix wrong delegations displayed in poll detail * Display votes in detail view * Use short name for poll options * Update motion/topic/assignemnt poll components to signal api * Update permissions * Remove unused components * Add parsedValue to ballots * Poll form validation
* Add new poll permissions to settings * Update progress bar permission check * Update permission check for displaying results * Vote form validation * Remove `allow_abstain` from rating score * Respect cumulative voting setting * Update onehundredpercent base on approval votes * Fix poll detail layout * Add general abstain option in poll forms * Allow cumulative voting for single candidate election
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds the maximum amount of yes votes to the frontend.
This PR depends on this PR: OpenSlides/openslides-backend#3623
This PR related to this overarching PR: OpenSlides/OpenSlides#7134
This is how the creation of a poll looks:

The maximum amount of yes votes will only appear if the user selects YN or YNA voting. I am not entirely sure if I like the current style by just inserting it into the current grid, but I also didn't want to rework the grid system.
This is how the ballot information looks like:

This is how the ballot looks like if the maximum amount of yes votes is reached:

To get this functionallity I introduced a system to disable individual vote buttons (isActionButtonDisabled).
When I first implemented this when disabled, the buttons had a alternating color. I disabled this in the global-components-style.scss. Not sure if this is the preffered way.
This PR allows for but doesn't add translations.