decidim 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of decidim might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/.codeclimate.yml +1 -0
- data/.rubocop.yml +12 -7
- data/Gemfile +0 -4
- data/Gemfile.lock +74 -71
- data/README.md +1 -0
- data/Rakefile +12 -1
- data/codecov.yml +3 -1
- data/decidim-admin/Rakefile +1 -0
- data/decidim-admin/app/assets/stylesheets/decidim/admin/application.scss.erb +6 -0
- data/decidim-admin/app/assets/stylesheets/decidim/admin/extra/_action-icon.scss +1 -0
- data/decidim-admin/app/assets/stylesheets/decidim/admin/extra/_dropdown_inverted.scss +38 -0
- data/decidim-admin/app/commands/decidim/admin/activate_participatory_process_step.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/copy_participatory_process.rb +113 -0
- data/decidim-admin/app/commands/decidim/admin/create_attachment.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_category.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_feature.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_newsletter.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_participatory_process.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_participatory_process_admin.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_participatory_process_group.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_participatory_process_step.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_scope.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/create_static_page.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/deactivate_participatory_process_step.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/deliver_newsletter.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/destroy_category.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/destroy_feature.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/destroy_participatory_process_step.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/hide_resource.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/publish_participatory_process.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/reject_user_group.rb +33 -0
- data/decidim-admin/app/commands/decidim/admin/reorder_participatory_process_steps.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/unpublish_participatory_process.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/unreport_resource.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_attachment.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_category.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_feature.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_feature_permissions.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_newsletter.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_organization.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_participatory_process.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_participatory_process_admin.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_participatory_process_group.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_participatory_process_step.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_scope.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_static_page.rb +1 -0
- data/decidim-admin/app/commands/decidim/admin/update_user_groups.rb +44 -0
- data/decidim-admin/app/commands/decidim/admin/verify_user_group.rb +32 -0
- data/decidim-admin/app/constraints/decidim/admin/organization_dashboard_constraint.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/application_controller.rb +2 -2
- data/decidim-admin/app/controllers/decidim/admin/categories_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/concerns/has_attachments.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/concerns/participatory_process_admin.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/dashboard_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/exports_controller.rb +39 -0
- data/decidim-admin/app/controllers/decidim/admin/feature_permissions_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/features/base_controller.rb +3 -0
- data/decidim-admin/app/controllers/decidim/admin/features_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/moderations_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/organization_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_attachments_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_copies_controller.rb +47 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_groups_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_publications_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_step_activations_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_step_ordering_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_steps_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_process_user_roles_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/participatory_processes_controller.rb +5 -0
- data/decidim-admin/app/controllers/decidim/admin/scopes_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/static_pages_controller.rb +1 -0
- data/decidim-admin/app/controllers/decidim/admin/user_groups_controller.rb +32 -4
- data/decidim-admin/app/controllers/decidim/admin/users_controller.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/attachment_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/category_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/feature_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/newsletter_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/organization_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/participatory_process_copy_form.rb +34 -0
- data/decidim-admin/app/forms/decidim/admin/participatory_process_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/participatory_process_group_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/participatory_process_step_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/participatory_process_user_role_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/permission_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/permissions_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/scope_form.rb +1 -0
- data/decidim-admin/app/forms/decidim/admin/static_page_form.rb +1 -0
- data/decidim-admin/app/helpers/decidim/admin/application_helper.rb +1 -8
- data/decidim-admin/app/helpers/decidim/admin/attributes_display_helper.rb +1 -0
- data/decidim-admin/app/helpers/decidim/admin/exports_helper.rb +18 -0
- data/decidim-admin/app/helpers/decidim/admin/feature_settings_helper.rb +1 -0
- data/decidim-admin/app/helpers/decidim/admin/icon_link_helper.rb +1 -0
- data/decidim-admin/app/helpers/decidim/admin/menu_helper.rb +18 -0
- data/decidim-admin/app/helpers/decidim/admin/process_groups_for_select_helper.rb +1 -0
- data/decidim-admin/app/helpers/decidim/admin/processes_for_select_helper.rb +1 -0
- data/decidim-admin/app/jobs/decidim/admin/application_job.rb +1 -0
- data/decidim-admin/app/jobs/decidim/admin/newsletter_delivery_job.rb +1 -0
- data/decidim-admin/app/jobs/decidim/admin/newsletter_job.rb +1 -0
- data/decidim-admin/app/mailers/decidim/admin/application_mailer.rb +1 -0
- data/decidim-admin/app/models/decidim/admin/abilities/admin_user.rb +2 -1
- data/decidim-admin/app/models/decidim/admin/abilities/base.rb +1 -0
- data/decidim-admin/app/models/decidim/admin/abilities/collaborator_user.rb +1 -0
- data/decidim-admin/app/models/decidim/admin/abilities/participatory_process_admin.rb +1 -0
- data/decidim-admin/app/models/decidim/admin/application_record.rb +1 -0
- data/decidim-admin/app/models/decidim/admin/participatory_process_user_role.rb +3 -2
- data/decidim-admin/app/queries/decidim/admin/manageable_participatory_processes_for_user.rb +1 -0
- data/decidim-admin/app/queries/decidim/admin/process_admin_roles_for_process.rb +1 -0
- data/decidim-admin/app/queries/decidim/admin/process_admins.rb +1 -0
- data/decidim-admin/app/queries/decidim/admin/user_groups_evaluation.rb +54 -0
- data/decidim-admin/app/views/decidim/admin/exports/_dropdown.html.erb +10 -0
- data/decidim-admin/app/views/decidim/admin/participatory_process_copies/_form.html.erb +38 -0
- data/decidim-admin/app/views/decidim/admin/participatory_process_copies/new.html.erb +7 -0
- data/decidim-admin/app/views/decidim/admin/participatory_processes/index.html.erb +2 -0
- data/decidim-admin/app/views/decidim/admin/scopes/new.html.erb +0 -1
- data/decidim-admin/app/views/decidim/admin/user_groups/index.html.erb +67 -5
- data/decidim-admin/app/views/layouts/decidim/admin/_application.html.erb +1 -1
- data/decidim-admin/app/views/layouts/decidim/admin/_title_bar.html.erb +1 -1
- data/decidim-admin/bin/rails +1 -0
- data/decidim-admin/config/i18n-tasks.yml +6 -6
- data/decidim-admin/config/locales/ca.yml +36 -2
- data/decidim-admin/config/locales/en.yml +36 -2
- data/decidim-admin/config/locales/es.yml +37 -3
- data/decidim-admin/config/locales/eu.yml +41 -3
- data/decidim-admin/config/locales/fi.yml +0 -3
- data/decidim-admin/config/locales/fr.yml +0 -3
- data/decidim-admin/config/routes.rb +4 -0
- data/decidim-admin/db/seeds.rb +1 -0
- data/decidim-admin/decidim-admin.gemspec +0 -1
- data/decidim-admin/lib/decidim/admin.rb +1 -0
- data/decidim-admin/lib/decidim/admin/engine.rb +51 -0
- data/decidim-admin/lib/decidim/admin/features.rb +1 -0
- data/decidim-admin/lib/decidim/admin/test/factories.rb +1 -0
- data/decidim-admin/lib/decidim/admin/test/manage_attachments_examples.rb +1 -0
- data/decidim-admin/spec/commands/activate_participatory_process_step_spec.rb +1 -0
- data/decidim-admin/spec/commands/copy_participatory_process_spec.rb +128 -0
- data/decidim-admin/spec/commands/create_category_spec.rb +1 -0
- data/decidim-admin/spec/commands/create_feature_spec.rb +1 -0
- data/decidim-admin/spec/commands/create_newsletter_spec.rb +1 -0
- data/decidim-admin/spec/commands/create_participatory_process_admin_spec.rb +1 -0
- data/decidim-admin/spec/commands/create_participatory_process_spec.rb +1 -0
- data/decidim-admin/spec/commands/create_scope_spec.rb +1 -0
- data/decidim-admin/spec/commands/create_static_page_spec.rb +1 -0
- data/decidim-admin/spec/commands/deactivate_participatory_process_step_spec.rb +1 -0
- data/decidim-admin/spec/commands/deliver_newsletter_spec.rb +1 -0
- data/decidim-admin/spec/commands/destroy_category_spec.rb +1 -0
- data/decidim-admin/spec/commands/destroy_feature_spec.rb +1 -0
- data/decidim-admin/spec/commands/destroy_participatory_process_step_spec.rb +1 -0
- data/decidim-admin/spec/commands/hide_resource_spec.rb +1 -0
- data/decidim-admin/spec/commands/publish_participatory_process_spec.rb +1 -0
- data/decidim-admin/spec/commands/reject_user_group_spec.rb +61 -0
- data/decidim-admin/spec/commands/reorder_participatory_process_steps_spec.rb +1 -0
- data/decidim-admin/spec/commands/unpublish_participatory_process_spec.rb +1 -0
- data/decidim-admin/spec/commands/unreport_resource_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_category_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_feature_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_newsletter_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_organization_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_participatory_process_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_scope_spec.rb +1 -0
- data/decidim-admin/spec/commands/update_static_page_spec.rb +1 -0
- data/decidim-admin/spec/commands/verify_user_group_spec.rb +61 -0
- data/decidim-admin/spec/controllers/exports_controller_spec.rb +49 -0
- data/decidim-admin/spec/controllers/participatory_processes_controller_spec.rb +1 -1
- data/decidim-admin/spec/controllers/static_pages_controller_spec.rb +1 -0
- data/decidim-admin/spec/factories.rb +1 -0
- data/decidim-admin/spec/features/admin_copy_participatory_process_spec.rb +108 -0
- data/decidim-admin/spec/features/admin_invite_spec.rb +1 -0
- data/decidim-admin/spec/features/admin_manages_feature_permissions_spec.rb +1 -0
- data/decidim-admin/spec/features/admin_manages_features_spec.rb +1 -1
- data/decidim-admin/spec/features/admin_manages_newsletters_spec.rb +0 -1
- data/decidim-admin/spec/features/admin_manages_organization_admins_spec.rb +1 -0
- data/decidim-admin/spec/features/admin_manages_organization_scopes_spec.rb +1 -0
- data/decidim-admin/spec/features/admin_manages_organization_spec.rb +0 -1
- data/decidim-admin/spec/features/admin_manages_participatory_process_groups_spec.rb +1 -1
- data/decidim-admin/spec/features/admin_manages_user_groups_spec.rb +14 -2
- data/decidim-admin/spec/features/static_pages_spec.rb +1 -0
- data/decidim-admin/spec/forms/category_form_spec.rb +1 -1
- data/decidim-admin/spec/forms/newsletter_form_spec.rb +1 -1
- data/decidim-admin/spec/forms/organization_form_spec.rb +1 -0
- data/decidim-admin/spec/forms/participatory_process_form_spec.rb +1 -1
- data/decidim-admin/spec/forms/participatory_process_group_form_spec.rb +1 -1
- data/decidim-admin/spec/forms/participatory_process_step_form_spec.rb +1 -1
- data/decidim-admin/spec/forms/participatory_process_user_role_form_spec.rb +1 -0
- data/decidim-admin/spec/forms/scope_form_spec.rb +1 -0
- data/decidim-admin/spec/forms/static_page_form_spec.rb +1 -1
- data/decidim-admin/spec/helpers/aria_selected_link_to_helper_spec.rb +1 -0
- data/decidim-admin/spec/helpers/exports_helper_spec.rb +27 -0
- data/decidim-admin/spec/helpers/feature_settings_helper_spec.rb +1 -0
- data/decidim-admin/spec/helpers/menu_helper_spec.rb +39 -0
- data/decidim-admin/spec/i18n_spec.rb +7 -0
- data/{decidim-proposals → decidim-admin}/spec/jobs/export_job_spec.rb +10 -10
- data/decidim-admin/spec/jobs/newsletter_delivery_job_spec.rb +1 -0
- data/decidim-admin/spec/jobs/newsletter_job_spec.rb +1 -0
- data/decidim-admin/spec/models/abilities/admin_user_spec.rb +1 -0
- data/decidim-admin/spec/models/abilities/collaborator_user_spec.rb +1 -0
- data/decidim-admin/spec/models/abilities/participatory_process_admin_spec.rb +1 -0
- data/decidim-admin/spec/models/participatory_process_user_role_spec.rb +1 -0
- data/decidim-admin/spec/organization_dashboard_constraint_spec.rb +1 -0
- data/decidim-admin/spec/queries/manageable_participatory_processes_for_user_spec.rb +1 -0
- data/decidim-admin/spec/queries/process_admin_roles_for_process_spec.rb +1 -0
- data/decidim-admin/spec/queries/process_admins_spec.rb +1 -0
- data/decidim-admin/spec/queries/user_group_evaluation_spec.rb +94 -0
- data/decidim-admin/spec/shared/manage_process_admins_examples.rb +1 -0
- data/decidim-admin/spec/shared/manage_process_attachments_examples.rb +1 -0
- data/decidim-admin/spec/shared/manage_process_categories_examples.rb +1 -0
- data/decidim-admin/spec/shared/manage_process_steps_examples.rb +1 -1
- data/decidim-admin/spec/shared/manage_processes_examples.rb +2 -2
- data/decidim-admin/spec/shared/participatory_admin_shared_context.rb +1 -0
- data/decidim-admin/spec/spec_helper.rb +1 -0
- data/decidim-admin/spec/support/processes_menu_links_helpers.rb +1 -0
- data/decidim-admin/spec/views/decidim/static_pages/_form.html.erb_spec.rb +1 -0
- data/decidim-api/Rakefile +1 -0
- data/decidim-api/app/assets/javascripts/decidim/api/docs.js.es6 +2 -0
- data/decidim-api/app/controllers/decidim/api/application_controller.rb +1 -0
- data/decidim-api/app/controllers/decidim/api/documentation_controller.rb +1 -0
- data/decidim-api/app/controllers/decidim/api/queries_controller.rb +1 -0
- data/decidim-api/bin/rails +1 -0
- data/decidim-api/config/routes.rb +1 -0
- data/decidim-api/decidim-api.gemspec +1 -1
- data/decidim-api/lib/decidim/api.rb +1 -0
- data/decidim-api/lib/decidim/api/engine.rb +1 -0
- data/decidim-api/lib/decidim/api/mutation_type.rb +1 -0
- data/decidim-api/lib/decidim/api/query_type.rb +1 -0
- data/decidim-api/lib/decidim/api/schema.rb +1 -0
- data/decidim-api/lib/decidim/api/test/type_context.rb +1 -0
- data/decidim-api/spec/controllers/queries_controller_spec.rb +1 -0
- data/decidim-api/spec/factories.rb +1 -0
- data/decidim-api/spec/features/documentation_spec.rb +1 -0
- data/decidim-api/spec/features/graphiql_spec.rb +1 -0
- data/decidim-api/spec/i18n_spec.rb +7 -0
- data/decidim-api/spec/spec_helper.rb +1 -0
- data/decidim-api/spec/types/query_type_spec.rb +1 -0
- data/decidim-budgets/Rakefile +1 -0
- data/decidim-budgets/app/commands/decidim/budgets/add_line_item.rb +1 -0
- data/decidim-budgets/app/commands/decidim/budgets/admin/create_project.rb +1 -0
- data/decidim-budgets/app/commands/decidim/budgets/admin/update_project.rb +1 -0
- data/decidim-budgets/app/commands/decidim/budgets/cancel_order.rb +1 -0
- data/decidim-budgets/app/commands/decidim/budgets/checkout.rb +1 -0
- data/decidim-budgets/app/commands/decidim/budgets/remove_line_item.rb +1 -0
- data/decidim-budgets/app/controllers/decidim/budgets/admin/application_controller.rb +1 -0
- data/decidim-budgets/app/controllers/decidim/budgets/admin/attachments_controller.rb +1 -0
- data/decidim-budgets/app/controllers/decidim/budgets/admin/projects_controller.rb +1 -0
- data/decidim-budgets/app/forms/decidim/budgets/admin/project_form.rb +1 -0
- data/decidim-budgets/app/helpers/decidim/budgets/application_helper.rb +1 -0
- data/decidim-budgets/app/helpers/decidim/budgets/projects_helper.rb +1 -0
- data/decidim-budgets/app/models/decidim/budgets/application_record.rb +1 -0
- data/decidim-budgets/app/models/decidim/budgets/line_item.rb +3 -2
- data/decidim-budgets/app/models/decidim/budgets/order.rb +4 -3
- data/decidim-budgets/app/models/decidim/budgets/project.rb +2 -1
- data/decidim-budgets/app/queries/decidim/budgets/filtered_projects.rb +1 -0
- data/decidim-budgets/app/services/decidim/budgets/project_search.rb +1 -0
- data/decidim-budgets/bin/rails +2 -1
- data/decidim-budgets/config/i18n-tasks.yml +4 -1
- data/decidim-budgets/config/locales/eu.yml +4 -0
- data/decidim-budgets/decidim-budgets.gemspec +1 -1
- data/decidim-budgets/lib/decidim/budgets.rb +2 -1
- data/decidim-budgets/lib/decidim/budgets/admin.rb +1 -0
- data/decidim-budgets/lib/decidim/budgets/admin_engine.rb +1 -0
- data/decidim-budgets/lib/decidim/budgets/{list_engine.rb → engine.rb} +2 -1
- data/decidim-budgets/lib/decidim/budgets/feature.rb +1 -1
- data/decidim-budgets/lib/decidim/budgets/test/factories.rb +1 -0
- data/decidim-budgets/spec/commands/add_line_item_spec.rb +1 -0
- data/decidim-budgets/spec/commands/cancel_order_spec.rb +1 -0
- data/decidim-budgets/spec/commands/checkout_spec.rb +1 -0
- data/decidim-budgets/spec/commands/create_project_spec.rb +1 -0
- data/decidim-budgets/spec/commands/remove_line_item_spec.rb +1 -0
- data/decidim-budgets/spec/commands/update_project_spec.rb +1 -0
- data/decidim-budgets/spec/factories.rb +1 -0
- data/decidim-budgets/spec/features/comments_spec.rb +1 -0
- data/decidim-budgets/spec/features/orders_spec.rb +1 -1
- data/decidim-budgets/spec/forms/project_form_spec.rb +1 -0
- data/decidim-budgets/spec/i18n_spec.rb +7 -0
- data/decidim-budgets/spec/queries/decidim/budgets/filtered_projects_spec.rb +1 -0
- data/decidim-budgets/spec/services/project_search_spec.rb +1 -0
- data/decidim-budgets/spec/shared/admin_shared_context.rb +1 -0
- data/decidim-budgets/spec/shared/manage_attachments_examples.rb +1 -0
- data/decidim-budgets/spec/shared/manage_projects_examples.rb +1 -0
- data/decidim-budgets/spec/spec_helper.rb +1 -0
- data/decidim-comments/.gitignore +0 -1
- data/decidim-comments/Rakefile +1 -0
- data/decidim-comments/app/assets/javascripts/decidim/comments/bundle.js +0 -0
- data/decidim-comments/app/commands/decidim/comments/create_comment.rb +1 -0
- data/decidim-comments/app/commands/decidim/comments/vote_comment.rb +1 -0
- data/decidim-comments/app/forms/decidim/comments/comment_form.rb +1 -0
- data/decidim-comments/app/frontend/comments/comment_order_selector.component.tsx +0 -1
- data/decidim-comments/app/frontend/comments/down_vote_button.component.test.tsx +2 -2
- data/decidim-comments/app/frontend/comments/down_vote_button.component.tsx +2 -2
- data/decidim-comments/app/frontend/comments/up_vote_button.component.test.tsx +2 -2
- data/decidim-comments/app/frontend/comments/up_vote_button.component.tsx +2 -2
- data/decidim-comments/app/frontend/fragments/comment_thread.fragment.graphql +0 -3
- data/decidim-comments/app/frontend/support/schema.ts +51 -16
- data/decidim-comments/app/mailers/decidim/comments/comment_notification_mailer.rb +1 -0
- data/decidim-comments/app/models/decidim/comments/abilities/admin_user.rb +1 -0
- data/decidim-comments/app/models/decidim/comments/abilities/process_admin_user.rb +1 -0
- data/decidim-comments/app/models/decidim/comments/application_record.rb +1 -0
- data/decidim-comments/app/models/decidim/comments/comment.rb +3 -2
- data/decidim-comments/app/models/decidim/comments/comment_vote.rb +3 -2
- data/decidim-comments/app/models/decidim/comments/seed.rb +1 -0
- data/decidim-comments/app/queries/decidim/comments/sorted_comments.rb +1 -0
- data/decidim-comments/app/resolvers/decidim/comments/vote_comment_resolver.rb +1 -0
- data/decidim-comments/app/types/decidim/comments/commentable_interface.rb +1 -0
- data/decidim-comments/app/types/decidim/comments/commentable_mutation_type.rb +1 -0
- data/decidim-comments/app/types/decidim/comments/commentable_type.rb +1 -0
- data/decidim-comments/bin/rails +1 -0
- data/decidim-comments/config/i18n-tasks.yml +2 -3
- data/decidim-comments/lib/decidim/comments.rb +3 -0
- data/decidim-comments/lib/decidim/comments/admin.rb +1 -0
- data/decidim-comments/lib/decidim/comments/admin_engine.rb +1 -0
- data/decidim-comments/lib/decidim/comments/api/add_comment_type.rb +1 -0
- data/decidim-comments/lib/decidim/comments/api/comment_mutation_type.rb +1 -0
- data/decidim-comments/lib/decidim/comments/api/comment_type.rb +1 -0
- data/decidim-comments/lib/decidim/comments/comment_serializer.rb +37 -0
- data/decidim-comments/lib/decidim/comments/comments_helper.rb +1 -0
- data/decidim-comments/lib/decidim/comments/engine.rb +1 -0
- data/decidim-comments/lib/decidim/comments/export.rb +22 -0
- data/decidim-comments/lib/decidim/comments/mutation_extensions.rb +1 -0
- data/decidim-comments/lib/decidim/comments/query_extensions.rb +1 -0
- data/decidim-comments/lib/decidim/comments/test/factories.rb +1 -0
- data/decidim-comments/spec/commands/create_comment_spec.rb +1 -0
- data/decidim-comments/spec/commands/vote_comment_spec.rb +5 -6
- data/decidim-comments/spec/factories.rb +1 -0
- data/decidim-comments/spec/features/comments_spec.rb +1 -0
- data/decidim-comments/spec/features/notifications_spec.rb +1 -0
- data/decidim-comments/spec/features/report_comment_spec.rb +1 -0
- data/decidim-comments/spec/forms/comment_form_spec.rb +1 -0
- data/decidim-comments/spec/helpers/comments_helper_spec.rb +1 -0
- data/decidim-comments/spec/i18n_spec.rb +7 -0
- data/decidim-comments/spec/lib/comment_serializer_spec.rb +44 -0
- data/decidim-comments/spec/lib/export_spec.rb +27 -0
- data/decidim-comments/spec/mailers/comment_notification_mailer_spec.rb +1 -0
- data/decidim-comments/spec/models/abilities/admin_user_spec.rb +1 -0
- data/decidim-comments/spec/models/abilities/process_admin_user_spec.rb +1 -0
- data/decidim-comments/spec/models/comment_spec.rb +1 -0
- data/decidim-comments/spec/models/comment_vote_spec.rb +1 -0
- data/decidim-comments/spec/models/seed_spec.rb +1 -0
- data/decidim-comments/spec/queries/sorted_comments_spec.rb +1 -0
- data/decidim-comments/spec/shared/admin_shared_context.rb +1 -0
- data/decidim-comments/spec/spec_helper.rb +1 -0
- data/decidim-comments/spec/types/comment_mutation_type_spec.rb +1 -0
- data/decidim-comments/spec/types/comment_type_spec.rb +1 -0
- data/decidim-comments/spec/types/commentable_mutation_type_spec.rb +1 -0
- data/decidim-comments/spec/types/commentable_type_spec.rb +1 -0
- data/decidim-comments/spec/types/mutation_type_spec.rb +1 -0
- data/decidim-comments/spec/types/query_type_spec.rb +1 -0
- data/decidim-dev/Rakefile +1 -0
- data/decidim-dev/app/assets/images/decidim/dummy.svg +4 -0
- data/decidim-dev/config/i18n-tasks.yml +3 -1
- data/decidim-dev/config/locales/ca.yml +4 -0
- data/decidim-dev/config/locales/en.yml +4 -0
- data/decidim-dev/config/locales/es.yml +4 -0
- data/decidim-dev/config/locales/eu.yml +4 -0
- data/decidim-dev/decidim-dev.gemspec +6 -6
- data/decidim-dev/lib/decidim/dev/common_rake.rb +2 -5
- data/decidim-dev/lib/decidim/dev/dummy_authorization_handler.rb +1 -0
- data/decidim-dev/lib/decidim/dev/railtie.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/authorization_shared_examples.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/base_spec_helper.rb +2 -1
- data/decidim-dev/lib/decidim/dev/test/{i18n_spec.rb → i18n_shared_examples.rb} +9 -6
- data/decidim-dev/lib/decidim/dev/test/rspec_support/action_mailer.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/authenticated_controller_context.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/authorization_handlers.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/capybara.rb +3 -3
- data/decidim-dev/lib/decidim/dev/test/rspec_support/database_cleaner.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/engine_routes.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/factory_girl.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/feature.rb +30 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/feature_context.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/geocoder.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/html_matchers.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/i18n.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/translation_helpers.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/warden.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/webmock.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/rspec_support/wisper.rb +1 -0
- data/decidim-dev/lib/decidim/dev/test/spec_helper.rb +1 -0
- data/decidim-dev/lib/generators/decidim/dummy_generator.rb +3 -6
- data/decidim-dev/lib/generators/decidim/templates/autoprefixer_initializer.rb +2 -1
- data/decidim-dev/lib/generators/decidim/templates/decidim_dev.rb +1 -0
- data/decidim-dev/lib/tasks/locale_checker.rake +21 -0
- data/decidim-dev/lib/tasks/test_app.rake +1 -2
- data/decidim-dev/spec/i18n_spec.rb +7 -0
- data/decidim-meetings/Rakefile +1 -0
- data/decidim-meetings/app/commands/decidim/meetings/admin/close_meeting.rb +1 -0
- data/decidim-meetings/app/commands/decidim/meetings/admin/create_meeting.rb +1 -0
- data/decidim-meetings/app/commands/decidim/meetings/admin/update_meeting.rb +1 -0
- data/decidim-meetings/app/controllers/decidim/meetings/admin/application_controller.rb +1 -0
- data/decidim-meetings/app/controllers/decidim/meetings/admin/attachments_controller.rb +1 -0
- data/decidim-meetings/app/controllers/decidim/meetings/admin/meeting_closes_controller.rb +1 -0
- data/decidim-meetings/app/controllers/decidim/meetings/admin/meetings_controller.rb +1 -0
- data/decidim-meetings/app/controllers/decidim/meetings/meeting_widgets_controller.rb +1 -0
- data/decidim-meetings/app/forms/decidim/meetings/admin/close_meeting_form.rb +1 -0
- data/decidim-meetings/app/forms/decidim/meetings/admin/meeting_form.rb +1 -0
- data/decidim-meetings/app/helpers/decidim/meetings/admin/application_helper.rb +1 -0
- data/decidim-meetings/app/helpers/decidim/meetings/application_helper.rb +1 -0
- data/decidim-meetings/app/helpers/decidim/meetings/map_helper.rb +1 -0
- data/decidim-meetings/app/models/decidim/meetings/application_record.rb +1 -0
- data/decidim-meetings/app/services/decidim/meetings/meeting_search.rb +1 -0
- data/decidim-meetings/bin/rails +2 -1
- data/decidim-meetings/config/i18n-tasks.yml +2 -1
- data/decidim-meetings/config/locales/eu.yml +7 -0
- data/decidim-meetings/decidim-meetings.gemspec +2 -2
- data/decidim-meetings/lib/decidim/meetings.rb +2 -1
- data/decidim-meetings/lib/decidim/meetings/admin.rb +1 -0
- data/decidim-meetings/lib/decidim/meetings/{list_engine.rb → engine.rb} +2 -1
- data/decidim-meetings/lib/decidim/meetings/feature.rb +1 -1
- data/decidim-meetings/lib/decidim/meetings/test/factories.rb +1 -0
- data/decidim-meetings/spec/commands/close_meeting_spec.rb +1 -0
- data/decidim-meetings/spec/commands/create_meeting_spec.rb +1 -0
- data/decidim-meetings/spec/commands/update_meeting_spec.rb +1 -0
- data/decidim-meetings/spec/factories.rb +1 -0
- data/decidim-meetings/spec/features/explore_meetings_spec.rb +1 -0
- data/decidim-meetings/spec/forms/close_meeting_form_spec.rb +1 -0
- data/decidim-meetings/spec/forms/meeting_form_spec.rb +1 -0
- data/decidim-meetings/spec/i18n_spec.rb +7 -0
- data/decidim-meetings/spec/services/meeting_search_spec.rb +1 -0
- data/decidim-meetings/spec/shared/admin_shared_context.rb +1 -0
- data/decidim-meetings/spec/shared/manage_attachments_examples.rb +1 -0
- data/decidim-meetings/spec/shared/manage_meetings_examples.rb +1 -0
- data/decidim-meetings/spec/spec_helper.rb +1 -0
- data/decidim-pages/Rakefile +1 -0
- data/decidim-pages/app/commands/decidim/pages/admin/update_page.rb +1 -0
- data/decidim-pages/app/commands/decidim/pages/copy_page.rb +26 -0
- data/decidim-pages/app/commands/decidim/pages/create_page.rb +1 -0
- data/decidim-pages/app/commands/decidim/pages/destroy_page.rb +1 -0
- data/decidim-pages/app/controllers/decidim/pages/admin/pages_controller.rb +1 -0
- data/decidim-pages/app/forms/decidim/pages/admin/page_form.rb +1 -0
- data/decidim-pages/app/helpers/decidim/pages/application_helper.rb +1 -0
- data/decidim-pages/app/models/decidim/pages/application_record.rb +1 -0
- data/decidim-pages/app/models/decidim/pages/page.rb +1 -0
- data/decidim-pages/bin/rails +1 -0
- data/decidim-pages/config/i18n-tasks.yml +2 -1
- data/decidim-pages/config/locales/eu.yml +1 -0
- data/decidim-pages/lib/decidim/pages.rb +1 -0
- data/decidim-pages/lib/decidim/pages/admin.rb +1 -0
- data/decidim-pages/lib/decidim/pages/admin_engine.rb +1 -0
- data/decidim-pages/lib/decidim/pages/engine.rb +1 -0
- data/decidim-pages/lib/decidim/pages/feature.rb +6 -0
- data/decidim-pages/spec/commands/copy_page_spec.rb +47 -0
- data/decidim-pages/spec/commands/create_page_spec.rb +1 -0
- data/decidim-pages/spec/commands/destroy_page_spec.rb +1 -0
- data/decidim-pages/spec/commands/update_page_spec.rb +1 -0
- data/decidim-pages/spec/factories.rb +1 -0
- data/decidim-pages/spec/features/admin_spec.rb +1 -1
- data/decidim-pages/spec/features/comments_spec.rb +1 -0
- data/decidim-pages/spec/features/page_show_spec.rb +1 -1
- data/decidim-pages/spec/forms/page_form_spec.rb +1 -1
- data/decidim-pages/spec/i18n_spec.rb +7 -0
- data/decidim-pages/spec/models/page_spec.rb +1 -0
- data/decidim-pages/spec/spec_helper.rb +1 -0
- data/decidim-proposals/Rakefile +1 -0
- data/decidim-proposals/app/commands/decidim/proposals/admin/answer_proposal.rb +1 -0
- data/decidim-proposals/app/commands/decidim/proposals/admin/create_proposal.rb +1 -0
- data/decidim-proposals/app/commands/decidim/proposals/create_proposal.rb +1 -0
- data/decidim-proposals/app/commands/decidim/proposals/create_proposal_export.rb +1 -0
- data/decidim-proposals/app/controllers/concerns/decidim/proposals/orderable.rb +64 -0
- data/decidim-proposals/app/controllers/decidim/proposals/admin/application_controller.rb +1 -0
- data/decidim-proposals/app/controllers/decidim/proposals/admin/proposal_answers_controller.rb +1 -0
- data/decidim-proposals/app/controllers/decidim/proposals/admin/proposals_controller.rb +1 -0
- data/decidim-proposals/app/controllers/decidim/proposals/proposals_controller.rb +2 -33
- data/decidim-proposals/app/forms/decidim/proposals/admin/proposal_answer_form.rb +1 -0
- data/decidim-proposals/app/forms/decidim/proposals/admin/proposal_form.rb +1 -0
- data/decidim-proposals/app/forms/decidim/proposals/proposal_form.rb +1 -0
- data/decidim-proposals/app/helpers/decidim/proposals/application_helper.rb +1 -1
- data/decidim-proposals/app/helpers/decidim/proposals/map_helper.rb +1 -0
- data/decidim-proposals/app/helpers/decidim/proposals/proposal_votes_helper.rb +1 -0
- data/decidim-proposals/app/models/decidim/proposals/abilities/admin_user.rb +1 -0
- data/decidim-proposals/app/models/decidim/proposals/abilities/current_user.rb +2 -1
- data/decidim-proposals/app/models/decidim/proposals/abilities/process_admin_user.rb +1 -0
- data/decidim-proposals/app/models/decidim/proposals/application_record.rb +1 -0
- data/decidim-proposals/app/models/decidim/proposals/proposal.rb +9 -1
- data/decidim-proposals/app/models/decidim/proposals/proposal_vote.rb +3 -2
- data/decidim-proposals/app/queries/decidim/proposals/filtered_proposals.rb +1 -0
- data/decidim-proposals/app/services/decidim/proposals/proposal_search.rb +1 -0
- data/decidim-proposals/app/views/decidim/proposals/admin/proposals/index.html.erb +1 -8
- data/decidim-proposals/app/views/decidim/proposals/proposals/_proposal.html.erb +1 -1
- data/decidim-proposals/app/views/decidim/proposals/proposals/_proposals.html.erb +2 -2
- data/decidim-proposals/app/views/decidim/proposals/proposals/_vote_button.html.erb +4 -10
- data/decidim-proposals/app/views/decidim/proposals/proposals/show.html.erb +2 -2
- data/decidim-proposals/bin/rails +1 -0
- data/decidim-proposals/config/i18n-tasks.yml +4 -1
- data/decidim-proposals/config/initializers/social_share_button.rb +1 -0
- data/decidim-proposals/config/locales/ca.yml +3 -3
- data/decidim-proposals/config/locales/en.yml +3 -4
- data/decidim-proposals/config/locales/es.yml +3 -3
- data/decidim-proposals/config/locales/eu.yml +10 -0
- data/decidim-proposals/config/locales/fr.yml +0 -3
- data/decidim-proposals/lib/decidim/proposals.rb +2 -0
- data/decidim-proposals/lib/decidim/proposals/admin.rb +1 -0
- data/decidim-proposals/lib/decidim/proposals/admin_engine.rb +1 -4
- data/decidim-proposals/lib/decidim/proposals/engine.rb +1 -0
- data/decidim-proposals/lib/decidim/proposals/feature.rb +20 -0
- data/decidim-proposals/{app/services → lib}/decidim/proposals/proposal_serializer.rb +1 -1
- data/decidim-proposals/lib/decidim/proposals/test/factories.rb +9 -0
- data/decidim-proposals/spec/commands/decidim/proposals/admin_create_proposal_spec.rb +1 -0
- data/decidim-proposals/spec/commands/decidim/proposals/answer_proposal_spec.rb +1 -0
- data/decidim-proposals/spec/commands/decidim/proposals/create_proposal_spec.rb +1 -0
- data/decidim-proposals/spec/{helpers/proposal_order_helper_spec.rb → controllers/concerns/orderable_test.rb} +13 -6
- data/decidim-proposals/spec/controllers/decidim/admin/proposal_answers_controller_spec.rb +1 -0
- data/decidim-proposals/spec/controllers/decidim/proposal_votes_controller_spec.rb +4 -5
- data/decidim-proposals/spec/controllers/decidim/proposals_controller_spec.rb +1 -0
- data/decidim-proposals/spec/factories.rb +1 -0
- data/decidim-proposals/spec/features/comments_spec.rb +1 -0
- data/decidim-proposals/spec/features/proposals_spec.rb +102 -30
- data/decidim-proposals/spec/features/report_proposal_spec.rb +1 -0
- data/decidim-proposals/spec/features/vote_proposal_spec.rb +39 -19
- data/decidim-proposals/spec/forms/decidim/proposals/admin_proposal_form_spec.rb +1 -0
- data/decidim-proposals/spec/forms/decidim/proposals/proposal_answer_form_spec.rb +1 -0
- data/decidim-proposals/spec/forms/decidim/proposals/proposal_form_spec.rb +1 -0
- data/decidim-proposals/spec/helpers/application_helper_spec.rb +1 -0
- data/decidim-proposals/spec/helpers/proposal_votes_helper_spec.rb +1 -0
- data/decidim-proposals/spec/i18n_spec.rb +7 -0
- data/decidim-proposals/spec/lib/decidim/proposals/feature_spec.rb +1 -0
- data/decidim-proposals/spec/models/decidim/proposals/abilities/admin_user_spec.rb +1 -0
- data/decidim-proposals/spec/models/decidim/proposals/abilities/process_admin_user_spec.rb +1 -0
- data/decidim-proposals/spec/models/decidim/proposals/proposal_spec.rb +1 -0
- data/decidim-proposals/spec/models/decidim/proposals/proposal_vote_spec.rb +1 -0
- data/decidim-proposals/spec/queries/decidim/proposals/filtered_proposals_spec.rb +1 -0
- data/decidim-proposals/spec/services/decidim/proposals/proposal_search_spec.rb +1 -0
- data/decidim-proposals/spec/services/decidim/proposals/proposal_serializer_spec.rb +1 -0
- data/decidim-proposals/spec/shared/admin_shared_context.rb +1 -0
- data/decidim-proposals/spec/shared/create_proposal_examples.rb +1 -0
- data/decidim-proposals/spec/shared/export_proposals_examples.rb +3 -2
- data/decidim-proposals/spec/shared/manage_proposals_examples.rb +1 -0
- data/decidim-proposals/spec/shared/proposal_form_examples.rb +1 -0
- data/decidim-proposals/spec/spec_helper.rb +1 -0
- data/decidim-results/Rakefile +1 -0
- data/decidim-results/app/commands/decidim/results/admin/create_result.rb +1 -0
- data/decidim-results/app/commands/decidim/results/admin/update_result.rb +1 -0
- data/decidim-results/app/controllers/decidim/results/admin/application_controller.rb +1 -0
- data/decidim-results/app/controllers/decidim/results/admin/results_controller.rb +1 -0
- data/decidim-results/app/controllers/decidim/results/result_widgets_controller.rb +1 -0
- data/decidim-results/app/forms/decidim/results/admin/result_form.rb +1 -0
- data/decidim-results/app/helpers/decidim/results/application_helper.rb +1 -0
- data/decidim-results/app/models/decidim/results/application_record.rb +1 -0
- data/decidim-results/app/models/decidim/results/result.rb +1 -0
- data/decidim-results/app/queries/decidim/results/filtered_results.rb +1 -0
- data/decidim-results/app/services/decidim/results/result_search.rb +1 -0
- data/decidim-results/app/services/decidim/results/result_stats_calculator.rb +1 -0
- data/decidim-results/bin/rails +2 -1
- data/decidim-results/config/i18n-tasks.yml +2 -1
- data/decidim-results/config/locales/eu.yml +3 -0
- data/decidim-results/decidim-results.gemspec +1 -1
- data/decidim-results/lib/decidim/results.rb +2 -1
- data/decidim-results/lib/decidim/results/admin.rb +1 -0
- data/decidim-results/lib/decidim/results/admin_engine.rb +1 -0
- data/decidim-results/lib/decidim/results/{list_engine.rb → engine.rb} +2 -1
- data/decidim-results/lib/decidim/results/feature.rb +1 -1
- data/decidim-results/lib/decidim/results/test/factories.rb +1 -0
- data/decidim-results/spec/commands/create_result_spec.rb +1 -0
- data/decidim-results/spec/commands/update_result_spec.rb +1 -0
- data/decidim-results/spec/controllers/results_controller_spec.rb +1 -0
- data/decidim-results/spec/factories.rb +1 -0
- data/decidim-results/spec/features/comments_spec.rb +1 -0
- data/decidim-results/spec/features/explore_results_spec.rb +1 -0
- data/decidim-results/spec/forms/result_form_spec.rb +1 -0
- data/decidim-results/spec/i18n_spec.rb +7 -0
- data/decidim-results/spec/queries/decidim/results/filtered_results_spec.rb +1 -0
- data/decidim-results/spec/services/result_search_spec.rb +1 -0
- data/decidim-results/spec/services/result_stats_calculator_spec.rb +1 -0
- data/decidim-results/spec/shared/admin_shared_context.rb +1 -0
- data/decidim-results/spec/shared/manage_results_examples.rb +1 -0
- data/decidim-results/spec/spec_helper.rb +1 -0
- data/decidim-system/Rakefile +1 -0
- data/decidim-system/app/assets/stylesheets/decidim/system/_sidebar.scss +9 -2
- data/decidim-system/app/commands/decidim/system/create_admin.rb +1 -0
- data/decidim-system/app/commands/decidim/system/create_default_pages.rb +1 -0
- data/decidim-system/app/commands/decidim/system/register_organization.rb +1 -0
- data/decidim-system/app/commands/decidim/system/update_admin.rb +1 -0
- data/decidim-system/app/commands/decidim/system/update_organization.rb +1 -0
- data/decidim-system/app/controllers/decidim/system/admins_controller.rb +1 -0
- data/decidim-system/app/controllers/decidim/system/application_controller.rb +3 -0
- data/decidim-system/app/controllers/decidim/system/dashboard_controller.rb +1 -0
- data/decidim-system/app/controllers/decidim/system/devise/passwords_controller.rb +1 -0
- data/decidim-system/app/controllers/decidim/system/devise/sessions_controller.rb +1 -0
- data/decidim-system/app/controllers/decidim/system/organizations_controller.rb +1 -0
- data/decidim-system/app/forms/decidim/system/admin_form.rb +1 -0
- data/decidim-system/app/forms/decidim/system/register_organization_form.rb +1 -0
- data/decidim-system/app/forms/decidim/system/update_organization_form.rb +1 -0
- data/decidim-system/app/helpers/decidim/system/application_helper.rb +1 -0
- data/decidim-system/app/helpers/decidim/system/menu_helper.rb +14 -0
- data/decidim-system/app/jobs/decidim/system/application_job.rb +1 -0
- data/decidim-system/app/mailers/decidim/system/application_mailer.rb +1 -0
- data/decidim-system/app/models/decidim/system/admin.rb +1 -0
- data/decidim-system/app/models/decidim/system/application_record.rb +1 -0
- data/decidim-system/app/views/layouts/decidim/system/_sidebar.html.erb +1 -5
- data/decidim-system/bin/rails +1 -0
- data/decidim-system/config/i18n-tasks.yml +6 -6
- data/decidim-system/config/locales/eu.yml +3 -0
- data/decidim-system/config/routes.rb +1 -0
- data/decidim-system/db/seeds.rb +1 -0
- data/decidim-system/lib/decidim/system.rb +1 -0
- data/decidim-system/lib/decidim/system/engine.rb +20 -0
- data/decidim-system/spec/commands/decidim/system/create_admin_spec.rb +1 -0
- data/decidim-system/spec/commands/decidim/system/create_default_pages_spec.rb +1 -0
- data/decidim-system/spec/commands/decidim/system/register_organization_spec.rb +1 -0
- data/decidim-system/spec/commands/decidim/system/update_organization_spec.rb +1 -0
- data/decidim-system/spec/factories.rb +1 -0
- data/decidim-system/spec/features/sessions_spec.rb +1 -0
- data/decidim-system/spec/helpers/menu_helper_spec.rb +28 -0
- data/decidim-system/spec/i18n_spec.rb +7 -0
- data/decidim-system/spec/models/admin_spec.rb +1 -0
- data/decidim-system/spec/spec_helper.rb +1 -0
- data/docs/features_and_components.md +15 -0
- data/docs/getting_started.md +10 -0
- data/docs/how_to_create_a_plugin.md +7 -16
- data/lib/decidim.rb +1 -0
- data/lib/generators/decidim/app_builder.rb +1 -0
- data/lib/generators/decidim/app_generator.rb +7 -0
- data/lib/generators/decidim/demo_generator.rb +1 -0
- data/lib/generators/decidim/docker_generator.rb +1 -4
- data/lib/generators/decidim/install_generator.rb +4 -3
- data/lib/generators/decidim/templates/authorization_handler.rb +1 -0
- data/lib/generators/decidim/templates/carrierwave.rb +1 -0
- data/lib/generators/decidim/templates/initializer.rb +1 -0
- data/lib/generators/decidim/templates/social_share_button.rb +1 -0
- data/package.json +10 -9
- data/yarn.lock +708 -862
- metadata +73 -37
- data/.hound.yml +0 -10
- data/decidim-admin/app/assets/stylesheets/decidim/admin/application.scss +0 -2
- data/decidim-admin/app/assets/stylesheets/decidim/admin/extra/_sidebar.scss +0 -102
- data/decidim-admin/app/views/layouts/decidim/admin/_language_chooser.html.erb +0 -14
- data/decidim-admin/app/views/layouts/decidim/admin/_main_nav.html.erb +0 -11
- data/decidim-proposals/app/controllers/decidim/proposals/admin/exports_controller.rb +0 -24
- data/decidim-proposals/app/helpers/decidim/proposals/proposal_order_helper.rb +0 -16
- data/decidim-proposals/app/jobs/decidim/proposals/export_job.rb +0 -21
@@ -1,4 +1,5 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
|
+
|
2
3
|
require "spec_helper"
|
3
4
|
|
4
5
|
module Decidim
|
@@ -97,14 +98,12 @@ module Decidim
|
|
97
98
|
create(:proposal_feature, :with_votes_enabled)
|
98
99
|
end
|
99
100
|
|
100
|
-
it "
|
101
|
+
it "deletes the vote" do
|
101
102
|
expect do
|
102
103
|
delete :destroy, format: :js, params: params
|
103
|
-
end.
|
104
|
+
end.to change { ProposalVote.count }.by(-1)
|
104
105
|
|
105
|
-
expect(
|
106
|
-
expect(response).to have_http_status(302)
|
107
|
-
expect(ProposalVote.count).to eq(1)
|
106
|
+
expect(ProposalVote.count).to eq(0)
|
108
107
|
end
|
109
108
|
end
|
110
109
|
end
|
@@ -1,16 +1,11 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
|
+
|
2
3
|
require "spec_helper"
|
3
4
|
|
4
5
|
describe "Proposals", type: :feature do
|
5
6
|
include_context "feature"
|
6
|
-
let!(:feature) do
|
7
|
-
create(:proposal_feature,
|
8
|
-
manifest: manifest,
|
9
|
-
participatory_process: participatory_process)
|
10
|
-
end
|
11
7
|
let(:manifest_name) { "proposals" }
|
12
8
|
|
13
|
-
let!(:proposals) { create_list(:proposal, 3, feature: feature) }
|
14
9
|
let!(:category) { create :category, participatory_process: participatory_process }
|
15
10
|
let!(:scope) { create :scope, organization: organization }
|
16
11
|
let!(:user) { create :user, :confirmed, organization: organization }
|
@@ -212,6 +207,14 @@ describe "Proposals", type: :feature do
|
|
212
207
|
end
|
213
208
|
|
214
209
|
context "viewing a single proposal" do
|
210
|
+
let!(:feature) do
|
211
|
+
create(:proposal_feature,
|
212
|
+
manifest: manifest,
|
213
|
+
participatory_process: participatory_process)
|
214
|
+
end
|
215
|
+
|
216
|
+
let!(:proposals) { create_list(:proposal, 3, feature: feature) }
|
217
|
+
|
215
218
|
it "allows viewing a single proposal" do
|
216
219
|
proposal = proposals.first
|
217
220
|
|
@@ -354,6 +357,11 @@ describe "Proposals", type: :feature do
|
|
354
357
|
end
|
355
358
|
|
356
359
|
context "when a proposal has been linked in a project" do
|
360
|
+
let(:feature) do
|
361
|
+
create(:proposal_feature,
|
362
|
+
manifest: manifest,
|
363
|
+
participatory_process: participatory_process)
|
364
|
+
end
|
357
365
|
let(:proposal) { create(:proposal, feature: feature) }
|
358
366
|
let(:budget_feature) do
|
359
367
|
create(:feature, manifest_name: :budgets, participatory_process: proposal.feature.participatory_process)
|
@@ -374,10 +382,77 @@ describe "Proposals", type: :feature do
|
|
374
382
|
|
375
383
|
context "listing proposals in a participatory process" do
|
376
384
|
it "lists all the proposals" do
|
385
|
+
create(:proposal_feature,
|
386
|
+
manifest: manifest,
|
387
|
+
participatory_process: participatory_process)
|
388
|
+
|
389
|
+
create_list(:proposal, 3, feature: feature)
|
390
|
+
|
377
391
|
visit_feature
|
378
392
|
expect(page).to have_css(".card--proposal", count: 3)
|
379
393
|
end
|
380
394
|
|
395
|
+
context "when voting phase is over" do
|
396
|
+
let!(:feature) do
|
397
|
+
create(:proposal_feature,
|
398
|
+
:with_votes_blocked,
|
399
|
+
manifest: manifest,
|
400
|
+
participatory_process: participatory_process)
|
401
|
+
end
|
402
|
+
|
403
|
+
let!(:most_voted_proposal) do
|
404
|
+
proposal = create(:proposal, feature: feature)
|
405
|
+
create_list(:proposal_vote, 3, proposal: proposal)
|
406
|
+
proposal
|
407
|
+
end
|
408
|
+
|
409
|
+
let!(:less_voted_proposal) { create(:proposal, feature: feature) }
|
410
|
+
|
411
|
+
before { visit_feature }
|
412
|
+
|
413
|
+
it "lists the proposals ordered by votes by default" do
|
414
|
+
expect(page).to have_selector("a", text: "Most voted")
|
415
|
+
expect(page).to have_selector("#proposals .card-grid .column:first-child", text: most_voted_proposal.title)
|
416
|
+
expect(page).to have_selector("#proposals .card-grid .column:last-child", text: less_voted_proposal.title)
|
417
|
+
end
|
418
|
+
|
419
|
+
it "shows a disabled vote button for each proposal, but no links to full proposals" do
|
420
|
+
expect(page).to have_button("Voting disabled", disabled: true, count: 2)
|
421
|
+
expect(page).to have_no_link("View proposal")
|
422
|
+
end
|
423
|
+
end
|
424
|
+
|
425
|
+
context "when voting is disabled" do
|
426
|
+
let!(:feature) do
|
427
|
+
create(:proposal_feature,
|
428
|
+
:with_votes_disabled,
|
429
|
+
manifest: manifest,
|
430
|
+
participatory_process: participatory_process)
|
431
|
+
end
|
432
|
+
|
433
|
+
let!(:lucky_proposal) { create(:proposal, title: "A", feature: feature) }
|
434
|
+
let!(:unlucky_proposal) { create(:proposal, title: "B", feature: feature) }
|
435
|
+
|
436
|
+
it "lists the proposals ordered randomly by default" do
|
437
|
+
allow_any_instance_of(Decidim::Proposals::Proposal::ActiveRecord_Relation).to \
|
438
|
+
receive(:order_randomly) { |scope, _seed| scope.order(title: :asc) }
|
439
|
+
|
440
|
+
visit_feature
|
441
|
+
|
442
|
+
expect(page).to have_selector("a", text: "Random")
|
443
|
+
expect(page).to have_selector("#proposals .card-grid .column:first-child", text: lucky_proposal.title)
|
444
|
+
expect(page).to have_selector("#proposals .card-grid .column:last-child", text: unlucky_proposal.title)
|
445
|
+
end
|
446
|
+
|
447
|
+
it "shows only links to full proposals" do
|
448
|
+
visit_feature
|
449
|
+
|
450
|
+
expect(page).to have_no_button("Voting disabled", disabled: true)
|
451
|
+
expect(page).to have_no_button("Vote")
|
452
|
+
expect(page).to have_link("View proposal", count: 2)
|
453
|
+
end
|
454
|
+
end
|
455
|
+
|
381
456
|
context "when there are a lot of proposals" do
|
382
457
|
before do
|
383
458
|
create_list(:proposal, 17, feature: feature)
|
@@ -388,11 +463,11 @@ describe "Proposals", type: :feature do
|
|
388
463
|
|
389
464
|
expect(page).to have_css(".card--proposal", count: 12)
|
390
465
|
|
391
|
-
|
466
|
+
click_link "Next"
|
392
467
|
|
393
468
|
expect(page).to have_selector(".pagination .current", text: "2")
|
394
469
|
|
395
|
-
expect(page).to have_css(".card--proposal", count:
|
470
|
+
expect(page).to have_css(".card--proposal", count: 5)
|
396
471
|
end
|
397
472
|
end
|
398
473
|
|
@@ -412,28 +487,31 @@ describe "Proposals", type: :feature do
|
|
412
487
|
|
413
488
|
context "by origin 'official'" do
|
414
489
|
it "lists the filtered proposals" do
|
415
|
-
|
490
|
+
create_list(:proposal, 2, :official, feature: feature, scope: scope)
|
491
|
+
create(:proposal, feature: feature, scope: scope)
|
416
492
|
visit_feature
|
417
493
|
|
418
494
|
within ".filters" do
|
419
495
|
choose "Official"
|
420
496
|
end
|
421
497
|
|
422
|
-
expect(page).to have_css(".card--proposal", count:
|
423
|
-
expect(page).to have_content("
|
498
|
+
expect(page).to have_css(".card--proposal", count: 2)
|
499
|
+
expect(page).to have_content("2 PROPOSALS")
|
424
500
|
end
|
425
501
|
end
|
426
502
|
|
427
503
|
context "by origin 'citizenship'" do
|
428
504
|
it "lists the filtered proposals" do
|
505
|
+
create_list(:proposal, 2, feature: feature, scope: scope)
|
506
|
+
create(:proposal, :official, feature: feature, scope: scope)
|
429
507
|
visit_feature
|
430
508
|
|
431
509
|
within ".filters" do
|
432
510
|
choose "Citizenship"
|
433
511
|
end
|
434
512
|
|
435
|
-
expect(page).to have_css(".card--proposal", count:
|
436
|
-
expect(page).to have_content("
|
513
|
+
expect(page).to have_css(".card--proposal", count: 2)
|
514
|
+
expect(page).to have_content("2 PROPOSALS")
|
437
515
|
end
|
438
516
|
end
|
439
517
|
end
|
@@ -578,7 +656,7 @@ describe "Proposals", type: :feature do
|
|
578
656
|
end
|
579
657
|
|
580
658
|
context "when ordering" do
|
581
|
-
context "by '
|
659
|
+
context "by 'most_voted'" do
|
582
660
|
let!(:feature) do
|
583
661
|
create(:proposal_feature,
|
584
662
|
:with_votes_enabled,
|
@@ -586,12 +664,6 @@ describe "Proposals", type: :feature do
|
|
586
664
|
participatory_process: participatory_process)
|
587
665
|
end
|
588
666
|
|
589
|
-
before do
|
590
|
-
proposals.each do |proposal|
|
591
|
-
create(:proposal_vote, proposal: proposal)
|
592
|
-
end
|
593
|
-
end
|
594
|
-
|
595
667
|
it "lists the proposals ordered by votes" do
|
596
668
|
most_voted_proposal = create(:proposal, feature: feature)
|
597
669
|
create_list(:proposal_vote, 3, proposal: most_voted_proposal)
|
@@ -600,13 +672,13 @@ describe "Proposals", type: :feature do
|
|
600
672
|
visit_feature
|
601
673
|
|
602
674
|
within ".order-by" do
|
603
|
-
page.
|
675
|
+
expect(page).to have_selector("ul[data-dropdown-menu$=dropdown-menu]", text: "Random")
|
676
|
+
page.find("a", text: "Random").click
|
677
|
+
click_link "Most voted"
|
604
678
|
end
|
605
679
|
|
606
|
-
|
607
|
-
|
608
|
-
expect(page.find("#proposals .card-grid .column:first-child", text: most_voted_proposal.title)).to be
|
609
|
-
expect(page.find("#proposals .card-grid .column:last-child", text: less_voted_proposal.title)).to be
|
680
|
+
expect(page).to have_selector("#proposals .card-grid .column:first-child", text: most_voted_proposal.title)
|
681
|
+
expect(page).to have_selector("#proposals .card-grid .column:last-child", text: less_voted_proposal.title)
|
610
682
|
end
|
611
683
|
end
|
612
684
|
|
@@ -618,13 +690,13 @@ describe "Proposals", type: :feature do
|
|
618
690
|
visit_feature
|
619
691
|
|
620
692
|
within ".order-by" do
|
621
|
-
page.
|
693
|
+
expect(page).to have_selector("ul[data-dropdown-menu$=dropdown-menu]", text: "Random")
|
694
|
+
page.find("a", text: "Random").click
|
695
|
+
click_link "Recent"
|
622
696
|
end
|
623
697
|
|
624
|
-
|
625
|
-
|
626
|
-
expect(page.find("#proposals .card-grid .column:first-child", text: recent_proposal.title)).to be
|
627
|
-
expect(page.find("#proposals .card-grid .column:last-child", text: older_proposal.title)).to be
|
698
|
+
expect(page).to have_selector("#proposals .card-grid .column:first-child", text: recent_proposal.title)
|
699
|
+
expect(page).to have_selector("#proposals .card-grid .column:last-child", text: older_proposal.title)
|
628
700
|
end
|
629
701
|
end
|
630
702
|
end
|
@@ -1,4 +1,5 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
|
+
|
2
3
|
require "spec_helper"
|
3
4
|
|
4
5
|
describe "Vote Proposal", type: :feature do
|
@@ -9,16 +10,10 @@ describe "Vote Proposal", type: :feature do
|
|
9
10
|
let!(:proposal) { Decidim::Proposals::Proposal.where(feature: feature).first }
|
10
11
|
let!(:user) { create :user, :confirmed, organization: organization }
|
11
12
|
|
12
|
-
let!(:feature) do
|
13
|
-
create(:proposal_feature,
|
14
|
-
manifest: manifest,
|
15
|
-
participatory_process: participatory_process)
|
16
|
-
end
|
17
|
-
|
18
13
|
context "when votes are not enabled" do
|
19
14
|
it "doesn't show the vote proposal button and counts" do
|
20
|
-
expect(page).
|
21
|
-
expect(page).
|
15
|
+
expect(page).to have_no_button("Vote")
|
16
|
+
expect(page).to have_no_css(".card__support__data span", text: "0 VOTES")
|
22
17
|
end
|
23
18
|
end
|
24
19
|
|
@@ -50,7 +45,7 @@ describe "Vote Proposal", type: :feature do
|
|
50
45
|
visit_feature
|
51
46
|
|
52
47
|
within ".card__support", match: :first do
|
53
|
-
|
48
|
+
click_button "Vote"
|
54
49
|
end
|
55
50
|
|
56
51
|
expect(page).to have_css("#loginModal", visible: true)
|
@@ -60,14 +55,17 @@ describe "Vote Proposal", type: :feature do
|
|
60
55
|
context "when the user is logged in" do
|
61
56
|
before do
|
62
57
|
login_as user, scope: :user
|
63
|
-
visit_feature
|
64
58
|
end
|
65
59
|
|
66
60
|
context "when the proposal is not voted yet" do
|
61
|
+
before do
|
62
|
+
visit_feature
|
63
|
+
end
|
64
|
+
|
67
65
|
it "should be able to vote the proposal" do
|
68
66
|
within "#proposal-#{proposal.id}-vote-button" do
|
69
|
-
|
70
|
-
expect(page).to
|
67
|
+
click_button "Vote"
|
68
|
+
expect(page).to have_button("Already voted")
|
71
69
|
end
|
72
70
|
|
73
71
|
within "#proposal-#{proposal.id}-votes-count" do
|
@@ -84,14 +82,25 @@ describe "Vote Proposal", type: :feature do
|
|
84
82
|
|
85
83
|
it "should not be able to vote it again" do
|
86
84
|
within "#proposal-#{proposal.id}-vote-button" do
|
87
|
-
expect(page).to
|
88
|
-
page.
|
85
|
+
expect(page).to have_button("Already voted")
|
86
|
+
expect(page).to have_no_button("Vote")
|
89
87
|
end
|
90
88
|
|
91
89
|
within "#proposal-#{proposal.id}-votes-count" do
|
92
90
|
expect(page).to have_content("1 VOTE")
|
93
91
|
end
|
94
92
|
end
|
93
|
+
|
94
|
+
it "should be able to undo the vote" do
|
95
|
+
within "#proposal-#{proposal.id}-vote-button" do
|
96
|
+
click_button "Already voted"
|
97
|
+
expect(page).to have_button("Vote")
|
98
|
+
end
|
99
|
+
|
100
|
+
within "#proposal-#{proposal.id}-votes-count" do
|
101
|
+
expect(page).to have_content("0 VOTES")
|
102
|
+
end
|
103
|
+
end
|
95
104
|
end
|
96
105
|
|
97
106
|
context "when the feature has a vote limit" do
|
@@ -107,10 +116,14 @@ describe "Vote Proposal", type: :feature do
|
|
107
116
|
end
|
108
117
|
|
109
118
|
context "when the proposal is not voted yet" do
|
119
|
+
before do
|
120
|
+
visit_feature
|
121
|
+
end
|
122
|
+
|
110
123
|
it "should update the remaining votes counter" do
|
111
124
|
within "#proposal-#{proposal.id}-vote-button" do
|
112
|
-
|
113
|
-
expect(page).to
|
125
|
+
click_button "Vote"
|
126
|
+
expect(page).to have_button("Already voted")
|
114
127
|
end
|
115
128
|
|
116
129
|
expect(page).to have_content("REMAINING 9 VOTES")
|
@@ -125,7 +138,7 @@ describe "Vote Proposal", type: :feature do
|
|
125
138
|
|
126
139
|
it "should show a modal dialog" do
|
127
140
|
within "#proposal-#{proposal.id}-vote-button" do
|
128
|
-
|
141
|
+
click_button "Vote"
|
129
142
|
end
|
130
143
|
|
131
144
|
expect(page).to have_content("Authorization required")
|
@@ -138,10 +151,17 @@ describe "Vote Proposal", type: :feature do
|
|
138
151
|
visit_feature
|
139
152
|
end
|
140
153
|
|
154
|
+
it "should not be able to vote it again" do
|
155
|
+
within "#proposal-#{proposal.id}-vote-button" do
|
156
|
+
expect(page).to have_button("Already voted")
|
157
|
+
expect(page).to have_no_button("Vote")
|
158
|
+
end
|
159
|
+
end
|
160
|
+
|
141
161
|
it "should be able to undo the vote" do
|
142
162
|
within "#proposal-#{proposal.id}-vote-button" do
|
143
|
-
|
144
|
-
page.
|
163
|
+
click_button "Already voted"
|
164
|
+
expect(page).to have_button("Vote")
|
145
165
|
end
|
146
166
|
|
147
167
|
within "#proposal-#{proposal.id}-votes-count" do
|