mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Fixed #14370 -- Allowed using a Select2 widget for ForeignKey and ManyToManyField in the admin.
Thanks Florian Apolloner and Tim Graham for review and contributing to the patch.
This commit is contained in:
committed by
Tim Graham
parent
01a294f8f0
commit
94cd8efc50
@@ -27,6 +27,7 @@ class Band(models.Model):
|
||||
|
||||
class Album(models.Model):
|
||||
band = models.ForeignKey(Band, models.CASCADE)
|
||||
featuring = models.ManyToManyField(Band, related_name='featured')
|
||||
name = models.CharField(max_length=100)
|
||||
cover_art = models.FileField(upload_to='albums')
|
||||
backside_art = MyFileField(upload_to='albums_back', null=True)
|
||||
|
||||
Reference in New Issue
Block a user