decidim-admin 0.31.7 → 0.32.0.rc1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +2 -12
- data/app/cells/decidim/admin/attachments_privacy_warning/show.erb +1 -1
- data/app/cells/decidim/admin/attachments_privacy_warning_cell.rb +2 -6
- data/app/commands/decidim/admin/content_blocks/reorder_content_blocks.rb +1 -1
- data/app/commands/decidim/admin/create_newsletter.rb +1 -1
- data/app/commands/decidim/admin/create_taxonomy_filter.rb +2 -16
- data/app/commands/decidim/admin/participatory_space/create_member.rb +99 -0
- data/app/commands/decidim/admin/participatory_space/destroy_member.rb +30 -0
- data/app/commands/decidim/admin/participatory_space/import_member_csv.rb +46 -0
- data/app/commands/decidim/admin/participatory_space/publish_all_members.rb +52 -0
- data/app/commands/decidim/admin/participatory_space/unpublish_all_members.rb +52 -0
- data/app/commands/decidim/admin/participatory_space/update_member.rb +13 -0
- data/app/commands/decidim/admin/reorder_components.rb +1 -1
- data/app/commands/decidim/admin/reorder_taxonomies.rb +1 -1
- data/app/commands/decidim/admin/update_organization.rb +1 -1
- data/app/commands/decidim/admin/update_taxonomy_filter.rb +6 -24
- data/app/controllers/concerns/decidim/admin/content_blocks/landing_page.rb +1 -0
- data/app/controllers/concerns/decidim/admin/content_blocks/landing_page_content_blocks.rb +3 -2
- data/app/controllers/concerns/decidim/admin/filterable.rb +4 -4
- data/app/controllers/concerns/decidim/admin/participatory_space_admin_context.rb +1 -0
- data/app/controllers/concerns/decidim/admin/participatory_space_export.rb +1 -1
- data/app/controllers/decidim/admin/area_types_controller.rb +2 -2
- data/app/controllers/decidim/admin/areas_controller.rb +3 -2
- data/app/controllers/decidim/admin/block_user_controller.rb +2 -4
- data/app/controllers/decidim/admin/component_permissions_controller.rb +1 -1
- data/app/controllers/decidim/admin/components/base_controller.rb +13 -9
- data/app/controllers/decidim/admin/components_controller.rb +3 -2
- data/app/controllers/decidim/admin/concerns/has_attachment_collections.rb +2 -2
- data/app/controllers/decidim/admin/concerns/has_attachments.rb +2 -2
- data/app/controllers/decidim/admin/conflicts_controller.rb +1 -1
- data/app/controllers/decidim/admin/exports_controller.rb +1 -1
- data/app/controllers/decidim/admin/impersonations_controller.rb +1 -1
- data/app/controllers/decidim/admin/imports_controller.rb +2 -1
- data/app/controllers/decidim/admin/managed_users/promotions_controller.rb +1 -1
- data/app/controllers/decidim/admin/newsletters_controller.rb +9 -9
- data/app/controllers/decidim/admin/officializations_controller.rb +0 -2
- data/app/controllers/decidim/admin/organization_appearance_controller.rb +1 -1
- data/app/controllers/decidim/admin/organization_controller.rb +30 -1
- data/app/controllers/decidim/admin/organization_external_domain_allowlist_controller.rb +1 -1
- data/app/controllers/decidim/admin/participatory_space/concerns/has_members.rb +166 -0
- data/app/controllers/decidim/admin/participatory_space/concerns/has_members_csv_import.rb +67 -0
- data/app/controllers/decidim/admin/participatory_space/concerns/members_filterable.rb +36 -0
- data/app/controllers/decidim/admin/participatory_space/user_role_controller.rb +2 -2
- data/app/controllers/decidim/admin/reminders_controller.rb +1 -1
- data/app/controllers/decidim/admin/resource_permissions_controller.rb +1 -1
- data/app/controllers/decidim/admin/scope_types_controller.rb +2 -2
- data/app/controllers/decidim/admin/scopes_controller.rb +3 -2
- data/app/controllers/decidim/admin/share_tokens_controller.rb +2 -2
- data/app/controllers/decidim/admin/space_publications_controller.rb +2 -2
- data/app/controllers/decidim/admin/static_page_topics_controller.rb +2 -2
- data/app/controllers/decidim/admin/static_pages_controller.rb +2 -2
- data/app/controllers/decidim/admin/taxonomies_controller.rb +3 -3
- data/app/controllers/decidim/admin/taxonomy_filters_controller.rb +3 -3
- data/app/controllers/decidim/admin/taxonomy_items_controller.rb +3 -3
- data/app/controllers/decidim/admin/users_controller.rb +1 -1
- data/app/forms/decidim/admin/content_block_form.rb +28 -1
- data/app/forms/decidim/admin/organization_form.rb +0 -1
- data/app/forms/decidim/admin/participatory_space/member_csv_import_form.rb +33 -0
- data/app/forms/decidim/admin/participatory_space/member_form.rb +26 -0
- data/app/forms/decidim/admin/participatory_space_admin_user_form.rb +1 -1
- data/app/forms/decidim/admin/selective_newsletter_form.rb +7 -7
- data/app/forms/decidim/admin/taxonomy_filter_form.rb +10 -11
- data/app/helpers/decidim/admin/newsletters_helper.rb +8 -5
- data/app/helpers/decidim/admin/search_form_helper.rb +17 -0
- data/app/helpers/decidim/admin/settings_helper.rb +2 -0
- data/app/jobs/decidim/admin/newsletter_job.rb +2 -2
- data/app/jobs/decidim/admin/participatory_space/destroy_members_follows_job.rb +36 -0
- data/app/jobs/decidim/admin/participatory_space/import_member_csv_job.rb +29 -0
- data/app/packs/src/decidim/admin/admin_autocomplete.js +10 -16
- data/app/packs/src/decidim/admin/controllers/access_mode/access_mode.test.js +68 -0
- data/app/packs/src/decidim/admin/controllers/access_mode/controller.js +52 -0
- data/app/packs/src/decidim/admin/newsletters.js +2 -2
- data/app/packs/stylesheets/decidim/admin/_datepicker.scss +0 -4
- data/app/packs/stylesheets/decidim/admin/application.scss +1 -1
- data/app/queries/decidim/admin/newsletter_recipients.rb +8 -8
- data/app/views/decidim/admin/admin_terms/show.html.erb +3 -1
- data/app/views/decidim/admin/area_types/index.html.erb +3 -2
- data/app/views/decidim/admin/areas/index.html.erb +3 -2
- data/app/views/decidim/admin/attachment_collections/edit.html.erb +2 -2
- data/app/views/decidim/admin/attachment_collections/index.html.erb +3 -3
- data/app/views/decidim/admin/attachment_collections/new.html.erb +2 -2
- data/app/views/decidim/admin/attachments/index.html.erb +3 -2
- data/app/views/decidim/admin/authorization_workflows/index.html.erb +2 -2
- data/app/views/decidim/admin/block_user/new.html.erb +1 -0
- data/app/views/decidim/admin/components/_actions.html.erb +1 -1
- data/app/views/decidim/admin/components/index.html.erb +2 -2
- data/app/views/decidim/admin/components/manage_trash.html.erb +2 -2
- data/app/views/decidim/admin/conflicts/edit.html.erb +3 -1
- data/app/views/decidim/admin/conflicts/index.html.erb +3 -2
- data/app/views/decidim/admin/dashboard/show.html.erb +4 -4
- data/app/views/decidim/admin/help_sections/update.html.erb +2 -0
- data/app/views/decidim/admin/impersonatable_users/index.html.erb +3 -2
- data/app/views/decidim/admin/impersonations/_form.html.erb +2 -2
- data/app/views/decidim/admin/impersonations/new.html.erb +3 -2
- data/app/views/decidim/admin/imports/new.html.erb +1 -0
- data/app/views/decidim/admin/logs/_logs_list.html.erb +1 -1
- data/app/views/decidim/admin/logs/index.html.erb +1 -1
- data/app/views/decidim/admin/managed_users/impersonation_logs/index.html.erb +6 -5
- data/app/views/decidim/admin/managed_users/promotions/new.html.erb +3 -2
- data/app/views/decidim/admin/{participatory_space_private_users → members}/edit.html.erb +2 -2
- data/app/views/decidim/admin/{participatory_space_private_users → members}/index.html.erb +25 -25
- data/app/views/decidim/admin/{participatory_space_private_users → members}/new.html.erb +2 -2
- data/app/views/decidim/admin/{participatory_space_private_users_csv_imports → members_csv_imports}/new.html.erb +2 -2
- data/app/views/decidim/admin/moderations/_moderation-tr.html.erb +3 -7
- data/app/views/decidim/admin/moderations/_moderations-thead.html.erb +0 -1
- data/app/views/decidim/admin/moderations/reports/index.html.erb +1 -1
- data/app/views/decidim/admin/newsletter_templates/show.html.erb +3 -2
- data/app/views/decidim/admin/newsletters/confirm_recipients.html.erb +4 -6
- data/app/views/decidim/admin/newsletters/index.html.erb +2 -2
- data/app/views/decidim/admin/newsletters/select_recipients_to_deliver.html.erb +2 -2
- data/app/views/decidim/admin/newsletters/show.html.erb +3 -2
- data/app/views/decidim/admin/officializations/index.html.erb +6 -4
- data/app/views/decidim/admin/officializations/show_email.html.erb +3 -7
- data/app/views/decidim/admin/organization/form/_extra_features.html.erb +0 -4
- data/app/views/decidim/admin/organization_external_domain_allowlist/_form.html.erb +2 -2
- data/app/views/decidim/admin/organization_external_domain_allowlist/edit.html.erb +2 -2
- data/app/views/decidim/admin/reminders/new.html.erb +8 -1
- data/app/views/decidim/admin/resource_permissions/edit.html.erb +2 -2
- data/app/views/decidim/admin/scope_types/index.html.erb +3 -2
- data/app/views/decidim/admin/scopes/index.html.erb +2 -2
- data/app/views/decidim/admin/share_tokens/index.html.erb +2 -0
- data/app/views/decidim/admin/shared/_gallery.html.erb +15 -0
- data/app/views/decidim/admin/shared/landing_page/_content_blocks.html.erb +0 -2
- data/app/views/decidim/admin/shared/landing_page/edit.html.erb +2 -0
- data/app/views/decidim/admin/shared/landing_page_content_blocks/edit.html.erb +1 -0
- data/app/views/decidim/admin/static_page_topics/index.html.erb +2 -2
- data/app/views/decidim/admin/static_pages/edit.html.erb +2 -1
- data/app/views/decidim/admin/static_pages/index.html.erb +2 -2
- data/app/views/decidim/admin/statistics/_statistics.html.erb +1 -1
- data/app/views/decidim/admin/statistics/index.html.erb +2 -0
- data/app/views/decidim/admin/taxonomies/_row.html.erb +1 -1
- data/app/views/decidim/admin/taxonomies/_row_children.html.erb +1 -1
- data/app/views/decidim/admin/taxonomies/_table.html.erb +1 -1
- data/app/views/decidim/admin/taxonomies/edit.html.erb +2 -2
- data/app/views/decidim/admin/taxonomies/index.html.erb +4 -4
- data/app/views/decidim/admin/taxonomy_filters/_table.html.erb +2 -2
- data/app/views/decidim/admin/taxonomy_filters/index.html.erb +2 -2
- data/app/views/decidim/admin/taxonomy_filters_selector/index.html.erb +2 -0
- data/app/views/decidim/admin/taxonomy_filters_selector/new.html.erb +2 -0
- data/app/views/decidim/admin/taxonomy_filters_selector/show.html.erb +2 -0
- data/app/views/decidim/admin/taxonomy_items/edit.html.erb +2 -0
- data/app/views/decidim/admin/taxonomy_items/new.html.erb +2 -0
- data/app/views/decidim/admin/users/index.html.erb +3 -2
- data/app/views/layouts/decidim/admin/_application.html.erb +1 -1
- data/config/locales/ar.yml +9 -49
- data/config/locales/bg.yml +9 -55
- data/config/locales/bs-BA.yml +4 -24
- data/config/locales/ca-IT.yml +130 -113
- data/config/locales/ca.yml +130 -113
- data/config/locales/cs.yml +126 -111
- data/config/locales/de.yml +114 -98
- data/config/locales/el.yml +17 -45
- data/config/locales/en.yml +130 -112
- data/config/locales/eo.yml +0 -7
- data/config/locales/es-MX.yml +130 -113
- data/config/locales/es-PY.yml +130 -113
- data/config/locales/es.yml +130 -113
- data/config/locales/eu.yml +159 -142
- data/config/locales/fi-plain.yml +129 -112
- data/config/locales/fi.yml +129 -112
- data/config/locales/fr-CA.yml +91 -145
- data/config/locales/fr.yml +91 -145
- data/config/locales/ga-IE.yml +0 -13
- data/config/locales/gl.yml +10 -41
- data/config/locales/he-IL.yml +1 -5
- data/config/locales/hu.yml +10 -52
- data/config/locales/id-ID.yml +4 -34
- data/config/locales/is-IS.yml +1 -16
- data/config/locales/it.yml +8 -69
- data/config/locales/ja.yml +129 -114
- data/config/locales/kaa.yml +4 -16
- data/config/locales/ko.yml +6 -40
- data/config/locales/lb.yml +9 -41
- data/config/locales/lt.yml +10 -52
- data/config/locales/lv.yml +8 -38
- data/config/locales/nl.yml +10 -46
- data/config/locales/no.yml +10 -46
- data/config/locales/pl.yml +9 -54
- data/config/locales/pt-BR.yml +121 -104
- data/config/locales/pt.yml +9 -42
- data/config/locales/ro-RO.yml +15 -51
- data/config/locales/ru.yml +4 -35
- data/config/locales/sk.yml +8 -814
- data/config/locales/sl.yml +1 -7
- data/config/locales/sq-AL.yml +1 -21
- data/config/locales/sr-CS.yml +4 -24
- data/config/locales/sv.yml +79 -89
- data/config/locales/th-TH.yml +0 -8
- data/config/locales/tr-TR.yml +33 -93
- data/config/locales/uk.yml +0 -26
- data/config/locales/val-ES.yml +0 -1
- data/config/locales/zh-CN.yml +9 -38
- data/config/locales/zh-TW.yml +10 -52
- data/config/routes.rb +4 -0
- data/decidim-admin.gemspec +7 -10
- data/lib/decidim/admin/engine.rb +5 -2
- data/lib/decidim/admin/form_builder.rb +3 -1
- data/lib/decidim/admin/menu.rb +1 -1
- data/lib/decidim/admin/test/admin_members_shared_examples.rb +119 -0
- data/lib/decidim/admin/test/admin_participatory_space_access_examples.rb +3 -3
- data/lib/decidim/admin/test/filterable_examples.rb +20 -11
- data/lib/decidim/admin/test/invite_participatory_space_admins_shared_examples.rb +17 -17
- data/lib/decidim/admin/test/invite_participatory_space_collaborators_shared_examples.rb +1 -1
- data/lib/decidim/admin/test/invite_participatory_space_moderators_shared_examples.rb +1 -1
- data/lib/decidim/admin/test/invite_participatory_space_users_shared_context.rb +1 -1
- data/lib/decidim/admin/test/manage_attachment_collections_examples.rb +3 -3
- data/lib/decidim/admin/test/manage_attachments_examples.rb +6 -6
- data/lib/decidim/admin/test/manage_component_permissions_examples.rb +5 -5
- data/lib/decidim/admin/test/manage_moderations_examples.rb +6 -6
- data/lib/decidim/admin/test/manage_participatory_space_publications_examples.rb +2 -2
- data/lib/decidim/admin/test/manage_resource_soft_deletion_examples.rb +3 -3
- data/lib/decidim/admin/version.rb +1 -1
- data/lib/decidim/admin.rb +0 -2
- metadata +40 -36
- data/app/commands/decidim/admin/create_participatory_space_private_user.rb +0 -98
- data/app/commands/decidim/admin/destroy_participatory_space_private_user.rb +0 -28
- data/app/commands/decidim/admin/process_participatory_space_private_user_import_csv.rb +0 -44
- data/app/commands/decidim/admin/publish_all_participatory_space_private_users.rb +0 -50
- data/app/commands/decidim/admin/unpublish_all_participatory_space_private_users.rb +0 -50
- data/app/commands/decidim/admin/update_participatory_space_private_user.rb +0 -11
- data/app/controllers/concerns/decidim/participatory_space_private_users/admin/filterable.rb +0 -34
- data/app/controllers/decidim/admin/concerns/has_private_users.rb +0 -169
- data/app/controllers/decidim/admin/concerns/has_private_users_csv_import.rb +0 -65
- data/app/forms/decidim/admin/participatory_space_private_user_csv_import_form.rb +0 -31
- data/app/forms/decidim/admin/participatory_space_private_user_form.rb +0 -24
- data/app/jobs/decidim/admin/destroy_private_users_follows_job.rb +0 -37
- data/app/jobs/decidim/admin/import_participatory_space_private_user_csv_job.rb +0 -27
- data/app/views/decidim/admin/devise/mailers/password_change.html.erb +0 -3
- data/app/views/decidim/admin/devise/mailers/reset_password_instructions.html.erb +0 -8
- data/app/views/decidim/admin/shared/_attachments.html.erb +0 -15
- /data/app/views/decidim/admin/{participatory_space_private_users → members}/_form.html.erb +0 -0
data/config/locales/zh-TW.yml
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
---
|
|
2
1
|
zh-TW:
|
|
3
2
|
activemodel:
|
|
4
3
|
attributes:
|
|
@@ -42,11 +41,11 @@ zh-TW:
|
|
|
42
41
|
alert_color: 警告
|
|
43
42
|
available_authorizations: 可用認證方式
|
|
44
43
|
badges_enabled: 啟用勳章
|
|
44
|
+
comments_max_length: 留言字數上限 (0 表示使用預設)
|
|
45
45
|
customize_welcome_notification: 自訂歡迎通知
|
|
46
46
|
default_locale: 預設語言
|
|
47
47
|
description: 說明
|
|
48
48
|
enable_omnipresent_banner: 顯示全域廣告
|
|
49
|
-
enable_participatory_space_filters: 啟用參與空間過濾器
|
|
50
49
|
facebook_handler: Facebook 處理器
|
|
51
50
|
favicon: 圖示
|
|
52
51
|
force_authentication: 強制認證
|
|
@@ -85,11 +84,6 @@ zh-TW:
|
|
|
85
84
|
welcome_notification_body: 歡迎通知內容
|
|
86
85
|
welcome_notification_subject: 歡迎通知主旨
|
|
87
86
|
youtube_handler: YouTube 處理器
|
|
88
|
-
participatory_space_private_user:
|
|
89
|
-
email: 電子郵件
|
|
90
|
-
name: 名稱
|
|
91
|
-
participatory_space_private_user_csv_import:
|
|
92
|
-
file: 檔案
|
|
93
87
|
scope:
|
|
94
88
|
code: 代碼
|
|
95
89
|
name: 名稱
|
|
@@ -130,10 +124,6 @@ zh-TW:
|
|
|
130
124
|
attributes:
|
|
131
125
|
official_img_footer:
|
|
132
126
|
allowed_file_content_types: 圖片有誤
|
|
133
|
-
participatory_space_private_user_csv_import:
|
|
134
|
-
attributes:
|
|
135
|
-
file:
|
|
136
|
-
malformed: 匯入檔案格式有誤,請小心閱讀教學並且確認檔案是使用 UTF-8 編碼
|
|
137
127
|
user_group_csv_verification:
|
|
138
128
|
attributes:
|
|
139
129
|
file:
|
|
@@ -171,8 +161,6 @@ zh-TW:
|
|
|
171
161
|
import: 匯入
|
|
172
162
|
newsletter:
|
|
173
163
|
new: 新電子報
|
|
174
|
-
participatory_space_private_user:
|
|
175
|
-
new: 新參與空間私有使用者
|
|
176
164
|
per_page: 每頁
|
|
177
165
|
share: 分享
|
|
178
166
|
user:
|
|
@@ -291,7 +279,6 @@ zh-TW:
|
|
|
291
279
|
title: '新增元件: %{name}'
|
|
292
280
|
publish:
|
|
293
281
|
success: 這個元件已經成功發佈
|
|
294
|
-
title: 组件
|
|
295
282
|
unpublish:
|
|
296
283
|
success: 這個元件已經成功取消發佈
|
|
297
284
|
update:
|
|
@@ -351,10 +338,6 @@ zh-TW:
|
|
|
351
338
|
values:
|
|
352
339
|
'false': 官方化
|
|
353
340
|
'true': 非官方化
|
|
354
|
-
participatory_space_private_users:
|
|
355
|
-
user_invitation_sent_at_not_null:
|
|
356
|
-
values:
|
|
357
|
-
'false': 未發送
|
|
358
341
|
private_space_eq:
|
|
359
342
|
label: 私人的
|
|
360
343
|
values:
|
|
@@ -417,7 +400,6 @@ zh-TW:
|
|
|
417
400
|
impersonate: 模擬
|
|
418
401
|
impersonate_existing_managed_user: 管理參與者 "%{name}"
|
|
419
402
|
impersonate_existing_user: 管理參與者 "%{name}"
|
|
420
|
-
impersonate_new_managed_user: 管理新參與者
|
|
421
403
|
imports:
|
|
422
404
|
and: 和
|
|
423
405
|
data_errors:
|
|
@@ -467,6 +449,10 @@ zh-TW:
|
|
|
467
449
|
new:
|
|
468
450
|
explanation: 受管理的參與者可以晉升為標準參與者。這意味著他們將受邀加入應用程式,您將無法再對其進行管理。被邀請的參與者將收到一封電子郵件,以接受您的邀請。
|
|
469
451
|
promote: 推廣
|
|
452
|
+
members_csv_imports:
|
|
453
|
+
new:
|
|
454
|
+
csv_upload:
|
|
455
|
+
title: 請上傳您的 CSV 檔案。
|
|
470
456
|
menu:
|
|
471
457
|
admin_log: 管理員活動日誌
|
|
472
458
|
admins: 管理員
|
|
@@ -524,8 +510,6 @@ zh-TW:
|
|
|
524
510
|
sent_to: 發送至
|
|
525
511
|
subject: 主旨
|
|
526
512
|
name: 電子報
|
|
527
|
-
participatory_space_private_user:
|
|
528
|
-
name: 參與空間私有參與者
|
|
529
513
|
scope:
|
|
530
514
|
fields:
|
|
531
515
|
name: 名稱
|
|
@@ -648,7 +632,6 @@ zh-TW:
|
|
|
648
632
|
send:
|
|
649
633
|
no_recipients: 沒有選擇收件人.
|
|
650
634
|
show:
|
|
651
|
-
preview: 預覽
|
|
652
635
|
select_recipients_to_deliver: 選擇要傳送的收件人
|
|
653
636
|
subject: 主旨
|
|
654
637
|
update:
|
|
@@ -702,30 +685,6 @@ zh-TW:
|
|
|
702
685
|
update:
|
|
703
686
|
error: 更新此組織時發生問題。
|
|
704
687
|
success: 組織更新成功
|
|
705
|
-
participatory_space_private_users:
|
|
706
|
-
create:
|
|
707
|
-
error: 在此參與空間中添加私人參與者時出現問題。
|
|
708
|
-
success: 成功建立參與空間的私人參與者訪問權限。
|
|
709
|
-
destroy:
|
|
710
|
-
error: 刪除參與空間的私人參與者時發生問題。
|
|
711
|
-
success: 成功刪除參與空間的私人參與者訪問權限。
|
|
712
|
-
edit:
|
|
713
|
-
update: 更新
|
|
714
|
-
index:
|
|
715
|
-
title: 參與空間私有參與者
|
|
716
|
-
new:
|
|
717
|
-
create: 建立
|
|
718
|
-
title: 新的參與空間私人參與者。
|
|
719
|
-
participatory_space_private_users_csv_imports:
|
|
720
|
-
new:
|
|
721
|
-
csv_upload:
|
|
722
|
-
title: 請上傳您的 CSV 檔案。
|
|
723
|
-
destroy:
|
|
724
|
-
button: 刪除所有私人參與者
|
|
725
|
-
confirm: 您確定要刪除所有私人參與者嗎?此操作無法撤銷,您將無法恢復它們。
|
|
726
|
-
empty: 您沒有私人參與者。
|
|
727
|
-
explanation: 您有 %{count} 位私人參與者。
|
|
728
|
-
title: 刪除私人參與者
|
|
729
688
|
reminders:
|
|
730
689
|
create:
|
|
731
690
|
error: 在創建提醒時遇到問題。
|
|
@@ -773,6 +732,11 @@ zh-TW:
|
|
|
773
732
|
share_tokens:
|
|
774
733
|
actions:
|
|
775
734
|
destroy: 刪除
|
|
735
|
+
shared:
|
|
736
|
+
gallery:
|
|
737
|
+
add_images: 添加圖案
|
|
738
|
+
edit_images: 編輯圖片
|
|
739
|
+
gallery_legend: 新增圖片庫(可選)
|
|
776
740
|
static_page_topics:
|
|
777
741
|
create:
|
|
778
742
|
error: 建立新主題時發生問題。
|
|
@@ -786,7 +750,6 @@ zh-TW:
|
|
|
786
750
|
title: 新增主題
|
|
787
751
|
update:
|
|
788
752
|
error: 更新主題時發生問題。
|
|
789
|
-
success: 主題已成功更新。
|
|
790
753
|
static_pages:
|
|
791
754
|
create:
|
|
792
755
|
error: 創建新頁面時出現問題。
|
|
@@ -810,14 +773,9 @@ zh-TW:
|
|
|
810
773
|
error: 更新此頁面時出現問題。
|
|
811
774
|
success: 頁面已更新成功.
|
|
812
775
|
titles:
|
|
813
|
-
area_types: 區域類型
|
|
814
776
|
areas: 區域
|
|
815
777
|
authorization_workflows: 驗證方式
|
|
816
|
-
impersonations: 參與者管理
|
|
817
|
-
pages: 頁
|
|
818
778
|
panel: 管理員
|
|
819
|
-
participants: 參與者
|
|
820
|
-
scope_types: 範圍類型
|
|
821
779
|
scopes: 範圍
|
|
822
780
|
users:
|
|
823
781
|
create:
|
data/config/routes.rb
CHANGED
|
@@ -8,6 +8,10 @@ Decidim::Admin::Engine.routes.draw do
|
|
|
8
8
|
resources :content_blocks, only: [:edit, :update, :destroy, :create], controller: "organization_homepage_content_blocks"
|
|
9
9
|
end
|
|
10
10
|
resource :external_domain_allowlist, only: [:edit, :update], controller: "organization_external_domain_allowlist"
|
|
11
|
+
|
|
12
|
+
member do
|
|
13
|
+
get :users
|
|
14
|
+
end
|
|
11
15
|
end
|
|
12
16
|
|
|
13
17
|
resources :static_pages do
|
data/decidim-admin.gemspec
CHANGED
|
@@ -2,12 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
$LOAD_PATH.push File.expand_path("lib", __dir__)
|
|
4
4
|
|
|
5
|
-
# Maintain your gem's version:
|
|
6
|
-
require "decidim/admin/version"
|
|
7
|
-
|
|
8
|
-
# Describe your gem and declare its dependencies:
|
|
9
5
|
Gem::Specification.new do |s|
|
|
10
|
-
|
|
6
|
+
version = "0.32.0.rc1"
|
|
7
|
+
s.version = version
|
|
11
8
|
s.authors = ["Josep Jaume Rey Peroy", "Marc Riera Casals", "Oriol Gual Oliva"]
|
|
12
9
|
s.email = ["josepjaume@gmail.com", "mrc2407@gmail.com", "oriolgual@gmail.com"]
|
|
13
10
|
s.license = "AGPL-3.0-or-later"
|
|
@@ -19,7 +16,7 @@ Gem::Specification.new do |s|
|
|
|
19
16
|
"homepage_uri" => "https://decidim.org",
|
|
20
17
|
"source_code_uri" => "https://github.com/decidim/decidim"
|
|
21
18
|
}
|
|
22
|
-
s.required_ruby_version = "~> 3.
|
|
19
|
+
s.required_ruby_version = "~> 3.4.0"
|
|
23
20
|
|
|
24
21
|
s.name = "decidim-admin"
|
|
25
22
|
s.summary = "Decidim organization administration"
|
|
@@ -33,11 +30,11 @@ Gem::Specification.new do |s|
|
|
|
33
30
|
end
|
|
34
31
|
|
|
35
32
|
s.add_dependency "active_link_to", "~> 1.0"
|
|
36
|
-
s.add_dependency "decidim-core",
|
|
37
|
-
s.add_dependency "devise", "
|
|
33
|
+
s.add_dependency "decidim-core", version
|
|
34
|
+
s.add_dependency "devise", ">= 4.7", "< 6.0"
|
|
38
35
|
s.add_dependency "devise-i18n", "~> 1.2"
|
|
39
36
|
s.add_dependency "devise_invitable", "~> 2.0", ">= 2.0.9"
|
|
40
37
|
|
|
41
|
-
s.add_development_dependency "decidim-dev",
|
|
42
|
-
s.add_development_dependency "decidim-participatory_processes",
|
|
38
|
+
s.add_development_dependency "decidim-dev", version
|
|
39
|
+
s.add_development_dependency "decidim-participatory_processes", version
|
|
43
40
|
end
|
data/lib/decidim/admin/engine.rb
CHANGED
|
@@ -20,7 +20,11 @@ module Decidim
|
|
|
20
20
|
|
|
21
21
|
initializer "decidim_admin.mount_routes" do |_app|
|
|
22
22
|
Decidim::Core::Engine.routes do
|
|
23
|
-
|
|
23
|
+
extend Decidim::Routes::LocaleRedirects
|
|
24
|
+
|
|
25
|
+
scope "/:locale", **locale_scope_options do
|
|
26
|
+
mount Decidim::Admin::Engine => "/admin"
|
|
27
|
+
end
|
|
24
28
|
end
|
|
25
29
|
end
|
|
26
30
|
|
|
@@ -44,7 +48,6 @@ module Decidim
|
|
|
44
48
|
Decidim.icons.register(name: "earth-line", icon: "earth-line", category: "system", description: "Earth line", engine: :admin)
|
|
45
49
|
|
|
46
50
|
Decidim.icons.register(name: "attachment-2", icon: "attachment-2", category: "system", description: "", engine: :admin)
|
|
47
|
-
Decidim.icons.register(name: "spy-line", icon: "spy-line", category: "system", description: "", engine: :admin)
|
|
48
51
|
Decidim.icons.register(name: "refresh-line", icon: "refresh-line", category: "system", description: "", engine: :admin)
|
|
49
52
|
Decidim.icons.register(name: "zoom-in-line", icon: "zoom-in-line", category: "system", description: "", engine: :admin)
|
|
50
53
|
Decidim.icons.register(name: "add-line", icon: "add-line", category: "system", description: "", engine: :admin)
|
|
@@ -19,6 +19,7 @@ module Decidim
|
|
|
19
19
|
# - :class (string) You can provide custom class name for the container (ex. autocomplete-field--results-inline)
|
|
20
20
|
# @param [Hash] prompt_options
|
|
21
21
|
# Prompt configuration. A hash with options:
|
|
22
|
+
# - :url (String) The url where the ajax endpoint to fill the select
|
|
22
23
|
# - :placeholder (String) Text to use as placeholder
|
|
23
24
|
# - :no_results (String) (optional) Text to use when there are no matching results (default: No results found)
|
|
24
25
|
# - :search_prompt (String) (optional) Text to prompt for search input (default: Type at least three characters to search)
|
|
@@ -29,7 +30,7 @@ module Decidim
|
|
|
29
30
|
# - label: This will be the label of the option select.
|
|
30
31
|
#
|
|
31
32
|
# @example How to use it
|
|
32
|
-
# <% prompt_options = {
|
|
33
|
+
# <% prompt_options = { url: users_url, text: t(".select_user") }
|
|
33
34
|
# options = { label: t(".user") } %>
|
|
34
35
|
# <%= form.autocomplete_select(:user_id, form.object.user.presence, options, prompt_options) do |user|
|
|
35
36
|
# { value: user.id, label: "#{user.name} (#{user.nickname})" }
|
|
@@ -47,6 +48,7 @@ module Decidim
|
|
|
47
48
|
name: options[:name] || "#{@object_name}[#{attribute}]",
|
|
48
49
|
options: (options[:default_options].to_a + [selected]).compact,
|
|
49
50
|
placeholder: prompt_options[:placeholder],
|
|
51
|
+
searchURL: prompt_options[:url],
|
|
50
52
|
changeURL: prompt_options[:change_url],
|
|
51
53
|
selected: selected ? selected[:value] : "",
|
|
52
54
|
searchPromptText: options[:search_prompt] || I18n.t("autocomplete.search_prompt", scope: "decidim.admin"),
|
data/lib/decidim/admin/menu.rb
CHANGED
|
@@ -48,7 +48,7 @@ module Decidim
|
|
|
48
48
|
def self.register_impersonate_menu!
|
|
49
49
|
Decidim.menu :impersonate_menu do |menu|
|
|
50
50
|
menu.add_item :conflicts,
|
|
51
|
-
I18n.t("title", scope: "decidim.admin.conflicts"),
|
|
51
|
+
I18n.t("title", scope: "decidim.admin.conflicts.index"),
|
|
52
52
|
decidim_admin.conflicts_path,
|
|
53
53
|
active: is_active_link?(decidim_admin.conflicts_path),
|
|
54
54
|
if: allowed_to?(:index, :impersonatable_user)
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
shared_examples "manage admin members examples" do
|
|
4
|
+
let(:other_user) { create(:user, organization:, email: "my_email@example.org") }
|
|
5
|
+
|
|
6
|
+
let!(:member) { create(:member, user:, participatory_space:) }
|
|
7
|
+
|
|
8
|
+
before do
|
|
9
|
+
switch_to_host(organization.host)
|
|
10
|
+
login_as user, scope: :user
|
|
11
|
+
visit participatory_space_edit_path
|
|
12
|
+
within_admin_sidebar_menu do
|
|
13
|
+
click_on "Members"
|
|
14
|
+
end
|
|
15
|
+
end
|
|
16
|
+
|
|
17
|
+
it "shows the member list" do
|
|
18
|
+
within "#members table" do
|
|
19
|
+
expect(page).to have_content(member.user.email)
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
it "creates a new member" do
|
|
24
|
+
click_on "New member"
|
|
25
|
+
|
|
26
|
+
within ".new_member" do
|
|
27
|
+
fill_in :member_name, with: "John Doe"
|
|
28
|
+
fill_in :member_email, with: other_user.email
|
|
29
|
+
|
|
30
|
+
find("*[type=submit]").click
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
expect(page).to have_callout("Member access successfully created.")
|
|
34
|
+
|
|
35
|
+
within "#members table" do
|
|
36
|
+
expect(page).to have_content(other_user.email)
|
|
37
|
+
end
|
|
38
|
+
|
|
39
|
+
visit decidim_admin.root_path
|
|
40
|
+
expect(page).to have_content("invited #{other_user.name} to be a member")
|
|
41
|
+
end
|
|
42
|
+
|
|
43
|
+
describe "when import a batch of members from csv" do
|
|
44
|
+
it "import a batch of members" do
|
|
45
|
+
click_on "Import via CSV"
|
|
46
|
+
|
|
47
|
+
# The CSV has no headers
|
|
48
|
+
expect(Decidim::Admin::ParticipatorySpace::ImportMemberCsvJob).to receive(:perform_later).once.ordered.with("john.doe@example.org", "John Doe", participatory_space, user)
|
|
49
|
+
expect(Decidim::Admin::ParticipatorySpace::ImportMemberCsvJob).to receive(:perform_later).once.ordered.with("jane.doe@example.org", "Jane Doe", participatory_space, user)
|
|
50
|
+
dynamically_attach_file(:member_csv_import_file, Decidim::Dev.asset("import_members.csv"))
|
|
51
|
+
perform_enqueued_jobs { click_on "Upload" }
|
|
52
|
+
|
|
53
|
+
expect(page).to have_content("CSV file uploaded successfully")
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
describe "when publishing all members" do
|
|
58
|
+
let!(:member) { create(:member, :unpublished, user:, participatory_space:) }
|
|
59
|
+
|
|
60
|
+
it "publishes all members" do
|
|
61
|
+
click_on "Publish all"
|
|
62
|
+
|
|
63
|
+
sleep(1)
|
|
64
|
+
expect(member.reload).to be_published
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
it "displays the correct log message" do
|
|
68
|
+
click_on "Publish all"
|
|
69
|
+
sleep(1)
|
|
70
|
+
visit decidim_admin.root_path
|
|
71
|
+
expect(page).to have_content("published all members of the #{translated(participatory_space.title)}")
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
describe "when managing different users" do
|
|
76
|
+
before do
|
|
77
|
+
create(:member, user: other_user, participatory_space:)
|
|
78
|
+
visit current_path
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
it "deletes a member" do
|
|
82
|
+
within "#members tr", text: other_user.email do
|
|
83
|
+
find("button[data-controller='dropdown']").click
|
|
84
|
+
accept_confirm { click_on "Delete" }
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
expect(page).to have_callout("Member access successfully destroyed.")
|
|
88
|
+
|
|
89
|
+
within "#members table" do
|
|
90
|
+
expect(page).to have_no_content(other_user.email)
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
context "when the user has not accepted the invitation" do
|
|
95
|
+
before do
|
|
96
|
+
form = Decidim::Admin::ParticipatorySpace::MemberForm.from_params(
|
|
97
|
+
name: "test",
|
|
98
|
+
email: "test@example.org"
|
|
99
|
+
)
|
|
100
|
+
|
|
101
|
+
Decidim::Admin::ParticipatorySpace::CreateMember.call(
|
|
102
|
+
form,
|
|
103
|
+
participatory_space
|
|
104
|
+
)
|
|
105
|
+
|
|
106
|
+
visit current_path
|
|
107
|
+
end
|
|
108
|
+
|
|
109
|
+
it "resends the invitation to the user" do
|
|
110
|
+
within "#members tr", text: "test@example.org" do
|
|
111
|
+
find("button[data-controller='dropdown']").click
|
|
112
|
+
click_on "Resend invitation"
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
expect(page).to have_callout("Invitation successfully resent.")
|
|
116
|
+
end
|
|
117
|
+
end
|
|
118
|
+
end
|
|
119
|
+
end
|
|
@@ -11,7 +11,7 @@ end
|
|
|
11
11
|
shared_examples "showing the unauthorized error message" do
|
|
12
12
|
it "redirects to the relevant unauthorized page" do
|
|
13
13
|
expect(page).to have_content("You are not authorized to perform this action")
|
|
14
|
-
expect(page).to have_current_path(
|
|
14
|
+
expect(page).to have_current_path(decidim_admin.root_path)
|
|
15
15
|
end
|
|
16
16
|
end
|
|
17
17
|
|
|
@@ -40,7 +40,7 @@ shared_examples "admin participatory space access" do
|
|
|
40
40
|
|
|
41
41
|
context "when the user is a normal user" do
|
|
42
42
|
let(:user) { create(:user, :confirmed, organization:) }
|
|
43
|
-
let(:unauthorized_path) {
|
|
43
|
+
let(:unauthorized_path) { decidim.root_path }
|
|
44
44
|
|
|
45
45
|
it_behaves_like "a 404 page"
|
|
46
46
|
end
|
|
@@ -53,7 +53,7 @@ shared_examples "admin participatory space access" do
|
|
|
53
53
|
visit decidim.root_path
|
|
54
54
|
|
|
55
55
|
within "#admin-bar" do
|
|
56
|
-
expect(page).to have_link("Admin dashboard", href:
|
|
56
|
+
expect(page).to have_link("Admin dashboard", href: decidim_admin.root_path)
|
|
57
57
|
end
|
|
58
58
|
end
|
|
59
59
|
end
|
|
@@ -148,27 +148,36 @@ shared_examples "filtering collection by published/unpublished" do
|
|
|
148
148
|
it_behaves_like "paginating a collection"
|
|
149
149
|
end
|
|
150
150
|
|
|
151
|
-
shared_examples "filtering collection by
|
|
151
|
+
shared_examples "filtering collection by open/restricted/transparent" do
|
|
152
152
|
include_context "with filterable context"
|
|
153
153
|
|
|
154
154
|
unless block_given?
|
|
155
|
-
let!(:
|
|
156
|
-
create(factory_name,
|
|
155
|
+
let!(:open_space) do
|
|
156
|
+
create(factory_name, :open, organization:)
|
|
157
157
|
end
|
|
158
158
|
|
|
159
|
-
let!(:
|
|
160
|
-
create(factory_name,
|
|
159
|
+
let!(:restricted_space) do
|
|
160
|
+
create(factory_name, :restricted, organization:)
|
|
161
161
|
end
|
|
162
|
+
|
|
163
|
+
let!(:transparent_space) do
|
|
164
|
+
create(factory_name, :transparent, organization:)
|
|
165
|
+
end
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
it_behaves_like "a filtered collection", options: "Access mode", filter: "Open" do
|
|
169
|
+
let(:in_filter) { translated(open_space.title) }
|
|
170
|
+
let(:not_in_filter) { [translated(restricted_space.title), translated(transparent_space.title)] }
|
|
162
171
|
end
|
|
163
172
|
|
|
164
|
-
it_behaves_like "a filtered collection", options: "
|
|
165
|
-
let(:in_filter) { translated(
|
|
166
|
-
let(:not_in_filter) { translated(
|
|
173
|
+
it_behaves_like "a filtered collection", options: "Access mode", filter: "Restricted" do
|
|
174
|
+
let(:in_filter) { translated(restricted_space.title) }
|
|
175
|
+
let(:not_in_filter) { [translated(open_space.title), translated(transparent_space.title)] }
|
|
167
176
|
end
|
|
168
177
|
|
|
169
|
-
it_behaves_like "a filtered collection", options: "
|
|
170
|
-
let(:in_filter) { translated(
|
|
171
|
-
let(:not_in_filter) { translated(
|
|
178
|
+
it_behaves_like "a filtered collection", options: "Access mode", filter: "Transparent" do
|
|
179
|
+
let(:in_filter) { translated(transparent_space.title) }
|
|
180
|
+
let(:not_in_filter) { [translated(open_space.title), translated(restricted_space.title)] }
|
|
172
181
|
end
|
|
173
182
|
|
|
174
183
|
it_behaves_like "paginating a collection"
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
shared_examples "inviting participatory space admins" do |
|
|
3
|
+
shared_examples "inviting participatory space admins" do |check_members_page: true, check_landing_page: true|
|
|
4
4
|
let(:role) { "Administrator" }
|
|
5
5
|
|
|
6
6
|
before do
|
|
7
7
|
switch_to_host organization.host
|
|
8
8
|
end
|
|
9
9
|
|
|
10
|
-
shared_examples "sees
|
|
10
|
+
shared_examples "sees space without members menu" do
|
|
11
11
|
it "can access all sections" do
|
|
12
12
|
within_admin_sidebar_menu do
|
|
13
13
|
expect(page).to have_content(about_this_space_label)
|
|
@@ -16,13 +16,13 @@ shared_examples "inviting participatory space admins" do |check_private_space: t
|
|
|
16
16
|
expect(page).to have_content("Components")
|
|
17
17
|
expect(page).to have_content("Attachments")
|
|
18
18
|
expect(page).to have_content(space_admins_label)
|
|
19
|
-
expect(page).to have_no_content("Members") if participatory_space.respond_to?(:
|
|
19
|
+
expect(page).to have_no_content("Members") if participatory_space.respond_to?(:has_members)
|
|
20
20
|
expect(page).to have_content("Moderations")
|
|
21
21
|
end
|
|
22
22
|
end
|
|
23
23
|
end
|
|
24
24
|
|
|
25
|
-
shared_examples "sees
|
|
25
|
+
shared_examples "sees space with members menu" do
|
|
26
26
|
it "can access all sections" do
|
|
27
27
|
within_admin_sidebar_menu do
|
|
28
28
|
expect(page).to have_content(about_this_space_label)
|
|
@@ -31,7 +31,7 @@ shared_examples "inviting participatory space admins" do |check_private_space: t
|
|
|
31
31
|
expect(page).to have_content("Components")
|
|
32
32
|
expect(page).to have_content("Attachments")
|
|
33
33
|
expect(page).to have_content(space_admins_label)
|
|
34
|
-
expect(page).to have_content("Members") if participatory_space.respond_to?(:
|
|
34
|
+
expect(page).to have_content("Members") if participatory_space.respond_to?(:has_members)
|
|
35
35
|
expect(page).to have_content("Moderations")
|
|
36
36
|
end
|
|
37
37
|
end
|
|
@@ -52,7 +52,7 @@ shared_examples "inviting participatory space admins" do |check_private_space: t
|
|
|
52
52
|
find("*[type=submit]").click
|
|
53
53
|
end
|
|
54
54
|
|
|
55
|
-
expect(page).to have_current_path
|
|
55
|
+
expect(page).to have_current_path decidim_admin.admin_terms_show_path
|
|
56
56
|
|
|
57
57
|
visit decidim_admin.admin_terms_show_path
|
|
58
58
|
|
|
@@ -81,7 +81,7 @@ shared_examples "inviting participatory space admins" do |check_private_space: t
|
|
|
81
81
|
find("*[type=submit]").click
|
|
82
82
|
end
|
|
83
83
|
|
|
84
|
-
expect(page).to have_current_path
|
|
84
|
+
expect(page).to have_current_path decidim_admin.admin_terms_show_path
|
|
85
85
|
|
|
86
86
|
visit decidim_admin.admin_terms_show_path
|
|
87
87
|
|
|
@@ -98,14 +98,14 @@ shared_examples "inviting participatory space admins" do |check_private_space: t
|
|
|
98
98
|
end
|
|
99
99
|
|
|
100
100
|
context "and is a public space" do
|
|
101
|
-
it_behaves_like "sees
|
|
101
|
+
it_behaves_like "sees space without members menu"
|
|
102
102
|
end
|
|
103
103
|
|
|
104
|
-
if
|
|
105
|
-
context "and is a
|
|
106
|
-
let(:participatory_space) {
|
|
104
|
+
if check_members_page
|
|
105
|
+
context "and is a space with members" do
|
|
106
|
+
let(:participatory_space) { members_participatory_space }
|
|
107
107
|
|
|
108
|
-
it_behaves_like "sees
|
|
108
|
+
it_behaves_like "sees space with members menu"
|
|
109
109
|
end
|
|
110
110
|
end
|
|
111
111
|
end
|
|
@@ -163,14 +163,14 @@ shared_examples "inviting participatory space admins" do |check_private_space: t
|
|
|
163
163
|
end
|
|
164
164
|
|
|
165
165
|
context "and is a public space" do
|
|
166
|
-
it_behaves_like "sees
|
|
166
|
+
it_behaves_like "sees space without members menu"
|
|
167
167
|
end
|
|
168
168
|
|
|
169
|
-
if
|
|
170
|
-
context "and is a
|
|
171
|
-
let(:participatory_space) {
|
|
169
|
+
if check_members_page
|
|
170
|
+
context "and is a space with members" do
|
|
171
|
+
let(:participatory_space) { members_participatory_space }
|
|
172
172
|
|
|
173
|
-
it_behaves_like "sees
|
|
173
|
+
it_behaves_like "sees space with members menu"
|
|
174
174
|
end
|
|
175
175
|
end
|
|
176
176
|
end
|
|
@@ -22,7 +22,7 @@ shared_examples "inviting participatory space collaborators" do
|
|
|
22
22
|
find("*[type=submit]").click
|
|
23
23
|
end
|
|
24
24
|
|
|
25
|
-
expect(page).to have_current_path
|
|
25
|
+
expect(page).to have_current_path decidim_admin.admin_terms_show_path
|
|
26
26
|
|
|
27
27
|
visit decidim_admin.admin_terms_show_path
|
|
28
28
|
find_button("I agree with the terms").click
|
|
@@ -20,7 +20,7 @@ shared_examples "inviting participatory space moderators" do
|
|
|
20
20
|
find("*[type=submit]").click
|
|
21
21
|
end
|
|
22
22
|
|
|
23
|
-
expect(page).to have_current_path
|
|
23
|
+
expect(page).to have_current_path decidim_admin.admin_terms_show_path
|
|
24
24
|
|
|
25
25
|
visit decidim_admin.admin_terms_show_path
|
|
26
26
|
find_button("I agree with the terms").click
|
|
@@ -18,7 +18,7 @@ shared_context "when inviting participatory space users" do
|
|
|
18
18
|
fill_in "Email", with: email
|
|
19
19
|
select role, from: "Role"
|
|
20
20
|
click_on "Create"
|
|
21
|
-
expect(page).to
|
|
21
|
+
expect(page).to have_callout(added_callout_message)
|
|
22
22
|
logout :user
|
|
23
23
|
end
|
|
24
24
|
|
|
@@ -44,7 +44,7 @@ shared_examples "manage attachment collections examples" do
|
|
|
44
44
|
find("*[type=submit]").click
|
|
45
45
|
end
|
|
46
46
|
|
|
47
|
-
expect(page).to
|
|
47
|
+
expect(page).to have_callout("Folder created successfully.")
|
|
48
48
|
|
|
49
49
|
within "#attachment_collections table" do
|
|
50
50
|
expect(page).to have_content(translated(attributes[:name]))
|
|
@@ -72,7 +72,7 @@ shared_examples "manage attachment collections examples" do
|
|
|
72
72
|
find("*[type=submit]").click
|
|
73
73
|
end
|
|
74
74
|
|
|
75
|
-
expect(page).to
|
|
75
|
+
expect(page).to have_callout("Folder updated successfully.")
|
|
76
76
|
|
|
77
77
|
within "#attachment_collections table" do
|
|
78
78
|
expect(page).to have_content(translated(attributes[:name]))
|
|
@@ -96,7 +96,7 @@ shared_examples "manage attachment collections examples" do
|
|
|
96
96
|
accept_confirm { click_on "Delete" }
|
|
97
97
|
end
|
|
98
98
|
|
|
99
|
-
expect(page).to
|
|
99
|
+
expect(page).to have_callout("Folder destroyed successfully.")
|
|
100
100
|
|
|
101
101
|
within "#attachment_collections table" do
|
|
102
102
|
expect(page).to have_no_content(translated(attachment_collection2.name))
|