remove useless if
Co-authored-by: Christophe Robillard <christophe.robillard@beta.gouv.fr>
This commit is contained in:
parent
f094c6c218
commit
1a6337cf37
1 changed files with 10 additions and 13 deletions
|
@ -73,19 +73,16 @@
|
||||||
- weight = nb_dossiers_termines * @average_dossier_weight
|
- weight = nb_dossiers_termines * @average_dossier_weight
|
||||||
= number_to_human_size(weight)
|
= number_to_human_size(weight)
|
||||||
%td
|
%td
|
||||||
- if nb_dossiers_termines > 0
|
- if matching_archive.present?
|
||||||
- if matching_archive.present?
|
- if matching_archive.status == 'generated' && matching_archive.file.attached?
|
||||||
- if matching_archive.status == 'generated' && matching_archive.file.attached?
|
= link_to url_for(matching_archive.file), class: 'button primary' do
|
||||||
= link_to url_for(matching_archive.file), class: 'button primary' do
|
%span.icon.download-white
|
||||||
%span.icon.download-white
|
= t(:archive_ready_html, generated_period: time_ago_in_words(matching_archive.updated_at), scope: [:instructeurs, :procedure])
|
||||||
= t(:archive_ready_html, generated_period: time_ago_in_words(matching_archive.updated_at), scope: [:instructeurs, :procedure])
|
|
||||||
- else
|
|
||||||
%span.icon.retry
|
|
||||||
= t(:archive_pending_html, created_period: time_ago_in_words(matching_archive.created_at), scope: [:instructeurs, :procedure])
|
|
||||||
- else
|
- else
|
||||||
= link_to instructeur_archives_path(@procedure, type:'monthly', month: month.strftime('%Y-%m')), method: :post, class: "button" do
|
%span.icon.retry
|
||||||
%span.icon.new-folder
|
= t(:archive_pending_html, created_period: time_ago_in_words(matching_archive.created_at), scope: [:instructeurs, :procedure])
|
||||||
Démander la création
|
|
||||||
- else
|
- else
|
||||||
Rien à télécharger !
|
= link_to instructeur_archives_path(@procedure, type:'monthly', month: month.strftime('%Y-%m')), method: :post, class: "button" do
|
||||||
|
%span.icon.new-folder
|
||||||
|
Démander la création
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue