Commit ae417a62 authored by Thonier Florian's avatar Thonier Florian
Browse files

server/controller/results_file; fix error of path of file to download

Allow to get result of hidden task (getreads case) or directly asked file (analysis artifacts)
parent 6fa2d6f6
Pipeline #732191 passed with stages
in 63 minutes and 20 seconds
......@@ -121,7 +121,14 @@ def download():
results_id = int(request.vars["results_file_id"])
query = db( ( == request.vars["results_file_id"]) ).select(, db.results_file.hidden, db.results_file.data_file)
filepath = defs.DIR_RESULTS + query[0].data_file
if query[0].hidden == True:
# If hidden, only result file is important (getReads)
filepath = defs.DIR_RESULTS + query[0].data_file
else: # else download given file
olddir = defs.DIR_OUT_VIDJIL_ID % results_id
filepath = olddir + request.vars['filename']"Downloaded results file", extra={'user_id':,
'record_id': request.vars["results_file_id"],
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment