- content_for :results do .main-filter-header.fr-my-3w = form_with(url: administrateurs_admin_procedures_path, method: :get, data: { turbo_frame: 'procedures' }, html: { role: 'search' }) do |f| - @filter.zone_ids&.each do |zone_id| = hidden_field_tag 'zone_ids[]', zone_id, id: "zone_#{zone_id}" - @filter.statuses&.each do |status| = hidden_field_tag 'statuses[]', status, id: "status_#{status}" = hidden_field_tag 'from_publication_date', @filter.from_publication_date if @filter.from_publication_date.present? = f.label 'email', 'Rechercher des administrateurs par email', class: 'fr-label' = f.search_field 'email', size: 40, class: 'fr-input', data: { turbo_force: :server } .actions= link_to 'Voir la liste des démarches', all_admin_procedures_path(@filter.params), class: 'fr-btn fr-btn--secondary' - if @filter.email .selected-email.fr-mb-2w = link_to @filter.email, administrateurs_admin_procedures_path(@filter.without(:email)), class: 'fr-tag fr-tag--dismiss fr-mb-1w' - if @filter.selected_zones.present? .selected-zones.fr-mb-2w - @filter.selected_zones.each do |zone| = link_to zone.current_label, all_admin_procedures_path(@filter.without(:zone_ids, zone.id)), class: 'fr-tag fr-tag--dismiss fr-mb-1w' - if @filter.statuses.present? .selected-statuses.fr-mb-2w - @filter.statuses.each do |status| = link_to status, all_admin_procedures_path(@filter.without(:statuses, status)), class: 'fr-tag fr-tag--dismiss fr-mb-1w' - if @filter.from_publication_date.present? .selected-from-publication-date.fr-mb-2w = link_to "Depuis le #{l(@filter.from_publication_date)}", all_admin_procedures_path(@filter.without(:from_publication_date)), class: 'fr-tag fr-tag--dismiss fr-mb-1w' .fr-table.fr-table--bordered .fr-table__wrapper .fr-table__container .fr-table__content %table#all-admins %caption = "#{@admins.total_count} administrateurs" %span.hidden.spinner{ 'aria-hidden': 'true', 'data-turbo-target': 'spinner' } %thead %tr %th{ scope: 'col' } %th{ scope: 'col' } Administrateurs %th{ scope: 'col' } Nb démarches %th{ scope: 'col' } Inscrit le - @admins.each do |admin| %tbody{ 'data-controller': 'expand' } %tr.procedure{ 'data-action': 'click->expand#toggle' } %th.fr-cell--center{ scope: 'row' } %button.fr-icon-add-line.fr-icon--sm.fr-mb-1w.fr-text-action-high--blue-france.fr-btn.fr-btn--tertiary-no-outline{ 'aria-hidden': 'true', 'data-expand-target': 'icon' } %td= admin.email %td.fr-cell--right.fr-cell--numeric= admin.procedures.size %td.fr-cell--numeric= l(admin.created_at, format: :message_date_without_time) %tr.hidden{ 'data-expand-target': 'content' } %td.fr-cell--multiline.fr-background-alt--green-emeraude{ colspan: '4' } %ul - admin.procedures.each do |procedure| %li= procedure.libelle .fr-table__footer .fr-table__footer--start .fr-table__footer--middle = paginate @admins, views_prefix: 'shared' .fr-table__footer--end.flex-no-grow