decidim-admin 0.7.4 → 0.8.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-admin might be problematic. Click here for more details.

Files changed (42) hide show
  1. checksums.yaml +5 -5
  2. data/README.md +10 -5
  3. data/app/assets/javascripts/decidim/admin/application.js.es6 +1 -1
  4. data/app/assets/stylesheets/decidim/admin/modules/_buttons.scss +5 -9
  5. data/app/assets/stylesheets/decidim/admin/modules/_cards.scss +1 -0
  6. data/app/assets/stylesheets/decidim/admin/modules/_modules.scss +1 -0
  7. data/app/assets/stylesheets/decidim/admin/modules/_pics.scss +5 -0
  8. data/app/assets/stylesheets/decidim/admin/modules/_table-list.scss +7 -0
  9. data/app/commands/decidim/admin/create_managed_user.rb +1 -1
  10. data/app/controllers/decidim/admin/authorization_workflows_controller.rb +15 -0
  11. data/app/controllers/decidim/admin/feature_permissions_controller.rb +3 -1
  12. data/app/forms/decidim/admin/impersonate_managed_user_form.rb +1 -1
  13. data/app/forms/decidim/admin/managed_user_form.rb +1 -1
  14. data/app/forms/decidim/admin/organization_appearance_form.rb +1 -1
  15. data/app/helpers/decidim/admin/icon_link_helper.rb +6 -4
  16. data/app/models/decidim/admin/abilities/admin_ability.rb +3 -0
  17. data/app/views/decidim/admin/authorization_workflows/index.html.erb +32 -0
  18. data/app/views/decidim/admin/exports/_dropdown.html.erb +1 -1
  19. data/app/views/decidim/admin/feature_permissions/edit.html.erb +1 -1
  20. data/app/views/decidim/admin/moderations/index.html.erb +1 -3
  21. data/app/views/decidim/admin/newsletters/_form.html.erb +1 -1
  22. data/app/views/decidim/admin/newsletters/index.html.erb +3 -9
  23. data/app/views/layouts/decidim/admin/users.html.erb +12 -0
  24. data/config/locales/ca.yml +4 -1
  25. data/config/locales/en.yml +4 -1
  26. data/config/locales/es.yml +4 -1
  27. data/config/locales/eu.yml +4 -1
  28. data/config/locales/fi.yml +4 -1
  29. data/config/locales/fr.yml +4 -1
  30. data/config/locales/it.yml +16 -13
  31. data/config/locales/nl.yml +75 -72
  32. data/config/locales/pl.yml +4 -1
  33. data/config/locales/pt.yml +471 -0
  34. data/config/locales/ru.yml +4 -3
  35. data/config/locales/uk.yml +5 -2
  36. data/config/routes.rb +6 -0
  37. data/lib/decidim/admin/engine.rb +1 -1
  38. data/lib/decidim/admin/test/forms/category_form_examples.rb +3 -3
  39. data/lib/decidim/admin/test/manage_attachments_examples.rb +5 -11
  40. data/lib/decidim/admin/test/manage_feature_permissions_examples.rb +3 -3
  41. data/lib/decidim/admin/version.rb +1 -1
  42. metadata +30 -40
@@ -51,7 +51,7 @@ ru:
51
51
  decidim/participatory_process:
52
52
  banner_image: Изображение баннера
53
53
  description: Описание
54
- developer_group: Группа разработчиков
54
+ developer_group: Группа зачинателей
55
55
  domain: Домен
56
56
  end_date: Дата завершения
57
57
  hashtag: Хэштег
@@ -131,7 +131,7 @@ ru:
131
131
  success: Категория успешно обновлена.
132
132
  dashboard:
133
133
  show:
134
- welcome: Добро пожаловать на новую панель администратора Десидим!
134
+ welcome: Добро пожаловать в админ-панель Десидим!
135
135
  exports:
136
136
  export_as: "%{name} как %{export_format}"
137
137
  notice: Идет сохранение в виде файла. Вы получите электронное письмо, когда оно будет завершено.
@@ -379,7 +379,7 @@ ru:
379
379
  title: Отредактировать страницу
380
380
  update: Обновить
381
381
  new:
382
- create: Новая
382
+ create: Добавить
383
383
  title: Новая страница
384
384
  update:
385
385
  error: При обновлении этой страницы произошла ошибка.
@@ -450,6 +450,7 @@ ru:
450
450
  reportable: Тип жалобы
451
451
  reported_content_url: URL-адрес обжалованного содержимого
452
452
  reports: Жалобы
453
+ visit_url: Посетите URL-адрес
453
454
  errors:
454
455
  messages:
455
456
  invalid_json: Недопустимый JSON
@@ -12,6 +12,7 @@ uk:
12
12
  feature:
