mirror of
https://github.com/django/django.git
synced 2025-07-04 09:49:12 +00:00
newforms-admin: Fixed a bug in ManyToManyRawIdWidget where a list of integers needed to be converted to a comma separated string for display.
git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@6323 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
3534c4cf39
commit
709f801877
@ -99,7 +99,7 @@ class ManyToManyRawIdWidget(ForeignKeyRawIdWidget):
|
||||
def render(self, name, value, attrs=None):
|
||||
attrs['class'] = 'vManyToManyRawIdAdminField'
|
||||
if value:
|
||||
value = ','.join(value)
|
||||
value = ','.join([str(v) for v in value])
|
||||
else:
|
||||
value = ""
|
||||
return super(ManyToManyRawIdWidget, self).render(name, value, attrs)
|
||||
|
Loading…
x
Reference in New Issue
Block a user