mirror of
https://github.com/django/django.git
synced 2025-12-04 00:55:36 +00:00
Fixed #23395 -- Limited line lengths to 119 characters.
This commit is contained in:
parent
84b0a8d2aa
commit
b1e33ceced
130 changed files with 5259 additions and 1501 deletions
|
|
@ -21,7 +21,11 @@ class Group(models.Model):
|
|||
name = models.CharField(max_length=128)
|
||||
members = models.ManyToManyField(Person, through='Membership')
|
||||
custom_members = models.ManyToManyField(Person, through='CustomMembership', related_name="custom")
|
||||
nodefaultsnonulls = models.ManyToManyField(Person, through='TestNoDefaultsOrNulls', related_name="testnodefaultsnonulls")
|
||||
nodefaultsnonulls = models.ManyToManyField(
|
||||
Person,
|
||||
through='TestNoDefaultsOrNulls',
|
||||
related_name="testnodefaultsnonulls",
|
||||
)
|
||||
|
||||
class Meta:
|
||||
ordering = ('name',)
|
||||
|
|
@ -88,7 +92,11 @@ class Friendship(models.Model):
|
|||
@python_2_unicode_compatible
|
||||
class Event(models.Model):
|
||||
title = models.CharField(max_length=50)
|
||||
invitees = models.ManyToManyField(Person, through='Invitation', through_fields=('event', 'invitee'), related_name='events_invited')
|
||||
invitees = models.ManyToManyField(
|
||||
Person, through='Invitation',
|
||||
through_fields=('event', 'invitee'),
|
||||
related_name='events_invited',
|
||||
)
|
||||
|
||||
def __str__(self):
|
||||
return self.title
|
||||
|
|
@ -104,7 +112,12 @@ class Invitation(models.Model):
|
|||
@python_2_unicode_compatible
|
||||
class Employee(models.Model):
|
||||
name = models.CharField(max_length=5)
|
||||
subordinates = models.ManyToManyField('self', through="Relationship", through_fields=('source', 'target'), symmetrical=False)
|
||||
subordinates = models.ManyToManyField(
|
||||
'self',
|
||||
through="Relationship",
|
||||
through_fields=('source', 'target'),
|
||||
symmetrical=False,
|
||||
)
|
||||
|
||||
class Meta:
|
||||
ordering = ('pk',)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue