mirror of
https://github.com/django/django.git
synced 2025-08-04 02:48:35 +00:00
Removed unused __str__() methods in tests models.
Co-Authored-By: Mariusz Felisiak <felisiak.mariusz@gmail.com> Co-Authored-By: Hasan Ramezani <hasan.r67@gmail.com>
This commit is contained in:
parent
f1a808a502
commit
6461583b6c
20 changed files with 0 additions and 150 deletions
|
@ -9,9 +9,6 @@ class Article(models.Model):
|
|||
|
||||
categories = models.ManyToManyField("Category", related_name="articles")
|
||||
|
||||
def __str__(self):
|
||||
return self.title
|
||||
|
||||
|
||||
class Comment(models.Model):
|
||||
article = models.ForeignKey(Article, models.CASCADE, related_name="comments")
|
||||
|
@ -19,9 +16,6 @@ class Comment(models.Model):
|
|||
pub_date = models.DateField()
|
||||
approval_date = models.DateField(null=True)
|
||||
|
||||
def __str__(self):
|
||||
return 'Comment to %s (%s)' % (self.article.title, self.pub_date)
|
||||
|
||||
|
||||
class Category(models.Model):
|
||||
name = models.CharField(max_length=255)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue