prend en compte uniquement les pj pour estimer la taille d'un dossier

This commit is contained in:
Christophe Robillard 2021-05-04 10:31:13 +02:00
parent 71a48c99bb
commit 01f180022b
7 changed files with 60 additions and 37 deletions

View file

@ -873,9 +873,8 @@ class Dossier < ApplicationRecord
end
end
def attachments_downloadable?
PiecesJustificativesService.liste_pieces_justificatives(self).present? \
&& PiecesJustificativesService.pieces_justificatives_total_size(self) < Dossier::TAILLE_MAX_ZIP
def export_and_attachments_downloadable?
PiecesJustificativesService.pieces_justificatives_total_size(self) < Dossier::TAILLE_MAX_ZIP
end
def linked_dossiers_for(instructeur_or_expert)