decidim-conferences 0.28.4 → 0.28.6
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/app/forms/decidim/conferences/admin/conference_form.rb +4 -4
- data/app/forms/decidim/conferences/admin/conference_speaker_form.rb +1 -1
- data/app/forms/decidim/conferences/admin/registration_type_form.rb +1 -1
- data/app/mailers/decidim/conferences/admin/send_conference_diploma_mailer.rb +9 -5
- data/app/models/decidim/conference.rb +1 -1
- data/app/permissions/decidim/conferences/permissions.rb +8 -0
- data/app/views/decidim/conferences/admin/media_links/new.html.erb +1 -1
- data/app/views/decidim/conferences/admin/send_conference_diploma_mailer/diploma_user.html.erb +12 -8
- data/app/views/layouts/decidim/diploma.html.erb +1 -1
- data/config/initializers/wicked_pdf.rb +0 -2
- data/config/locales/ar.yml +2 -21
- data/config/locales/bg.yml +0 -21
- data/config/locales/bn-BD.yml +1 -0
- data/config/locales/bs-BA.yml +14 -0
- data/config/locales/ca-IT.yml +603 -0
- data/config/locales/ca.yml +13 -11
- data/config/locales/cs.yml +15 -13
- data/config/locales/de.yml +14 -12
- data/config/locales/el.yml +0 -21
- data/config/locales/en.yml +21 -19
- data/config/locales/es-MX.yml +14 -12
- data/config/locales/es-PY.yml +17 -15
- data/config/locales/es.yml +10 -8
- data/config/locales/eu.yml +181 -179
- data/config/locales/fi-plain.yml +13 -11
- data/config/locales/fi.yml +19 -17
- data/config/locales/fr-CA.yml +15 -13
- data/config/locales/fr.yml +15 -13
- data/config/locales/gl.yml +0 -21
- data/config/locales/hu.yml +0 -21
- data/config/locales/id-ID.yml +0 -21
- data/config/locales/it.yml +2 -21
- data/config/locales/ja.yml +12 -10
- data/config/locales/lb.yml +0 -19
- data/config/locales/lt.yml +0 -21
- data/config/locales/lv.yml +0 -21
- data/config/locales/nl.yml +0 -21
- data/config/locales/no.yml +0 -21
- data/config/locales/pl.yml +0 -21
- data/config/locales/pt-BR.yml +0 -21
- data/config/locales/pt.yml +0 -21
- data/config/locales/ro-RO.yml +15 -12
- data/config/locales/sk.yml +0 -21
- data/config/locales/sv.yml +71 -21
- data/config/locales/tr-TR.yml +0 -21
- data/config/locales/zh-CN.yml +0 -21
- data/config/locales/zh-TW.yml +0 -21
- data/decidim-conferences.gemspec +1 -2
- data/lib/decidim/conferences/version.rb +1 -1
- metadata +14 -25
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 990d72a44756dcb32fb0bbf413558a22352d97331eb59b44d280f9b8e4a0cd47
|
4
|
+
data.tar.gz: 9b8ca058ecec8486c955abce1036113013762c3ce564b9e5afcb3c53fb6c7abe
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1edfc7e86efae9d46b977ea253ce9ac31bcc6194189fc52fb5ffd653899a970c0c1df8049071812bf61e76677cd7c126d519592ccf167aea7e38f66366b718ab
|
7
|
+
data.tar.gz: ce86a61a52e8cff75f692eabee4c50c510a12fb8610df98e8aa1938c6588a90e5aa3f97892291b689aef2ea9f470a23122d5a7f1a60b60f4ce3086b109c179bd
|
@@ -12,10 +12,10 @@ module Decidim
|
|
12
12
|
|
13
13
|
translatable_attribute :title, String
|
14
14
|
translatable_attribute :slogan, String
|
15
|
-
translatable_attribute :short_description,
|
16
|
-
translatable_attribute :description,
|
17
|
-
translatable_attribute :objectives,
|
18
|
-
translatable_attribute :registration_terms,
|
15
|
+
translatable_attribute :short_description, Decidim::Attributes::RichText
|
16
|
+
translatable_attribute :description, Decidim::Attributes::RichText
|
17
|
+
translatable_attribute :objectives, Decidim::Attributes::RichText
|
18
|
+
translatable_attribute :registration_terms, Decidim::Attributes::RichText
|
19
19
|
|
20
20
|
mimic :conference
|
21
21
|
|
@@ -11,7 +11,7 @@ module Decidim
|
|
11
11
|
mimic :conference_registration_type
|
12
12
|
|
13
13
|
translatable_attribute :title, String
|
14
|
-
translatable_attribute :description,
|
14
|
+
translatable_attribute :description, Decidim::Attributes::RichText
|
15
15
|
|
16
16
|
attribute :weight, Integer
|
17
17
|
attribute :price, Decimal
|
@@ -33,14 +33,18 @@ module Decidim
|
|
33
33
|
private
|
34
34
|
|
35
35
|
def add_diploma_attachment
|
36
|
-
diploma = WickedPdf.new.pdf_from_string(
|
36
|
+
diploma = WickedPdf.new.pdf_from_string(pdf_content, orientation: "Landscape")
|
37
|
+
|
38
|
+
attachments["conference-#{@user.nickname.parameterize}-diploma.pdf"] = diploma
|
39
|
+
end
|
40
|
+
|
41
|
+
def pdf_content
|
42
|
+
Premailer.new(
|
37
43
|
render_to_string(pdf: "conference-diploma",
|
38
44
|
template: "decidim/conferences/admin/send_conference_diploma_mailer/diploma_user",
|
39
45
|
layout: "decidim/diploma"),
|
40
|
-
|
41
|
-
)
|
42
|
-
|
43
|
-
attachments["conference-#{@user.nickname.parameterize}-diploma.pdf"] = diploma
|
46
|
+
with_html_string: true
|
47
|
+
).to_inline_css
|
44
48
|
end
|
45
49
|
end
|
46
50
|
end
|
@@ -136,7 +136,7 @@ module Decidim
|
|
136
136
|
end
|
137
137
|
|
138
138
|
def user_roles(role_name = nil)
|
139
|
-
roles = Decidim::ConferenceUserRole.where(conference: self)
|
139
|
+
roles = Decidim::ConferenceUserRole.order_by_name.where(conference: self)
|
140
140
|
return roles if role_name.blank?
|
141
141
|
|
142
142
|
roles.where(role: role_name)
|
@@ -3,6 +3,8 @@
|
|
3
3
|
module Decidim
|
4
4
|
module Conferences
|
5
5
|
class Permissions < Decidim::DefaultPermissions
|
6
|
+
include Decidim::UserRoleChecker
|
7
|
+
|
6
8
|
def permissions
|
7
9
|
user_can_enter_space_area?
|
8
10
|
|
@@ -42,6 +44,7 @@ module Decidim
|
|
42
44
|
user_can_export_conference_registrations?
|
43
45
|
user_can_confirm_conference_registration?
|
44
46
|
user_can_create_conference?
|
47
|
+
user_can_upload_images_in_conference?
|
45
48
|
|
46
49
|
# org admins and space admins can do everything in the admin section
|
47
50
|
org_admin_action?
|
@@ -314,6 +317,11 @@ module Decidim
|
|
314
317
|
def conference
|
315
318
|
@conference ||= context.fetch(:current_participatory_space, nil) || context.fetch(:conference, nil)
|
316
319
|
end
|
320
|
+
|
321
|
+
# Checks of assigned admins can upload images in the conference
|
322
|
+
def user_can_upload_images_in_conference?
|
323
|
+
allow! if user&.admin_terms_accepted? && user_has_any_role?(user, conference, broad_check: true) && (permission_action.subject == :editor_image)
|
324
|
+
end
|
317
325
|
end
|
318
326
|
end
|
319
327
|
end
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<% add_decidim_page_title(t("media_links.new.title", scope: "decidim.admin")) %>
|
2
2
|
<div class="item_show__header">
|
3
3
|
<h1 class="item_show__header-title">
|
4
|
-
<%= t("
|
4
|
+
<%= t("media_links.new.title", scope: "decidim.admin") %>
|
5
5
|
</h1>
|
6
6
|
</div>
|
7
7
|
<div class="item__edit item__edit-1col">
|
data/app/views/decidim/conferences/admin/send_conference_diploma_mailer/diploma_user.html.erb
CHANGED
@@ -1,11 +1,14 @@
|
|
1
1
|
<main class="conference-diploma">
|
2
2
|
<div class="diploma__border">
|
3
3
|
<div class="diploma__content">
|
4
|
-
<div
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
4
|
+
<div>
|
5
|
+
<% logo = @conference.attached_uploader(:main_logo).variant(:thumb) %>
|
6
|
+
<% if logo %>
|
7
|
+
<div class="diploma__logo">
|
8
|
+
<%= image_tag "data:#{logo.blob.content_type};base64, #{Base64.encode64(logo.download.presence || "")}" %>
|
9
|
+
</div>
|
10
|
+
<% end %>
|
11
|
+
<div class="diploma__name">
|
9
12
|
<h2><strong><%= translated_attribute(@conference.title) %></strong></h2>
|
10
13
|
<h3><%= t("decidim.conferences.admin.send_conference_diploma_mailer.diploma_user.certificate_of_attendance") %></h3>
|
11
14
|
<p><%= t("decidim.conferences.admin.send_conference_diploma_mailer.diploma_user.certificate_of_attendance_description", user: @user.name, title: translated_attribute(@conference.title), location: @conference.location, start: l(@conference.start_date, format: :decidim_short), end: l(@conference.end_date, format: :decidim_short) ).html_safe %></p>
|
@@ -13,9 +16,10 @@
|
|
13
16
|
<hr class="mt-m mb-m">
|
14
17
|
<div class="diploma__attendance">
|
15
18
|
<strong><%= t("decidim.conferences.admin.send_conference_diploma_mailer.diploma_user.attendance_verified_by") %></strong>
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
+
<% signature = @conference.attached_uploader(:signature).variant(:thumb) %>
|
20
|
+
<% if signature %>
|
21
|
+
<div><%= image_tag "data:#{signature.blob.content_type};base64, #{Base64.encode64(signature.download.presence || "")}" %></div>
|
22
|
+
<% end %>
|
19
23
|
<%= l(@conference.sign_date, format: :decidim_short) %>, <%= @conference.signature_name %>
|
20
24
|
</div>
|
21
25
|
</div>
|
@@ -3,7 +3,7 @@
|
|
3
3
|
<head>
|
4
4
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
5
5
|
<meta name="viewport" content="width=device-width">
|
6
|
-
<%=
|
6
|
+
<%= stylesheet_pack_tag "decidim_conference_diploma" %>
|
7
7
|
</head>
|
8
8
|
<body>
|
9
9
|
<%= yield %>
|
@@ -14,8 +14,6 @@ WickedPdf.config = {
|
|
14
14
|
# Path to the wkhtmltopdf executable: This usually is not needed if using
|
15
15
|
# one of the wkhtmltopdf-binary family of gems.
|
16
16
|
# exe_path: '/usr/local/bin/wkhtmltopdf',
|
17
|
-
# or
|
18
|
-
exe_path: Gem.bin_path("wkhtmltopdf-binary", "wkhtmltopdf")
|
19
17
|
|
20
18
|
# Layout file to be used for all PDFs
|
21
19
|
# (but can be overridden in `render :pdf` calls)
|
data/config/locales/ar.yml
CHANGED
@@ -63,6 +63,8 @@ ar:
|
|
63
63
|
email: البريد الإلكتروني
|
64
64
|
name: اسم
|
65
65
|
role: وظيفة
|
66
|
+
partner:
|
67
|
+
logo: الشعار
|
66
68
|
activerecord:
|
67
69
|
models:
|
68
70
|
decidim/conference:
|
@@ -116,13 +118,11 @@ ar:
|
|
116
118
|
destroy:
|
117
119
|
success: تم حذف رئيس المؤتمر بنجاح.
|
118
120
|
edit:
|
119
|
-
title: تحديث المتحدث المؤتمر.
|
120
121
|
update: تحديث
|
121
122
|
index:
|
122
123
|
conference_speakers_title: المتحدثون في المؤتمر
|
123
124
|
new:
|
124
125
|
create: إنشاء
|
125
|
-
title: رئيس المؤتمر الجديد.
|
126
126
|
update:
|
127
127
|
error: حدثت مشكلة أثناء تحديث متحدث المؤتمر هذا.
|
128
128
|
success: تم تحديث مكبر صوت المؤتمر بنجاح.
|
@@ -133,11 +133,9 @@ ar:
|
|
133
133
|
destroy:
|
134
134
|
success: تمت إزالة مسؤول المؤتمر بنجاح.
|
135
135
|
edit:
|
136
|
-
title: تحديث مسؤول المؤتمر.
|
137
136
|
update: تحديث
|
138
137
|
new:
|
139
138
|
create: إنشاء
|
140
|
-
title: مشرف المؤتمر الجديد.
|
141
139
|
update:
|
142
140
|
error: حدثت مشكلة أثناء تحديث مشرف المؤتمر هذا.
|
143
141
|
success: تم تحديث مشرف المؤتمر بنجاح.
|
@@ -166,20 +164,12 @@ ar:
|
|
166
164
|
media_links:
|
167
165
|
create:
|
168
166
|
error: حدثت مشكلة أثناء إنشاء رابط وسائط جديد.
|
169
|
-
success: تم إنشاء رابط الوسائط بنجاح.
|
170
|
-
destroy:
|
171
|
-
success: تم حذف رابط الوسائط بنجاح.
|
172
167
|
edit:
|
173
|
-
title: تحديث رابط الوسائط.
|
174
168
|
update: تحديث
|
175
|
-
index:
|
176
|
-
media_links_title: روابط الوسائط
|
177
169
|
new:
|
178
170
|
create: إنشاء
|
179
|
-
title: وصلة الوسائط
|
180
171
|
update:
|
181
172
|
error: حدثت مشكلة أثناء تحديث رابط الوسائط هذا.
|
182
|
-
success: تم تحديث رابط الوسائط بنجاح.
|
183
173
|
menu:
|
184
174
|
conferences: المؤتمرات
|
185
175
|
conferences_submenu:
|
@@ -191,14 +181,10 @@ ar:
|
|
191
181
|
conference_admins: المشرفون على المؤتمر
|
192
182
|
conference_invites: تدعو
|
193
183
|
conference_speakers: مكبرات الصوت
|
194
|
-
diploma: شهادة حضور
|
195
184
|
info: عن هذا المؤتمر
|
196
|
-
media_links: روابط الوسائط
|
197
185
|
moderations: الإعتدال
|
198
186
|
partners: شركاء
|
199
|
-
registration_types: أنواع التسجيل
|
200
187
|
registrations: التسجيلات
|
201
|
-
user_registrations: تسجيلات المستخدم
|
202
188
|
models:
|
203
189
|
conference:
|
204
190
|
fields:
|
@@ -227,7 +213,6 @@ ar:
|
|
227
213
|
date: تاريخ
|
228
214
|
link: حلقة الوصل
|
229
215
|
title: عنوان
|
230
|
-
name: وصلة الوسائط
|
231
216
|
partner:
|
232
217
|
fields:
|
233
218
|
link: حلقة الوصل
|
@@ -253,7 +238,6 @@ ar:
|
|
253
238
|
destroy:
|
254
239
|
success: تمت إزالة شريك المؤتمر بنجاح.
|
255
240
|
edit:
|
256
|
-
title: تحديث شريك.
|
257
241
|
update: تحديث
|
258
242
|
new:
|
259
243
|
create: إنشاء
|
@@ -275,7 +259,6 @@ ar:
|
|
275
259
|
destroy:
|
276
260
|
success: تمت إزالة نوع تسجيل المؤتمر بنجاح.
|
277
261
|
edit:
|
278
|
-
title: تحديث نوع التسجيل.
|
279
262
|
update: تحديث
|
280
263
|
new:
|
281
264
|
create: إنشاء
|
@@ -369,7 +352,6 @@ ar:
|
|
369
352
|
diplomas:
|
370
353
|
edit:
|
371
354
|
save: حفظ
|
372
|
-
title: شهادة حضور
|
373
355
|
invite_join_conference_mailer:
|
374
356
|
invite:
|
375
357
|
decline: رفض الدعوة "%{conference_title}"
|
@@ -388,7 +370,6 @@ ar:
|
|
388
370
|
diploma_html: ستجد شهادة حضور المؤتمر <a href="%{url}">%{title}</a> في المرفقات.
|
389
371
|
diploma_user:
|
390
372
|
attendance_verified_by: تم التحقق من الحضور بواسطة
|
391
|
-
certificate_of_attendance: شهادة حضور
|
392
373
|
certificate_of_attendance_description: هذا هو التأكيد على أن <strong>%{user}</strong> قد حضر وشارك في <strong>%{title}</strong> الذي عقد في <strong>%{location}</strong> في <strong>%{start} - %{end}</strong>
|
393
374
|
send_diploma:
|
394
375
|
error: حدثت مشكلة أثناء إرسال شهادات حضور المؤتمر.
|
data/config/locales/bg.yml
CHANGED
@@ -120,13 +120,11 @@ bg:
|
|
120
120
|
destroy:
|
121
121
|
success: Говорителят на конференцията беше изтрит успешно.
|
122
122
|
edit:
|
123
|
-
title: Актуализиране на говорителя на конференцията.
|
124
123
|
update: Актуализация
|
125
124
|
index:
|
126
125
|
conference_speakers_title: Говорители на конференция
|
127
126
|
new:
|
128
127
|
create: Създаване
|
129
|
-
title: Нов говорител на конференция.
|
130
128
|
update:
|
131
129
|
error: Възникна проблем при актуализирането на този говорител на конференцията.
|
132
130
|
success: Говорителят на конференцията беше актуализиран успешно.
|
@@ -137,13 +135,11 @@ bg:
|
|
137
135
|
destroy:
|
138
136
|
success: Администраторът на конференцията беше премахнат успешно.
|
139
137
|
edit:
|
140
|
-
title: Актуализиране на администратора на конференцията.
|
141
138
|
update: Актуализация
|
142
139
|
index:
|
143
140
|
conference_admins_title: Администратори на конференция
|
144
141
|
new:
|
145
142
|
create: Създаване
|
146
|
-
title: Нов администратор на конференция.
|
147
143
|
update:
|
148
144
|
error: Възникна проблем при актуализирането на този администратор на конференцията.
|
149
145
|
success: Администраторът на конференцията беше актуализиран успешно.
|
@@ -173,20 +169,12 @@ bg:
|
|
173
169
|
media_links:
|
174
170
|
create:
|
175
171
|
error: Възникна проблем при създаването на нов медия линк.
|
176
|
-
success: Медийният линк беше създаден успешно.
|
177
|
-
destroy:
|
178
|
-
success: Медийният линк беше изтрит успешно.
|
179
172
|
edit:
|
180
|
-
title: Актуализиране на медийния линк.
|
181
173
|
update: Актуализация
|
182
|
-
index:
|
183
|
-
media_links_title: Медийни линкове
|
184
174
|
new:
|
185
175
|
create: Създаване
|
186
|
-
title: Медия линк
|
187
176
|
update:
|
188
177
|
error: Възникна проблем при актуализирането на този медия линк.
|
189
|
-
success: Медийният линк беше актуализиран успешно.
|
190
178
|
menu:
|
191
179
|
conferences: Конференции
|
192
180
|
conferences_submenu:
|
@@ -198,15 +186,11 @@ bg:
|
|
198
186
|
conference_admins: Администратори на конференция
|
199
187
|
conference_invites: Покани
|
200
188
|
conference_speakers: Говорители
|
201
|
-
diploma: Сертификати за присъствие
|
202
189
|
info: Относно тази конференция
|
203
|
-
media_links: Медия линкове
|
204
190
|
moderations: Модерации
|
205
191
|
partners: Партньори
|
206
|
-
registration_types: Типове регистрация
|
207
192
|
registrations: Регистрации
|
208
193
|
see_conference: Виз конференцията
|
209
|
-
user_registrations: Потребителска регистрация
|
210
194
|
models:
|
211
195
|
conference:
|
212
196
|
fields:
|
@@ -235,7 +219,6 @@ bg:
|
|
235
219
|
date: Дата
|
236
220
|
link: Линк
|
237
221
|
title: Заглавие
|
238
|
-
name: Медия линк
|
239
222
|
partner:
|
240
223
|
fields:
|
241
224
|
link: Линк
|
@@ -261,7 +244,6 @@ bg:
|
|
261
244
|
destroy:
|
262
245
|
success: Партньорът за конференцията беше премахнат успешно.
|
263
246
|
edit:
|
264
|
-
title: Актуализиране на партньора.
|
265
247
|
update: Актуализация
|
266
248
|
new:
|
267
249
|
create: Създаване
|
@@ -283,7 +265,6 @@ bg:
|
|
283
265
|
destroy:
|
284
266
|
success: Типът регистрация за конференцията беше премахнат успешно.
|
285
267
|
edit:
|
286
|
-
title: Актуализиране на типа на регистрацията.
|
287
268
|
update: Актуализация
|
288
269
|
new:
|
289
270
|
create: Създаване
|
@@ -384,7 +365,6 @@ bg:
|
|
384
365
|
diplomas:
|
385
366
|
edit:
|
386
367
|
save: Запази
|
387
|
-
title: Сертификати за присъствие
|
388
368
|
invite_join_conference_mailer:
|
389
369
|
invite:
|
390
370
|
decline: Отказ на поканата за „%{conference_title}“
|
@@ -404,7 +384,6 @@ bg:
|
|
404
384
|
diploma_html: Ще намерите сертификата за присъствие на конференцията <a href="%{url}">%{title}</a> в прикачените файлове.
|
405
385
|
diploma_user:
|
406
386
|
attendance_verified_by: Присъствието е потвърдено от
|
407
|
-
certificate_of_attendance: Сертификати за присъствие
|
408
387
|
certificate_of_attendance_description: С настоящото се удостоверява, че <strong>%{user}</strong> посети и взе участие в(ъв) <strong>%{title}</strong>, <strong>%{location}</strong> на <strong>%{start} — %{end}</strong>
|
409
388
|
send_diploma:
|
410
389
|
error: Възникна проблем при изпращането на сертификатите за присъствие на конференцията.
|
@@ -0,0 +1 @@
|
|
1
|
+
bn:
|
@@ -0,0 +1,14 @@
|
|
1
|
+
---
|
2
|
+
bs:
|
3
|
+
decidim:
|
4
|
+
admin:
|
5
|
+
models:
|
6
|
+
conference_user_role:
|
7
|
+
roles:
|
8
|
+
valuator: Procenjivač
|
9
|
+
events:
|
10
|
+
conferences:
|
11
|
+
role_assigned:
|
12
|
+
email_intro: Imenovani ste na funkciju %{role} konferencije %{resource_title}.
|
13
|
+
email_outro: Dobili ste ovo obaveštenje zbog toga što ste %{role} konferencije %{resource_title}.
|
14
|
+
email_subject: Imenovani ste na funkciju %{role} %{resource_title}.
|