1
0
mirror of https://github.com/django/django.git synced 2025-10-24 14:16:09 +00:00

[1.5.x] Fixed #17911 -- Ensure that admin readonly fields' display values are shown in change forms when the raw value is None.

Backport of 29d59a879e
This commit is contained in:
Edward Tjörnhammar
2012-11-25 23:13:22 +01:00
committed by Julien Phalip
parent 22ca5bab95
commit 7c91b67cfa
4 changed files with 23 additions and 5 deletions

View File

@@ -660,3 +660,7 @@ class Simple(models.Model):
"""
Simple model with nothing on it for use in testing
"""
class Choice(models.Model):
choice = models.CharField(max_length=1, blank=True, null=True,
choices=(('y','Yes'), ('n','No'), (None, 'No opinion')))