<% add_decidim_page_title(t(".title")) %>

<%= t(".title") %>
<%= link_to t("actions.new", scope: "decidim.meetings", name: t("models.meeting.name", scope: "decidim.meetings.admin")), new_meeting_path, class: "button tiny button--simple" if allowed_to? :create, :meeting %> <%= export_dropdown %>

<%= admin_filter_selector(:meetings) %>
<% if maps_enabled? && Decidim::Map.available?(:static, :geocoding) %> <% end %> <% if resource_with_scopes_enabled? %> <% end %> <% meetings.each do |meeting| %> <% if maps_enabled? && Decidim::Map.available?(:static, :geocoding) %> <% end %> <%= td_resource_scope_for(meeting.scope) %> <% end %>
<%= sort_link(query, :id, t("models.meeting.fields.id", scope: "decidim.meetings"), default_order: :desc ) %> <%= sort_link(query, :translated_title, t("models.meeting.fields.title", scope: "decidim.meetings"), default_order: :desc ) %> <%= sort_link(query, :start_time, t("models.meeting.fields.start_time", scope: "decidim.meetings"), default_order: :desc ) %> <%= sort_link(query, :end_time, t("models.meeting.fields.end_time", scope: "decidim.meetings"), default_order: :desc ) %> <%= sort_link(query, :closed, t("models.meeting.fields.closed", scope: "decidim.meetings"), default_order: :desc ) %> <%= t("models.meeting.fields.map", scope: "decidim.meetings") %> <%= sort_link(query, :scope_name, t("models.proposal.fields.scope", scope: "decidim.proposals") ) %> <%= t("actions.title", scope: "decidim.meetings") %>
<%= meeting.id %>
<%= present(meeting).title(html_escape: true) %>
<% if meeting.start_time %> <%= l meeting.start_time, format: :long %> <% end %> <% if meeting.end_time %> <%= l meeting.end_time, format: :long %> <% end %> <%= humanize_boolean meeting.closed? %> <%= static_map_link(meeting) %> <% if allowed_to? :update, :meeting, meeting: meeting %> <% if meeting.published? %> <%= icon_link_to "x", unpublish_meeting_path(meeting), t("actions.unpublish", scope: "decidim.admin"), method: :put, class: "action-icon--unpublish", data: { confirm: t("actions.unpublish", scope: "decidim.admin") } %> <% else %> <%= icon_link_to "check", publish_meeting_path(meeting), t("actions.publish", scope: "decidim.admin"), method: :put, class: "action-icon--publish" %> <% end %> <% else %> <% end %> <%= icon_link_to "eye", resource_locator(meeting).path, t("actions.preview", scope: "decidim.meetings"), class: "action-icon--preview", target: :blank %> <% if allowed_to? :copy, :meeting, meeting: meeting %> <%= icon_link_to "clipboard", new_meeting_copy_path(meeting), t("actions.duplicate", scope: "decidim.admin"), class: "action-icon--copy" %> <% else %> <% end %> <% if allowed_to? :update, :meeting, meeting: meeting %> <% if meeting.registration_disabled? %> <%= icon "people", class: "action-icon action-icon--disabled", role: "img", aria_label: t("actions.registrations", scope: "decidim.meetings") %> <% else %> <%= icon_link_to "people", meeting.on_this_platform? ? edit_meeting_registrations_path(meeting) : meeting.registration_url, t("actions.registrations", scope: "decidim.meetings"), class: "action-icon--registrations" %> <% end %> <% end %> <% if allowed_to? :update, :meeting, meeting: meeting %> <%= icon_link_to "pencil", edit_meeting_path(meeting), t("actions.edit", scope: "decidim.meetings"), class: "action-icon--edit" %> <%= icon_link_to "calendar", meeting.agenda.present? ? edit_meeting_agenda_path(meeting, meeting.agenda) : new_meeting_agenda_path(meeting), t("actions.agenda", scope: "decidim.meetings"), class: "action-icon--agenda" %> <%= icon_link_to "list", edit_meeting_poll_path(meeting), t("actions.manage_poll", scope: "decidim.meetings"), class: "action-icon--manage-poll-questionnaire" %> <% else %> <% end %> <% if allowed_to? :close, :meeting, meeting: meeting %> <%= icon_link_to "lock-locked", edit_meeting_meeting_close_path(meeting_id: meeting.id, id: meeting.id), t("actions.close", scope: "decidim.meetings"), class: "action-icon--close" %> <% else %> <% end %> <% if allowed_to? :update, :meeting, meeting: meeting %> <%= icon_link_to "folder", meeting_attachment_collections_path(meeting), t("actions.attachment_collections", scope: "decidim.meetings"), class: "action-icon--attachment_collections" %> <% else %> <% end %> <% if allowed_to? :update, :meeting, meeting: meeting %> <%= icon_link_to "paperclip", meeting_attachments_path(meeting), t("actions.attachments", scope: "decidim.meetings"), class: "action-icon--attachments" %> <% else %> <% end %> <%= resource_permissions_link(meeting) %> <% if allowed_to? :destroy, :meeting, meeting: meeting %> <% if present(meeting).authored_proposals.empty? %> <%= icon_link_to "circle-x", meeting_path(meeting), t("actions.destroy", scope: "decidim.meetings"), method: :delete, class: "action-icon--remove", data: { confirm: t("actions.confirm_destroy", scope: "decidim.meetings") } %> <% else %> <%= content_tag(:button, class: ["action-icon", "action-icon--remove", "destroy-meeting-alert"], "data-invalid-destroy-message" => t("actions.invalid_destroy.proposals_count", count: present(meeting).authored_proposals.size, scope: "decidim.meetings"), "data-proposal-titles" => present(meeting).formatted_proposals_titles) do content_tag(:span, data: { tooltip: true, disable_hover: false, click_open: false }, title: t("actions.destroy", scope: "decidim.meetings")) do icon("circle-x") end end %> <% end %> <% else %> <% end %>
<%= paginate meetings, theme: "decidim" %>
<%= javascript_pack_tag "decidim_meetings_admin" %>