clean(expiration_banner): dedicated to user not shared

This commit is contained in:
Martin 2021-12-02 15:54:18 +01:00
parent 1bb868714c
commit 8e9b15aef4
4 changed files with 4 additions and 4 deletions

View file

@ -1,25 +0,0 @@
-# small expires mention
- if dossier.expirable?
%p.expires_at
%small= t("shared.dossiers.header.expires_at.#{dossier.state}", date: safe_expiration_date(dossier))
-# big banner warning
- if dossier.close_to_expiration?
.card.warning.mt-2.mb-3
.card-title= t('shared.dossiers.header.banner.title')
%p
- if dossier.brouillon?
= t('shared.dossiers.header.banner.states.brouillon')
- elsif dossier.en_construction?
= t('shared.dossiers.header.banner.states.en_construction')
- elsif dossier.termine?
= t('shared.dossiers.header.banner.states.termine')
- if dossier.expiration_can_be_extended?
%br
= button_to t('shared.dossiers.header.banner.button_delay_expiration'), users_dossier_repousser_expiration_path(dossier), class: 'button secondary mt-2'
- else
%p.expires_at_en_instruction
%small= t("shared.dossiers.header.expires_at.en_instruction")

View file

@ -6,7 +6,7 @@
= t('views.users.dossiers.show.header.dossier_number', dossier_id: dossier.id)
= t('views.users.dossiers.show.header.created_date', date_du_dossier: I18n.l(dossier.created_at))
= render(partial: 'shared/dossiers/expiration_banner', locals: {dossier: dossier})
= render(partial: 'users/dossiers/expiration_banner', locals: {dossier: dossier})
.header-actions
- if current_user.owns?(dossier)