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:
@@ -4,14 +4,12 @@ Tests for the order_with_respect_to Meta attribute.
|
||||
|
||||
from django.db import models
|
||||
from django.utils import six
|
||||
from django.utils.encoding import python_2_unicode_compatible
|
||||
|
||||
|
||||
class Question(models.Model):
|
||||
text = models.CharField(max_length=200)
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Answer(models.Model):
|
||||
text = models.CharField(max_length=200)
|
||||
question = models.ForeignKey(Question, models.CASCADE)
|
||||
@@ -23,7 +21,6 @@ class Answer(models.Model):
|
||||
return six.text_type(self.text)
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Post(models.Model):
|
||||
title = models.CharField(max_length=200)
|
||||
parent = models.ForeignKey("self", models.SET_NULL, related_name="children", null=True)
|
||||
|
||||
Reference in New Issue
Block a user