diff options
Diffstat (limited to 'tests/update_only_fields/models.py')
| -rw-r--r-- | tests/update_only_fields/models.py | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/update_only_fields/models.py b/tests/update_only_fields/models.py index b7100398cd..3bba684d21 100644 --- a/tests/update_only_fields/models.py +++ b/tests/update_only_fields/models.py @@ -22,9 +22,19 @@ class Employee(Person): accounts = models.ManyToManyField('Account', related_name='employees', blank=True) +class NonConcreteField(models.IntegerField): + def db_type(self, connection): + return None + + def get_attname_column(self): + attname, _ = super().get_attname_column() + return attname, None + + class Profile(models.Model): name = models.CharField(max_length=200) salary = models.FloatField(default=1000.0) + non_concrete = NonConcreteField() class ProxyEmployee(Employee): |
