decidim-participatory_processes 0.27.6 → 0.28.0.rc4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (254) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/app/cells/decidim/participatory_process_groups/content_block_cell.rb +5 -1
  4. data/app/cells/decidim/participatory_process_groups/content_blocks/extra_data/recent_users.erb +1 -0
  5. data/app/cells/decidim/participatory_process_groups/content_blocks/extra_data_cell.rb +71 -0
  6. data/app/cells/decidim/participatory_process_groups/content_blocks/main_data/content.erb +30 -0
  7. data/app/cells/decidim/participatory_process_groups/content_blocks/main_data_cell.rb +77 -0
  8. data/app/cells/decidim/participatory_process_groups/content_blocks/related_processes_cell.rb +47 -0
  9. data/app/cells/decidim/participatory_process_groups/content_blocks/statistics_cell.rb +2 -2
  10. data/app/cells/decidim/participatory_process_groups/process_filters_cell.rb +4 -4
  11. data/app/cells/decidim/participatory_processes/content_block_cell.rb +21 -0
  12. data/app/cells/decidim/participatory_processes/content_blocks/extra_data/active_step.erb +1 -0
  13. data/app/cells/decidim/participatory_processes/content_blocks/extra_data_cell.rb +60 -0
  14. data/app/cells/decidim/participatory_processes/content_blocks/hero_cell.rb +29 -0
  15. data/app/cells/decidim/participatory_processes/content_blocks/highlighted_processes_cell.rb +14 -27
  16. data/app/cells/decidim/participatory_processes/content_blocks/highlighted_processes_settings_form/show.erb +1 -1
  17. data/app/cells/decidim/participatory_processes/content_blocks/main_data_cell.rb +34 -0
  18. data/app/cells/decidim/participatory_processes/content_blocks/metadata_cell.rb +23 -0
  19. data/app/cells/decidim/participatory_processes/content_blocks/metrics_cell.rb +25 -0
  20. data/app/cells/decidim/participatory_processes/content_blocks/processes_settings_form/show.erb +3 -0
  21. data/app/cells/decidim/participatory_processes/content_blocks/processes_settings_form_cell.rb +28 -0
  22. data/app/cells/decidim/participatory_processes/content_blocks/related_processes/content.erb +1 -0
  23. data/app/cells/decidim/participatory_processes/content_blocks/related_processes_cell.rb +53 -0
  24. data/app/cells/decidim/participatory_processes/content_blocks/stats_cell.rb +17 -0
  25. data/app/cells/decidim/participatory_processes/filtered_participatory_processes_cell.rb +1 -1
  26. data/app/cells/decidim/participatory_processes/process_cell.rb +2 -2
  27. data/app/cells/decidim/participatory_processes/process_dropdown_metadata/metadata.erb +22 -0
  28. data/app/cells/decidim/participatory_processes/process_dropdown_metadata_cell.rb +39 -0
  29. data/app/cells/decidim/participatory_processes/process_filters/show.erb +4 -5
  30. data/app/cells/decidim/participatory_processes/process_filters/type_filter.erb +1 -1
  31. data/app/cells/decidim/participatory_processes/process_filters_cell.rb +6 -6
  32. data/app/cells/decidim/participatory_processes/process_g_cell.rb +31 -0
  33. data/app/cells/decidim/participatory_processes/process_group_cell.rb +2 -2
  34. data/app/cells/decidim/participatory_processes/process_group_g_cell.rb +23 -0
  35. data/app/cells/decidim/participatory_processes/process_group_metadata_cell.rb +46 -0
  36. data/app/cells/decidim/participatory_processes/process_group_s_cell.rb +5 -13
  37. data/app/cells/decidim/participatory_processes/process_metadata_cell.rb +44 -0
  38. data/app/cells/decidim/participatory_processes/process_metadata_g_cell.rb +15 -0
  39. data/app/cells/decidim/participatory_processes/process_s_cell.rb +5 -25
  40. data/app/cells/decidim/participatory_processes/process_step/show.erb +48 -0
  41. data/app/cells/decidim/participatory_processes/process_step_cell.rb +30 -0
  42. data/app/cells/decidim/participatory_processes/processes/show.erb +16 -0
  43. data/app/cells/decidim/participatory_processes/processes_cell.rb +24 -0
  44. data/app/commands/decidim/participatory_processes/admin/activate_participatory_process_step.rb +1 -1
  45. data/app/commands/decidim/participatory_processes/admin/copy_participatory_process.rb +2 -2
  46. data/app/commands/decidim/participatory_processes/admin/create_participatory_process.rb +3 -1
  47. data/app/commands/decidim/participatory_processes/admin/create_participatory_process_group.rb +4 -2
  48. data/app/commands/decidim/participatory_processes/admin/create_participatory_process_step.rb +1 -1
  49. data/app/commands/decidim/participatory_processes/admin/create_participatory_process_type.rb +1 -1
  50. data/app/commands/decidim/participatory_processes/admin/destroy_participatory_process_group.rb +1 -1
  51. data/app/commands/decidim/participatory_processes/admin/destroy_participatory_process_step.rb +1 -1
  52. data/app/commands/decidim/participatory_processes/admin/destroy_participatory_process_type.rb +1 -1
  53. data/app/commands/decidim/participatory_processes/admin/import_participatory_process.rb +1 -1
  54. data/app/commands/decidim/participatory_processes/admin/reorder_participatory_process_steps.rb +1 -1
  55. data/app/commands/decidim/participatory_processes/admin/update_participatory_process.rb +1 -1
  56. data/app/commands/decidim/participatory_processes/admin/update_participatory_process_group.rb +2 -2
  57. data/app/commands/decidim/participatory_processes/admin/update_participatory_process_step.rb +1 -1
  58. data/app/commands/decidim/participatory_processes/admin/update_participatory_process_type.rb +1 -1
  59. data/app/constraints/decidim/participatory_processes/current_participatory_process.rb +1 -1
  60. data/app/controllers/decidim/participatory_processes/admin/application_controller.rb +29 -0
  61. data/app/controllers/decidim/participatory_processes/admin/categories_controller.rb +2 -0
  62. data/app/controllers/decidim/participatory_processes/admin/concerns/participatory_process_admin.rb +3 -1
  63. data/app/controllers/decidim/participatory_processes/admin/moderations/reports_controller.rb +1 -1
  64. data/app/controllers/decidim/participatory_processes/admin/moderations_controller.rb +1 -1
  65. data/app/controllers/decidim/participatory_processes/admin/participatory_process_attachment_collections_controller.rb +5 -0
  66. data/app/controllers/decidim/participatory_processes/admin/participatory_process_attachments_controller.rb +5 -0
  67. data/app/controllers/decidim/participatory_processes/admin/participatory_process_group_landing_page_content_blocks_controller.rb +1 -5
  68. data/app/controllers/decidim/participatory_processes/admin/participatory_process_group_landing_page_controller.rb +24 -7
  69. data/app/controllers/decidim/participatory_processes/admin/participatory_process_groups_controller.rb +16 -0
  70. data/app/controllers/decidim/participatory_processes/admin/participatory_process_imports_controller.rb +14 -0
  71. data/app/controllers/decidim/participatory_processes/admin/participatory_process_landing_page_content_blocks_controller.rb +37 -0
  72. data/app/controllers/decidim/participatory_processes/admin/participatory_process_landing_page_controller.rb +37 -0
  73. data/app/controllers/decidim/participatory_processes/admin/participatory_process_publications_controller.rb +9 -29
  74. data/app/controllers/decidim/participatory_processes/admin/participatory_process_step_activations_controller.rb +1 -1
  75. data/app/controllers/decidim/participatory_processes/admin/participatory_process_steps_controller.rb +16 -4
  76. data/app/controllers/decidim/participatory_processes/admin/participatory_process_types_controller.rb +19 -0
  77. data/app/controllers/decidim/participatory_processes/admin/participatory_process_user_roles_controller.rb +8 -91
  78. data/app/controllers/decidim/participatory_processes/admin/participatory_processes_controller.rb +3 -0
  79. data/app/controllers/decidim/participatory_processes/participatory_process_groups_controller.rb +14 -1
  80. data/app/controllers/decidim/participatory_processes/participatory_processes_controller.rb +19 -4
  81. data/app/events/decidim/participatory_process_role_assigned_event.rb +6 -6
  82. data/app/events/decidim/participatory_process_step_activated_event.rb +5 -4
  83. data/app/events/decidim/participatory_process_step_changed_event.rb +5 -4
  84. data/app/forms/decidim/participatory_processes/admin/participatory_process_copy_form.rb +1 -1
  85. data/app/forms/decidim/participatory_processes/admin/participatory_process_form.rb +1 -1
  86. data/app/forms/decidim/participatory_processes/admin/participatory_process_import_form.rb +1 -1
  87. data/app/forms/decidim/participatory_processes/admin/participatory_process_step_form.rb +2 -2
  88. data/app/forms/decidim/participatory_processes/admin/participatory_process_user_role_form.rb +2 -18
  89. data/app/helpers/decidim/participatory_processes/admin/participatory_process_helper.rb +1 -0
  90. data/app/helpers/decidim/participatory_processes/application_helper.rb +5 -0
  91. data/app/helpers/decidim/participatory_processes/participatory_process_helper.rb +37 -9
  92. data/app/helpers/decidim/participatory_processes/participatory_space_content_blocks_helper.rb +17 -0
  93. data/app/jobs/decidim/participatory_processes/change_active_step_job.rb +35 -0
  94. data/app/models/decidim/participatory_process.rb +5 -5
  95. data/app/models/decidim/participatory_process_group.rb +4 -0
  96. data/app/models/decidim/participatory_process_user_role.rb +5 -34
  97. data/app/packs/entrypoints/decidim_participatory_processes.js +0 -2
  98. data/app/packs/src/decidim/participatory_processes/admin/participatory_processes.js +2 -2
  99. data/app/permissions/decidim/participatory_processes/permissions.rb +11 -15
  100. data/app/presenters/decidim/participatory_processes/admin_log/participatory_process_group_presenter.rb +2 -2
  101. data/app/presenters/decidim/participatory_processes/admin_log/participatory_process_presenter.rb +2 -2
  102. data/app/presenters/decidim/participatory_processes/admin_log/participatory_process_type_presenter.rb +2 -2
  103. data/app/presenters/decidim/participatory_processes/admin_log/participatory_process_user_role_presenter.rb +2 -2
  104. data/app/presenters/decidim/participatory_processes/admin_log/step_presenter.rb +2 -2
  105. data/app/presenters/decidim/participatory_processes/participatory_process_group_stats_presenter.rb +4 -40
  106. data/app/presenters/decidim/participatory_processes/participatory_process_metric_charts_presenter.rb +0 -68
  107. data/app/presenters/decidim/participatory_processes/participatory_process_presenter.rb +6 -0
  108. data/app/presenters/decidim/participatory_processes/participatory_process_stats_presenter.rb +3 -42
  109. data/app/queries/decidim/participatory_processes/admin/admin_users.rb +1 -1
  110. data/app/queries/decidim/participatory_processes/admin/moderators.rb +1 -1
  111. data/app/serializers/decidim/participatory_processes/participatory_process_importer.rb +4 -4
  112. data/app/views/decidim/participatory_processes/admin/participatory_process_copies/_form.html.erb +24 -29
  113. data/app/views/decidim/participatory_processes/admin/participatory_process_copies/new.html.erb +16 -5
  114. data/app/views/decidim/participatory_processes/admin/participatory_process_groups/_form.html.erb +72 -50
  115. data/app/views/decidim/participatory_processes/admin/participatory_process_groups/edit.html.erb +15 -9
  116. data/app/views/decidim/participatory_processes/admin/participatory_process_groups/index.html.erb +49 -54
  117. data/app/views/decidim/participatory_processes/admin/participatory_process_groups/new.html.erb +28 -5
  118. data/app/views/decidim/participatory_processes/admin/participatory_process_imports/_form.html.erb +33 -39
  119. data/app/views/decidim/participatory_processes/admin/participatory_process_imports/new.html.erb +18 -5
  120. data/app/views/decidim/participatory_processes/admin/participatory_process_steps/_form.html.erb +18 -25
  121. data/app/views/decidim/participatory_processes/admin/participatory_process_steps/edit.html.erb +16 -5
  122. data/app/views/decidim/participatory_processes/admin/participatory_process_steps/index.html.erb +54 -54
  123. data/app/views/decidim/participatory_processes/admin/participatory_process_steps/new.html.erb +18 -5
  124. data/app/views/decidim/participatory_processes/admin/participatory_process_steps/show.html.erb +2 -2
  125. data/app/views/decidim/participatory_processes/admin/participatory_process_types/_form.html.erb +6 -8
  126. data/app/views/decidim/participatory_processes/admin/participatory_process_types/edit.html.erb +14 -6
  127. data/app/views/decidim/participatory_processes/admin/participatory_process_types/index.html.erb +47 -50
  128. data/app/views/decidim/participatory_processes/admin/participatory_process_types/new.html.erb +14 -6
  129. data/app/views/decidim/participatory_processes/admin/participatory_process_user_roles/_form.html.erb +14 -18
  130. data/app/views/decidim/participatory_processes/admin/participatory_process_user_roles/edit.html.erb +17 -6
  131. data/app/views/decidim/participatory_processes/admin/participatory_process_user_roles/index.html.erb +59 -60
  132. data/app/views/decidim/participatory_processes/admin/participatory_process_user_roles/new.html.erb +16 -5
  133. data/app/views/decidim/participatory_processes/admin/participatory_processes/_form.html.erb +193 -146
  134. data/app/views/decidim/participatory_processes/admin/participatory_processes/edit.html.erb +25 -11
  135. data/app/views/decidim/participatory_processes/admin/participatory_processes/index.html.erb +111 -128
  136. data/app/views/decidim/participatory_processes/admin/participatory_processes/new.html.erb +16 -9
  137. data/app/views/decidim/participatory_processes/participatory_process_groups/show.html.erb +6 -10
  138. data/app/views/decidim/participatory_processes/participatory_processes/_collection.html.erb +8 -0
  139. data/app/views/decidim/participatory_processes/participatory_processes/all_metrics.html.erb +21 -8
  140. data/app/views/decidim/participatory_processes/participatory_processes/index.html.erb +19 -17
  141. data/app/views/decidim/participatory_processes/participatory_processes/index.js.erb +1 -8
  142. data/app/views/decidim/participatory_processes/participatory_processes/show.html.erb +14 -128
  143. data/app/views/layouts/decidim/_process_header.html.erb +15 -26
  144. data/app/views/layouts/decidim/_process_nav_item.html.erb +6 -0
  145. data/app/views/layouts/decidim/admin/_manage_processes.html.erb +36 -0
  146. data/app/views/layouts/decidim/admin/participatory_process.html.erb +12 -14
  147. data/app/views/layouts/decidim/admin/participatory_process_group.html.erb +23 -13
  148. data/app/views/layouts/decidim/admin/participatory_process_groups.html.erb +13 -0
  149. data/app/views/layouts/decidim/admin/participatory_process_type.html.erb +13 -11
  150. data/app/views/layouts/decidim/admin/participatory_processes.html.erb +14 -8
  151. data/app/views/layouts/decidim/participatory_process.html.erb +7 -14
  152. data/config/locales/ar.yml +1 -55
  153. data/config/locales/bg.yml +0 -72
  154. data/config/locales/ca.yml +50 -70
  155. data/config/locales/cs.yml +51 -71
  156. data/config/locales/de.yml +51 -71
  157. data/config/locales/el.yml +8 -64
  158. data/config/locales/en.yml +52 -72
  159. data/config/locales/es-MX.yml +49 -69
  160. data/config/locales/es-PY.yml +49 -69
  161. data/config/locales/es.yml +49 -69
  162. data/config/locales/eu.yml +89 -112
  163. data/config/locales/fi-plain.yml +50 -70
  164. data/config/locales/fi.yml +51 -71
  165. data/config/locales/fr-CA.yml +51 -71
  166. data/config/locales/fr.yml +52 -72
  167. data/config/locales/ga-IE.yml +0 -16
  168. data/config/locales/gl.yml +0 -67
  169. data/config/locales/hu.yml +6 -66
  170. data/config/locales/id-ID.yml +1 -55
  171. data/config/locales/is-IS.yml +0 -24
  172. data/config/locales/it.yml +0 -67
  173. data/config/locales/ja.yml +51 -71
  174. data/config/locales/lb.yml +1 -153
  175. data/config/locales/lt.yml +39 -65
  176. data/config/locales/lv.yml +1 -59
  177. data/config/locales/nl.yml +0 -67
  178. data/config/locales/no.yml +0 -92
  179. data/config/locales/pl.yml +0 -100
  180. data/config/locales/pt-BR.yml +1 -113
  181. data/config/locales/pt.yml +0 -67
  182. data/config/locales/ro-RO.yml +4 -64
  183. data/config/locales/ru.yml +0 -49
  184. data/config/locales/sk.yml +1 -56
  185. data/config/locales/sl.yml +0 -7
  186. data/config/locales/sr-CS.yml +0 -4
  187. data/config/locales/sv.yml +15 -66
  188. data/config/locales/tr-TR.yml +7 -68
  189. data/config/locales/uk.yml +0 -49
  190. data/config/locales/zh-CN.yml +2 -63
  191. data/config/locales/zh-TW.yml +3 -63
  192. data/db/migrate/20220315100140_change_steps_dates_to_datetime.rb +8 -0
  193. data/lib/decidim/api/participatory_process_step_type.rb +2 -2
  194. data/lib/decidim/participatory_processes/admin_engine.rb +20 -139
  195. data/lib/decidim/participatory_processes/content_blocks/registry_manager.rb +278 -0
  196. data/lib/decidim/participatory_processes/engine.rb +13 -103
  197. data/lib/decidim/participatory_processes/menu.rb +190 -0
  198. data/lib/decidim/participatory_processes/participatory_space.rb +7 -204
  199. data/lib/decidim/participatory_processes/query_extensions.rb +2 -2
  200. data/lib/decidim/participatory_processes/seeds.rb +164 -0
  201. data/lib/decidim/participatory_processes/test/factories.rb +58 -65
  202. data/lib/decidim/participatory_processes/version.rb +1 -1
  203. data/lib/tasks/decidim_participatory_processes.rake +8 -0
  204. metadata +65 -70
  205. data/app/cells/decidim/participatory_process_groups/content_blocks/highlighted_participatory_processes/filters.erb +0 -21
  206. data/app/cells/decidim/participatory_process_groups/content_blocks/highlighted_participatory_processes/filters_small_view.erb +0 -18
  207. data/app/cells/decidim/participatory_process_groups/content_blocks/highlighted_participatory_processes/participatory_space_filters.erb +0 -6
  208. data/app/cells/decidim/participatory_process_groups/content_blocks/highlighted_participatory_processes/show.erb +0 -8
  209. data/app/cells/decidim/participatory_process_groups/content_blocks/highlighted_participatory_processes/title_filter_order.erb +0 -8
  210. data/app/cells/decidim/participatory_process_groups/content_blocks/highlighted_participatory_processes_cell.rb +0 -60
  211. data/app/cells/decidim/participatory_process_groups/content_blocks/html/show.erb +0 -3
  212. data/app/cells/decidim/participatory_process_groups/content_blocks/html_cell.rb +0 -13
  213. data/app/cells/decidim/participatory_process_groups/content_blocks/metadata/show.erb +0 -28
  214. data/app/cells/decidim/participatory_process_groups/content_blocks/metadata_cell.rb +0 -15
  215. data/app/cells/decidim/participatory_process_groups/content_blocks/title/show.erb +0 -43
  216. data/app/cells/decidim/participatory_process_groups/content_blocks/title_cell.rb +0 -64
  217. data/app/cells/decidim/participatory_processes/content_blocks/highlighted_processes/_all_processes.erb +0 -9
  218. data/app/cells/decidim/participatory_processes/content_blocks/highlighted_processes/show.erb +0 -14
  219. data/app/cells/decidim/participatory_processes/content_blocks/highlighted_processes/single_process.erb +0 -48
  220. data/app/cells/decidim/participatory_processes/process_group_m/footer.erb +0 -8
  221. data/app/cells/decidim/participatory_processes/process_group_m_cell.rb +0 -60
  222. data/app/cells/decidim/participatory_processes/process_group_s/image.erb +0 -1
  223. data/app/cells/decidim/participatory_processes/process_group_s/show.erb +0 -8
  224. data/app/cells/decidim/participatory_processes/process_m/data.erb +0 -21
  225. data/app/cells/decidim/participatory_processes/process_m/footer.erb +0 -14
  226. data/app/cells/decidim/participatory_processes/process_m/tags.erb +0 -8
  227. data/app/cells/decidim/participatory_processes/process_m_cell.rb +0 -87
  228. data/app/cells/decidim/participatory_processes/process_s/image.erb +0 -1
  229. data/app/cells/decidim/participatory_processes/process_s/show.erb +0 -14
  230. data/app/commands/decidim/participatory_processes/admin/create_participatory_process_admin.rb +0 -58
  231. data/app/commands/decidim/participatory_processes/admin/destroy_participatory_process_admin.rb +0 -58
  232. data/app/commands/decidim/participatory_processes/admin/notify_role_assigned_to_participatory_process.rb +0 -22
  233. data/app/commands/decidim/participatory_processes/admin/publish_participatory_process.rb +0 -40
  234. data/app/commands/decidim/participatory_processes/admin/unpublish_participatory_process.rb +0 -40
  235. data/app/commands/decidim/participatory_processes/admin/update_participatory_process_admin.rb +0 -56
  236. data/app/controllers/decidim/participatory_processes/participatory_process_steps_controller.rb +0 -28
  237. data/app/controllers/decidim/participatory_processes/widgets_controller.rb +0 -37
  238. data/app/packs/src/decidim/participatory_processes/filters.js +0 -28
  239. data/app/views/decidim/participatory_process_steps/_participatory_process_step.html.erb +0 -16
  240. data/app/views/decidim/participatory_processes/participatory_process_steps/_timeline.html.erb +0 -7
  241. data/app/views/decidim/participatory_processes/participatory_process_steps/index.html.erb +0 -18
  242. data/app/views/decidim/participatory_processes/participatory_processes/_metrics.html.erb +0 -10
  243. data/app/views/decidim/participatory_processes/participatory_processes/_order_by_processes.html.erb +0 -1
  244. data/app/views/decidim/participatory_processes/participatory_processes/_participatory_process_group.html.erb +0 -4
  245. data/app/views/decidim/participatory_processes/participatory_processes/_promoted_process.html.erb +0 -39
  246. data/app/views/decidim/participatory_processes/participatory_processes/_promoted_process_group.html.erb +0 -31
  247. data/app/views/layouts/decidim/_process_header_steps.html.erb +0 -37
  248. data/app/views/layouts/decidim/_process_navigation.html.erb +0 -20
  249. data/config/locales/he-IL.yml +0 -1
  250. data/db/seeds/Exampledocument.pdf +0 -0
  251. data/db/seeds/city.jpeg +0 -0
  252. data/db/seeds/city2.jpeg +0 -0
  253. data/db/seeds/homepage_image.jpg +0 -0
  254. data/decidim-participatory_processes.gemspec +0 -31
@@ -1,61 +1,58 @@
1
1
  <% add_decidim_page_title(t("titles.participatory_process_types", scope: "decidim.admin")) %>
2
2
  <div class="card" id="participatory-process-types">
3
- <div class="card-divider">
4
- <h2 class="card-title">
3
+ <div class="item_show__header">
4
+ <h2 class="item_show__header-title">
5
5
  <%= t("titles.participatory_process_types", scope: "decidim.admin") %>
6
6
  <%= link_to(
7
7
  t("actions.new_process_type", scope: "decidim.admin"),
8
8
  [:new, :participatory_process_type],
9
- class: "button tiny button--title"
9
+ class: "button button__sm button__secondary"
10
10
  ) if allowed_to? :create, :participatory_process_type %>
11
11
  </h2>
12
12
  </div>
13
- <div class="card-section">
14
- <div class="table-scroll">
15
- <table class="table-list">
16
- <thead>
17
- <tr>
18
- <th><%= t("models.participatory_process_type.fields.title", scope: "decidim.admin") %></th>
19
- <th><%= t("models.participatory_process_type.fields.created_at", scope: "decidim.admin") %></th>
20
- <th></th>
21
- </tr>
22
- </thead>
23
- <tbody>
24
- <% collection.each do |participatory_process_type| %>
25
- <tr>
26
- <td>
27
- <% if allowed_to?(:update, :participatory_process_type, participatory_process_type: participatory_process_type) %>
28
- <%= link_to(
29
- translated_attribute(participatory_process_type.title),
30
- edit_participatory_process_type_path(participatory_process_type)
31
- ) %>
32
- <% else %>
33
- <%= translated_attribute(participatory_process_type.title) %></td>
34
- <% end %>
35
- <td><%= l(participatory_process_type.created_at, format: :short) %></td>
36
- <td class="table-list__actions">
37
- <% if allowed_to?(:update, :participatory_process_type, participatory_process_type: participatory_process_type) %>
38
- <%= icon_link_to(
39
- "pencil",
40
- edit_participatory_process_type_path(participatory_process_type),
41
- t("actions.edit", scope: "decidim.admin"),
42
- class: "action-icon--new"
43
- ) %>
44
- <% end %>
45
- <% if allowed_to?(:destroy, :participatory_process_type, participatory_process_type: participatory_process_type) %>
46
- <%= icon_link_to(
47
- "circle-x",
48
- participatory_process_type_path(participatory_process_type),
49
- t("actions.destroy", scope: "decidim.admin"),
50
- class: "action-icon--remove",
51
- method: :delete,
52
- data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin") }
53
- ) %>
54
- <% end %>
55
- </td>
56
- <% end %>
57
- </tbody>
58
- </table>
59
- </div>
13
+ <div class="table-scroll">
14
+ <table class="table-list">
15
+ <thead>
16
+ <tr>
17
+ <th><%= t("models.participatory_process_type.fields.title", scope: "decidim.admin") %></th>
18
+ <th><%= t("models.participatory_process_type.fields.created_at", scope: "decidim.admin") %></th>
19
+ <th></th>
20
+ </tr>
21
+ </thead>
22
+ <tbody>
23
+ <% collection.each do |participatory_process_type| %>
24
+ <tr>
25
+ <td>
26
+ <% if allowed_to?(:update, :participatory_process_type, participatory_process_type: participatory_process_type) %>
27
+ <%= link_to translated_attribute(participatory_process_type.title), edit_participatory_process_type_path(participatory_process_type) %>
28
+ <% else %>
29
+ <%= translated_attribute(participatory_process_type.title) %>
30
+ <% end %>
31
+ </td>
32
+ <td><%= l(participatory_process_type.created_at, format: :short) %></td>
33
+ <td class="table-list__actions">
34
+ <% if allowed_to?(:update, :participatory_process_type, participatory_process_type: participatory_process_type) %>
35
+ <%= icon_link_to(
36
+ "pencil-line",
37
+ edit_participatory_process_type_path(participatory_process_type),
38
+ t("actions.edit", scope: "decidim.admin"),
39
+ class: "action-icon--new"
40
+ ) %>
41
+ <% end %>
42
+ <% if allowed_to?(:destroy, :participatory_process_type, participatory_process_type: participatory_process_type) %>
43
+ <%= icon_link_to(
44
+ "delete-bin-line",
45
+ participatory_process_type_path(participatory_process_type),
46
+ t("actions.destroy", scope: "decidim.admin"),
47
+ class: "action-icon--remove",
48
+ method: :delete,
49
+ data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin") }
50
+ ) %>
51
+ <% end %>
52
+ </td>
53
+ </tr>
54
+ <% end %>
55
+ </tbody>
56
+ </table>
60
57
  </div>
61
58
  </div>
@@ -1,10 +1,18 @@
1
1
  <% add_decidim_page_title(t("participatory_process_types.new.title", scope: "decidim.admin")) %>
2
- <%= decidim_form_for(@form, html: { class: "form new_participatory_process_type" }) do |f| %>
3
- <h2 class="process-title-summary">
2
+ <div class="item_show__header">
3
+ <h2 class="item_show__header-title">
4
4
  <%= t("participatory_process_types.new.title", scope: "decidim.admin") %>
5
5
  </h2>
6
- <%= render partial: "form", object: f %>
7
- <div class="button--double form-general-submit">
8
- <%= f.submit t("participatory_process_types.new.create", scope: "decidim.admin"), class: "button" %>
6
+ </div>
7
+ <div class="item__edit item__edit-1col">
8
+ <div class="item__edit-form">
9
+ <%= decidim_form_for(@form, html: { class: "form-defaults form new_participatory_process_type" }) do |f| %>
10
+ <%= render partial: "form", object: f %>
11
+ <div class="item__edit-sticky">
12
+ <div class="item__edit-sticky-container">
13
+ <%= f.submit t("participatory_process_types.new.create", scope: "decidim.admin"), class: "button button__sm button__secondary" %>
14
+ </div>
15
+ </div>
16
+ <% end %>
9
17
  </div>
10
- <% end %>
18
+ </div>
@@ -1,21 +1,17 @@
1
- <div class="card">
2
- <div class="card-divider">
3
- <h2 class="card-title">
4
- <%= title %>
5
- </h2>
6
- </div>
7
-
8
- <div class="card-section">
9
- <div class="row">
10
- <div class="columns xlarge-4">
11
- <%= form.text_field :name, readonly: @form.persisted? %>
12
- </div>
13
- <div class="columns xlarge-4">
14
- <%= form.email_field :email, readonly: @form.persisted? %>
15
- </div>
16
- <div class="columns xlarge-4">
17
- <%= form.label :role %>
18
- <%= select :participatory_process_user_role, :role, @form.roles, include_blank: false %>
1
+ <div class="form__wrapper">
2
+ <div class="card pt-4">
3
+ <div id="panel-title" class="card-section">
4
+ <div class="row">
5
+ <div class="columns">
6
+ <%= form.text_field :name, readonly: @form.persisted? %>
7
+ </div>
8
+ <div class="columns">
9
+ <%= form.email_field :email, readonly: @form.persisted? %>
10
+ </div>
11
+ <div class="columns">
12
+ <%= form.label :role %>
13
+ <%= select :participatory_process_user_role, :role, @form.roles, include_blank: false %>
14
+ </div>
19
15
  </div>
20
16
  </div>
21
17
  </div>
@@ -1,9 +1,20 @@
1
1
  <% add_decidim_page_title(t("participatory_process_user_roles.edit.title", scope: "decidim.admin")) %>
2
2
 
3
- <%= decidim_form_for(@form, url: participatory_process_user_role_path(@user_role.participatory_process, @user_role), html: { class: "form edit_participatory_process_user_roles" }) do |f| %>
4
- <%= render partial: "form", object: f, locals: { title: t("participatory_process_user_roles.edit.title", scope: "decidim.admin") } %>
3
+ <div class="item_show__header">
4
+ <h2 class="item_show__header-title">
5
+ <%= t("participatory_process_user_roles.edit.title", scope: "decidim.admin") %>
6
+ </h2>
7
+ </div>
5
8
 
6
- <div class="button--double form-general-submit">
7
- <%= f.submit t("participatory_process_user_roles.edit.update", scope: "decidim.admin") %>
8
- </div>
9
- <% end %>
9
+ <div class="item__edit item__edit-1col">
10
+ <div class="item__edit-form">
11
+ <%= decidim_form_for(@form, url: participatory_process_user_role_path(@user_role.participatory_process, @user_role), html: { class: "form-defaults form edit_participatory_process_user_roles" }) do |f| %>
12
+ <%= render partial: "form", object: f, locals: { title: t("participatory_process_user_roles.edit.title", scope: "decidim.admin") } %>
13
+ <div class="item__edit-sticky">
14
+ <div class="item__edit-sticky-container">
15
+ <%= f.submit t("participatory_process_user_roles.edit.update", scope: "decidim.admin"), class: "button button__sm button__secondary" %>
16
+ </div>
17
+ </div>
18
+ <% end %>
19
+ </div>
20
+ </div>
@@ -1,73 +1,72 @@
1
1
  <% add_decidim_page_title(t("participatory_process_user_roles.index.process_admins_title", scope: "decidim.admin")) %>
2
2
 
3
- <div class='card' id="process_admins">
4
- <div class="card-divider">
5
- <h2 class="card-title">
3
+ <div class="card" id="process_admins">
4
+ <div class="item_show__header">
5
+ <h2 class="item_show__header-title">
6
6
  <%= t("participatory_process_user_roles.index.process_admins_title", scope: "decidim.admin") %>
7
7
  <% if allowed_to? :create, :process_user_role %>
8
- <%= link_to t("actions.new_process_user_role", scope: "decidim.admin"), new_participatory_process_user_role_path(current_participatory_process), class: "button tiny button--title new" %>
8
+ <%= link_to t("actions.new_process_user_role", scope: "decidim.admin"), new_participatory_process_user_role_path(current_participatory_process), class: "button button__sm button__secondary new ml-auto" %>
9
9
  <% end %>
10
10
  </h2>
11
11
  </div>
12
12
  <%= admin_filter_selector %>
13
- <div class="card-section">
14
- <div class="table-scroll">
15
- <table class="stack table-list">
16
- <thead>
13
+ <div class="table-scroll">
14
+ <table class="stack table-list">
15
+ <thead>
16
+ <tr>
17
+ <th><%= sort_link(query, :name,t("models.participatory_process_user_role.fields.name", scope: "decidim.admin"), default_order: :desc) %></th>
18
+ <th><%= sort_link(query, :email, t("models.participatory_process_user_role.fields.email", scope: "decidim.admin"), default_order: :desc) %></th>
19
+ <th><%= sort_link(query, :last_sign_in_at, t("models.user.fields.last_sign_in_at", scope: "decidim.admin"), default_order: :desc) %></th>
20
+ <th><%= sort_link(query, :invitation_accepted_at, t("models.user.fields.invitation_accepted_at", scope: "decidim.admin"), default_order: :desc) %></th>
21
+ <th><%= sort_link(query, :role, t("models.participatory_process_user_role.fields.role", scope: "decidim.admin"), default_order: :desc) %></th>
22
+ <th class="actions"></th>
23
+ </tr>
24
+ </thead>
25
+ <tbody>
26
+ <% filtered_collection.each do |role| %>
17
27
  <tr>
