decidim-conferences 0.15.2 → 0.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (115) hide show
  1. checksums.yaml +4 -4
  2. data/app/assets/config/admin/decidim_conferences_manifest.js +1 -0
  3. data/app/assets/images/decidim/conferences/conference.svg +2 -5
  4. data/app/cells/decidim/conferences/linked_participatory_spaces_cell.rb +3 -0
  5. data/app/cells/decidim/conferences/{join_conference_button/show.erb → registration_type/join_conference.erb} +6 -7
  6. data/app/cells/decidim/conferences/{join_conference_button → registration_type}/registration_confirm.erb +2 -2
  7. data/app/cells/decidim/conferences/registration_type/show.erb +16 -0
  8. data/app/cells/decidim/conferences/registration_type_cell.rb +51 -0
  9. data/app/commands/decidim/conferences/admin/confirm_conference_registration.rb +75 -0
  10. data/app/commands/decidim/conferences/admin/create_conference.rb +1 -1
  11. data/app/commands/decidim/conferences/admin/create_registration_type.rb +77 -0
  12. data/app/commands/decidim/conferences/admin/destroy_registration_type.rb +56 -0
  13. data/app/commands/decidim/conferences/admin/invite_user_to_join_conference.rb +3 -2
  14. data/app/commands/decidim/conferences/admin/publish_registration_type.rb +36 -0
  15. data/app/commands/decidim/conferences/admin/send_conference_diplomas.rb +48 -0
  16. data/app/commands/decidim/conferences/admin/unpublish_registration_type.rb +36 -0
  17. data/app/commands/decidim/conferences/admin/update_conference.rb +2 -2
  18. data/app/commands/decidim/conferences/admin/update_diploma.rb +47 -0
  19. data/app/commands/decidim/conferences/admin/update_partner.rb +1 -1
  20. data/app/commands/decidim/conferences/admin/update_registration_type.rb +74 -0
  21. data/app/commands/decidim/conferences/join_conference.rb +21 -9
  22. data/app/commands/decidim/conferences/leave_conference.rb +5 -3
  23. data/app/controllers/decidim/conferences/admin/conference_registrations_controller.rb +21 -0
  24. data/app/controllers/decidim/conferences/admin/conferences_controller.rb +0 -9
  25. data/app/controllers/decidim/conferences/admin/diplomas_controller.rb +62 -0
  26. data/app/controllers/decidim/conferences/admin/registration_type_publications_controller.rb +53 -0
  27. data/app/controllers/decidim/conferences/admin/registration_types_controller.rb +84 -0
  28. data/app/controllers/decidim/conferences/application_controller.rb +2 -0
  29. data/app/controllers/decidim/conferences/conference_registrations_controller.rb +6 -2
  30. data/app/controllers/decidim/conferences/conferences_controller.rb +4 -0
  31. data/app/controllers/decidim/conferences/registration_types_controller.rb +39 -0
  32. data/app/events/decidim/conferences/conference_registration_notification_event.rb +21 -0
  33. data/app/forms/decidim/conferences/admin/conference_form.rb +5 -2
  34. data/app/forms/decidim/conferences/admin/conference_registration_invite_form.rb +15 -0
  35. data/app/forms/decidim/conferences/admin/diploma_form.rb +24 -0
  36. data/app/forms/decidim/conferences/admin/registration_type_form.rb +44 -0
  37. data/app/helpers/decidim/conferences/conference_helper.rb +15 -0
  38. data/app/jobs/decidim/conferences/admin/send_conference_diploma_job.rb +20 -0
  39. data/app/jobs/decidim/conferences/upcoming_conference_notification_job.rb +1 -1
  40. data/app/mailers/decidim/conferences/admin/invite_join_conference_mailer.rb +2 -1
  41. data/app/mailers/decidim/conferences/admin/send_conference_diploma_mailer.rb +48 -0
  42. data/app/mailers/decidim/conferences/conference_registration_mailer.rb +16 -1
  43. data/app/models/decidim/conference.rb +12 -0
  44. data/app/models/decidim/conference_meeting.rb +2 -0
  45. data/app/models/decidim/conferences/conference_invite.rb +1 -0
  46. data/app/models/decidim/conferences/conference_meeting_registration_type.rb +10 -0
  47. data/app/models/decidim/conferences/conference_registration.rb +11 -0
  48. data/app/models/decidim/conferences/registration_type.rb +25 -0
  49. data/app/permissions/decidim/conferences/permissions.rb +19 -12
  50. data/app/presenters/decidim/conference_speaker_presenter.rb +4 -0
  51. data/app/presenters/decidim/conferences/admin_log/conference_registration_presenter.rb +43 -0
  52. data/app/presenters/decidim/conferences/admin_log/conferences_presenter.rb +4 -2
  53. data/app/presenters/decidim/conferences/admin_log/partner_presenter.rb +1 -1
  54. data/app/presenters/decidim/conferences/admin_log/registration_type_presenter.rb +45 -0
  55. data/app/serializers/decidim/conferences/conference_registration_serializer.rb +4 -0
  56. data/app/serializers/decidim/conferences/data_portability_conference_invite_serializer.rb +4 -0
  57. data/app/serializers/decidim/conferences/data_portability_conference_registration_serializer.rb +4 -0
  58. data/app/uploaders/decidim/conferences/diploma_uploader.rb +12 -0
  59. data/app/views/decidim/conferences/admin/conference_invites/_form.html.erb +8 -0
  60. data/app/views/decidim/conferences/admin/conference_invites/index.html.erb +4 -0
  61. data/app/views/decidim/conferences/admin/conference_registrations/index.html.erb +16 -0
  62. data/app/views/decidim/conferences/admin/conferences/edit.html.erb +0 -4
  63. data/app/views/decidim/conferences/admin/diplomas/_form.html.erb +31 -0
  64. data/app/views/decidim/conferences/admin/diplomas/edit.html.erb +7 -0
  65. data/app/views/decidim/conferences/admin/invite_join_conference_mailer/invite.html.erb +2 -2
  66. data/app/views/decidim/conferences/admin/registration_types/_form.html.erb +30 -0
  67. data/app/views/decidim/conferences/admin/registration_types/edit.html.erb +7 -0
  68. data/app/views/decidim/conferences/admin/registration_types/index.html.erb +65 -0
  69. data/app/views/decidim/conferences/admin/registration_types/new.html.erb +7 -0
  70. data/app/views/decidim/conferences/admin/send_conference_diploma_mailer/diploma.html.erb +1 -0
  71. data/app/views/decidim/conferences/admin/send_conference_diploma_mailer/diploma_user.html.erb +24 -0
  72. data/app/views/decidim/conferences/conference_program/_program_meeting.html.erb +1 -2
  73. data/app/views/decidim/conferences/conference_registration_mailer/confirmation.html.erb +9 -1
  74. data/app/views/decidim/conferences/conference_registration_mailer/pending_validation.html.erb +11 -0
  75. data/app/views/decidim/conferences/conferences/index.html.erb +2 -2
  76. data/app/views/decidim/conferences/conferences/show.html.erb +10 -24
  77. data/app/views/decidim/conferences/registration_types/index.html.erb +30 -0
  78. data/app/views/decidim/conferences/shared/_conference_user_login.html.erb +14 -0
  79. data/app/views/layouts/decidim/_conference_hero.html.erb +5 -3
  80. data/app/views/layouts/decidim/_conferences_nav.html.erb +45 -89
  81. data/app/views/layouts/decidim/admin/conference.html.erb +26 -8
  82. data/app/views/layouts/decidim/diploma.html.erb +11 -0
  83. data/config/initializers/wicked_pdf.rb +23 -0
  84. data/config/locales/ca.yml +125 -19
  85. data/config/locales/de.yml +127 -21
  86. data/config/locales/en.yml +127 -21
  87. data/config/locales/es-PY.yml +125 -19
  88. data/config/locales/es.yml +125 -19
  89. data/config/locales/eu.yml +127 -21
  90. data/config/locales/fi-pl.yml +128 -22
  91. data/config/locales/fi.yml +128 -22
  92. data/config/locales/fr.yml +127 -21
  93. data/config/locales/gl.yml +126 -20
  94. data/config/locales/hu.yml +127 -21
  95. data/config/locales/id-ID.yml +125 -20
  96. data/config/locales/it.yml +127 -21
  97. data/config/locales/nl.yml +126 -20
  98. data/config/locales/pl.yml +127 -24
  99. data/config/locales/pt-BR.yml +125 -19
  100. data/config/locales/pt.yml +126 -20
  101. data/config/locales/sv.yml +126 -20
  102. data/config/locales/tr-TR.yml +125 -22
  103. data/db/migrate/20181023142325_add_conference_registration_types.rb +21 -0
  104. data/db/migrate/20181030090202_add_reference_registration_type_to_conference_registration.rb +9 -0
  105. data/db/migrate/20181030153614_add_registration_type_to_conference_invite.rb +8 -0
  106. data/db/migrate/20181106092826_add_diploma_fields_to_conference.rb +11 -0
  107. data/db/migrate/20181123124424_make_price_optional_conference_registration_type.rb +7 -0
  108. data/lib/decidim/conferences/admin_engine.rb +16 -2
  109. data/lib/decidim/conferences/engine.rb +8 -4
  110. data/lib/decidim/conferences/participatory_space.rb +11 -0
  111. data/lib/decidim/conferences/test/factories.rb +36 -0
  112. data/lib/decidim/conferences/version.rb +1 -1
  113. metadata +92 -23
  114. data/app/cells/decidim/conferences/join_conference_button_cell.rb +0 -42
  115. data/app/views/decidim/conferences/conferences/_conferences_sidebar.html.erb +0 -11
@@ -11,6 +11,10 @@ module Decidim
11
11
  name: resource.user.name,
12
12
  email: resource.user.email
13
13
  },
14
+ registration_type: {
15
+ title: resource.registration_type.title,
16
+ price: resource.registration_type.price
17
+ },
14
18
  conference: {
15
19
  title: resource.conference.title,
16
20
  reference: resource.conference.reference,
@@ -0,0 +1,12 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Decidim
4
+ module Conferences
5
+ # This class deals with uploading the conference partner logo.
6
+ class DiplomaUploader < ImageUploader
7
+ version :thumb do
8
+ process resize_to_fit: [275, 90]
9
+ end
10
+ end
11
+ end
12
+ end
@@ -25,6 +25,14 @@
25
25
  end %>
26
26
  </div>
27
27
  </div>
28
+ <div class="grid-x grid-margin-x">
29
+ <div class="auto cell">
30
+ <%= form.select :registration_type_id,
31
+ options_for_select(@form.registration_types_for_select),
32
+ { include_blank: false },
33
+ { multiple: false, class: "chosen-select" } %>
34
+ </div>
35
+ </div>
28
36
  </div>
29
37
 
30
38
  <%= javascript_include_tag "decidim/conferences/admin/conference_invite_form" %>
@@ -53,6 +53,7 @@
53
53
  <th><%= t("models.conference_invite.fields.email", scope: "decidim.conferences") %></th>
54
54
  <th><%= t("models.conference_invite.fields.sent_at", scope: "decidim.conferences") %></th>
55
55
  <th><%= t("models.conference_invite.fields.status", scope: "decidim.conferences") %></th>
56
+ <th><%= t("models.conference_invite.fields.registration_type", scope: "decidim.conferences") %></th>
56
57
  </tr>
57
58
  </thead>
58
59
  <tbody>
@@ -73,6 +74,9 @@
73
74
  <td class="<%= presenter.status_html_class %>">
74
75
  <%= presenter.status %>
75
76
  </td>
77
+ <td>
78
+ <%= translated_attribute(invite.registration_type.title) %>
79
+ </td>
76
80
  </tr>
77
81
  <% end %>
78
82
  </tbody>
@@ -22,6 +22,9 @@
22
22
  <tr>
23
23
  <th><%= t("models.conference_registration.fields.name", scope: "decidim.conferences") %></th>
24
24
  <th><%= t("models.conference_registration.fields.email", scope: "decidim.conferences") %></th>
25
+ <th><%= t("models.conference_registration.fields.registration_type", scope: "decidim.conferences") %></th>
26
+ <th><%= t("models.conference_registration.fields.state", scope: "decidim.conferences") %></th>
27
+ <th></th>
25
28
  </tr>
26
29
  </thead>
27
30
  <tbody>
@@ -33,6 +36,19 @@
33
36
  <td>
34
37
  <%= registration.user.email %>
35
38
  </td>
39
+ <td>
40
+ <%= translated_attribute(registration.registration_type.title) %>
41
+ </td>
42
+ <td>
43
+ <%= t("models.conference_registration.fields.states.#{registration.confirmed? ? "confirmed" : "pending"}", scope: "decidim.conferences") %>
44
+ </td>
45
+ <td>
46
+ <% if allowed_to?(:confirm, :conference_registration, conference_registration: registration) %>
47
+ <% if !registration.confirmed? %>
48
+ <%= icon_link_to "check", confirm_conference_conference_registration_path(current_conference, registration), t("actions.confirm", scope: "decidim.admin"), class: "action-icon--publish", method: :post %>
49
+ <% end %>
50
+ <% end %>
51
+ </td>
36
52
  </tr>
37
53
  <% end %>
38
54
  </tbody>
@@ -10,9 +10,5 @@
10
10
  <%= link_to t("actions.publish", scope: "decidim.admin"), conference_publish_path(current_conference), method: :post, class: "button hollow" %>
11
11
  <% end %>
12
12
  <% end %>
13
-
14
- <% if allowed_to? :destroy, :conference, conference: current_conference %>
15
- <%= link_to t("decidim.admin.actions.destroy"), current_conference, method: :delete, class: "alert button", data: { confirm: t("decidim.admin.actions.confirm_destroy") } %>
16
- <% end %>
17
13
  </div>
18
14
  <% end %>
@@ -0,0 +1,31 @@
1
+ <div class="card">
2
+ <div class="card-divider">
3
+ <h2 class="card-title">
4
+ <%= title %>
5
+ <% if allowed_to?(:send_diplomas, :conference, conference: current_participatory_space ) && current_participatory_space.sign_date.present? && current_participatory_space.conference_registrations.confirmed.any? %>
6
+ <%= link_to t("actions.send_diplomas", scope: "decidim.admin"), send_conference_diploma_path(current_conference), method: :post, id: "send-diplomas", class: "button tiny button--title new #{"disabled" if current_participatory_space.diploma_sent? }" %>
7
+ <% end %>
8
+ </h2>
9
+ </div>
10
+
11
+ <div class="card-section">
12
+ <div class="row">
13
+ <div class="columns xlarge-6">
14
+ <%= form.upload :main_logo, optional: false %>
15
+ </div>
16
+ </div>
17
+
18
+ <div class="row">
19
+ <div class="columns xlarge-6">
20
+ <%= form.upload :signature, optional: false %>
21
+ </div>
22
+ </div>
23
+ <div class="row column">
24
+ <%= form.date_field :sign_date %>
25
+ </div>
26
+
27
+ <div class="row column">
28
+ <%= form.text_field :signature_name %>
29
+ </div>
30
+ </div>
31
+ </div>
@@ -0,0 +1,7 @@
1
+ <%= decidim_form_for(@form, url: conference_diploma_path, html: { class: "form edit_conference_diploma" }) do |f| %>
2
+ <%= render partial: "form", object: f, locals: { title: t("diplomas.edit.title", scope: "decidim.conferences.admin") } %>
3
+
4
+ <div class="button--double form-general-submit">
5
+ <%= f.submit t(".save") %>
6
+ </div>
7
+ <% end %>
@@ -5,8 +5,8 @@
5
5
  </p>
6
6
 
7
7
  <p>
8
- <%= link_to t(".decline", conference_title: translated_attribute(@conference.title)),routes.decline_invitation_conference_conference_registration_path(conference_slug: @conference.slug) %>
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
10
  <p>
11
- <%= link_to t(".join", conference_title: translated_attribute(@conference.title)),routes.conference_conference_registration_url(conference_slug: @conference.slug) %>
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>
@@ -0,0 +1,30 @@
1
+ <div class="card">
2
+ <div class="card-divider">
3
+ <h2 class="card-title">
4
+ <%= title %>
5
+ </h2>
6
+ </div>
7
+
8
+ <div class="card-section">
9
+ <div class="row column">
10
+ <%= form.translated :text_field, :title, autofocus: true %>
11
+ </div>
12
+
13
+ <div class="row column">
14
+ <%= form.number_field :weight %>
15
+ </div>
16
+
17
+ <div class="row column">
18
+ <%= form.translated :editor, :description %>
19
+ </div>
20
+
21
+ <div class="row column">
22
+ <%= form.number_field :price %>
23
+ </div>
24
+
25
+ <div class="row column">
26
+ <%= form.label t(".select_conference_meetings") %>
27
+ <%= form.collection_check_boxes :conference_meeting_ids, @form.meetings, :value, :title, legend_title: "" %>
28
+ </div>
29
+ </div>
30
+ </div>
@@ -0,0 +1,7 @@
1
+ <%= decidim_form_for(@form, url: conference_registration_type_path(@registration_type.conference, @registration_type), html: { class: "form edit_registration_type" }) do |f| %>
2
+ <%= render partial: "form", object: f, locals: { title: t("registration_types.edit.title", scope: "decidim.admin") } %>
3
+
4
+ <div class="button--double form-general-submit">
5
+ <%= f.submit t("registration_types.edit.update", scope: "decidim.admin") %>
6
+ </div>
7
+ <% end %>
@@ -0,0 +1,65 @@
1
+ <div class='card' id="registration_types">
2
+ <div class="card-divider">
3
+ <h2 class="card-title">
4
+ <%= t(".title") %>
5
+ <% if allowed_to? :create, :registration_type %>
6
+ <%= link_to t("actions.new", scope: "decidim.admin", name: t("models.registration_type.name", scope: "decidim.admin")), new_conference_registration_type_path(current_conference), class: "button tiny button--title new" %>
7
+ <% end %>
8
+ </h2>
9
+ </div>
10
+
11
+ <div class="card-section">
12
+ <div class="table-scroll">
13
+ <table class="stack">
14
+ <thead>
15
+ <tr>
16
+ <th><%= t("models.registration_type.fields.title", scope: "decidim.admin") %></th>
17
+ <th><%= t("models.registration_type.fields.price", scope: "decidim.admin") %></th>
18
+ <th><%= t("models.registration_type.fields.weight", scope: "decidim.admin") %></th>
19
+ <th><%= t("models.registration_type.fields.conference_meetings", scope: "decidim.admin") %></th>
20
+ <th><%= t("models.registration_type.fields.registrations_count", scope: "decidim.admin") %></th>
21
+ <th class="actions"></th>
22
+ </tr>
23
+ </thead>
24
+ <tbody>
25
+ <% @registration_types.each do |registration_type| %>
26
+ <tr>
27
+ <td>
28
+ <%= translated_attribute(registration_type.title) %>
29
+ </td>
30
+ <td>
31
+ <%= registration_type.price %>
32
+ </td>
33
+ <td>
34
+ <%= registration_type.weight %>
35
+ </td>
36
+ <td>
37
+ <%= registration_type.conference_meeting_registration_types.count %>
38
+ </td>
39
+ <td>
40
+ <%= registration_type.conference_registrations.count %>
41
+ </td>
42
+ <td class="table-list__actions">
43
+ <% if allowed_to?(:update, :registration_type, registration_type: registration_type) && !registration_type.conference_registrations.any? %>
44
+ <%= icon_link_to "pencil", edit_conference_registration_type_path(current_conference, registration_type), t("actions.edit", scope: "decidim.admin"), class: "action-icon--edit" %>
45
+ <% end %>
46
+
47
+ <% if allowed_to?(:update, :registration_type, registration_type: registration_type) %>
48
+ <% if registration_type.published? %>
49
+ <%= icon_link_to "x", conference_registration_type_publish_path(current_conference, registration_type), t("actions.unpublish", scope: "decidim.admin"), class: "action-icon--unpublish", method: :delete %>
50
+ <% else %>
51
+ <%= icon_link_to "check", conference_registration_type_publish_path(current_conference, registration_type), t("actions.publish", scope: "decidim.admin"), class: "action-icon--publish", method: :post %>
52
+ <% end %>
53
+ <% end %>
54
+
55
+ <% if allowed_to?(:destroy, :registration_type, registration_type: registration_type) && !registration_type.conference_registrations.any? %>
56
+ <%= icon_link_to "circle-x", conference_registration_type_path(current_conference, registration_type), t("actions.destroy", scope: "decidim.admin"), class: "action-icon--remove", method: :delete, data: { confirm: t("actions.confirm_destroy", scope: "decidim.admin") } %>
57
+ <% end %>
58
+ </td>
59
+ </tr>
60
+ <% end %>
61
+ </tbody>
62
+ </table>
63
+ </div>
64
+ </div>
65
+ </div>
@@ -0,0 +1,7 @@
1
+ <%= decidim_form_for(@form, html: { class: "form new_registration_type" }) do |f| %>
2
+ <%= render partial: "form", object: f, locals: { title: t("registration_types.new.title", scope: "decidim.admin") } %>
3
+
4
+ <div class="button--double form-general-submit">
5
+ <%= f.submit t("registration_types.new.create", scope: "decidim.admin") %>
6
+ </div>
7
+ <% end %>
@@ -0,0 +1 @@
1
+ <p><%= t(".diploma_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
@@ -0,0 +1,24 @@
1
+ <main class="conference-diploma">
2
+ <div class="diploma__border">
3
+ <div class="diploma__content">
4
+ <div class="small-11 small-centered">
5
+ <div class="diploma__logo small-4 small-centered">
6
+ <%= wicked_pdf_image_tag @conference.main_logo.thumb.url %>
7
+ </div>
8
+ <div class="diploma__name small-10 small-centered">
9
+ <h2><strong><%= translated_attribute(@conference.title) %></strong></h2>
10
+ <h3><%= t("decidim.conferences.admin.send_conference_diploma_mailer.diploma_user.certificate_of_attendance") %></h3>
11
+ <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>
12
+ </div>
13
+ <hr class="reset mt-m mb-m" />
14
+ <div class="diploma__attendance">
15
+ <strong><%= t("decidim.conferences.admin.send_conference_diploma_mailer.diploma_user.attendance_verified_by") %></strong>
16
+ <div>
17
+ <%= wicked_pdf_image_tag @conference.signature.thumb.url %>
18
+ </div>
19
+ <%= l(@conference.sign_date, format: :decidim_short) %>, <%= @conference.signature_name %>
20
+ </div>
21
+ </div>
22
+ </div>
23
+ </div>
24
+ </main>
@@ -9,7 +9,6 @@
9
9
  <div class="row">
10
10
  <div class="column medium-10 medium-push-2">
11
11
  <% attribute = present(meeting).description %>
12
- <div class="programme-resume"><%= decidim_sanitize(html_truncate((attribute), length: 50)) %></div>
13
12
  <div class="programme-extra">
14
13
  <% conference_meeting = meeting.becomes(Decidim::ConferenceMeeting) %>
15
14
  <% speakers = conference_meeting.conference_speakers %>
@@ -44,7 +43,7 @@
44
43
  <strong><%= t(".content") %></strong>
45
44
  </div>
46
45
  <div class="column medium-10">
47
- <%= decidim_sanitize(present(meeting).html_description) %>
46
+ <%= decidim_sanitize(present(meeting).description(links: true)) %>
48
47
  </div>
49
48
  </div>
50
49
  <% end %>
@@ -1,3 +1,11 @@
1
1
  <p><%= t(".confirmed_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
2
2
 
3
- <p><%= t(".details") %></p>
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>
4
+
5
+ <ul>
6
+ <% @registration_type.conference_meetings.each do |conference_meeting| %>
7
+ <li><%= present(conference_meeting).title %> </li>
8
+ <% end %>
9
+ </ul>
10
+
11
+ <p><%= t(".details_2") %></p>
@@ -0,0 +1,11 @@
1
+ <p><%= t(".pending_html", title: translated_attribute(@conference.title), url: @locator.url) %></p>
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>
4
+
5
+ <ul>
6
+ <% @registration_type.conference_meetings.each do |conference_meeting| %>
7
+ <li><%= present(conference_meeting).title %> </li>
8
+ <% end %>
9
+ </ul>
10
+
11
+ <p><%= t(".confirmation_pending") %></p>
@@ -8,7 +8,7 @@ edit_link(
8
8
  )
9
9
  %>
10
10
 
11
- <main class="wrapper">
11
+ <%= participatory_space_wrapper do %>
12
12
  <% if promoted_conferences.any? %>
13
13
  <section id="highlighted-conferences" class="row section">
14
14
  <h1 class="section-heading"><%= t("conferences.index.promoted_conferences", scope: "layouts.decidim") %></h1>
@@ -22,4 +22,4 @@ edit_link(
22
22
  <%= render(collection) %>
23
23
  </div>
24
24
  </section>
25
- </main>
25
+ <% end %>
@@ -14,8 +14,10 @@ edit_link(
14
14
  )
15
15
  %>
16
16
 
17
+ <%= participatory_space_floating_help %>
18
+
17
19
  <div class="row">
18
- <div class="columns mediumlarge-8 large-9">
20
+ <div class="columns mediumlarge-12">
19
21
  <section class="section">
20
22
  <h4 class="section-heading"><%= t("conferences.show.introduction", scope: "decidim") %></h4>
21
23
  <%= decidim_sanitize translated_attribute(current_participatory_space.short_description) %>
@@ -28,7 +30,9 @@ edit_link(
28
30
  <div class="column medium-9 medium-centered">
29
31
  <% if current_participatory_space.registrations_enabled? %>
30
32
  <div class="column medium-6">
31
- <%= cell "decidim/conferences/join_conference_button", current_participatory_space, big_button: true, show_remaining_slots: false, allowed: allowed_to?(:join, :conference, conference: current_participatory_space) %>
33
+ <%= link_to decidim_conferences.conference_registration_types_path(current_participatory_space) do %>
34
+ <button type="button" class="button button--sc light expanded"><%= t(".register") %></button>
35
+ <% end %>
32
36
  </div>
33
37
  <% end %>
34
38
  <% current_participatory_space.components.where(manifest_name: "meetings").each do |component_meeting| %>
@@ -57,24 +61,13 @@ edit_link(
57
61
  <p><%= t(".login_as", name: current_user.name, email: current_user.email ) %></p>
58
62
  <p><%= t(".make_conference_registration") %></p>
59
63
  <div class="medium-3" style="margin: 0 auto;">
60
- <%= cell "decidim/conferences/join_conference_button", current_participatory_space, big_button: true, show_remaining_slots: false, allowed: allowed_to?(:join, :conference, conference: current_participatory_space) %>
64
+ <%= link_to decidim_conferences.conference_registration_types_path(current_participatory_space) do %>
65
+ <button type="button" class="button button--sc light expanded"><%= t(".register") %></button>
66
+ <% end %>
61
67
  </div>
62
68
  </div>
63
69
  <% else %>
64
- <div class="row" data-equalizer>
65
- <div class="column medium-6">
66
- <div class="card p-m" data-equalizer-watch>
67
- <p><%= t(".already_account") %></p>
68
- <%= link_to t(".sign_in"), decidim.new_user_session_path, class: "" %>
69
- </div>
70
- </div>
71
- <div class="column medium-6">
72
- <div class="card p-m" data-equalizer-watch>
73
- <p><%= t(".new_user") %></p>
74
- <%= link_to t(".sign_up"), decidim.new_user_registration_path, class: "" %>
75
- </div>
76
- </div>
77
- </div>
70
+ <%= render partial: "decidim/conferences/shared/conference_user_login" %>
78
71
  <% end %>
79
72
  </section>
80
73
  <% end %>
@@ -94,12 +87,5 @@ edit_link(
94
87
  <%= render partial: "statistics" %>
95
88
  <% end %>
96
89
  </div>
97
-
98
- <div class="columns section view-side mediumlarge-4 large-3">
99
- <%= render partial: "conferences_sidebar" %>
100
- </div>
101
90
  </div>
102
-
103
- <%= javascript_include_tag "decidim/proposals/social_share" %>
104
- <%= stylesheet_link_tag "decidim/proposals/social_share" %>
105
91
  <%= javascript_include_tag "decidim/conferences/conferences" %>
@@ -0,0 +1,30 @@
1
+ <% add_decidim_meta_tags(title: t("registration_types.index.title", scope: "decidim.conferences")) %>
2
+
3
+ <%
4
+ edit_link(
5
+ decidim_admin_conferences.conference_registration_types_path(current_participatory_space.slug),
6
+ :update,
7
+ :conference,
8
+ conference: current_participatory_space
9
+ )
10
+ %>
11
+ <div class="row">
12
+ <div class="columns mediumlarge-12">
13
+ <section class="section">
14
+ <h4 class="section-heading"><%= t("registration_types.index.register", scope: "decidim.conferences") %></h4>
15
+ <% if current_user.present? %>
16
+ <p><%= t(".login_as", name: current_user.name, email: current_user.email ) %></p>
17
+ <% else %>
18
+ <%= render partial: "decidim/conferences/shared/conference_user_login" %>
19
+ <% end %>
20
+ <% if collection.any? %>
21
+ <p><%= t(".choose_an_option") %></p>
22
+ <% collection.each do |registration_type| %>
23
+ <%= cell "decidim/conferences/registration_type", registration_type, allowed: allowed_to?(:join, :conference, conference: current_participatory_space) %>
24
+ <% end %>
25
+ <% else %>
26
+ No registrations
27
+ <% end %>
28
+ </section>
29
+ </div>
30
+ </div>