Skip to content

armgit / wger

Public Imported from GitHub
0

Self hosted FLOSS fitness/workout, nutrition and weight tracker

Don't translate generated filenames, makes trouble with unicode

Roland Geiderf2ff55e4cb84
diff --git a/wger/manager/pdf.py b/wger/manager/pdf.py
index 4a33bdc7d..ef9dd6e99 100644
--- a/wger/manager/pdf.py
+++ b/wger/manager/pdf.py
@@ -50,7 +50,7 @@ def workout_log(request, id):
# Create the HttpResponse object with the appropriate PDF headers.
response = HttpResponse(mimetype='application/pdf')
- response['Content-Disposition'] = 'attachment; filename=%s.pdf' % _('Workout')
+ response['Content-Disposition'] = 'attachment; filename=Workout-{0}.pdf'.format(id)
# Create the PDF object, using the response object as its "file."
doc = SimpleDocTemplate(response,