18
- <th><%= sort_link(query, :name,t("models.participatory_process_user_role.fields.name", scope: "decidim.admin"), default_order: :desc) %></th>
19
- <th><%= sort_link(query, :email, t("models.participatory_process_user_role.fields.email", scope: "decidim.admin"), default_order: :desc) %></th>
20
- <th><%= sort_link(query, :last_sign_in_at, t("models.user.fields.last_sign_in_at", scope: "decidim.admin"), default_order: :desc) %></th>
21
- <th><%= sort_link(query, :invitation_accepted_at, t("models.user.fields.invitation_accepted_at", scope: "decidim.admin"), default_order: :desc) %></th>
22
- <th><%= sort_link(query, :role, t("models.participatory_process_user_role.fields.role", scope: "decidim.admin"), default_order: :desc) %></th>
23
- <th class="actions"></th>
24
- </tr>
25
- </thead>
26
- <tbody>
27
- <% @participatory_process_user_roles.each do |role| %>
28
- <tr>
29
- <td>
30
- <%= role.user.name %><br>
31
- </td>
32
- <td>
33
- <%= role.user.email %><br>
34
- </td>
35
- <td>
36
- <% if role.user.invitation_sent_at %>
37
- <%= l role.user.invitation_sent_at, format: :short %>
38
- <% end %>
39
- </td>
40
- <td>
41
- <% if role.user.invitation_accepted_at %>
42
- <%= l role.user.invitation_accepted_at, format: :short %>
43
- <% end %>
44
- </td>
45
- <td>
46
- <%= t("#{role.role}", scope: "decidim.admin.models.participatory_process_user_role.roles") %><br>
47
- </td>
48
- <td class="table-list__actions">
49
- <% if allowed_to?(:invite, :process_user_role, user_role: role) && role.user.invited_to_sign_up? %>
50
- <%= icon_link_to "reload", resend_invitation_participatory_process_user_role_path(current_participatory_process, role), t("actions.resend_invitation", scope: "decidim.admin"), class: "resend-invitation", method: :post %>
51
- <% else %>
52
- <span class="action-space icon"></span>
53
- <% end %>
28
+ <td>
29
+ <%= role.user.name %><br>
30
+ </td>
31
+ <td>
32
+ <%= role.user.email %><br>
33
+ </td>
34
+ <td>
35
+ <% if role.user.invitation_sent_at %>
36
+ <%= l role.user.invitation_sent_at, format: :short %>
37
+ <% end %>
38
+ </td>
39
+ <td>
40
+ <% if role.user.invitation_accepted_at %>
41
+ <%= l role.user.invitation_accepted_at, format: :short %>
42
+ <% end %>
43
+ </td>
44
+ <td>
45
+ <%= t("#{role.role}", scope: "decidim.admin.models.participatory_process_user_role.roles") %><br>
46
+ </td>
47
+ <td class="table-list__actions">
48
+ <% if allowed_to? :update, :process_user_role, user_role: role %>
49
+ <%= icon_link_to "pencil-line", edit_participatory_process_user_role_path(current_participatory_process, role), t("actions.edit", scope: "decidim.admin"), class: "action-icon--edit" %>
50
+ <% else %>
51
+ <span class="action-space icon"></span>
52
+ <% end %>
54
53
 
