Commit Graph

4846 Commits

Author SHA1 Message Date
Julian Herrero
1f76b25e2a Show name and email for deleted poll officer's user account
Avoid to raise an exception `Module::DelegationError' when trying to
show the name and/or email of a poll officer whose user account has
been deleted.
We'll show a message "User deleted" and "Email deleted" instead.
2019-06-04 18:55:51 +02:00
Javier Martín
90c1d681d0 Merge pull request #3576 from consul/new_settings
Add new settings automatically on every deployment
2019-06-03 11:54:44 +02:00
Javier Martín
a6c63ac64f Merge pull request #3564 from consul/default_settings
Simplify settings seeds
2019-06-03 11:53:20 +02:00
Alberto
2f8505332e Merge pull request #3574 from consul/remove-dashboard-polls
Allow users to delete dashboard polls
2019-06-01 11:06:34 +02:00
Alberto
8ee396f311 Merge pull request #3573 from consul/improve-ux
Add help texs, links and new message section to improve UX
2019-06-01 10:38:52 +02:00
Javi Martín
e339ed94d1 Add new settings every time we deploy
This way we don't need to add and execute rake tasks every time we add a
new setting.
2019-05-31 19:33:31 +02:00
Javi Martín
ff21ce7665 Use translations for official level names seeds 2019-05-31 19:30:14 +02:00
Raimond Garcia
0d967b2765 Merge pull request #3571 from consul/i18n_available_locales
Add Bosnian, Croatian, Czech, Danish, Greek, and Turkish locales
2019-05-31 19:12:33 +02:00
voodoorai2000
d0b8fef6b3 Delete spending proposals 2019-05-31 18:22:59 +02:00
voodoorai2000
24dde9c35e Delete valuation 2019-05-31 15:43:06 +02:00
Julian Nicolas Herrero
3ba7bd1cab Merge pull request #3567 from consul/select_proposals_by_admins
Make proposals to be selected by administrators
2019-05-31 15:30:39 +02:00
Javier Martín
888c161944 Merge pull request #2616 from consul/show_votes_associated_to_signatures
Show count of votes associated to verified signatures
2019-05-31 15:30:04 +02:00
voodoorai2000
6970e4c8fb Update locale names for Italian, Polish and Albanian 2019-05-31 14:49:38 +02:00
voodoorai2000
78f3cec133 Add Bosnian, Czech, Danish, Greek, Croatian and Turkish locales 2019-05-31 14:49:38 +02:00
Raimond Garcia
2004349cf3 Merge pull request #3378 from consul/i18n_crowdin
Update translations from Crowdin
2019-05-31 13:57:28 +02:00
decabeza
7ed80d7883 Move link to selected proposals on proposals index 2019-05-31 12:24:10 +02:00
decabeza
3855bf26ad Allow users to delete dashboard polls 2019-05-31 11:55:23 +02:00
decabeza
de7b2e8681 Replace name label on dashboard polls form 2019-05-31 11:55:14 +02:00
decabeza
4c5b2723f4 Create new messages section for proposal's dashboard 2019-05-31 11:42:15 +02:00
decabeza
c1d5c7b1b7 Remove send notification proposal from community 2019-05-31 11:41:01 +02:00
decabeza
6b85ed8747 Add show and collapse text on comments tree 2019-05-31 11:40:57 +02:00
decabeza
5fd493cd2c Add link to process on legislation processes proposals 2019-05-31 11:40:48 +02:00
decabeza
b810d6b6b9 Add help text to email and poster proposals settings 2019-05-31 11:40:43 +02:00
decabeza
45329ede9f Rename legislation setting to collaborative legislation 2019-05-31 11:40:23 +02:00
voodoorai2000
b9651bc9b3 Update translations from Crowdin 2019-05-30 20:26:13 +02:00
Bertocq
d9fdc2e0f2 Show votes associated to verified signatures 2019-05-30 18:38:46 +02:00
Javi Martín
6881ee134a Fix valid ballots label
It was incorrectly labeled as "total ballots", which actually meant
"total valid ballots", but users were unsure as to whether include
blank and invalid ballots in that amount.
2019-05-30 17:22:16 +02:00
Julian Herrero
5952c2664d Show a 'Selected proposal' message in the show view 2019-05-30 11:19:38 +02:00
Julian Herrero
db774e3fd2 Extract proposal supports progress bar to a partial 2019-05-30 11:19:38 +02:00
Julian Herrero
b68a872298 Change links for proposals lists
Changed applied:

- Remove Archived proposals from tab and add a link under Proposals
  lists
- Remove Popular proposals link from custom section and add it to the
  Proposals lists
- Remove Retired proposals link from custom section and add it to the
  Proposals lists
- Remove Selected proposals link from custom section and add it to the
  Proposals lists
2019-05-30 11:19:38 +02:00
Julian Herrero
28835a29ef Share helper between class Proposal and Legislation::Proposal 2019-05-30 11:19:38 +02:00
Julian Herrero
ad5f7a06e1 Allow admins to select proposals and users to list them 2019-05-30 11:19:33 +02:00
Alberto
24bab90cff Merge pull request #3539 from consul/hide-token
Remove token on views
2019-05-29 16:28:35 +02:00
decabeza
585f9ea5ab Remove token on views temporally 2019-05-29 15:49:28 +02:00
decabeza
c2acd53a06 Change devise configuration
This change don't let the user know if the email address exists when asking to resend confirmation or password reset instructions.
2019-05-28 14:23:37 +02:00
voodoorai2000
29f5268e42 Display polls for current booth
Polls that were not votable by a user were not being displayed in the officing interface. Creating a confusing situation for officers.

With this commit polls that are not votable by a user will be displayed, with the corresponding message explaining that that poll can only be voted by residents of a certain geozone.
2019-05-24 15:20:54 +02:00
Javier Martín
387488aa68 Merge pull request #3520 from consul/backport-refactor_stats_enabled
Add options to show advanced stats
2019-05-23 13:07:19 +02:00
Javi Martín
45a3d8daf0 Add option to enable advanced stats 2019-05-22 11:50:03 +02:00
Javi Martín
4f4dc2c2af Add show results and stats form to budgets 2019-05-22 11:50:03 +02:00
Javi Martín
354b183e17 Create reports
This table will store which reports (stats, results, ...) will be shown
for a certain process (polls, budgets, ...).

Note Rails fails to save a poll and its report when both are new records
if we add a `validate :process, presence: true` rule. Since it caused a
lot of trouble when creating records for tests during factories rule
completely. Instead, I've created the `results_enabled=` and
`stats_enabled=` methods, so tests are easier to set up, while also
automatically creating a report if it doesn't already exist. This also
decouples form structure and database implemenation.

Originally I named this table `enabled_reports` and instead of having
`stats` and `results` columns, it had an `enabled` column and a `kind`
column, which would be set to "stats" or "results". However, although
that table would allow us to add arbitrary reports easily, I found the
way we had to handle the `has_many` relationship was a bit too complex.
2019-05-22 11:50:03 +02:00
Alberto
ac1d8195f2 Merge pull request #3488 from consul/basic-yml
Admin basic customization texts
2019-05-21 21:43:07 +02:00
Javier Martín
82e3c41aa9 Merge pull request #3512 from consul/backport-stats
Change stats layout
2019-05-21 17:18:47 +02:00
decabeza
a2cb7501f7 Create new basic tab for admin information texts 2019-05-21 14:06:58 +02:00
Javi Martín
13dd77dd1b Add tasks to generate and expire stats cache
We're generating stats every 2 hours because it's less than the time it
will take to generate stats for every process. Once stats are generated,
this task should take less than a second.

The regenerate task has been added so we can manually execute it.
2019-05-21 13:50:19 +02:00
Javi Martín
944bd2d418 Don't capitalize common nouns 2019-05-21 13:50:19 +02:00
Javi Martín
66ecb2835b Show only available budget stats phases
This way we can show statistics for the supports phase before the vote
phase is over.
2019-05-21 13:50:18 +02:00
Javi Martín
e146fafb60 Only show "no demographic data" when necessary
If there's demographic data for all participants, it doesn't make sense
to show the message.

We're using translations instead of an `if` in the view because the text
is also different when there's only one participant. In some languages
the text might also be different depending on how many people with no
demographic data participated.

Another possibility would be to use an `if` in the view so we don't
display an empty paragraph when the cont is zero, and then using
translation for `one` and `other`. I haven't gone that way because I
thought the logic would be more complex and the benefits wouldn't be
that great.
2019-05-21 13:50:18 +02:00
Javi Martín
ae4cd06c24 Include no geozone in no demographic data 2019-05-21 13:50:18 +02:00
Javi Martín
558070d530 Remove geozone participation percentage
We currently don't store geozone population.
2019-05-21 13:50:18 +02:00
Javi Martín
4843959c7d Use poll voters valid origins as stats channels
They're the same thing, and duplicating them led into a typo saying
"mail" instead of "letter".
2019-05-21 13:50:18 +02:00