Remove useless ids in the new Avis templates
This commit is contained in:
parent
bf1e103ef3
commit
0a185fb76b
3 changed files with 57 additions and 60 deletions
|
@ -1,41 +1,40 @@
|
|||
- avis_statut = (@statut == NewGestionnaire::AvisController::A_DONNER_STATUS) ? 'à donner' : 'rendus'
|
||||
- content_for(:title, "Avis #{avis_statut}")
|
||||
|
||||
#avis-index
|
||||
.accompagnateur-header
|
||||
.container.flex
|
||||
.width-100
|
||||
%h1.tab-title Avis
|
||||
%ul.tabs
|
||||
%li{ class: (@statut == NewGestionnaire::AvisController::A_DONNER_STATUS) ? 'active' : nil }>
|
||||
= link_to(avis_index_path(statut: NewGestionnaire::AvisController::A_DONNER_STATUS)) do
|
||||
avis à donner
|
||||
%span.badge= @avis_a_donner.count
|
||||
- if @avis_a_donner.any?
|
||||
%span.notifications
|
||||
.accompagnateur-header
|
||||
.container.flex
|
||||
.width-100
|
||||
%h1.tab-title Avis
|
||||
%ul.tabs
|
||||
%li{ class: (@statut == NewGestionnaire::AvisController::A_DONNER_STATUS) ? 'active' : nil }>
|
||||
= link_to(avis_index_path(statut: NewGestionnaire::AvisController::A_DONNER_STATUS)) do
|
||||
avis à donner
|
||||
%span.badge= @avis_a_donner.count
|
||||
- if @avis_a_donner.any?
|
||||
%span.notifications
|
||||
|
||||
%li{ class: (@statut == NewGestionnaire::AvisController::DONNES_STATUS) ? 'active' : nil }>
|
||||
= link_to(avis_index_path(statut: NewGestionnaire::AvisController::DONNES_STATUS)) do
|
||||
avis #{'donné'.pluralize(@avis_donnes.count)}
|
||||
%span.badge= @avis_donnes.count
|
||||
%li{ class: (@statut == NewGestionnaire::AvisController::DONNES_STATUS) ? 'active' : nil }>
|
||||
= link_to(avis_index_path(statut: NewGestionnaire::AvisController::DONNES_STATUS)) do
|
||||
avis #{'donné'.pluralize(@avis_donnes.count)}
|
||||
%span.badge= @avis_donnes.count
|
||||
|
||||
.container
|
||||
- if @avis.present?
|
||||
%table.table.dossiers-table.hoverable
|
||||
%thead
|
||||
.container
|
||||
- if @avis.present?
|
||||
%table.table.dossiers-table.hoverable
|
||||
%thead
|
||||
%tr
|
||||
%th.number-col Nº dossier
|
||||
%th Demandeur
|
||||
%th Procédure
|
||||
%tbody
|
||||
- @avis.each do |avis|
|
||||
%tr
|
||||
%th.number-col Nº dossier
|
||||
%th Demandeur
|
||||
%th Procédure
|
||||
%tbody
|
||||
- @avis.each do |avis|
|
||||
%tr
|
||||
%td.number-col
|
||||
= link_to(avis_path(avis), class: 'cell-link') do
|
||||
%span.icon.folder
|
||||
#{avis.dossier.id}
|
||||
%td= link_to(avis.dossier.user.email, avis_path(avis), class: 'cell-link')
|
||||
%td= link_to(avis.dossier.procedure.libelle, avis_path(avis), class: 'cell-link')
|
||||
= paginate(@avis)
|
||||
- else
|
||||
%h2.empty-text Aucun avis
|
||||
%td.number-col
|
||||
= link_to(avis_path(avis), class: 'cell-link') do
|
||||
%span.icon.folder
|
||||
#{avis.dossier.id}
|
||||
%td= link_to(avis.dossier.user.email, avis_path(avis), class: 'cell-link')
|
||||
%td= link_to(avis.dossier.procedure.libelle, avis_path(avis), class: 'cell-link')
|
||||
= paginate(@avis)
|
||||
- else
|
||||
%h2.empty-text Aucun avis
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
- content_for(:title, "Avis · Dossier nº #{@dossier.id} (#{@dossier.owner_name})")
|
||||
|
||||
#avis-show
|
||||
= render partial: 'header', locals: { avis: @avis, dossier: @dossier }
|
||||
= render partial: 'header', locals: { avis: @avis, dossier: @dossier }
|
||||
|
||||
.container
|
||||
%section.give-avis
|
||||
|
|
|
@ -1,29 +1,28 @@
|
|||
- content_for(:title, "Demande · Dossier nº #{@dossier.id} (#{@dossier.owner_name})")
|
||||
|
||||
#avis-show
|
||||
= render partial: 'header', locals: { avis: @avis, dossier: @dossier }
|
||||
= render partial: 'header', locals: { avis: @avis, dossier: @dossier }
|
||||
|
||||
.container
|
||||
.tab-title Identité du demandeur
|
||||
.container
|
||||
.tab-title Identité du demandeur
|
||||
.card
|
||||
- if @dossier.entreprise.present?
|
||||
= render partial: 'new_gestionnaire/dossiers/identite_entreprise', locals: { entreprise: @dossier.entreprise }
|
||||
|
||||
- if @dossier.individual.present?
|
||||
= render partial: 'new_gestionnaire/dossiers/identite_individual', locals: { individual: @dossier.individual }
|
||||
|
||||
.tab-title Formulaire
|
||||
- champs = @dossier.ordered_champs.decorate
|
||||
- if champs.any?
|
||||
.card
|
||||
- if @dossier.entreprise.present?
|
||||
= render partial: 'new_gestionnaire/dossiers/identite_entreprise', locals: { entreprise: @dossier.entreprise }
|
||||
= render partial: 'new_gestionnaire/dossiers/champs', locals: { champs: champs, dossier: @dossier, demande_seen_at: nil }
|
||||
|
||||
- if @dossier.individual.present?
|
||||
= render partial: 'new_gestionnaire/dossiers/identite_individual', locals: { individual: @dossier.individual }
|
||||
- if @dossier.procedure.use_api_carto
|
||||
.tab-title Cartographie
|
||||
.card
|
||||
= render partial: 'new_gestionnaire/dossiers/map', locals: { dossier: @dossier }
|
||||
|
||||
.tab-title Formulaire
|
||||
- champs = @dossier.ordered_champs.decorate
|
||||
- if champs.any?
|
||||
.card
|
||||
= render partial: 'new_gestionnaire/dossiers/champs', locals: { champs: champs, dossier: @dossier, demande_seen_at: nil }
|
||||
|
||||
- if @dossier.procedure.use_api_carto
|
||||
.tab-title Cartographie
|
||||
.card
|
||||
= render partial: 'new_gestionnaire/dossiers/map', locals: { dossier: @dossier }
|
||||
|
||||
- if @dossier.procedure.cerfa_flag? || @dossier.types_de_piece_justificative.any?
|
||||
.tab-title Pièces jointes
|
||||
.card
|
||||
= render partial: "new_gestionnaire/dossiers/pieces_jointes", locals: { dossier: @dossier, demande_seen_at: nil }
|
||||
- if @dossier.procedure.cerfa_flag? || @dossier.types_de_piece_justificative.any?
|
||||
.tab-title Pièces jointes
|
||||
.card
|
||||
= render partial: "new_gestionnaire/dossiers/pieces_jointes", locals: { dossier: @dossier, demande_seen_at: nil }
|
||||
|
|
Loading…
Reference in a new issue