decidim-conferences 0.27.5 → 0.27.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/cells/decidim/conferences/conference_address/show.erb +2 -2
- data/app/cells/decidim/conferences/conference_m_cell.rb +0 -4
- data/app/cells/decidim/conferences/conference_speaker_cell.rb +1 -1
- data/app/cells/decidim/conferences/content_blocks/highlighted_conferences/show.erb +1 -1
- data/app/cells/decidim/conferences/photo_cell.rb +1 -1
- data/app/controllers/decidim/conferences/conference_widgets_controller.rb +11 -1
- data/app/events/decidim/conferences/conference_registration_notification_event.rb +10 -0
- data/app/permissions/decidim/conferences/permissions.rb +11 -0
- data/app/views/decidim/conferences/conference_program/_program_meeting.html.erb +1 -1
- data/config/locales/ar.yml +2 -0
- data/config/locales/bg.yml +611 -0
- data/config/locales/ca.yml +2 -2
- data/config/locales/es-MX.yml +1 -1
- data/config/locales/es-PY.yml +1 -1
- data/config/locales/es.yml +1 -1
- data/config/locales/fi.yml +1 -1
- data/config/locales/he-IL.yml +1 -0
- data/config/locales/hu.yml +2 -0
- data/config/locales/ja.yml +2 -0
- data/config/locales/lv.yml +1 -0
- data/config/locales/pl.yml +3 -0
- data/config/locales/pt-BR.yml +9 -0
- data/config/locales/sk.yml +1 -0
- data/config/locales/sr-CS.yml +4 -0
- data/config/locales/tr-TR.yml +1 -0
- data/decidim-conferences.gemspec +33 -0
- data/lib/decidim/conferences/admin_engine.rb +1 -1
- data/lib/decidim/conferences/test/factories.rb +68 -31
- data/lib/decidim/conferences/version.rb +1 -1
- metadata +15 -14
- data/config/environment.rb +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 873b7b4885e630d523b8fcaf40bc12581b95e52d9346f1516fe7e8398922ef45
|
4
|
+
data.tar.gz: f243423b5405868cf22de819d876bb3064ac1e744d350c94c318d1c31c4b672c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1fecffcbb0c34107a3c4e70342b0fb6116275ecf86bac4df7b518048fb3a83e14a97e02af1526fc997b8358647b902de7d64118aacd6535e3f05524e9730d33a
|
7
|
+
data.tar.gz: 8dda12135eaeae94872946c580bc87c222f98eedab80f62a6ab426a1dba2fa46489cac55fae7d0d53af9037b4de7f005d613dd37f456f1f57764fff9c3dc500b
|
@@ -1,11 +1,11 @@
|
|
1
1
|
<div class="mb-s">
|
2
2
|
<% if model.respond_to? :location %>
|
3
3
|
<div>
|
4
|
-
<strong><%=
|
4
|
+
<strong><%= decidim_escape_translated model.location %></strong><br>
|
5
5
|
</div>
|
6
6
|
<% end %>
|
7
7
|
<div class="text-medium"><%= model.address %></div>
|
8
8
|
<% if model.respond_to? :location_hints %>
|
9
|
-
<div class="text-medium"><%=
|
9
|
+
<div class="text-medium"><%= decidim_escape_translated model.location_hints %></div>
|
10
10
|
<% end %>
|
11
11
|
</div>
|
@@ -10,7 +10,7 @@
|
|
10
10
|
<div aria-hidden="true" class="card__image-top"
|
11
11
|
style="background-image:url('<%= conference.attached_uploader(:hero_image).path %>')"></div>
|
12
12
|
<div class="card__content">
|
13
|
-
<span class="card__title card__link"><%=
|
13
|
+
<span class="card__title card__link"><%= decidim_escape_translated conference.title %></span>
|
14
14
|
</div>
|
15
15
|
<% end %>
|
16
16
|
</div>
|
@@ -5,10 +5,16 @@ module Decidim
|
|
5
5
|
class ConferenceWidgetsController < Decidim::WidgetsController
|
6
6
|
helper Decidim::SanitizeHelper
|
7
7
|
|
8
|
+
def show
|
9
|
+
enforce_permission_to :embed, :conference, conference: model if model
|
10
|
+
|
11
|
+
super
|
12
|
+
end
|
13
|
+
|
8
14
|
private
|
9
15
|
|
10
16
|
def model
|
11
|
-
@model ||= Conference.find_by(slug: params[:conference_slug])
|
17
|
+
@model ||= Conference.where(organization: current_organization).published.find_by(slug: params[:conference_slug])
|
12
18
|
end
|
13
19
|
|
14
20
|
def current_participatory_space
|
@@ -18,6 +24,10 @@ module Decidim
|
|
18
24
|
def iframe_url
|
19
25
|
@iframe_url ||= conference_conference_widget_url(model)
|
20
26
|
end
|
27
|
+
|
28
|
+
def permission_class_chain
|
29
|
+
::Decidim.permissions_registry.chain_for(::Decidim::Conferences::ApplicationController)
|
30
|
+
end
|
21
31
|
end
|
22
32
|
end
|
23
33
|
end
|
@@ -4,6 +4,7 @@ module Decidim
|
|
4
4
|
module Conferences
|
5
5
|
class ConferenceRegistrationNotificationEvent < Decidim::Events::BaseEvent
|
6
6
|
include Decidim::Events::NotificationEvent
|
7
|
+
include Decidim::SanitizeHelper
|
7
8
|
|
8
9
|
def notification_title
|
9
10
|
I18n.t("notification_title", **i18n_options).html_safe
|
@@ -12,10 +13,19 @@ module Decidim
|
|
12
13
|
def i18n_options
|
13
14
|
{
|
14
15
|
resource_title: resource_title,
|
16
|
+
resource_path: resource_path,
|
15
17
|
resource_url: resource_url,
|
16
18
|
scope: event_name
|
17
19
|
}
|
18
20
|
end
|
21
|
+
|
22
|
+
def resource_title
|
23
|
+
return unless resource
|
24
|
+
|
25
|
+
title = decidim_sanitize_translated(resource.title)
|
26
|
+
|
27
|
+
Decidim::ContentProcessor.render_without_format(title, links: false).html_safe
|
28
|
+
end
|
19
29
|
end
|
20
30
|
end
|
21
31
|
end
|
@@ -16,6 +16,7 @@ module Decidim
|
|
16
16
|
if permission_action.scope == :public
|
17
17
|
public_list_conferences_action?
|
18
18
|
public_read_conference_action?
|
19
|
+
public_embed_conference_action?
|
19
20
|
public_list_speakers_action?
|
20
21
|
public_list_program_action?
|
21
22
|
public_list_media_links_action?
|
@@ -131,6 +132,16 @@ module Decidim
|
|
131
132
|
toggle_allow(can_manage_conference?)
|
132
133
|
end
|
133
134
|
|
135
|
+
def public_embed_conference_action?
|
136
|
+
return unless permission_action.action == :embed &&
|
137
|
+
[:conference, :participatory_space].include?(permission_action.subject) &&
|
138
|
+
conference
|
139
|
+
|
140
|
+
return disallow! unless conference.published?
|
141
|
+
|
142
|
+
allow!
|
143
|
+
end
|
144
|
+
|
134
145
|
def public_list_speakers_action?
|
135
146
|
return unless permission_action.action == :list &&
|
136
147
|
permission_action.subject == :speakers
|
@@ -3,7 +3,7 @@
|
|
3
3
|
<%= start_time.to_s(:time) %> - <%= end_time.to_s(:time) %>
|
4
4
|
</div>
|
5
5
|
<div class="column medium-10 programme-title">
|
6
|
-
<%= link_to present(meeting).title, resource_locator(meeting).path %>
|
6
|
+
<%= link_to decidim_sanitize(present(meeting).title), resource_locator(meeting).path %>
|
7
7
|
</div>
|
8
8
|
</div>
|
9
9
|
<div class="row">
|
data/config/locales/ar.yml
CHANGED
@@ -58,6 +58,7 @@ ar:
|
|
58
58
|
conference_meeting_ids: الاجتماعات ذات الصلة
|
59
59
|
full_name: الاسم الكامل
|
60
60
|
position: المنصب
|
61
|
+
twitter_handle: معرّف X
|
61
62
|
user_id: المستخدم
|
62
63
|
conference_user_role:
|
63
64
|
email: البريد الإلكتروني
|
@@ -440,6 +441,7 @@ ar:
|
|
440
441
|
invalid: حدثت مشكلة أثناء مغادرة هذا المؤتمر.
|
441
442
|
success: لقد تركت المؤتمر بنجاح.
|
442
443
|
conference_speaker:
|
444
|
+
go_to_twitter: الذهاب إلى X
|
443
445
|
more_info: مزيد من المعلومات
|
444
446
|
personal_website: موقع الويب الشخصي
|
445
447
|
show:
|