Skip to content

Commit 2f41387

Browse files
author
Emmanouil Konstantinidis
committed
Clean up
1 parent 5ef8d63 commit 2f41387

File tree

3 files changed

+1
-27
lines changed

3 files changed

+1
-27
lines changed

demo/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ A demo project to get you started with DRF docs development.
1111
env/bin/pip install -r requirements.txt
1212

1313
# Install Django Rest Framework Docs
14-
pip install -e ../
14+
env/bin/pip install -e ../
1515

1616
# Run the project
1717
env/bin/python manage.py runserver

demo/project/accounts/models.py

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -14,22 +14,3 @@ class User(AbstractBaseUser):
1414

1515
USERNAME_FIELD = 'email'
1616
REQUIRED_FIELDS = ['email', 'full_name']
17-
18-
def __str__(self):
19-
return self.email
20-
21-
def has_perm(self, perm, obj=None):
22-
"Does the user have a specific permission?"
23-
# Simplest possible answer: Yes, always
24-
return True
25-
26-
def has_module_perms(self, app_label):
27-
"Does the user have permissions to view the app `app_label`?"
28-
# Simplest possible answer: Yes, always
29-
return True
30-
31-
@property
32-
def is_staff(self):
33-
"Is the user a member of staff?"
34-
# Simplest possible answer: All admins are staff
35-
return self.is_admin

demo/project/organisations/models.py

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,6 @@
55

66
class Organisation(models.Model):
77

8-
class Meta:
9-
verbose_name_plural = "Organisations"
10-
ordering = ['name']
11-
128
id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False)
139
created = models.DateTimeField(auto_now_add=True)
1410
modified = models.DateTimeField(auto_now=True)
@@ -19,9 +15,6 @@ class Meta:
1915

2016
is_active = models.BooleanField(default=False)
2117

22-
def __str__(self):
23-
return self.name
24-
2518

2619
class Membership(models.Model):
2720

0 commit comments

Comments
 (0)