PEP fixes for /company

This commit is contained in:
Oliver Walters 2019-04-14 09:30:45 +10:00
parent b9f23554a5
commit ac3a4e3de4
3 changed files with 3 additions and 2 deletions

View File

@ -31,4 +31,4 @@ class CompanyImageForm(HelperForm):
model = Company
fields = [
'image'
]
]

View File

@ -78,4 +78,4 @@ class Contact(models.Model):
role = models.CharField(max_length=100, blank=True)
company = models.ForeignKey(Company, related_name='contacts',
on_delete = models.CASCADE)
on_delete=models.CASCADE)

View File

@ -15,6 +15,7 @@ class CompanyBriefSerializer(serializers.ModelSerializer):
'name'
]
class CompanySerializer(serializers.ModelSerializer):
url = serializers.CharField(source='get_absolute_url', read_only=True)