13
13
  name: Ім'я
14
14
  weight: Вага
15
+ id: Ідентифікатор
15
16
  newsletter:
16
17
  body: Основний текст
17
18
  subject: Тема
@@ -51,7 +52,7 @@ uk:
51
52
  decidim/participatory_process:
52
53
  banner_image: Банерне зображення
53
54
  description: Опис
54
- developer_group: Група розробників
55
+ developer_group: Група зачинальників
55
56
  domain: Домен
56
57
  end_date: Дата закінчення
57
58
  hashtag: Хештег
@@ -131,7 +132,7 @@ uk:
131
132
  success: Розділ успішно оновлено.
132
133
  dashboard:
133
134
  show:
134
- welcome: Ласкаво просимо на нову панель адміністратора Десідім!
135
+ welcome: Ласкаво просимо до адмін-панелі Десідім!
135
136
  exports:
136
137
  export_as: "%{name} як %{export_format}"
137
138
  notice: Зараз відбувається збереження у вигляді файлу. Ви отримаєте електронного листа після його завершення.
@@ -385,6 +386,7 @@ uk:
385
386
  error: При оновленні цієї сторінки сталася помилка.
386
387
  success: Сторінку успішно оновлено
387
388
  titles:
389
+ authorization_workflows: Методи перевірки
388
390
  dashboard: Приладна дошка
389
391
  impersonations: Виступи в ролі учасника
390
392
  managed_users: Керовані учасники
@@ -450,6 +452,7 @@ uk:
450
452
  reportable: Тип скарги
451
453
  reported_content_url: URL-адреса оскарженого вмісту
452
454
  reports: Скарги
455
+ visit_url: Відвідайте URL-адресу
453
456
  errors:
454
457
  messages:
455
458
  invalid_json: Неприпустимий JSON
@@ -16,6 +16,12 @@ Decidim::Admin::Engine.routes.draw do
16
16
  resources :scopes, except: [:show]
17
17
  end
18
18
 
19
+ resources :authorization_workflows, only: :index
20
+
21
+ Decidim.authorization_admin_engines.each do |manifest|
22
+ mount manifest.admin_engine, at: "/#{manifest.name}", as: "decidim_admin_#{manifest.name}"
23
+ end
24
+
19
25
  resources :users, except: [:edit, :update], controller: "users" do
20
26
  member do
21
27
  post :resend_invitation, to: "users#resend_invitation"
@@ -61,7 +61,7 @@ module Decidim
61
61
  can?(:read, :admin_users) ? decidim_admin.users_path : decidim_admin.managed_users_path,
62
62
  icon_name: "person",
63
63
  position: 5,
64
- active: [%w(decidim/admin/user_groups decidim/admin/users decidim/admin/managed_users), []],
64
+ active: [%w(decidim/admin/user_groups decidim/admin/users decidim/admin/managed_users decidim/admin/authorization_workflows), []],
65
65
  if: can?(:read, :admin_users) || can?(:read, :managed_users)
66
66
 
67
67
  menu.item I18n.t("menu.newsletters", scope: "decidim.admin"),
@@ -48,11 +48,11 @@ module Decidim
48
48
  it { is_expected.to be_valid }
49
49
  end
50
50
 
51
- context "when some language in name is missing" do
51
+ context "when default language in name is missing" do
52
52
  let(:name) do
53
53
  {
54
- en: "Name",
55
- ca: "Nombre"
54
+ ca: "Nom",
55
+ es: "Nombre"
56
56
  }
57
57
  end
58
58
 
@@ -49,9 +49,7 @@ shared_examples "manage attachments examples" do
49
49
  find("*[type=submit]").click
50
50
  end
51
51
 
52
- within ".callout-wrapper" do
53
- expect(page).to have_content("successfully")
54
- end
52
+ expect(page).to have_admin_callout("successfully")
55
53
 
56
54
  within "#attachments table" do
57
55
  expect(page).to have_link("Very Important Document")
@@ -60,12 +58,10 @@ shared_examples "manage attachments examples" do
60
58
 
61
59
  it "can delete an attachment from a process" do
62
60
  within find("tr", text: stripped(translated(attachment.title))) do
63
- accept_confirm { page.find("a.action-icon--remove").click }
61
+ accept_confirm { click_link "Destroy" }
64
62
  end
65
63
 
66
- within ".callout-wrapper" do
67
- expect(page).to have_content("successfully")
68
- end
64
+ expect(page).to have_admin_callout("successfully")
69
65
 
70
66
  expect(page).to have_no_content(translated(attachment.title, locale: :en))
71
67
  end
@@ -73,7 +69,7 @@ shared_examples "manage attachments examples" do
73
69
  it "can update an attachment" do
74
70
  within "#attachments" do
75
71
  within find("tr", text: stripped(translated(attachment.title))) do
76
- page.find("a.action-icon--edit").click
72
+ click_link "Edit"
77
73
  end
78
74
  end
79
75
 
@@ -89,9 +85,7 @@ shared_examples "manage attachments examples" do
89
85
  find("*[type=submit]").click
90
86
  end
91
87
 
92
- within ".callout-wrapper" do
93
- expect(page).to have_content("successfully")
94
- end
88
+ expect(page).to have_admin_callout("successfully")
95
89
 
96
90
  within "#attachments table" do
97
91
  expect(page).to have_link("This is a nice photo")
@@ -3,7 +3,7 @@
3
3
  require "spec_helper"
4
4
 
5
5
  shared_examples "Managing feature permissions" do
6
- let(:organization) { create(:organization, available_authorizations: ["Decidim::DummyAuthorizationHandler"]) }
6
+ let(:organization) { create(:organization, available_authorizations: ["dummy_authorization_handler"]) }
7
7
  let(:user) { create(:user, :admin, :confirmed, organization: organization) }
8
8
 
9
9
  let!(:feature) do
@@ -16,7 +16,7 @@ shared_examples "Managing feature permissions" do
16
16
  visit participatory_space_engine.features_path(participatory_space)
17
17
 
18
18
  within ".feature-#{feature.id}" do
19
- page.find(".action-icon--permissions").click
19
+ click_link "Permissions"
20
20
  end
21
21
  end
22
22
 
@@ -33,7 +33,7 @@ shared_examples "Managing feature permissions" do
33
33
 
34
34
  expect(feature.reload.permissions["foo"]).to(
35
35
  include(
36
- "authorization_handler_name" => "decidim/dummy_authorization_handler",
36
+ "authorization_handler_name" => "dummy_authorization_handler",
37
37
  "options" => { "foo" => 123 }
38
38
  )
39
39
  )
@@ -4,7 +4,7 @@ module Decidim
4
4
  # This holds the decidim-admin version.
5
5
  module Admin
6
6
  def self.version
7
- "0.7.4"
7
+ "0.8.0"
8
8
  end
9
9
  end
10
10
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: decidim-admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.4
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Josep Jaume Rey Peroy
@@ -10,22 +10,36 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2017-11-23 00:00:00.000000000 Z
13
+ date: 2017-12-05 00:00:00.000000000 Z
14
14
  dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: active_link_to
17
+ requirement: !ruby/object:Gem::Requirement
18
+ requirements:
19
+ - - "~>"
20
+ - !ruby/object:Gem::Version
21
+ version: 1.0.0
22
+ type: :runtime
23
+ prerelease: false
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ requirements:
26
+ - - "~>"
27
+ - !ruby/object:Gem::Version
28
+ version: 1.0.0
15
29
  - !ruby/object:Gem::Dependency
16
30
  name: decidim-core
17
31
  requirement: !ruby/object:Gem::Requirement
18
32
  requirements:
19
33
  - - '='
20
34
  - !ruby/object:Gem::Version
21
- version: 0.7.4
35
+ version: 0.8.0
22
36
  type: :runtime
23
37
  prerelease: false
24
38
  version_requirements: !ruby/object:Gem::Requirement
25
39
  requirements:
26
40
  - - '='
27
41
  - !ruby/object:Gem::Version
28
- version: 0.7.4
42
+ version: 0.8.0
29
43
  - !ruby/object:Gem::Dependency
30
44
  name: devise
31
45
  requirement: !ruby/object:Gem::Requirement
@@ -68,20 +82,6 @@ dependencies:
68
82
  - - "~>"
69
83
  - !ruby/object:Gem::Version
70
84
  version: 1.7.0
71
- - !ruby/object:Gem::Dependency
72
- name: sassc-rails
73
- requirement: !ruby/object:Gem::Requirement
74
- requirements:
75
- - - "~>"
76
- - !ruby/object:Gem::Version
77
- version: 1.3.0
78
- type: :runtime
79
- prerelease: false
80
- version_requirements: !ruby/object:Gem::Requirement
81
- requirements:
82
- - - "~>"
83
- - !ruby/object:Gem::Version
84
- version: 1.3.0
85
85
  - !ruby/object:Gem::Dependency
86
86
  name: jquery-rails
87
87
  requirement: !ruby/object:Gem::Requirement
@@ -97,33 +97,19 @@ dependencies:
97
97
  - !ruby/object:Gem::Version
98
98
  version: 4.3.1
99
99
  - !ruby/object:Gem::Dependency
100
- name: foundation_rails_helper
101
- requirement: !ruby/object:Gem::Requirement
102
- requirements:
103
- - - "~>"
104
- - !ruby/object:Gem::Version
105
- version: 3.0.0.rc
106
- type: :runtime
107
- prerelease: false
108
- version_requirements: !ruby/object:Gem::Requirement
109
- requirements:
110
- - - "~>"
111
- - !ruby/object:Gem::Version
112
- version: 3.0.0.rc
113
- - !ruby/object:Gem::Dependency
114
- name: active_link_to
100
+ name: sassc-rails
115
101
  requirement: !ruby/object:Gem::Requirement
116
102
  requirements:
117
103
  - - "~>"
118
104
  - !ruby/object:Gem::Version
119
- version: 1.0.0
105
+ version: 1.3.0
120
106
  type: :runtime
121
107
  prerelease: false
122
108
  version_requirements: !ruby/object:Gem::Requirement
123
109
  requirements:
124
110
  - - "~>"
125
111
  - !ruby/object:Gem::Version
126
- version: 1.0.0
112
+ version: 1.3.0
127
113
  - !ruby/object:Gem::Dependency
128
114
  name: select2-rails
129
115
  requirement: !ruby/object:Gem::Requirement
@@ -144,28 +130,28 @@ dependencies:
144
130
  requirements:
145
131
  - - '='
146
132
  - !ruby/object:Gem::Version
147
- version: 0.7.4
133
+ version: 0.8.0
148
134
  type: :development
149
135
  prerelease: false
150
136
  version_requirements: !ruby/object:Gem::Requirement
151
137
  requirements:
152
138
  - - '='
153
139
  - !ruby/object:Gem::Version
154
- version: 0.7.4
140
+ version: 0.8.0
155
141
  - !ruby/object:Gem::Dependency
156
142
  name: decidim-participatory_processes
157
143
  requirement: !ruby/object:Gem::Requirement
158
144
  requirements:
159
145
  - - '='
160
146
  - !ruby/object:Gem::Version
161
- version: 0.7.4
147
+ version: 0.8.0
162
148
  type: :development
163
149
  prerelease: false
164
150
  version_requirements: !ruby/object:Gem::Requirement
165
151
  requirements:
166
152
  - - '='
167
153
  - !ruby/object:Gem::Version
168
- version: 0.7.4
154
+ version: 0.8.0
169
155
  description: Organization administration to manage a single organization.
170
156
  email:
171
157
  - josepjaume@gmail.com
@@ -210,6 +196,7 @@ files:
210
196
  - app/assets/stylesheets/decidim/admin/modules/_layout.scss
211
197
  - app/assets/stylesheets/decidim/admin/modules/_main-nav.scss
212
198
  - app/assets/stylesheets/decidim/admin/modules/_modules.scss
199
+ - app/assets/stylesheets/decidim/admin/modules/_pics.scss
213
200
  - app/assets/stylesheets/decidim/admin/modules/_process-header.scss
214
201
  - app/assets/stylesheets/decidim/admin/modules/_secondary-nav.scss
215
202
  - app/assets/stylesheets/decidim/admin/modules/_table-list.scss
@@ -279,6 +266,7 @@ files:
279
266
  - app/commands/decidim/admin/verify_user_group.rb
280
267
  - app/constraints/decidim/admin/organization_dashboard_constraint.rb
281
268
  - app/controllers/decidim/admin/application_controller.rb
269
+ - app/controllers/decidim/admin/authorization_workflows_controller.rb
282
270
  - app/controllers/decidim/admin/categories_controller.rb
283
271
  - app/controllers/decidim/admin/concerns/has_attachments.rb
284
272
  - app/controllers/decidim/admin/dashboard_controller.rb
@@ -337,6 +325,7 @@ files:
337
325
  - app/views/decidim/admin/attachments/index.html.erb
338
326
  - app/views/decidim/admin/attachments/new.html.erb
339
327
  - app/views/decidim/admin/attachments/show.html.erb
328
+ - app/views/decidim/admin/authorization_workflows/index.html.erb
340
329
  - app/views/decidim/admin/categories/_form.html.erb
341
330
  - app/views/decidim/admin/categories/edit.html.erb
342
331
  - app/views/decidim/admin/categories/index.html.erb
@@ -410,6 +399,7 @@ files:
410
399
  - config/locales/it.yml
411
400
  - config/locales/nl.yml
412
401
  - config/locales/pl.yml
402
+ - config/locales/pt.yml
413
403
  - config/locales/ru.yml
414
404
  - config/locales/uk.yml
415
405
  - config/routes.rb
@@ -448,7 +438,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
448
438
  version: '0'
449
439
  requirements: []
450
440
  rubyforge_project:
451
- rubygems_version: 2.7.1
441
+ rubygems_version: 2.6.13
452
442
  signing_key:
453
443
  specification_version: 4
454
444
  summary: Organization administration