aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrea Lepori <alepori@student.ethz.ch>2020-08-29 14:54:55 +0200
committerAndrea Lepori <alepori@student.ethz.ch>2020-08-29 14:54:55 +0200
commit00e0868dc17684ac8f5bd3086005f4b792a6c85e (patch)
tree86c40ef57aef88bf7ef8b58ee9bf92fbc771747b
parentrevert to previous download method (diff)
downloadscout-subs-00e0868dc17684ac8f5bd3086005f4b792a6c85e.tar.gz
scout-subs-00e0868dc17684ac8f5bd3086005f4b792a6c85e.zip
remove delay for js to load
-rw-r--r--server/views.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/views.py b/server/views.py
index 2f601e6..cdc1b74 100644
--- a/server/views.py
+++ b/server/views.py
@@ -221,7 +221,7 @@ def ulist(request):
# render context
html = template.render(context)
# render pdf using wkhtmltopdf
- pdf = pdfkit.from_string(html, False, options={'javascript-delay':'5000', 'no-stop-slow-scripts':False})
+ pdf = pdfkit.from_string(html, False)
result = BytesIO(pdf)
result.seek(0)
return FileResponse(result, filename=document.user.username+"_"+document.document_type.name+".pdf")
@@ -601,7 +601,7 @@ def doclist(request):
context = {'doc': doc, 'vac': vac_file,
'health': health_file, 'sign_doc_file': sign_doc_file}
html = template.render(context)
- pdf = pdfkit.from_string(html, False, options={'javascript-delay':'5000', 'no-stop-slow-scripts':False})
+ pdf = pdfkit.from_string(html, False)
result = BytesIO(pdf)
result.seek(0)
return FileResponse(result, filename=document.user.username+"_"+document.document_type.name+".pdf")