decidim-elections 0.23.1 → 0.24.0.rc2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/app/assets/config/admin/decidim_votings_manifest.css +0 -0
- data/app/assets/config/admin/decidim_votings_manifest.js +4 -0
- data/app/assets/config/decidim_elections_manifest.css +3 -0
- data/app/assets/config/decidim_elections_manifest.js +6 -0
- data/app/assets/config/decidim_votings_manifest.css +3 -0
- data/app/assets/config/decidim_votings_manifest.js +0 -0
- data/app/assets/images/decidim/votings/icon.svg +1 -0
- data/app/assets/javascripts/decidim/elections/admin/pending_action.js.es6 +16 -0
- data/app/assets/javascripts/decidim/elections/admin/vote_statistics.js.es6 +11 -0
- data/app/assets/javascripts/decidim/elections/trustee_zone.js.es6 +54 -0
- data/app/assets/javascripts/decidim/elections/trustee_zone/key_ceremony.js.es6 +126 -0
- data/app/assets/javascripts/decidim/elections/trustee_zone/tally.js.es6 +104 -0
- data/app/assets/javascripts/decidim/elections/vote.js.es6 +107 -160
- data/app/assets/javascripts/decidim/elections/vote_questions.component.js.es6 +129 -0
- data/app/assets/javascripts/decidim/elections/vote_verify.js.es6 +71 -0
- data/app/assets/javascripts/decidim/votings/admin/monitoring_committee_members_form.js.es6 +35 -0
- data/app/assets/javascripts/decidim/votings/admin/polling_officers_form.js.es6 +35 -0
- data/app/assets/javascripts/decidim/votings/admin/polling_officers_picker.js.es6 +35 -0
- data/app/assets/javascripts/decidim/votings/admin/polling_stations_form.js.es6 +5 -0
- data/app/assets/stylesheets/decidim/elections/elections.scss +0 -4
- data/app/assets/stylesheets/decidim/elections/focus/_accordion.scss +36 -0
- data/app/assets/stylesheets/decidim/elections/focus/_evote.scss +58 -0
- data/app/assets/stylesheets/decidim/elections/trustee_zone.scss +24 -0
- data/app/assets/stylesheets/decidim/votings/votings.scss +1 -0
- data/app/assets/stylesheets/decidim/votings/votings/_votings-header.scss +99 -0
- data/app/assets/stylesheets/decidim/votings/votings/_votings-home-banner.scss +11 -0
- data/app/cells/decidim/votings/content_block_cell.rb +17 -0
- data/app/cells/decidim/votings/content_blocks/highlighted_votings/show.erb +30 -0
- data/app/cells/decidim/votings/content_blocks/highlighted_votings_cell.rb +33 -0
- data/app/cells/decidim/votings/content_blocks/highlighted_votings_settings_form/show.erb +3 -0
- data/app/cells/decidim/votings/content_blocks/highlighted_votings_settings_form_cell.rb +19 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/attachments_and_folders_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/description_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/elections_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/header_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/metrics_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/polling_stations_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/stats_cell.rb +15 -0
- data/app/cells/decidim/votings/content_blocks/landing_page/timeline_cell.rb +15 -0
- data/app/cells/decidim/votings/polling_officers/polling_officers_picker/polling_officers.erb +12 -0
- data/app/cells/decidim/votings/polling_officers/polling_officers_picker/show.erb +14 -0
- data/app/cells/decidim/votings/polling_officers/polling_officers_picker_cell.rb +73 -0
- data/app/cells/decidim/votings/voting_cell.rb +19 -0
- data/app/cells/decidim/votings/voting_m/data.erb +21 -0
- data/app/cells/decidim/votings/voting_m/footer.erb +5 -0
- data/app/cells/decidim/votings/voting_m_cell.rb +94 -0
- data/app/commands/decidim/elections/admin/add_user_as_trustee.rb +81 -0
- data/app/commands/decidim/elections/admin/create_election.rb +2 -1
- data/app/commands/decidim/elections/admin/end_vote.rb +63 -0
- data/app/commands/decidim/elections/admin/publish_results.rb +59 -0
- data/app/commands/decidim/elections/admin/remove_trustee_from_participatory_space.rb +37 -0
- data/app/commands/decidim/elections/admin/setup_election.rb +160 -0
- data/app/commands/decidim/elections/admin/start_key_ceremony.rb +63 -0
- data/app/commands/decidim/elections/admin/start_tally.rb +63 -0
- data/app/commands/decidim/elections/admin/start_vote.rb +63 -0
- data/app/commands/decidim/elections/admin/update_action_status.rb +47 -0
- data/app/commands/decidim/elections/admin/update_answer_selection.rb +41 -0
- data/app/commands/decidim/elections/admin/update_trustee_participatory_space.rb +40 -0
- data/app/commands/decidim/elections/trustee_zone/update_election_bulletin_board_status.rb +39 -0
- data/app/commands/decidim/elections/trustee_zone/update_trustee.rb +41 -0
- data/app/commands/decidim/elections/voter/cast_vote.rb +59 -0
- data/app/commands/decidim/elections/voter/update_vote_status.rb +70 -0
- data/app/commands/decidim/votings/admin/create_monitoring_committee_member.rb +99 -0
- data/app/commands/decidim/votings/admin/create_polling_officer.rb +99 -0
- data/app/commands/decidim/votings/admin/create_polling_station.rb +59 -0
- data/app/commands/decidim/votings/admin/create_voting.rb +59 -0
- data/app/commands/decidim/votings/admin/destroy_monitoring_committee_member.rb +51 -0
- data/app/commands/decidim/votings/admin/destroy_polling_officer.rb +52 -0
- data/app/commands/decidim/votings/admin/destroy_polling_station.rb +40 -0
- data/app/commands/decidim/votings/admin/manage_polling_station.rb +64 -0
- data/app/commands/decidim/votings/admin/publish_voting.rb +40 -0
- data/app/commands/decidim/votings/admin/unpublish_voting.rb +40 -0
- data/app/commands/decidim/votings/admin/update_polling_station.rb +50 -0
- data/app/commands/decidim/votings/admin/update_voting.rb +85 -0
- data/app/constraints/decidim/votings/current_component.rb +28 -0
- data/app/constraints/decidim/votings/current_voting.rb +43 -0
- data/app/controllers/concerns/decidim/elections/orderable.rb +2 -2
- data/app/controllers/concerns/decidim/polling_officers/admin/filterable.rb +58 -0
- data/app/controllers/concerns/decidim/polling_stations/admin/filterable.rb +57 -0
- data/app/controllers/concerns/decidim/votings/admin/filterable.rb +27 -0
- data/app/controllers/concerns/decidim/votings/admin/voting_admin.rb +48 -0
- data/app/controllers/concerns/decidim/votings/needs_voting.rb +44 -0
- data/app/controllers/concerns/decidim/votings/orderable.rb +32 -0
- data/app/controllers/decidim/elections/admin/answers_controller.rb +32 -0
- data/app/controllers/decidim/elections/admin/elections_controller.rb +2 -2
- data/app/controllers/decidim/elections/admin/feedback_forms_controller.rb +55 -0
- data/app/controllers/decidim/elections/admin/steps_controller.rb +96 -0
- data/app/controllers/decidim/elections/admin/trustees_participatory_spaces_controller.rb +89 -0
- data/app/controllers/decidim/elections/elections_controller.rb +5 -1
- data/app/controllers/decidim/elections/feedbacks_controller.rb +38 -0
- data/app/controllers/decidim/elections/trustee_zone/application_controller.rb +45 -0
- data/app/controllers/decidim/elections/trustee_zone/elections_controller.rb +35 -0
- data/app/controllers/decidim/elections/trustee_zone/trustees_controller.rb +36 -0
- data/app/controllers/decidim/elections/votes_controller.rb +54 -2
- data/app/controllers/decidim/votings/admin/application_controller.rb +26 -0
- data/app/controllers/decidim/votings/admin/component_permissions_controller.rb +13 -0
- data/app/controllers/decidim/votings/admin/components_controller.rb +15 -0
- data/app/controllers/decidim/votings/admin/monitoring_committee_members_controller.rb +62 -0
- data/app/controllers/decidim/votings/admin/polling_officers_controller.rb +66 -0
- data/app/controllers/decidim/votings/admin/polling_stations_controller.rb +92 -0
- data/app/controllers/decidim/votings/admin/voting_attachment_collections_controller.rb +22 -0
- data/app/controllers/decidim/votings/admin/voting_attachments_controller.rb +21 -0
- data/app/controllers/decidim/votings/admin/votings_controller.rb +124 -0
- data/app/controllers/decidim/votings/admin/votings_landing_page_content_blocks_controller.rb +44 -0
- data/app/controllers/decidim/votings/admin/votings_landing_page_controller.rb +46 -0
- data/app/controllers/decidim/votings/application_controller.rb +26 -0
- data/app/controllers/decidim/votings/polling_officer_zone/application_controller.rb +33 -0
- data/app/controllers/decidim/votings/polling_officer_zone/polling_officers_controller.rb +17 -0
- data/app/controllers/decidim/votings/polling_officer_zone/polling_stations_controller.rb +22 -0
- data/app/controllers/decidim/votings/votings_controller.rb +98 -0
- data/app/events/decidim/elections/trustees/notify_new_trustee_event.rb +28 -0
- data/app/events/decidim/elections/trustees/notify_trustee_new_election_event.rb +14 -0
- data/app/events/decidim/elections/votes/vote_accepted_event.rb +24 -0
- data/app/events/decidim/votings/polling_officers/polling_station_assigned_event.rb +44 -0
- data/app/forms/decidim/elections/admin/action_form.rb +34 -0
- data/app/forms/decidim/elections/admin/answer_form.rb +3 -2
- data/app/forms/decidim/elections/admin/election_form.rb +3 -2
- data/app/forms/decidim/elections/admin/setup_form.rb +79 -0
- data/app/forms/decidim/elections/admin/trustees_participatory_space_form.rb +22 -0
- data/app/forms/decidim/elections/admin/vote_period_form.rb +37 -0
- data/app/forms/decidim/elections/ballot/verify_vote_form.rb +29 -0
- data/app/forms/decidim/elections/trustee_zone/trustee_form.rb +26 -0
- data/app/forms/decidim/elections/voter/encrypted_vote_form.rb +49 -0
- data/app/forms/decidim/votings/admin/monitoring_committee_member_form.rb +27 -0
- data/app/forms/decidim/votings/admin/polling_officer_form.rb +27 -0
- data/app/forms/decidim/votings/admin/polling_station_form.rb +58 -0
- data/app/forms/decidim/votings/admin/voting_form.rb +71 -0
- data/app/helpers/decidim/elections/admin/answers_helper.rb +19 -0
- data/app/helpers/decidim/elections/admin/steps_helper.rb +23 -0
- data/app/helpers/decidim/elections/admin/trustees_participatory_spaces_helper.rb +31 -0
- data/app/helpers/decidim/elections/elections_helper.rb +29 -0
- data/app/helpers/decidim/votings/admin/polling_officers_picker_helper.rb +29 -0
- data/app/helpers/decidim/votings/votings_helper.rb +20 -0
- data/app/models/decidim/elections/action.rb +13 -0
- data/app/models/decidim/elections/election.rb +54 -3
- data/app/models/decidim/elections/elections_trustee.rb +11 -0
- data/app/models/decidim/elections/question.rb +19 -0
- data/app/models/decidim/elections/trustee.rb +26 -0
- data/app/models/decidim/elections/trustees_participatory_space.rb +13 -0
- data/app/models/decidim/elections/vote.rb +15 -0
- data/app/models/decidim/votings/monitoring_committee_member.rb +24 -0
- data/app/models/decidim/votings/polling_officer.rb +76 -0
- data/app/models/decidim/votings/polling_station.rb +64 -0
- data/app/models/decidim/votings/voting.rb +138 -0
- data/app/permissions/decidim/elections/admin/permissions.rb +50 -10
- data/app/permissions/decidim/elections/permissions.rb +20 -2
- data/app/permissions/decidim/elections/trustee_zone/permissions.rb +32 -0
- data/app/permissions/decidim/votings/admin/permissions.rb +127 -0
- data/app/permissions/decidim/votings/permissions.rb +40 -0
- data/app/permissions/decidim/votings/polling_officer_zone/permissions.rb +32 -0
- data/app/presenters/decidim/elections/admin_log/election_presenter.rb +1 -1
- data/app/presenters/decidim/elections/trustee_presenter.rb +24 -0
- data/app/presenters/decidim/votings/admin_log/voting_presenter.rb +45 -0
- data/app/presenters/decidim/votings/polling_station_presenter.rb +27 -0
- data/app/presenters/decidim/votings/voting_presenter.rb +36 -0
- data/app/queries/decidim/elections/admin/pending_actions.rb +20 -0
- data/app/queries/decidim/elections/admin/votes_for_statistics.rb +24 -0
- data/app/queries/decidim/elections/elections_finished_to_end.rb +19 -0
- data/app/queries/decidim/elections/elections_ready_to_start.rb +25 -0
- data/app/queries/decidim/elections/trustees/by_participatory_space.rb +24 -0
- data/app/queries/decidim/elections/trustees/by_participatory_space_trustee_ids.rb +24 -0
- data/app/queries/decidim/elections/votes/election_votes.rb +19 -0
- data/app/queries/decidim/elections/votes/pending_votes.rb +20 -0
- data/app/queries/decidim/elections/votes/user_election_last_vote.rb +26 -0
- data/app/queries/decidim/elections/votes/user_votes.rb +19 -0
- data/app/queries/decidim/votings/admin/admin_users.rb +39 -0
- data/app/queries/decidim/votings/admin/polling_officers_join_polling_stations.rb +33 -0
- data/app/queries/decidim/votings/admin/polling_officers_join_polling_stations_and_user.rb +34 -0
- data/app/queries/decidim/votings/admin/polling_officers_join_user.rb +32 -0
- data/app/queries/decidim/votings/organization_prioritized_votings.rb +21 -0
- data/app/queries/decidim/votings/organization_promoted_votings.rb +16 -0
- data/app/queries/decidim/votings/organization_published_votings.rb +19 -0
- data/app/queries/decidim/votings/organization_votings.rb +16 -0
- data/app/queries/decidim/votings/prioritized_votings.rb +13 -0
- data/app/queries/decidim/votings/published_votings.rb +12 -0
- data/app/services/decidim/votings/voting_search.rb +46 -0
- data/app/views/decidim/elections/admin/answers/index.html.erb +12 -0
- data/app/views/decidim/elections/admin/elections/index.html.erb +13 -1
- data/app/views/decidim/elections/admin/proposals_imports/new.html.erb +1 -1
- data/app/views/decidim/elections/admin/questions/index.html.erb +5 -1
- data/app/views/decidim/elections/admin/shared/_trustees_secondary_nav.html.erb +3 -0
- data/app/views/decidim/elections/admin/steps/_create_election.html.erb +38 -0
- data/app/views/decidim/elections/admin/steps/_created.html.erb +16 -0
- data/app/views/decidim/elections/admin/steps/_key_ceremony.html.erb +16 -0
- data/app/views/decidim/elections/admin/steps/_key_ceremony_ended.html.erb +15 -0
- data/app/views/decidim/elections/admin/steps/_tally.html.erb +17 -0
- data/app/views/decidim/elections/admin/steps/_tally_ended.html.erb +9 -0
- data/app/views/decidim/elections/admin/steps/_vote.html.erb +21 -0
- data/app/views/decidim/elections/admin/steps/_vote_ended.html.erb +15 -0
- data/app/views/decidim/elections/admin/steps/_vote_stats.html.erb +31 -0
- data/app/views/decidim/elections/admin/steps/index.html.erb +43 -0
- data/app/views/decidim/elections/admin/trustees_participatory_spaces/_form.html.erb +19 -0
- data/app/views/decidim/elections/admin/trustees_participatory_spaces/index.html.erb +64 -0
- data/app/views/decidim/elections/admin/trustees_participatory_spaces/new.html.erb +7 -0
- data/app/views/decidim/elections/elections/_filters_small_view.html.erb +1 -1
- data/app/views/decidim/elections/elections/_preview.html.erb +26 -0
- data/app/views/decidim/elections/elections/_results.html.erb +47 -0
- data/app/views/decidim/elections/elections/show.html.erb +39 -12
- data/app/views/decidim/elections/trustee_zone/elections/_backup_modal.html.erb +24 -0
- data/app/views/decidim/elections/trustee_zone/elections/_key_ceremony_steps.html.erb +44 -0
- data/app/views/decidim/elections/trustee_zone/elections/_restore_modal.html.erb +25 -0
- data/app/views/decidim/elections/trustee_zone/elections/_tally_steps.html.erb +43 -0
- data/app/views/decidim/elections/trustee_zone/elections/show.html.erb +38 -0
- data/app/views/decidim/elections/trustee_zone/elections/update.js.erb +5 -0
- data/app/views/decidim/elections/trustee_zone/trustees/show.html.erb +102 -0
- data/app/views/decidim/elections/votes/_election_votes_confirmed.html.erb +38 -17
- data/app/views/decidim/elections/votes/_election_votes_failed.html.erb +21 -0
- data/app/views/decidim/elections/votes/_election_votes_question.html.erb +4 -4
- data/app/views/decidim/elections/votes/cast_failed.js.erb +1 -0
- data/app/views/decidim/elections/votes/cast_success.js.erb +1 -0
- data/app/views/decidim/elections/votes/new.html.erb +41 -33
- data/app/views/decidim/elections/votes/verify.html.erb +78 -0
- data/app/views/decidim/votings/admin/monitoring_committee_members/_form.html.erb +27 -0
- data/app/views/decidim/votings/admin/monitoring_committee_members/index.html.erb +41 -0
- data/app/views/decidim/votings/admin/monitoring_committee_members/new.html.erb +7 -0
- data/app/views/decidim/votings/admin/polling_officers/_form.html.erb +27 -0
- data/app/views/decidim/votings/admin/polling_officers/index.html.erb +50 -0
- data/app/views/decidim/votings/admin/polling_officers/new.html.erb +7 -0
- data/app/views/decidim/votings/admin/polling_stations/_form.html.erb +40 -0
- data/app/views/decidim/votings/admin/polling_stations/edit.html.erb +7 -0
- data/app/views/decidim/votings/admin/polling_stations/index.html.erb +55 -0
- data/app/views/decidim/votings/admin/polling_stations/new.html.erb +7 -0
- data/app/views/decidim/votings/admin/votings/_form.html.erb +63 -0
- data/app/views/decidim/votings/admin/votings/edit.html.erb +31 -0
- data/app/views/decidim/votings/admin/votings/index.html.erb +87 -0
- data/app/views/decidim/votings/admin/votings/new.html.erb +13 -0
- data/app/views/decidim/votings/admin/votings/polling_officers_picker.html.erb +2 -0
- data/app/views/decidim/votings/polling_officer_zone/polling_officers/show.html.erb +42 -0
- data/app/views/decidim/votings/polling_officer_zone/polling_stations/show.html.erb +1 -0
- data/app/views/decidim/votings/votings/_count.html.erb +1 -0
- data/app/views/decidim/votings/votings/_filters.html.erb +25 -0
- data/app/views/decidim/votings/votings/_filters_small_view.html.erb +23 -0
- data/app/views/decidim/votings/votings/_promoted_voting.html.erb +27 -0
- data/app/views/decidim/votings/votings/_voting_details.html.erb +7 -0
- data/app/views/decidim/votings/votings/_votings.html.erb +25 -0
- data/app/views/decidim/votings/votings/index.html.erb +42 -0
- data/app/views/decidim/votings/votings/index.js.erb +10 -0
- data/app/views/decidim/votings/votings/show.html.erb +20 -0
- data/app/views/layouts/decidim/_voting_header.html.erb +16 -0
- data/app/views/layouts/decidim/admin/voting.html.erb +101 -0
- data/app/views/layouts/decidim/voting.html.erb +16 -0
- data/config/initializers/decidim_bulletin_board.rb +23 -0
- data/config/locales/ca.yml +635 -6
- data/config/locales/cs.yml +635 -6
- data/config/locales/de.yml +677 -10
- data/config/locales/el.yml +4 -2
- data/config/locales/en.yml +636 -6
- data/config/locales/es-MX.yml +636 -7
- data/config/locales/es-PY.yml +636 -7
- data/config/locales/es.yml +636 -7
- data/config/locales/fi-plain.yml +636 -7
- data/config/locales/fi.yml +637 -8
- data/config/locales/fr-CA.yml +419 -6
- data/config/locales/fr.yml +419 -6
- data/config/locales/gl.yml +168 -0
- data/config/locales/it.yml +108 -6
- data/config/locales/ja.yml +12 -6
- data/config/locales/lv.yml +4 -2
- data/config/locales/nl.yml +502 -6
- data/config/locales/no.yml +0 -6
- data/config/locales/pl.yml +657 -9
- data/config/locales/pt.yml +4 -6
- data/config/locales/ro-RO.yml +4 -6
- data/config/locales/si-LK.yml +1 -0
- data/config/locales/sv.yml +11 -6
- data/config/locales/sw-KE.yml +1 -0
- data/config/locales/tr-TR.yml +366 -0
- data/config/locales/zh-CN.yml +4 -6
- data/db/migrate/20200915142713_add_questionnaire_to_existing_elections.rb +29 -0
- data/db/migrate/20200918153813_create_decidim_elections_trustees_participatory_spaces.rb +13 -0
- data/db/migrate/20200918153824_create_decidim_elections_elections_trustees.rb +10 -0
- data/db/migrate/20200918153835_create_decidim_elections_trustees.rb +12 -0
- data/db/migrate/20201026163334_add_blocked_at_and_bb_status_to_elections.rb +8 -0
- data/db/migrate/20201028090110_add_votes_to_decidim_elections_answers.rb +7 -0
- data/db/migrate/20201028135614_add_selected_to_decidim_elections_answers.rb +7 -0
- data/db/migrate/20201209110653_create_decidim_elections_votes.rb +14 -0
- data/db/migrate/20201216091123_add_name_to_trustees.rb +7 -0
- data/db/migrate/20210113113818_add_message_id_to_decidim_elections_votes.rb +7 -0
- data/db/migrate/20210113120115_create_decidim_elections_votings.rb +20 -0
- data/db/migrate/20210114100749_add_published_at_to_decidim_votings_votings.rb +7 -0
- data/db/migrate/20210114111850_add_user_to_decidim_elections_votes.rb +7 -0
- data/db/migrate/20210120164634_add_promoted_to_voting.rb +7 -0
- data/db/migrate/20210125124801_add_voting_type_to_voting_voting.rb +7 -0
- data/db/migrate/20210129124956_create_decidim_elections_actions.rb +14 -0
- data/db/migrate/20210204132111_add_votings_polling_stations.rb +19 -0
- data/db/migrate/20210208090441_add_polling_officers_to_votings.rb +12 -0
- data/db/migrate/20210210090738_add_votings_polling_station_references_to_votings_polling_officer.rb +8 -0
- data/db/migrate/20210216074707_add_monitoring_committee_member.rb +12 -0
- data/db/seeds/city.jpeg +0 -0
- data/lib/decidim/api/election_answer_type.rb +23 -0
- data/lib/decidim/api/election_question_type.rb +22 -0
- data/lib/decidim/api/election_type.rb +27 -0
- data/lib/decidim/api/elections_type.rb +32 -0
- data/lib/decidim/api/trustee_type.rb +16 -0
- data/lib/decidim/api/voting_type.rb +20 -0
- data/lib/decidim/elections.rb +19 -2
- data/lib/decidim/elections/admin_engine.rb +42 -1
- data/lib/decidim/elections/answer_serializer.rb +48 -0
- data/lib/decidim/elections/api.rb +11 -0
- data/lib/decidim/elections/component.rb +367 -24
- data/lib/decidim/elections/engine.rb +8 -1
- data/lib/decidim/elections/test/factories.rb +201 -4
- data/lib/decidim/elections/trustee_zone.rb +10 -0
- data/lib/decidim/elections/trustee_zone_engine.rb +35 -0
- data/lib/decidim/elections/version.rb +1 -1
- data/lib/decidim/votings.rb +16 -0
- data/lib/decidim/votings/admin.rb +10 -0
- data/lib/decidim/votings/admin_engine.rb +71 -0
- data/lib/decidim/votings/api.rb +7 -0
- data/lib/decidim/votings/engine.rb +147 -0
- data/lib/decidim/votings/participatory_space.rb +92 -0
- data/lib/decidim/votings/polling_officer_zone.rb +10 -0
- data/lib/decidim/votings/polling_officer_zone_engine.rb +33 -0
- data/lib/decidim/votings/query_extensions.rb +43 -0
- data/lib/decidim/votings/test/capybara_polling_officers_picker.rb +49 -0
- data/lib/decidim/votings/test/factories.rb +83 -0
- data/lib/decidim/votings/voting_serializer.rb +54 -0
- data/lib/tasks/decidim_elections.rake +68 -5
- metadata +309 -24
- data/app/types/decidim/elections/election_answer_type.rb +0 -24
- data/app/types/decidim/elections/election_question_type.rb +0 -25
- data/app/types/decidim/elections/election_type.rb +0 -27
- data/app/types/decidim/elections/elections_type.rb +0 -32
- data/config/i18n-tasks.yml +0 -10
- data/lib/decidim/elections/bulletin_board_client.rb +0 -35
data/config/locales/gl.yml
CHANGED
@@ -1 +1,169 @@
|
|
1
1
|
gl:
|
2
|
+
activemodel:
|
3
|
+
attributes:
|
4
|
+
answer:
|
5
|
+
description: Descrición
|
6
|
+
image: Imaxe
|
7
|
+
proposals: Propostas relacionadas
|
8
|
+
title: Título
|
9
|
+
election:
|
10
|
+
description: Descrición
|
11
|
+
end_time: A votación remata ás
|
12
|
+
start_time: A votación comeza ás
|
13
|
+
title: Título
|
14
|
+
question:
|
15
|
+
description: Descrición
|
16
|
+
title: Título
|
17
|
+
activerecord:
|
18
|
+
models:
|
19
|
+
decidim/elections/answer:
|
20
|
+
one: Resposta
|
21
|
+
other: Respostas
|
22
|
+
decidim/elections/question:
|
23
|
+
one: Pregunta
|
24
|
+
other: Preguntas
|
25
|
+
decidim/votings/voting:
|
26
|
+
one: Votación
|
27
|
+
other: Votacións
|
28
|
+
decidim:
|
29
|
+
components:
|
30
|
+
elections:
|
31
|
+
actions:
|
32
|
+
vote: Votar
|
33
|
+
elections:
|
34
|
+
actions:
|
35
|
+
confirm_destroy: Estás certo/a?
|
36
|
+
edit: Editar
|
37
|
+
manage_answers: Xestionar respostas
|
38
|
+
manage_questions: Xestionar preguntas
|
39
|
+
manage_steps: Xestionar pasos
|
40
|
+
new: Nova %{name}
|
41
|
+
publish: Publicar
|
42
|
+
title: Accións
|
43
|
+
admin:
|
44
|
+
answers:
|
45
|
+
edit:
|
46
|
+
title: Editar resposta
|
47
|
+
update: Actualizar resposta
|
48
|
+
index:
|
49
|
+
title: Respostas
|
50
|
+
new:
|
51
|
+
create: Crear resposta
|
52
|
+
title: Nova resposta
|
53
|
+
models:
|
54
|
+
answer:
|
55
|
+
name: Resposta
|
56
|
+
question:
|
57
|
+
name: Pregunta
|
58
|
+
questions:
|
59
|
+
edit:
|
60
|
+
title: Editar pregunta
|
61
|
+
update: Actualizar pregunta
|
62
|
+
index:
|
63
|
+
title: Preguntas
|
64
|
+
new:
|
65
|
+
create: Crear pregunta
|
66
|
+
title: Nova pregunta
|
67
|
+
steps:
|
68
|
+
create_election:
|
69
|
+
errors:
|
70
|
+
minimum_answers: As preguntas teñen de ter <strong>polo menos dúas respostas</strong>.
|
71
|
+
not_used_trustee: "(non usada)"
|
72
|
+
election_m:
|
73
|
+
badge_name:
|
74
|
+
finished: Finalizada
|
75
|
+
ongoing: Activa
|
76
|
+
upcoming: Vindeiras
|
77
|
+
footer:
|
78
|
+
view: Ver
|
79
|
+
vote: Votar
|
80
|
+
label:
|
81
|
+
date: Datas
|
82
|
+
questions: Preguntas %{count}
|
83
|
+
unspecified: Sen especificar
|
84
|
+
elections:
|
85
|
+
filters:
|
86
|
+
active: Activa
|
87
|
+
all: Todas
|
88
|
+
finished: Finalizada
|
89
|
+
search: Procurar
|
90
|
+
state: Estado
|
91
|
+
upcoming: Vindeiras
|
92
|
+
filters_small_view:
|
93
|
+
close_modal: Pechar modal
|
94
|
+
filter: Filtrar
|
95
|
+
filter_by: Filtrar por
|
96
|
+
preview:
|
97
|
+
available_answers: Respostas dispoñibles
|
98
|
+
results:
|
99
|
+
selected: Seleccionado
|
100
|
+
models:
|
101
|
+
answer:
|
102
|
+
fields:
|
103
|
+
title: Título
|
104
|
+
election:
|
105
|
+
fields:
|
106
|
+
title: Título
|
107
|
+
question:
|
108
|
+
fields:
|
109
|
+
answers: Respostas
|
110
|
+
title: Título
|
111
|
+
trustees_participatory_space:
|
112
|
+
fields:
|
113
|
+
inactive: inactivo
|
114
|
+
trustee_zone:
|
115
|
+
elections:
|
116
|
+
key_ceremony_steps:
|
117
|
+
back: Volver
|
118
|
+
list:
|
119
|
+
status: Estado
|
120
|
+
task: Tarefa
|
121
|
+
start: Comezar
|
122
|
+
status:
|
123
|
+
pending: Pendente
|
124
|
+
processing: Procesando
|
125
|
+
trustees:
|
126
|
+
show:
|
127
|
+
elections:
|
128
|
+
list:
|
129
|
+
action_required:
|
130
|
+
'false': 'Non'
|
131
|
+
name: Acción requirida?
|
132
|
+
bb_status: Estado
|
133
|
+
identification_keys:
|
134
|
+
submit: Enviar
|
135
|
+
votes:
|
136
|
+
confirmed:
|
137
|
+
error: Sentímolo, produciuse un erro confirmando o voto. Por favor, vota de novo.
|
138
|
+
experience: Como valoras a túa experiencia?
|
139
|
+
feedback: Dános a túa opinión
|
140
|
+
header: Voto confirmado
|
141
|
+
header:
|
142
|
+
confirm: Confirma o teu voto
|
143
|
+
confirmed: Voto confirmado
|
144
|
+
encrypting: Confirmando o voto
|
145
|
+
modal:
|
146
|
+
close: Pechar
|
147
|
+
update:
|
148
|
+
error: Produciuse un problema ao actualizar o estado do voto
|
149
|
+
success: Estado do voto actualizado con éxito
|
150
|
+
events:
|
151
|
+
elections:
|
152
|
+
votes:
|
153
|
+
accepted_votes:
|
154
|
+
email_intro: 'O teu voto foi aceptado! Empregando o teu token de votación: %{encrypted_vote_hash}, podes verificar o teu voto <a href="%{verify_url}">aquí</a>.'
|
155
|
+
email_outro: Recibiches esta notificación porque votaches pola elección de %{resource_name}.
|
156
|
+
email_subject: O teu voto por %{resource_name} foi aceptado.
|
157
|
+
notification_title: 'O teu voto foi aceptado, verifícao <a href="%{verify_url}">aquí</a> empregando o teu token de votación: %{encrypted_vote_hash}'
|
158
|
+
votings:
|
159
|
+
admin:
|
160
|
+
menu:
|
161
|
+
votings_submenu:
|
162
|
+
components: Compoñentes
|
163
|
+
votings:
|
164
|
+
form:
|
165
|
+
select_a_voting_type: Por favor, selecciona un tipo de votación
|
166
|
+
voting_type:
|
167
|
+
hybrid: Híbrido
|
168
|
+
in_person: En persoa
|
169
|
+
online: En liña
|
data/config/locales/it.yml
CHANGED
@@ -22,6 +22,16 @@ it:
|
|
22
22
|
attributes:
|
23
23
|
attachment:
|
24
24
|
needs_to_be_reattached: Necessita di essere riallegato
|
25
|
+
election:
|
26
|
+
attributes:
|
27
|
+
attachment:
|
28
|
+
needs_to_be_reattached: Necessita di essere riallegato
|
29
|
+
trustee:
|
30
|
+
attributes:
|
31
|
+
name:
|
32
|
+
cant_be_changed: non modificabile
|
33
|
+
public_key:
|
34
|
+
cant_be_changed: non modificabile
|
25
35
|
activerecord:
|
26
36
|
models:
|
27
37
|
decidim/elections/answer:
|
@@ -33,6 +43,9 @@ it:
|
|
33
43
|
decidim/elections/question:
|
34
44
|
one: Domanda
|
35
45
|
other: Domande
|
46
|
+
decidim/votings/voting:
|
47
|
+
one: Votazione
|
48
|
+
other: Votazioni
|
36
49
|
decidim:
|
37
50
|
components:
|
38
51
|
elections:
|
@@ -49,9 +62,11 @@ it:
|
|
49
62
|
confirm_destroy: Sei sicuro?
|
50
63
|
destroy: Elimina
|
51
64
|
edit: Modifica
|
52
|
-
|
53
|
-
edit_questions: Modifica domanda
|
65
|
+
feedback: Feedback del votante
|
54
66
|
import: Importa proposte in risposte
|
67
|
+
manage_answers: Gestisci le risposte
|
68
|
+
manage_questions: Gestisci i quesiti
|
69
|
+
manage_steps: Gestisci passaggi
|
55
70
|
new: Nuovo %{name}
|
56
71
|
preview: Anteprima
|
57
72
|
publish: Pubblica
|
@@ -69,10 +84,19 @@ it:
|
|
69
84
|
title: Modifica risposta
|
70
85
|
update: Aggiorna risposta
|
71
86
|
index:
|
87
|
+
invalid_max_selections: Hai bisogno di %{missing_answers} altre risposte per scegliere le selezioni massime
|
72
88
|
title: Risposte
|
73
89
|
new:
|
74
90
|
create: Crea risposta
|
75
91
|
title: Nuova risposta
|
92
|
+
select:
|
93
|
+
disable: Deseleziona la risposta
|
94
|
+
enable: Segna la risposta come selezionata
|
95
|
+
invalid: Si è verificato un problema durante la selezione di questa risposta
|
96
|
+
success: Risposta selezionata con successo
|
97
|
+
unselect:
|
98
|
+
invalid: Si è verificato un problema deselezionazionando questa risposta
|
99
|
+
success: Risposta deselezionata con successo
|
76
100
|
update:
|
77
101
|
invalid: Si è verificato un errore durante l'aggiornamento di questa risposta
|
78
102
|
success: Risposta aggiornata con successo
|
@@ -87,6 +111,7 @@ it:
|
|
87
111
|
title: Modifica elezione
|
88
112
|
update: Aggiorna elezione
|
89
113
|
index:
|
114
|
+
no_bulletin_board: Non è configurato alcun <a href="https://github.com/decidim/decidim-bulletin-board">Bulletin Board server</a> che sia necessario per usare questo modulo. Questa attività dovrebbe essere eseguita dall'amministratore di sistema.
|
90
115
|
title: Elezioni
|
91
116
|
new:
|
92
117
|
create: Crea elezione
|
@@ -98,6 +123,9 @@ it:
|
|
98
123
|
update:
|
99
124
|
invalid: Si è verificato un problema durante l'aggiornamento di questa elezione
|
100
125
|
success: Elezione aggiornata con successo
|
126
|
+
exports:
|
127
|
+
elections: Elezioni
|
128
|
+
feedback_form_answers: Risposte al modulo di feedback
|
101
129
|
models:
|
102
130
|
answer:
|
103
131
|
name: Risposta
|
@@ -105,6 +133,8 @@ it:
|
|
105
133
|
name: Elezione
|
106
134
|
question:
|
107
135
|
name: Quesito
|
136
|
+
trustee:
|
137
|
+
name: Fiduciari
|
108
138
|
proposals_imports:
|
109
139
|
create:
|
110
140
|
invalid: Si è verificato un problema durante l'importazione delle proposte nelle risposte
|
@@ -113,6 +143,7 @@ it:
|
|
113
143
|
create: Importa proposte a cui rispondere
|
114
144
|
no_components: Non vi sono altre componenti di proposte in questo spazio partecipativo per importare le proposte in risposte.
|
115
145
|
select_component: Si prega di selezionare un componente
|
146
|
+
title: Importa proposte
|
116
147
|
questions:
|
117
148
|
create:
|
118
149
|
invalid: Si è verificato un errore durante la creazione di questa domanda
|
@@ -131,6 +162,35 @@ it:
|
|
131
162
|
update:
|
132
163
|
invalid: Si è verificato un errore durante l'aggiornamento del quesito
|
133
164
|
success: Quesito aggiornato correttamente
|
165
|
+
steps:
|
166
|
+
create_election:
|
167
|
+
errors:
|
168
|
+
max_selections: Le domande non hanno un valore <strong>corretto per la quantità di risposte</strong>
|
169
|
+
minimum_answers: Le domande devono avere <strong>almeno due risposte</strong>.
|
170
|
+
minimum_questions: Le elezioni <strong>devono avere almeno un quesito</strong>.
|
171
|
+
published: L'elezione non è <strong>pubblicata</strong>.
|
172
|
+
time_before: L'ora di inizio è in <strong>meno di 3 ore</strong> prima dell'inizio delle elezioni.
|
173
|
+
trustees_number: Lo spazio partecipativo <strong>deve avere almeno %{number} fiduciari con chiave pubblica</strong>.
|
174
|
+
invalid: Si è verificato un errore durante la creazione di questa elezione
|
175
|
+
no_trustees: Non ci sono Fiduciari configurati per questo spazio partecipativo
|
176
|
+
not_used_trustee: "(non utilizzato)"
|
177
|
+
public_key:
|
178
|
+
'false': non ha una <strong>chiave pubblica</strong>
|
179
|
+
'true': ha una <strong>chiave pubblica</strong>
|
180
|
+
requirements:
|
181
|
+
max_selections: Tutti i quesiti hanno un valore corretto per <strong>massimo di risposte</strong>.
|
182
|
+
minimum_answers: Ogni quesito ha <strong>almeno 2 risposte</strong>.
|
183
|
+
minimum_questions: L'elezione ha <strong>almeno 1 quesito</strong>.
|
184
|
+
published: L'elezione è <strong>pubblicata</strong>.
|
185
|
+
time_before: La configurazione viene eseguita <strong>almeno %{hours} ore</strong> prima dell'inizio delle elezioni.
|
186
|
+
trustees_number: Lo spazio partecipativo ha <strong>almeno %{number} fiduciari con chiave pubblica</strong>.
|
187
|
+
submit: Imposta elezione
|
188
|
+
success: Elezione inviata con successo al Bollettino
|
189
|
+
title: Imposta elezione
|
190
|
+
trustees: Fiduciari Delle Elezioni
|
191
|
+
key_ceremony:
|
192
|
+
title: Cerimonia chiave
|
193
|
+
trustees: Fiduciari
|
134
194
|
admin_log:
|
135
195
|
election:
|
136
196
|
publish: "%{user_name} ha pubblicato l'elezione %{resource_name}"
|
@@ -140,14 +200,21 @@ it:
|
|
140
200
|
elections_count:
|
141
201
|
one: "%{count} elezione"
|
142
202
|
other: "%{count} elezioni"
|
203
|
+
results:
|
204
|
+
description: Questi sono i risultati della votazione, per ogni quesito
|
205
|
+
selected: Selezionato
|
206
|
+
title: Risultati delle elezioni
|
143
207
|
show:
|
144
|
-
back:
|
208
|
+
back: Elezioni disponibili
|
145
209
|
preview: Anteprima
|
146
|
-
vote: Vota
|
147
210
|
voting_period_status:
|
148
211
|
finished: La votazione è iniziata il %{start_time} ed è terminata il %{end_time}
|
149
|
-
ongoing: La votazione termina il %{end_time}
|
150
212
|
upcoming: La votazione inizia il %{start_time}
|
213
|
+
feedback:
|
214
|
+
answer:
|
215
|
+
invalid: Si è verificato un errore durante l'invio del tuo feedback.
|
216
|
+
spam_detected: C'è stato un problema nelle risposte ai quesiti. Forse sei stato troppo veloce, puoi riprovare?
|
217
|
+
success: Feedback inviato con successo.
|
151
218
|
models:
|
152
219
|
answer:
|
153
220
|
fields:
|
@@ -155,6 +222,7 @@ it:
|
|
155
222
|
title: Titolo
|
156
223
|
election:
|
157
224
|
fields:
|
225
|
+
bb_status: Stato scheda bollettino
|
158
226
|
end_time: Finisce il
|
159
227
|
start_time: Inizia il
|
160
228
|
title: Titolo
|
@@ -163,6 +231,37 @@ it:
|
|
163
231
|
answers: Risposte
|
164
232
|
max_selections: Max. selezioni
|
165
233
|
title: Titolo
|
234
|
+
trustees_participatory_space:
|
235
|
+
fields:
|
236
|
+
considered: considerato
|
237
|
+
email: Email
|
238
|
+
inactive: inattivo
|
239
|
+
name: Nome
|
240
|
+
notification: Notifica inviata a
|
241
|
+
public_key: Chiave Pubblica
|
242
|
+
status: Stato
|
243
|
+
orders:
|
244
|
+
label: Ordina le elezioni per
|
245
|
+
older: Meno recente
|
246
|
+
recent: Recenti
|
247
|
+
trustee_zone:
|
248
|
+
elections:
|
249
|
+
backup_modal:
|
250
|
+
description: Questa elezione è in corso di creazione nel Bollettino. È molto importante che ogni fiduciario che partecipa crei una copia di backup di queste chiavi e le memorizzi in un luogo sicuro. Dopo di che, il processo continuerà.
|
251
|
+
download_election_keys: Scarica le chiavi
|
252
|
+
download_icon: Icona che indica un'azione di download
|
253
|
+
title: Backup delle chiavi elettorali per %{election}
|
254
|
+
key_ceremony_steps:
|
255
|
+
back: Indietro
|
256
|
+
description: Questa elezione è in fase di creazione nel Bollettino. Per completare questo processo, è necessaria la vostra partecipazione come fiduciario.
|
257
|
+
keys:
|
258
|
+
create_election: Generazione chiavi
|
259
|
+
key_ceremony:
|
260
|
+
joint_election_key: Generazione chiave congiunta
|
261
|
+
step_1: Pubblicazione delle chiavi
|
262
|
+
list:
|
263
|
+
status: Stato
|
264
|
+
task: Attività
|
166
265
|
votes:
|
167
266
|
confirm:
|
168
267
|
answer: Risposta
|
@@ -180,7 +279,6 @@ it:
|
|
180
279
|
header: Voto confermato
|
181
280
|
lead: Il tuo voto è già stato espresso!
|
182
281
|
text: 'Puoi controllare che il tuo voto sia stato aggiunto con successo alla scheda elettorale con il seguente identificatore: <strong class="evote__poll-id">%{e_vote_poll_id}</strong>'
|
183
|
-
verify_text: Per controllarlo, copia l'identificatore e incollalo nella pagina <a href="evote-verify">di verifica del voto</a>
|
184
282
|
encrypting:
|
185
283
|
header: Codifica del voto...
|
186
284
|
text: Il tuo voto viene crittografato per assicurarti di poterlo lanciare in modo anonimo.
|
@@ -210,6 +308,10 @@ it:
|
|
210
308
|
email_outro: Hai ricevuto questa notifica perché stai seguendo %{participatory_space_title}. È possibile interrompere la ricezione di notifiche seguendo il collegamento precedente.
|
211
309
|
email_subject: L'elezione di %{resource_title} è ora attiva per %{participatory_space_title}.
|
212
310
|
notification_title: L'elezione <a href="%{resource_path}">%{resource_title}</a> è ora attiva per %{participatory_space_title}.
|
311
|
+
pages:
|
312
|
+
home:
|
313
|
+
statistics:
|
314
|
+
elections_count: Elezioni
|
213
315
|
participatory_processes:
|
214
316
|
statistics:
|
215
317
|
elections_count: Elezioni
|
data/config/locales/ja.yml
CHANGED
@@ -50,8 +50,7 @@ ja:
|
|
50
50
|
confirm_destroy: よろしいですか?
|
51
51
|
destroy: 削除
|
52
52
|
edit: 編集
|
53
|
-
|
54
|
-
edit_questions: 質問を編集
|
53
|
+
feedback: 投票者からのフィードバック
|
55
54
|
import: 提案を回答にインポート
|
56
55
|
new: 新しい %{name}
|
57
56
|
preview: プレビュー
|
@@ -101,6 +100,8 @@ ja:
|
|
101
100
|
update:
|
102
101
|
invalid: 選挙の更新中に問題が発生しました
|
103
102
|
success: 選挙が正常に更新されました
|
103
|
+
exports:
|
104
|
+
feedback_form_answers: フィードバックフォームの回答
|
104
105
|
models:
|
105
106
|
answer:
|
106
107
|
name: 回答
|
@@ -169,13 +170,15 @@ ja:
|
|
169
170
|
filter_by: 絞り込み条件
|
170
171
|
unfold: 展開
|
171
172
|
show:
|
172
|
-
back: すべての選挙
|
173
173
|
preview: プレビュー
|
174
|
-
vote: 投票
|
175
174
|
voting_period_status:
|
176
175
|
finished: '%{start_time} に投票が開始され、 %{end_time} に終了しました'
|
177
|
-
ongoing: '%{end_time} に投票が終了します'
|
178
176
|
upcoming: '%{start_time} に投票が終了します'
|
177
|
+
feedback:
|
178
|
+
answer:
|
179
|
+
invalid: フィードバックの送信中に問題が発生しました
|
180
|
+
spam_detected: フォームに回答する際に問題が発生しました。もう一度お試しください。
|
181
|
+
success: フィードバックは正常に送信されました
|
179
182
|
models:
|
180
183
|
answer:
|
181
184
|
fields:
|
@@ -212,7 +215,6 @@ ja:
|
|
212
215
|
header: 投票が確定されました
|
213
216
|
lead: あなたの票は既に投じられました!
|
214
217
|
text: '投票が投票箱に正常に追加されたことを、次の識別子で確認できます: <strong class="evote__poll-id">%{e_vote_poll_id}</strong>'
|
215
|
-
verify_text: 確認するには、識別子をコピーして <a href="evote-verify">投票検証ページ</a> に貼り付けてください。
|
216
218
|
encrypting:
|
217
219
|
header: 投票の暗号化...
|
218
220
|
text: 投票は暗号化されており、匿名で投票することができます。
|
@@ -245,6 +247,10 @@ ja:
|
|
245
247
|
email_outro: '%{participatory_space_title}をフォローしているため、この通知を受け取りました。前のリンクに続く通知の受信を停止することができます。'
|
246
248
|
email_subject: '%{resource_title} の選挙は %{participatory_space_title} のために有効になりました。'
|
247
249
|
notification_title: <a href="%{resource_path}">%{resource_title}</a> の選挙が %{participatory_space_title} に有効になりました。
|
250
|
+
pages:
|
251
|
+
home:
|
252
|
+
statistics:
|
253
|
+
elections_count: 選挙
|
248
254
|
participatory_processes:
|
249
255
|
statistics:
|
250
256
|
elections_count: 選挙
|
data/config/locales/lv.yml
CHANGED
@@ -49,8 +49,6 @@ lv:
|
|
49
49
|
confirm_destroy: Vai esat pārliecināts?
|
50
50
|
destroy: Dzēst
|
51
51
|
edit: Labot
|
52
|
-
edit_answers: Rediģēt atbildes
|
53
|
-
edit_questions: Rediģēt jautājumus
|
54
52
|
import: Importēt priekšlikumus atbildēm
|
55
53
|
new: Jauns %{name}
|
56
54
|
preview: Priekšskatīt
|
@@ -140,6 +138,10 @@ lv:
|
|
140
138
|
answers: Atbildes
|
141
139
|
max_selections: Maks. izvēles
|
142
140
|
title: Nosaukums
|
141
|
+
pages:
|
142
|
+
home:
|
143
|
+
statistics:
|
144
|
+
elections_count: Vēlēšanas
|
143
145
|
participatory_processes:
|
144
146
|
statistics:
|
145
147
|
elections_count: Vēlēšanas
|