2022-03-11 13:57:53 +01:00
|
|
|
- if hidden_by_administration
|
|
|
|
= link_to restore_instructeur_dossier_path(procedure_id, dossier_id), method: :patch, class: "button" do
|
|
|
|
= t('views.instructeurs.dossiers.restore')
|
|
|
|
- elsif close_to_expiration || Dossier::TERMINE.include?(state)
|
2022-05-11 16:08:48 +02:00
|
|
|
.dropdown.user-dossier-actions{ data: { controller: 'menu-button' } }
|
|
|
|
%button.button.dropdown-button{ data: { menu_button_target: 'button' } }
|
2021-06-16 16:03:57 +02:00
|
|
|
Actions
|
2022-07-07 13:28:12 +02:00
|
|
|
.dropdown-content.fade-in-down{ data: { menu_button_target: 'menu' }, id: "dossier_#{dossier_id}_actions_menu" }
|
2021-06-16 16:03:57 +02:00
|
|
|
%ul.dropdown-items
|
2021-12-03 16:09:51 +01:00
|
|
|
- if close_to_expiration
|
|
|
|
%li
|
|
|
|
= link_to repousser_expiration_instructeur_dossier_path(procedure_id, dossier_id), method: :post do
|
|
|
|
%span.icon.standby
|
|
|
|
.dropdown-description= t('instructeurs.dossiers.header.banner.button_delay_expiration')
|
2021-06-16 16:03:57 +02:00
|
|
|
- if archived
|
|
|
|
%li
|
|
|
|
= link_to unarchive_instructeur_dossier_path(procedure_id, dossier_id), method: :patch do
|
|
|
|
%span.icon.unarchive
|
|
|
|
.dropdown-description
|
|
|
|
Désarchiver le dossier
|
|
|
|
- else
|
|
|
|
%li
|
|
|
|
= link_to archive_instructeur_dossier_path(procedure_id, dossier_id), method: :patch do
|
|
|
|
%span.icon.archive
|
|
|
|
.dropdown-description
|
|
|
|
Archiver le dossier
|
2022-02-02 19:34:00 +01:00
|
|
|
|
2022-01-27 17:02:02 +01:00
|
|
|
%li.danger
|
2022-03-11 13:57:09 +01:00
|
|
|
= link_to instructeur_dossier_path(procedure_id, dossier_id), method: :delete do
|
2022-01-27 17:02:02 +01:00
|
|
|
%span.icon.delete
|
|
|
|
.dropdown-description
|
|
|
|
= t('views.instructeurs.dossiers.delete_dossier')
|
2021-06-16 16:03:57 +02:00
|
|
|
|
|
|
|
- elsif Dossier::EN_CONSTRUCTION_OU_INSTRUCTION.include?(state)
|
2017-07-31 18:35:34 +02:00
|
|
|
- if dossier_is_followed
|
2021-04-26 10:35:22 +02:00
|
|
|
= link_to unfollow_instructeur_dossier_path(procedure_id, dossier_id), method: :patch, class: 'button' do
|
2017-12-12 14:51:44 +01:00
|
|
|
%span.icon.unfollow>
|
2022-04-13 15:44:29 +02:00
|
|
|
= t('views.instructeurs.dossiers.stop_follow')
|
2017-07-11 15:58:31 +02:00
|
|
|
- else
|
2021-04-26 10:35:22 +02:00
|
|
|
= link_to follow_instructeur_dossier_path(procedure_id, dossier_id), method: :patch, class: 'button' do
|
2017-12-12 14:51:44 +01:00
|
|
|
%span.icon.follow>
|
2022-04-13 15:44:29 +02:00
|
|
|
= t('views.instructeurs.dossiers.follow_file')
|