decidim-conferences 0.24.0 → 0.25.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (104) hide show
  1. checksums.yaml +4 -4
  2. data/app/cells/decidim/conferences/conference_m_cell.rb +1 -1
  3. data/app/cells/decidim/conferences/conference_speaker/show.erb +2 -2
  4. data/app/cells/decidim/conferences/conference_speaker_cell.rb +3 -3
  5. data/app/cells/decidim/conferences/content_blocks/highlighted_conferences/show.erb +1 -1
  6. data/app/cells/decidim/conferences/partner_cell.rb +2 -2
  7. data/app/commands/decidim/conferences/admin/copy_conference.rb +9 -2
  8. data/app/commands/decidim/conferences/admin/create_conference_speaker.rb +4 -2
  9. data/app/commands/decidim/conferences/admin/update_conference.rb +5 -10
  10. data/app/commands/decidim/conferences/admin/update_conference_speaker.rb +5 -9
  11. data/app/commands/decidim/conferences/admin/update_diploma.rb +2 -2
  12. data/app/commands/decidim/conferences/admin/update_partner.rb +5 -5
  13. data/app/controllers/decidim/conferences/admin/conference_invites_controller.rb +0 -2
  14. data/app/controllers/decidim/conferences/admin/conference_registrations_controller.rb +0 -2
  15. data/app/controllers/decidim/conferences/admin/conference_speakers_controller.rb +3 -3
  16. data/app/controllers/decidim/conferences/admin/conferences_controller.rb +1 -5
  17. data/app/controllers/decidim/conferences/admin/diplomas_controller.rb +2 -4
  18. data/app/forms/decidim/conferences/admin/conference_form.rb +5 -4
  19. data/app/forms/decidim/conferences/admin/conference_speaker_form.rb +1 -1
  20. data/app/forms/decidim/conferences/admin/partner_form.rb +2 -2
  21. data/app/models/decidim/conference.rb +8 -8
  22. data/app/models/decidim/conference_speaker.rb +2 -2
  23. data/app/models/decidim/conferences/partner.rb +2 -2
  24. data/app/packs/entrypoints/decidim_conferences_admin.js +7 -0
  25. data/app/{assets/images/decidim/conferences/conference.svg → packs/images/decidim/conferences/decidim_conferences.svg} +0 -0
  26. data/app/{assets/javascripts/decidim/conferences/admin/conference_invite_form.es6 → packs/src/decidim/conferences/admin/conference_invite_form.js} +3 -3
  27. data/app/{assets/javascripts/decidim/conferences/admin/conference_speakers.js.es6 → packs/src/decidim/conferences/admin/conference_speakers.js} +3 -3
  28. data/app/packs/src/decidim/conferences/admin/conferences.js +27 -0
  29. data/app/{assets/stylesheet → packs/stylesheets}/decidim/conferences/conferences.scss +0 -0
  30. data/app/presenters/decidim/conferences/conference_stats_presenter.rb +8 -22
  31. data/app/queries/decidim/conferences/admin/admin_users.rb +24 -11
  32. data/app/uploaders/decidim/conferences/diploma_uploader.rb +4 -2
  33. data/app/uploaders/decidim/conferences/partner_logo_uploader.rb +5 -5
  34. data/app/uploaders/decidim/cw/conferences/diploma_uploader.rb +14 -0
  35. data/app/uploaders/decidim/cw/conferences/partner_logo_uploader.rb +15 -0
  36. data/app/views/decidim/conferences/admin/conference_copies/_form.html.erb +1 -1
  37. data/app/views/decidim/conferences/admin/conference_invites/_form.html.erb +1 -1
  38. data/app/views/decidim/conferences/admin/conference_invites/index.html.erb +1 -1
  39. data/app/views/decidim/conferences/admin/conference_registrations/index.html.erb +1 -1
  40. data/app/views/decidim/conferences/admin/conference_speakers/_form.html.erb +1 -1
  41. data/app/views/decidim/conferences/admin/conference_speakers/edit.html.erb +1 -1
  42. data/app/views/decidim/conferences/admin/conferences/_form.html.erb +1 -3
  43. data/app/views/decidim/conferences/admin/invite_join_conference_mailer/invite.html.erb +4 -4
  44. data/app/views/decidim/conferences/admin/partners/index.html.erb +1 -1
  45. data/app/views/decidim/conferences/admin/send_conference_diploma_mailer/diploma_user.html.erb +2 -2
  46. data/app/views/decidim/conferences/conference_program/_program_meeting.html.erb +5 -5
  47. data/app/views/decidim/conferences/conference_registration_mailer/confirmation.html.erb +3 -3
  48. data/app/views/decidim/conferences/conference_registration_mailer/pending_validation.html.erb +3 -3
  49. data/app/views/decidim/conferences/conferences/_promoted_conference.html.erb +1 -1
  50. data/app/views/decidim/conferences/conferences/show.html.erb +2 -3
  51. data/app/views/devise/mailer/join_conference.html.erb +5 -5
  52. data/app/views/layouts/decidim/_conference_hero.html.erb +1 -1
  53. data/app/views/layouts/decidim/admin/conference.html.erb +4 -106
  54. data/app/views/layouts/decidim/conference.html.erb +2 -2
  55. data/app/views/layouts/decidim/diploma.html.erb +1 -1
  56. data/config/assets.rb +9 -0
  57. data/config/locales/ar.yml +6 -18
  58. data/config/locales/ca.yml +44 -18
  59. data/config/locales/cs.yml +46 -20
  60. data/config/locales/de.yml +10 -18
  61. data/config/locales/el.yml +6 -18
  62. data/config/locales/en.yml +44 -18
  63. data/config/locales/es-MX.yml +44 -18
  64. data/config/locales/es-PY.yml +44 -18
  65. data/config/locales/es.yml +44 -18
  66. data/config/locales/eu.yml +6 -18
  67. data/config/locales/fi-plain.yml +44 -18
  68. data/config/locales/fi.yml +44 -18
  69. data/config/locales/fr-CA.yml +7 -18
  70. data/config/locales/fr-LU.yml +577 -0
  71. data/config/locales/fr.yml +7 -18
  72. data/config/locales/gl.yml +58 -18
  73. data/config/locales/hu.yml +6 -18
  74. data/config/locales/id-ID.yml +6 -18
  75. data/config/locales/it.yml +55 -18
  76. data/config/locales/ja.yml +49 -18
  77. data/config/locales/lb-LU.yml +1 -0
  78. data/config/locales/lv.yml +6 -17
  79. data/config/locales/nl.yml +176 -144
  80. data/config/locales/no.yml +6 -18
  81. data/config/locales/pl.yml +33 -26
  82. data/config/locales/pt-BR.yml +65 -18
  83. data/config/locales/pt.yml +6 -18
  84. data/config/locales/ro-RO.yml +30 -18
  85. data/config/locales/sk.yml +6 -18
  86. data/config/locales/sl.yml +0 -2
  87. data/config/locales/sv.yml +47 -17
  88. data/config/locales/tr-TR.yml +6 -18
  89. data/config/locales/zh-CN.yml +6 -18
  90. data/db/migrate/20210408204953_allow_null_logo_column_in_decidim_conferences_partners_table.rb +7 -0
  91. data/lib/decidim/api/conference_partner_type.rb +4 -0
  92. data/lib/decidim/api/conference_speaker_type.rb +4 -0
  93. data/lib/decidim/api/conference_type.rb +9 -1
  94. data/lib/decidim/conferences/admin_engine.rb +138 -8
  95. data/lib/decidim/conferences/engine.rb +6 -9
  96. data/lib/decidim/conferences/participatory_space.rb +40 -7
  97. data/lib/decidim/conferences/version.rb +1 -1
  98. metadata +27 -25
  99. data/app/assets/config/admin/decidim_conferences_manifest.js +0 -3
  100. data/app/assets/config/decidim_conferences_manifest.js +0 -2
  101. data/app/assets/javascripts/decidim/conferences/admin/conferences.js.es6 +0 -30
  102. data/app/assets/javascripts/decidim/conferences/conferences.js.es6 +0 -0
  103. data/app/views/decidim/conferences/conferences/_statistics.html.erb +0 -10
  104. data/config/locales/ja-JP.yml +0 -575
