Merge pull request #2223 from betagouv/fix-file-download-without-extension
Temporary fix to allow users to download files with extensions
This commit is contained in:
commit
9e08ac9da2
1 changed files with 2 additions and 1 deletions
|
@ -1,7 +1,8 @@
|
||||||
- pj = champ.piece_justificative_file
|
- pj = champ.piece_justificative_file
|
||||||
- if champ.virus_scan.present?
|
- if champ.virus_scan.present?
|
||||||
- if champ.virus_scan.safe?
|
- if champ.virus_scan.safe?
|
||||||
= link_to pj.filename.to_s, url_for(pj), target: '_blank'
|
#FIXME : use url_for(pj) and remove download attribute when Riak content_disposition bug is solved https://github.com/betagouv/tps/issues/2180
|
||||||
|
= link_to pj.filename.to_s, pj.service_url(expires_in: 1.hour), target: '_blank', download: pj.filename.to_s
|
||||||
- else
|
- else
|
||||||
= pj.filename.to_s
|
= pj.filename.to_s
|
||||||
- if champ.virus_scan.pending?
|
- if champ.virus_scan.pending?
|
||||||
|
|
Loading…
Reference in a new issue