Skip to content

Commit

Permalink
close darklow#768 : On my side with these modifications, the demo can…
Browse files Browse the repository at this point in the history
… run without error.
  • Loading branch information
Frédéric Ravetier committed Nov 11, 2020
1 parent 0d854c9 commit d7ec7a2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion demo/demo/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class PopulationFilter(IsNullFieldListFilter):
class CountryAdmin(RelatedFieldAdmin):
form = CountryForm
search_fields = ('name', 'code')
list_display = ('name', 'code', 'link_to_continent', 'independence_day')
list_display = ('name', 'code', 'independence_day')
list_filter = ('continent', 'independence_day', 'code', ('population', PopulationFilter))
suit_list_filter_horizontal = ('code', 'population')
list_select_related = True
Expand Down
6 changes: 3 additions & 3 deletions suit/widgets.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def media(self):
return forms.Media(js=('suit/js/autosize.min.js',))

def render(self, name, value, attrs=None, renderer=None):
output = super(AutosizedTextarea, self).render(name, value, attrs,renderer)
output = super(AutosizedTextarea, self).render(name, value, attrs)
output += mark_safe(
"<script type=\"text/javascript\">django.jQuery(function () { autosize(document.getElementById('id_%s')); });</script>"
% name)
Expand All @@ -30,7 +30,7 @@ class CharacterCountTextarea(AutosizedTextarea):
"""

def render(self, name, value, attrs=None, renderer=None):
output = super(CharacterCountTextarea, self).render(name, value, attrs, renderer)
output = super(CharacterCountTextarea, self).render(name, value, attrs,)
output += mark_safe(
"<script type=\"text/javascript\">django.jQuery(function () { django.jQuery('#id_%s').suitCharactersCount(); });</script>"
% name)
Expand Down Expand Up @@ -69,7 +69,7 @@ def enclose_value(self, value, wrapper_class):
return '<span class="input-group-%s">%s</span>' % (wrapper_class, value)

def render(self, name, value, attrs=None, renderer=None):
output = super(EnclosedInput, self).render(name, value, attrs, renderer)
output = super(EnclosedInput, self).render(name, value, attrs)
div_classes = set()
if self.prepend:
div_classes.add('input-group')
Expand Down

0 comments on commit d7ec7a2

Please sign in to comment.