@@ -0,0 +1,27 @@
1
+ $(() => {
2
+ const $conferenceScopeEnabled = $("#conference_scopes_enabled");
3
+ const $conferenceScopeId = $("#conference_scope_id");
4
+ const $form = $(".edit_conference, .new_conference");
5
+
6
+ if ($form.length > 0) {
7
+ $conferenceScopeEnabled.on("change", (event) => {
8
+ const checked = event.target.checked;
9
+ window.theDataPicker.enabled($conferenceScopeId, checked);
10
+ })
11
+ window.theDataPicker.enabled($conferenceScopeId, $conferenceScopeEnabled.prop("checked"));
12
+
13
+ const $registrationsEnabled = $form.find("#conference_registrations_enabled");
14
+ const $availableSlots = $form.find("#conference_available_slots");
15
+ const toggleDisabledFields = () => {
16
+ const enabled = $registrationsEnabled.prop("checked");
17
+ $availableSlots.attr("disabled", !enabled);
18
+
19
+ $form.find("#conference_registrations_terms .editor-container").each((idx, node) => {
20
+ const quill = Quill.find(node);
21
+ quill.enable(enabled);
22
+ })
23
+ };
24
+ $registrationsEnabled.on("change", toggleDisabledFields);
25
+ toggleDisabledFields();
26
+ }
27
+ });
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Conferences
5
5
  # A presenter to render statistics in the homepage.
6
- class ConferenceStatsPresenter < Rectify::Presenter
6
+ class ConferenceStatsPresenter < Decidim::StatsPresenter
7
7
  attribute :conference, Decidim::Conference
8
8
  include IconHelper
9
9
 
@@ -11,39 +11,25 @@ module Decidim
11
11
  def highlighted
12
12
  highlighted_stats = component_stats(priority: StatsRegistry::HIGH_PRIORITY)
13
13
  highlighted_stats.concat(component_stats(priority: StatsRegistry::MEDIUM_PRIORITY))
14
+ highlighted_stats.concat(comments_stats(:conferences))
14
15
  highlighted_stats = highlighted_stats.reject(&:empty?)
15
16
  highlighted_stats = highlighted_stats.reject { |_manifest, _name, data| data.zero? }
16
- grouped_highlighted_stats = highlighted_stats.group_by { |stats| stats.first.name }
17
+ grouped_highlighted_stats = highlighted_stats.group_by(&:first)
17
18
 
18
- safe_join(
19
- grouped_highlighted_stats.map do |_manifest_name, stats|
20
- content_tag :div, class: "process_stats-item" do
21
- safe_join(
22
- stats.each_with_index.map do |stat, index|
23
- render_stats_data(stat[0], stat[1], stat[2], index)
24
- end
25
- )
26
- end
27
- end
28
- )
19
+ statistics(grouped_highlighted_stats)
29
20
  end
30
21
 
31
22
  private
32
23
 
33
24
  def component_stats(conditions)
34
25
  Decidim.component_manifests.map do |component_manifest|
35
- component_manifest.stats.filter(conditions).with_context(published_components).map { |name, data| [component_manifest, name, data] }.flatten
26
+ component_manifest.stats
27
+ .filter(conditions)
28
+ .with_context(published_components)
29
+ .map { |name, data| [component_manifest.name, name, data] }.flatten
36
30
  end
37
31
  end
38
32
 
39
- def render_stats_data(component_manifest, name, data, index)
40
- safe_join([
41
- index.zero? ? manifest_icon(component_manifest, role: "img", "aria-hidden": true) : " /&nbsp".html_safe,
42
- content_tag(:span, "#{number_with_delimiter(data)} " + I18n.t(name, scope: "decidim.conferences.statistics"),
43
- class: "#{name} process_stats-text")
44
- ])
45
- end
46
-
47
33
  def published_components
48
34
  @published_components ||= Component.where(participatory_space: conference).published
49
35
  end
@@ -3,7 +3,7 @@
3
3
  module Decidim
4
4
  module Conferences
5
5
  module Admin
6
- # A class used to find the admins for an conference.
6
+ # A class used to find the admins for an conference or an organization conferences.
7
7
  class AdminUsers < Rectify::Query
8
8
  # Syntactic sugar to initialize the class and return the queried objects.
9
9
  #
@@ -12,33 +12,46 @@ module Decidim
12
12
  new(conference).query
13
13
  end
14
14
 
15
+ # Syntactic sugar to initialize the class and return the queried objects.
16
+ #
17
+ # organization - an organization that needs to find its conference admins
18
+ def self.for_organization(organization)
19
+ new(nil, organization).query
20
+ end
21
+
15
22
  # Initializes the class.
16
23
  #
17
24
  # conference - an conference that needs to find its conference admins
18
- def initialize(conference)
25
+ # organization - an organization that needs to find its conference admins
26
+ def initialize(conference, organization = nil)
19
27
  @conference = conference
28
+ @organization = conference&.organization || organization
20
29
  end
21
30
 
22
31
  # Finds organization admins and the users with role admin for the given conference.
23
32
  #
24
33
  # Returns an ActiveRecord::Relation.
25
34
  def query
26
- Decidim::User.where(id: organization_admins).or(conference_user_admins)
35
+ organization.admins.or(conferences_user_admins)
27
36
  end
28
37
 
29
38
  private
30
39
 
31
- attr_reader :conference
40
+ attr_reader :conference, :organization
32
41
 
33
- def organization_admins
34
- conference.organization.admins
42
+ def conferences_user_admins
43
+ Decidim::User.where(
44
+ id: Decidim::ConferenceUserRole.where(conference: conferences, role: :admin)
45
+ .select(:decidim_user_id)
46
+ )
35
47
  end
