2017-07-11 16:09:03 +02:00
|
|
|
|
#procedure-show
|
2017-07-18 15:12:55 +02:00
|
|
|
|
.backoffice-header
|
|
|
|
|
.container.flex
|
2017-07-11 16:09:03 +02:00
|
|
|
|
|
2017-09-14 10:11:45 +02:00
|
|
|
|
.procedure-logo
|
|
|
|
|
- if @procedure.logo.present?
|
|
|
|
|
= image_tag @procedure.logo, alt: "Logo de la procédure"
|
|
|
|
|
|
|
|
|
|
.procedure-header
|
2017-07-11 16:09:03 +02:00
|
|
|
|
%h1= @procedure.libelle
|
2017-08-28 10:52:25 +02:00
|
|
|
|
%ul.tabs
|
2017-07-11 16:09:03 +02:00
|
|
|
|
%li{ class: (@statut == 'a-suivre') ? 'active' : nil }>
|
|
|
|
|
= link_to(procedure_path(@procedure, statut: 'a-suivre')) do
|
|
|
|
|
à suivre
|
2017-08-28 10:52:25 +02:00
|
|
|
|
%span.badge= @a_suivre_dossiers.count
|
2017-07-11 16:09:03 +02:00
|
|
|
|
|
|
|
|
|
%li{ class: (@statut == 'suivis') ? 'active' : nil }>
|
2017-08-30 15:31:17 +02:00
|
|
|
|
- if @followed_dossiers.with_unread_notifications.present?
|
|
|
|
|
%span.notifications{ 'aria-label': 'notifications' }
|
2017-07-11 16:09:03 +02:00
|
|
|
|
= link_to(procedure_path(@procedure, statut: 'suivis')) do
|
|
|
|
|
= t('pluralize.followed', count: @followed_dossiers.count)
|
2017-08-28 10:52:25 +02:00
|
|
|
|
%span.badge= @followed_dossiers.count
|
2017-07-11 16:09:03 +02:00
|
|
|
|
|
|
|
|
|
%li{ class: (@statut == 'traites') ? 'active' : nil }>
|
|
|
|
|
= link_to(procedure_path(@procedure, statut: 'traites')) do
|
|
|
|
|
= t('pluralize.processed', count: @termines_dossiers.count)
|
2017-08-28 10:52:25 +02:00
|
|
|
|
%span.badge= @termines_dossiers.count
|
2017-07-11 16:09:03 +02:00
|
|
|
|
|
|
|
|
|
%li{ class: (@statut == 'tous') ? 'active' : nil }>
|
2017-08-30 15:31:17 +02:00
|
|
|
|
- if @followed_dossiers.with_unread_notifications.present?
|
|
|
|
|
%span.notifications{ 'aria-label': 'notifications' }
|
2017-07-11 16:09:03 +02:00
|
|
|
|
= link_to(procedure_path(@procedure, statut: 'tous')) do
|
|
|
|
|
tous les dossiers
|
2017-08-28 10:52:25 +02:00
|
|
|
|
%span.badge= @all_state_dossiers.count
|
2017-07-11 16:09:03 +02:00
|
|
|
|
|
|
|
|
|
%li{ class: (@statut == 'archives') ? 'active' : nil }>
|
|
|
|
|
= link_to(procedure_path(@procedure, statut: 'archives')) do
|
|
|
|
|
= t('pluralize.archived', count: @archived_dossiers.count)
|
2017-08-28 10:52:25 +02:00
|
|
|
|
%span.badge= @archived_dossiers.count
|
2017-07-11 15:40:09 +02:00
|
|
|
|
|
2017-09-15 14:46:17 +02:00
|
|
|
|
.procedure-actions
|
|
|
|
|
%span.button.dropdown
|
|
|
|
|
Télécharger tous les dossiers
|
|
|
|
|
.dropdown-content.fade-in-down
|
|
|
|
|
%ul.dropdown-items
|
|
|
|
|
%li
|
|
|
|
|
= link_to "Au format .csv", backoffice_download_dossiers_tps_path(format: :csv, procedure_id: @procedure.id), target: "_blank"
|
|
|
|
|
%li
|
|
|
|
|
= link_to "Au format .xls", backoffice_download_dossiers_tps_path(format: :xls, procedure_id: @procedure.id), target: "_blank"
|
|
|
|
|
%li
|
|
|
|
|
= link_to "Au format .ods", backoffice_download_dossiers_tps_path(format: :ods, procedure_id: @procedure.id), target: "_blank"
|
|
|
|
|
|
2017-07-11 15:40:09 +02:00
|
|
|
|
.container
|
|
|
|
|
- if @dossiers.present?
|
2017-07-31 15:01:26 +02:00
|
|
|
|
%table.table.dossiers-table.hoverable
|
|
|
|
|
%thead
|
2017-07-11 15:40:09 +02:00
|
|
|
|
%tr
|
2017-07-31 15:01:26 +02:00
|
|
|
|
%th.number-col Nº dossier
|
|
|
|
|
%th Demandeur
|
|
|
|
|
%th.status-col Statut
|
|
|
|
|
%th.follow-col
|
|
|
|
|
%tbody
|
|
|
|
|
- @dossiers.each do |dossier|
|
|
|
|
|
%tr
|
|
|
|
|
%td.number-col
|
|
|
|
|
= link_to(dossier_path(@procedure, dossier), class: 'cell-link') do
|
|
|
|
|
%i.folder
|
2017-08-30 15:31:17 +02:00
|
|
|
|
- if @followed_dossiers.with_unread_notifications.include?(dossier)
|
|
|
|
|
%span.notifications{ 'aria-label': 'notifications' }
|
2017-07-31 15:01:26 +02:00
|
|
|
|
= dossier.id
|
|
|
|
|
%td= link_to(dossier.user.email, dossier_path(@procedure, dossier), class: 'cell-link')
|
|
|
|
|
%td.status-col
|
|
|
|
|
= link_to(dossier_path(@procedure, dossier), class: 'cell-link') do
|
|
|
|
|
= render partial: 'status', locals: { dossier: dossier }
|
|
|
|
|
%td.follow-col= render partial: 'dossier_actions', locals: { procedure: @procedure, dossier: dossier, dossier_is_followed: @followed_dossiers_id.include?(dossier.id) }
|
2017-07-11 15:40:09 +02:00
|
|
|
|
- else
|
|
|
|
|
%h2 Aucun dossier
|