55
- <% if allowed_to? :update, :process_user_role, user_role: role %>
56
- <%= icon_link_to "pencil", edit_participatory_process_user_role_path(current_participatory_process, role), t("actions.edit", scope: "decidim.admin"), class: "action-icon--edit" %>
57
- <% else %>
58
- <span class="action-space icon"></span>
59
- <% end %>
54
+ <% if allowed_to?(:invite, :process_user_role, user_role: role) && role.user.invited_to_sign_up? %>
55
+ <%= icon_link_to "refresh-line", resend_invitation_participatory_process_user_role_path(current_participatory_process, role), t("actions.resend_invitation", scope: "decidim.admin"), class: "resend-invitation", method: :post %>
56
+ <% else %>
57
+ <span class="action-space icon"></span>
58
+ <% end %>
60
59
 
61
- <% if allowed_to? :destroy, :process_user_role, user_role: role %>
62
- <%= icon_link_to "circle-x", participatory_process_user_role_path(current_participatory_process, role), t("actions.destroy", scope: "decidim.admin"), class: "action-icon--remove", method: :delete, data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin") } %>
63
- <% else %>
64
- <span class="action-space icon"></span>
65
- <% end %>
66
- </td>
67
- </tr>
68
- <% end %>
69
- </tbody>
70
- </table>
71
- </div>
60
+ <% if allowed_to? :destroy, :process_user_role, user_role: role %>
61
+ <%= icon_link_to "delete-bin-line", participatory_process_user_role_path(current_participatory_process, role), t("actions.destroy", scope: "decidim.admin"), class: "action-icon--remove", method: :delete, data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin") } %>
62
+ <% else %>
63
+ <span class="action-space icon"></span>
64
+ <% end %>
65
+ </td>
66
+ </tr>
67
+ <% end %>
68
+ </tbody>
69
+ </table>
72
70
  </div>
73
71
  </div>
72
+ <%= decidim_paginate filtered_collection %>
@@ -1,9 +1,20 @@
1
1
  <% add_decidim_page_title(t("participatory_process_user_roles.new.title", scope: "decidim.admin")) %>
2
2
 
3
- <%= decidim_form_for(@form, html: { class: "form new_participatory_process_user_role" }) do |f| %>
4
- <%= render partial: "form", object: f, locals: { title: t("participatory_process_user_roles.new.title", scope: "decidim.admin") } %>
3
+ <div class="item_show__header">
4
+ <h2 class="item_show__header-title">
5
+ <%= t("participatory_process_user_roles.new.title", scope: "decidim.admin") %>
6
+ </h2>
7
+ </div>
5
8
 
6
- <div class="button--double form-general-submit">
7
- <%= f.submit t("participatory_process_user_roles.new.create", scope: "decidim.admin") %>
9
+ <div class="item__edit item__edit-1col">
10
+ <div class="item__edit-form">
11
+ <%= decidim_form_for(@form, html: { class: "form-defaults form new_participatory_process_user_role" }) do |f| %>
12
+ <%= render partial: "form", object: f %>
13
+ <div class="item__edit-sticky">
14
+ <div class="item__edit-sticky-container">
15
+ <%= f.submit t("participatory_process_user_roles.new.create", scope: "decidim.admin"), class: "button button__sm button__secondary" %>
16
+ </div>
17
+ </div>
18
+ <% end %>
8
19
  </div>
9
- <% end %>
20
+ </div>