2017-11-28 10:24:36 +01:00
|
|
|
- if procedure.dossiers.state_not_brouillon.any?
|
2018-09-11 17:51:44 +02:00
|
|
|
%span.dropdown
|
|
|
|
%button.button.dropdown-button
|
|
|
|
Télécharger tous les dossiers
|
2019-06-25 15:46:10 +02:00
|
|
|
.dropdown-content.fade-in-down{ style: 'width: 330px' }
|
2017-11-28 10:24:36 +01:00
|
|
|
%ul.dropdown-items
|
2019-12-11 17:42:44 +01:00
|
|
|
- [[xlsx_export, :xlsx], [csv_export, :csv], [ods_export, :ods]].each do |(export, format)|
|
|
|
|
%li
|
|
|
|
- if export.nil?
|
2019-12-11 17:43:24 +01:00
|
|
|
= link_to "Demander un export au format .#{format}", download_export_instructeur_procedure_path(procedure, export_format: format), remote: true
|
2019-12-11 17:42:44 +01:00
|
|
|
- elsif export.ready?
|
2019-12-11 17:43:24 +01:00
|
|
|
= link_to "Télécharger l'export au format .#{format}", url_for(export.file), target: "_blank", rel: "noopener"
|
2019-10-03 15:35:31 +02:00
|
|
|
- else
|
2019-12-11 17:42:44 +01:00
|
|
|
L'export au format .#{format} est en cours de préparation
|