mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
Refs #23919 -- Removed python_2_unicode_compatible decorator usage
This commit is contained in:
@@ -2,10 +2,8 @@
|
||||
Testing signals before/after saving and deleting.
|
||||
"""
|
||||
from django.db import models
|
||||
from django.utils.encoding import python_2_unicode_compatible
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Person(models.Model):
|
||||
first_name = models.CharField(max_length=20)
|
||||
last_name = models.CharField(max_length=20)
|
||||
@@ -14,7 +12,6 @@ class Person(models.Model):
|
||||
return "%s %s" % (self.first_name, self.last_name)
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Car(models.Model):
|
||||
make = models.CharField(max_length=20)
|
||||
model = models.CharField(max_length=20)
|
||||
@@ -23,7 +20,6 @@ class Car(models.Model):
|
||||
return "%s %s" % (self.make, self.model)
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Author(models.Model):
|
||||
name = models.CharField(max_length=20)
|
||||
|
||||
@@ -31,7 +27,6 @@ class Author(models.Model):
|
||||
return self.name
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Book(models.Model):
|
||||
name = models.CharField(max_length=20)
|
||||
authors = models.ManyToManyField(Author)
|
||||
|
||||
Reference in New Issue
Block a user