Sha256: 263667a17b8ecc3e559cca310144408813fef9d7a9d8593fe619b11097435229

Contents?: true

Size: 1.52 KB

Versions: 26

Compression:

Stored size: 1.52 KB

Contents

<% if model.can_be_joined_by?(current_user) %>
  <% if model.has_registration_for? current_user %>
    <span>
      <%= icon("check", class: "icon--small") %>
      <%= t("going", scope: "decidim.meetings.meetings.show") %>
    </span>
    <%= action_authorized_button_to(
      :join,
      t("leave", scope: "decidim.meetings.meetings.show"),
      meeting_registration_path(model),
      resource: model,
      method: :delete,
      class: button_classes,
      data: { disable: true, confirm: t("leave_confirmation", scope: "decidim.meetings.meetings.show") }
    ) %>
  <% else %>
    <% if model.registration_form_enabled? %>
      <%= action_authorized_link_to(
        :join,
        i18n_join_text,
        join_meeting_registration_path(model),
        class: button_classes,
        disabled: !model.has_available_slots?,
      ) %>
    <% else %>
      <%= render :registration_confirm %>
      <%= action_authorized_button_to(
        :join,
        i18n_join_text,
        "#",
        class: button_classes,
        disabled: !model.has_available_slots?,
        data: { open: current_user.present? ? "meeting-registration-confirm-#{model.id}" : "loginModal" }
      ) %>
    <% end %>
  <% end %>
  <% if shows_remaining_slots? %>
    <span><%= t("remaining_slots", scope: "decidim.meetings.meetings.show", count: model.remaining_slots) %></span>
  <% end %>
<% elsif model.on_different_platform? %>
  <%= action_authorized_link_to(
    :join,
    i18n_join_text,
    model.registration_url,
    class: button_classes
  ) %>
<% end %>

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
decidim-meetings-0.26.10 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.9 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.8 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.4 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.3 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.7 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.5 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.2 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.1 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.4 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.0 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.3 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.0.rc2 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.27.0.rc1 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.2 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.1 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.0 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.0.rc2 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.26.0.rc1 app/cells/decidim/meetings/join_meeting_button/show.erb
decidim-meetings-0.25.2 app/cells/decidim/meetings/join_meeting_button/show.erb