X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/362ea2e7f8ac4254398791139cc060090199f400..e63f03c5b943370167ab71beddb83dd22df0ba17:/apps/sponsors/widgets.py?ds=sidebyside diff --git a/apps/sponsors/widgets.py b/apps/sponsors/widgets.py index 72aaf0a83..ed06ba641 100644 --- a/apps/sponsors/widgets.py +++ b/apps/sponsors/widgets.py @@ -19,8 +19,8 @@ class SponsorPageWidget(forms.Textarea): def render(self, name, value, attrs=None): output = [super(SponsorPageWidget, self).render(name, value, attrs)] - sponsors = [(unicode(obj), obj.pk) for obj in models.Sponsor.objects.all()] - sponsors_js = ', '.join('{name: "%s", id: %d}' % sponsor for sponsor in sponsors) + sponsors = [(unicode(obj), obj.pk, obj.logo.thumbnail) for obj in models.Sponsor.objects.all()] + sponsors_js = ', '.join('{name: "%s", id: %d, image: "%s"}' % sponsor for sponsor in sponsors) output.append(u'