36
48
 
37
- def conference_user_admins
38
- conference_user_admin_ids = Decidim::ConferenceUserRole
39
- .where(conference: conference, role: :admin)
40
- .pluck(:decidim_user_id)
41
- Decidim::User.where(id: conference_user_admin_ids)
49
+ def conferences
50
+ if conference
51
+ [conference]
52
+ else
53
+ Decidim::Conference.where(organization: organization)
54
+ end
42
55
  end
43
56
  end
44
57
  end
@@ -4,8 +4,10 @@ module Decidim
4
4
  module Conferences
5
5
  # This class deals with uploading the conference partner logo.
6
6
  class DiplomaUploader < ImageUploader
7
- version :thumb do
8
- process resize_to_fit: [275, 90]
7
+ set_variants do
8
+ {
9
+ thumb: { resize_to_fit: [275, 90] }
10
+ }
9
11
  end
10
12
  end
11
13
  end
@@ -4,11 +4,11 @@ module Decidim
4
4
  module Conferences
5
5
  # This class deals with uploading the conference partner logo.
6
6
  class PartnerLogoUploader < ImageUploader
7
- version :thumb do
8
- process resize_to_fit: [200, 55]
9
- end
10
- version :medium do
11
- process resize_to_fit: [600, 160]
7
+ set_variants do
8
+ {
9
+ thumb: { resize_to_fit: [200, 55] },
10
+ medium: { resize_to_fit: [600, 160] }
11
+ }
12
12
  end
13
13
  end
14
14
  end
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Decidim::Cw
4
+ module Conferences
5
+ # This class deals with uploading the conference partner logo.
6
+ class DiplomaUploader < Decidim::Cw::ImageUploader
7
+ set_variants do
8
+ {
9
+ thumb: { resize_to_fit: [275, 90] }
10
+ }
11
+ end
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,15 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Decidim::Cw
4
+ module Conferences
5
+ # This class deals with uploading the conference partner logo.
6
+ class PartnerLogoUploader < Decidim::Cw::ImageUploader
7
+ set_variants do
8
+ {
9
+ thumb: { resize_to_fit: [200, 55] },
10
+ medium: { resize_to_fit: [600, 160] }
11
+ }
12
+ end
13
+ end
14
+ end
15
+ end
@@ -1,4 +1,4 @@
1
- <%= javascript_include_tag "decidim/slug_form" %>
1
+ <%= javascript_pack_tag "decidim_conferences_admin" %>
2
2
 
3
3
  <div class="card" id="conferences">
4
4
  <div class="card-divider">
@@ -35,4 +35,4 @@
35
35
  </div>
36
36
  </div>
37
37
 
38
- <%= javascript_include_tag "decidim/conferences/admin/conference_invite_form" %>
38
+ <%= javascript_pack_tag "decidim_conferences_admin" %>
@@ -39,7 +39,7 @@
39
39
  <div class="card" id="conference-invites">
40
40
  <div class="card-divider">
41
41
  <h2 class="card-title">
42
- <%= title %> - <%= t(".invites") %>
42
+ <%= t(".invites") %>
43
43
  <%= link_to t(".invite_attendee"), conference.registrations_enabled ? new_conference_conference_invite_path(conference) : "#", class: "button tiny button--title #{'disabled' unless conference.registrations_enabled && allowed_to?(:invite_attendee, :conference, conference: conference) }" %>
44
44
  </h2>
45
45
  </div>
@@ -1,7 +1,7 @@
1
1
  <div class="card" id="conference-registrations">
2
2
  <div class="card-divider">
3
3
  <h2 class="card-title">
4
- <%= title %> - <%= t(".registrations") %>
4
+ <%= t(".registrations") %>
5
5
  <% if allowed_to? :export_conference_registrations, :conference, conference: conference %>
6
6
  <span class="exports dropdown tiny button button--simple button--title" data-toggle="export-dropdown"><%= t "actions.export", scope: "decidim.admin" %></span>
7
7
  <div class="dropdown-pane" id="export-dropdown" data-dropdown data-auto-focus="true" data-close-on-click="true">
@@ -58,4 +58,4 @@
58
58
  </div>
59
59
  </div>
60
60
 
61
- <%= javascript_include_tag "decidim/conferences/admin/conference_speakers" %>
61
+ <%= javascript_pack_tag "decidim_conferences_admin" %>
@@ -1,4 +1,4 @@
1
- <%= decidim_form_for(@form, url: conference_speaker_path(@conference_speaker.conference, @conference_speaker), html: { class: "form edit_conference_speaker" }) do |f| %>
1
+ <%= decidim_form_for(@form, url: conference_speaker_path(@item.conference, @item), html: { class: "form edit_conference_speaker" }) do |f| %>
2
2
  <%= render partial: "form", object: f, locals: { title: t("conference_speakers.edit.title", scope: "decidim.admin") } %>
