Skip to content
Snippets Groups Projects
Commit 0c103f04 authored by Carlos Vega's avatar Carlos Vega
Browse files

make pep happy

parent 5570ac80
No related branches found
No related tags found
1 merge request!445Support for Python 3.11
......@@ -89,7 +89,7 @@ def create_field_for_custom_study_subject_field(study_subject_field: CustomStudy
required=study_subject_field.required,
disabled=study_subject_field.readonly,
initial=initial,
widget=SecuredFileWidget() #TO DO: how to allow multiple files?
widget=SecuredFileWidget() # TODO: how to allow multiple files?
)
else:
raise NotImplementedError
......
......@@ -10,7 +10,7 @@ logger = logging.getLogger(__name__)
class SecuredFileWidget(forms.FileInput):
"""A FileField Widget that shows secure file link"""
allow_multiple_selected = False
allow_multiple_selected = False
def __init__(self, attrs=None):
if attrs is None:
......@@ -24,4 +24,4 @@ class SecuredFileWidget(forms.FileInput):
out = '<a href="{}">{}</a><br />{} '
output.append(out.format(url, _('Download'), _('Change:')))
output.append(super().render(name, value, attrs, renderer=renderer))
return mark_safe(''.join(output))
\ No newline at end of file
return mark_safe(''.join(output))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment