File tree Expand file tree Collapse file tree 3 files changed +1
-27
lines changed Expand file tree Collapse file tree 3 files changed +1
-27
lines changed Original file line number Diff line number Diff 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
Original file line number Diff line number Diff 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
Original file line number Diff line number Diff line change 55
66class 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
2619class Membership (models .Model ):
2720
You can’t perform that action at this time.
0 commit comments