3
3
 
4
4
  <div class="button--double form-general-submit">
@@ -1,5 +1,3 @@
1
- <%= javascript_include_tag "decidim/slug_form" %>
2
-
3
1
  <div class="card">
4
2
  <div class="card-divider">
5
3
  <h2 class="card-title"><%= t "conferences.form.title", scope: "decidim.admin" %></h2>
@@ -119,4 +117,4 @@
119
117
  </div>
120
118
  </div>
121
119
 
122
- <%= javascript_include_tag "decidim/conferences/admin/conferences" %>
120
+ <%= javascript_pack_tag "decidim_conferences_admin" %>
@@ -1,12 +1,12 @@
1
- <p><%= t("devise.mailer.invitation_instructions.hello", email: @user.name) %></p>
1
+ <p class="email-greeting"><%= t("devise.mailer.invitation_instructions.hello", email: @user.name) %></p>
2
2
 
3
- <p>
3
+ <p class="email-instructions">
4
4
  <%= t ".invited_you_to_join_a_conference", invited_by: @invited_by.name, application: @user.organization.name %>
5
5
  </p>
6
6
 
7
- <p>
7
+ <p class="email-button email-button__cta cta-decline">
8
8
  <%= link_to t(".decline", conference_title: translated_attribute(@conference.title)),routes.decline_invitation_conference_registration_type_conference_registration_path(conference_slug: @conference.slug, registration_type_id: @registration_type.id) %>
9
9
  </p>
10
- <p>
10
+ <p class="email-button email-button__cta cta-accept">
11
11
  <%= link_to t(".registration", conference_title: translated_attribute(@conference.title)),routes.conference_registration_type_conference_registration_url(conference_slug: @conference.slug, registration_type_id: @registration_type.id) %>
12
12
  </p>
@@ -36,7 +36,7 @@
36
36
  <% end %>
37
37
  </td>
38
38
  <td>
39
- <%= image_tag(partner.logo.thumb.url) %>
39
+ <%= image_tag(partner.attached_uploader(:logo).path(variant: :thumb)) %>
40
40
  </td>
41
41
  <td class="table-list__actions">
42
42
  <% if allowed_to? :update, :partner, partner: partner %>
@@ -3,7 +3,7 @@
3
3
  <div class="diploma__content">
4
4
  <div class="small-11 small-centered">
5
5
  <div class="diploma__logo small-4 small-centered">
6
- <%= wicked_pdf_image_tag @conference.main_logo.thumb.url %>
6
+ <%= wicked_pdf_image_tag @conference.attached_uploader(:main_logo).url(variant: :thumb, host: @conference.organization.host) %>
7
7
  </div>
8
8
  <div class="diploma__name small-10 small-centered">
9
9
  <h2><strong><%= translated_attribute(@conference.title) %></strong></h2>
@@ -14,7 +14,7 @@
14
14
  <div class="diploma__attendance">
15
15
  <strong><%= t("decidim.conferences.admin.send_conference_diploma_mailer.diploma_user.attendance_verified_by") %></strong>
16
16
  <div>
17
- <%= wicked_pdf_image_tag @conference.signature.thumb.url %>
17
+ <%= wicked_pdf_image_tag @conference.attached_uploader(:signature).url(variant: :thumb, host: @conference.organization.host) %>
18
18
  </div>
19
19
  <%= l(@conference.sign_date, format: :decidim_short) %>, <%= @conference.signature_name %>
20
20
  </div>
@@ -47,17 +47,17 @@
47
47
  </div>
48
48
  </div>
49
49
  <% end %>
50
- <% if meeting.minutes.present? && meeting.minutes.visible? && (meeting.minutes.video_url.presence || meeting.minutes.audio_url.presence) %>
50
+ <% if meeting.closing_visible? && (meeting.video_url.presence || meeting.audio_url.presence) %>
51
51
  <div class="row">
52
52
  <div class="column medium-2">
53
53
  <strong><%= t(".streaming") %></strong>
54
54
  </div>
55
55
  <div class="column medium-10">
56
- <% if meeting.minutes.video_url.presence %>
57
- <u><%= link_to meeting.minutes.video_url, meeting.minutes.video_url, target: "_blank" %></u>
56
+ <% if meeting.video_url.presence %>
57
+ <u><%= link_to meeting.video_url, meeting.video_url, target: "_blank" %></u>
58
58
  <% end %>
59
- <% if meeting.minutes.audio_url.presence %>
60
- <u><%= link_to meeting.minutes.audio_url, meeting.minutes.audio_url, target: "_blank" %></u>
59
+ <% if meeting.audio_url.presence %>
60
+ <u><%= link_to meeting.audio_url, meeting.audio_url, target: "_blank" %></u>
61
61
  <% end %>
62
62
  </div>
63
63
  </div>
@@ -1,6 +1,6 @@
1
- <p><%= t(".confirmed_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
1
+ <p class="email-greeting"><%= t(".confirmed_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
2
2
 
3
- <p><%= t(".details_1", registration_type: translated_attribute(@registration_type.title), price: number_to_currency((@registration_type.price || 0), locale: I18n.locale, unit: Decidim.currency_unit)) %></p>
3
+ <p class="email-instructions"><%= t(".details_1", registration_type: translated_attribute(@registration_type.title), price: number_to_currency((@registration_type.price || 0), locale: I18n.locale, unit: Decidim.currency_unit)) %></p>
4
4
 
5
5
  <ul>
6
6
  <% @registration_type.conference_meetings.order(:start_time).each do |conference_meeting| %>
@@ -8,4 +8,4 @@
8
8
  <% end %>
9
9
  </ul>
10
10
 
11
- <p><%= t(".details_2") %></p>
11
+ <p class="email-instructions"><%= t(".details_2") %></p>
@@ -1,6 +1,6 @@
1
- <p><%= t(".pending_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
1
+ <p class="email-greeting"><%= t(".pending_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
2
2
 
3
- <p><%= t(".details", registration_type: translated_attribute(@registration_type.title), price: number_to_currency((@registration_type.price || 0), locale: I18n.locale, unit: Decidim.currency_unit)) %></p>
3
+ <p class="email-instructions"><%= t(".details", registration_type: translated_attribute(@registration_type.title), price: number_to_currency((@registration_type.price || 0), locale: I18n.locale, unit: Decidim.currency_unit)) %></p>
4
4
 
5
5
  <ul>
6
6
  <% @registration_type.conference_meetings.order(:start_time).each do |conference_meeting| %>
@@ -8,4 +8,4 @@
8
8
  <% end %>
9
9
  </ul>
10
10
 
11
- <p><%= t(".confirmation_pending") %></p>
11
+ <p class="email-small email-closing"><%= t(".confirmation_pending") %></p>
@@ -13,7 +13,7 @@
13
13
  </div>
14
14
  <div class="columns mediumlarge-8 large-6 card--process__column">
15
15
  <div class="card--full__image"
16
- style="background-image:url(<%= promoted_conference.hero_image.url %>)">
16
+ style="background-image:url(<%= promoted_conference.attached_uploader(:hero_image).path %>)">
17
17
  <div class="card__content row collapse">
18
18
  <div class="large-6 large-offset-6 columns">
19
19
  <%= link_to conference_path(promoted_conference), class: "button expanded button--sc" do %>
@@ -1,5 +1,5 @@
1
1
  <% add_decidim_meta_tags({
2
- image_url: current_participatory_space.hero_image.url,
2
+ image_url: current_participatory_space.attached_uploader(:hero_image).path,
3
3
  description: translated_attribute(current_participatory_space.short_description),
4
4
  url: conference_url(current_participatory_space),
5
5
  twitter_handler: current_organization.twitter_handler
@@ -78,8 +78,7 @@ edit_link(
78
78
  <%= cell("decidim/conferences/linked_participatory_spaces", current_participatory_space) %>
79
79
 
80
80
  <% if current_participatory_space.show_statistics? %>
81
- <%= render partial: "statistics" %>
81
+ <%= cell("decidim/statistics", stats.highlighted) %>
82
82
  <% end %>
83
83
  </div>
84
84
  </div>
85
- <%= javascript_include_tag "decidim/conferences/conferences" %>
@@ -1,13 +1,13 @@
1
- <p><%= t("devise.mailer.invitation_instructions.hello", email: @resource.name) %></p>
1
+ <p class="email-greeting"><%= t("devise.mailer.invitation_instructions.hello", email: @resource.name) %></p>
2
2
 
3
- <p>
3
+ <p class="email-instructions">
4
4
  <%= t("decidim.conferences.admin.invite_join_conference_mailer.invite.invited_you_to_join_a_conference", invited_by: @resource.invited_by.name, application: @resource.organization.name) %>
5
5
  </p>
6
6
 
7
- <p><%= link_to t("devise.mailer.invitation_instructions.accept"), accept_invitation_url(@resource, invitation_token: @token, invite_redirect: Decidim::EngineRouter.main_proxy(@opts[:conference]).conference_conference_registration_path(conference_slug: @opts[:conference]), host: @resource.organization.host) %></p>
7
+ <p class="email-button email-button__cta"><%= link_to t("devise.mailer.invitation_instructions.accept"), accept_invitation_url(@resource, invitation_token: @token, invite_redirect: Decidim::EngineRouter.main_proxy(@opts[:conference]).conference_conference_registration_path(conference_slug: @opts[:conference]), host: @resource.organization.host) %></p>
8
8
 
9
9
  <% if @resource.invitation_due_at %>
10
- <p><%= t("devise.mailer.invitation_instructions.accept_until", due_date: l(@resource.invitation_due_at, format: :long)) %></p>
10
+ <p class="email-small"><%= t("devise.mailer.invitation_instructions.accept_until", due_date: l(@resource.invitation_due_at, format: :long)) %></p>
11
11
  <% end %>
12
12
 
13
- <p><%= t("devise.mailer.invitation_instructions.ignore").html_safe %></p>
13
+ <p class="email-small email-closing"><%= t("devise.mailer.invitation_instructions.ignore").html_safe %></p>
@@ -1,5 +1,5 @@
1
1
  <section class="extended hero"
2
- style="background-image:url(<%= current_participatory_space.banner_image.url %>);">
2
+ style="background-image:url(<%= current_participatory_space.attached_uploader(:banner_image).path %>);">
3
3
  <div class="hero__container">
4
4
  <div class="row">
5
5
  <div class="columns large-10 text-left">
@@ -1,109 +1,7 @@
1
- <% content_for :secondary_nav do %>
2
- <div class="secondary-nav secondary-nav--subnav">
3
- <ul>
4
- <%= public_page_link decidim_conferences.conference_path(current_participatory_space) %>
5
- <% if allowed_to? :update, :conference, conference: current_participatory_space %>
6
- <li <% if is_active_link?(decidim_admin_conferences.edit_conference_path(current_participatory_space)) %> class="is-active" <% end %>>
7
- <%= aria_selected_link_to t("info", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.edit_conference_path(current_participatory_space) %>
8
- </li>
9
- <% end %>
10
- <% if allowed_to? :read, :component, conference: current_participatory_space %>
11
- <li <% if is_active_link?(decidim_admin_conferences.components_path(current_participatory_space)) %> class="is-active" <% end %>>
12
- <%= aria_selected_link_to t("components", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.components_path(current_participatory_space) %>
13
- <ul id="components-list">
14
- <% current_participatory_space.components.each do |component| %>
15
- <% if component.manifest.admin_engine && user_role_config.component_is_accessible?(component.manifest_name) %>
16
- <li <% if is_active_link?(manage_component_path(component)) || is_active_link?(decidim_admin_conferences.edit_component_path(current_participatory_space, component)) || is_active_link?(decidim_admin_conferences.edit_component_permissions_path(current_participatory_space, component)) || participatory_space_active_link?(component) %> class="is-active" <% end %>>
17
- <%= link_to manage_component_path(component) do %>
18
- <%= translated_attribute component.name %>
19
- <% if component.primary_stat.present? %>
20
- <span class="component-counter <%= "component-counter--off" if component.primary_stat.zero? %>"><%= component.primary_stat %></span>
21
- <% end %>
22
- <% end %>
23
- </li>
24
- <% end %>
25
- <% end %>
26
- </ul>
27
- </li>
28
- <% end %>
29
- <% if allowed_to? :read, :category, conference: current_participatory_space %>
30
- <li <% if is_active_link?(decidim_admin_conferences.categories_path(current_participatory_space)) %> class="is-active" <% end %>>
31
- <%= aria_selected_link_to t("categories", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.categories_path(current_participatory_space) %>
32
- </li>
33
- <% end %>
34
- <% if allowed_to?(:read, :attachment_collection, conference: current_participatory_space) || allowed_to?(:read, :attachment, conference: current_participatory_space) %>
35
- <li>
36
- <span class="secondary-nav__subtitle"><%= t("attachments", scope: "decidim.admin.menu.conferences_submenu") %></span>
37
- <ul>
38
- <% if allowed_to? :read, :attachment_collection, conference: current_participatory_space %>
39
- <li <% if is_active_link?(decidim_admin_conferences.conference_attachment_collections_path(current_participatory_space)) %> class="is-active" <% end %>>
40
- <%= aria_selected_link_to t("attachment_collections", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_attachment_collections_path(current_participatory_space) %>
41
- </li>
42
- <% end %>
43
- <% if allowed_to? :read, :attachment, conference: current_participatory_space %>
44
- <li <% if is_active_link?(decidim_admin_conferences.conference_attachments_path(current_participatory_space)) %> class="is-active" <% end %>>
45
- <%= aria_selected_link_to t("attachment_files", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_attachments_path(current_participatory_space) %>
46
- </li>
47
- <% end %>
48
- </ul>
49
- </li>
50
- <% end %>
51
- <% if allowed_to? :read, :media_link, conference: current_participatory_space %>
52
- <li <% if is_active_link?(decidim_admin_conferences.conference_media_links_path(current_participatory_space)) %> class="is-active" <% end %>>
53
- <%= aria_selected_link_to t("media_links", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_media_links_path(current_participatory_space) %>
54
- </li>
55
- <% end %>
56
- <% if allowed_to? :read, :partner, conference: current_participatory_space %>
57
- <li <% if is_active_link?(decidim_admin_conferences.conference_partners_path(current_participatory_space)) %> class="is-active" <% end %>>
58
- <%= aria_selected_link_to t("partners", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_partners_path(current_participatory_space) %>
59
- </li>
60
- <% end %>
61
- <% if allowed_to? :read, :conference_speaker, conference: current_participatory_space %>
62
- <li <% if is_active_link?(decidim_admin_conferences.conference_speakers_path(current_participatory_space)) %> class="is-active" <% end %>>
63
- <%= aria_selected_link_to t("conference_speakers", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_speakers_path(current_participatory_space) %>
64
- </li>
65
- <% end %>
66
-
67
- <% if allowed_to?(:read, :conference_invite, conference: current_participatory_space) || allowed_to?(:read, :registration_type, conference: current_participatory_space) || allowed_to?(:read, :conference_registration, conference: current_participatory_space) %>
68
- <li>
69
- <span class="secondary-nav__subtitle"><%= t("registrations", scope: "decidim.admin.menu.conferences_submenu") %></span>
70
- <ul>
71
- <% if allowed_to? :read, :registration_type, conference: current_participatory_space %>
72
- <li <% if is_active_link?(decidim_admin_conferences.conference_registration_types_path(current_participatory_space)) %> class="is-active" <% end %>>
73
- <%= aria_selected_link_to t("registration_types", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_registration_types_path(current_participatory_space) %>
74
- </li>
75
- <% end %>
76
- <% if allowed_to? :read, :conference_registration, conference: current_participatory_space %>
77
- <li <% if is_active_link?(decidim_admin_conferences.conference_conference_registrations_path(current_participatory_space)) %> class="is-active" <% end %>>
78
- <%= aria_selected_link_to t("user_registrations", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_conference_registrations_path(current_participatory_space) %>
79
- </li>
80
- <% end %>
81
- <% if allowed_to? :read, :conference_invite, conference: current_participatory_space %>
82
- <li <% if is_active_link?(decidim_admin_conferences.conference_conference_invites_path(current_participatory_space)) %> class="is-active" <% end %>>
83
- <%= aria_selected_link_to t("conference_invites", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_conference_invites_path(current_participatory_space) %>
84
- </li>
85
- <% end %>
86
- <% if allowed_to? :update, :conference, conference: current_participatory_space %>
87
- <li <% if is_active_link?(decidim_admin_conferences.edit_conference_diploma_path(current_participatory_space)) %> class="is-active" <% end %>>
88
- <%= aria_selected_link_to t("diploma", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.edit_conference_diploma_path(current_participatory_space) %>
89
- </li>
90
- <% end %>
91
- </ul>
92
- </li>
93
- <% end %>
94
- <% if allowed_to? :read, :conference_user_role, conference: current_participatory_space %>
95
- <li <% if is_active_link?(decidim_admin_conferences.conference_user_roles_path(current_participatory_space)) %> class="is-active" <% end %>>
96
- <%= aria_selected_link_to t("conference_admins", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.conference_user_roles_path(current_participatory_space) %>
97
- </li>
98
- <% end %>
99
- <% if allowed_to? :read, :moderation, conference: current_participatory_space %>
100
- <li <% if is_active_link?(decidim_admin_conferences.moderations_path(current_participatory_space)) %> class="is-active" <% end %>>
101
- <%= aria_selected_link_to t("moderations", scope: "decidim.admin.menu.conferences_submenu"), decidim_admin_conferences.moderations_path(current_participatory_space) %>
102
- </li>
103
- <% end %>
104
- <%= Decidim::Admin.view_hooks.render(:admin_secondary_nav, deep_dup) %>
105
- </ul>
106
- </div>
1
+ <% content_for :sidebar_menu_nav do %>
2
+ <%= sidebar_menu(:conferences_admin_menu).render do
3
+ public_page_link decidim_conferences.conference_path(current_participatory_space)
4
+ end %>
107
5
  <% end %>
108
6
 
109
7
  <%= render "layouts/decidim/admin/application" do %>