paperwork: Only return a list name for departments with the flag
This commit is contained in:
parent
bb0e5abad5
commit
86000be17b
@ -72,7 +72,10 @@ class Department(models.Model):
|
|||||||
|
|
||||||
@property
|
@property
|
||||||
def list_name(self):
|
def list_name(self):
|
||||||
|
if self.has_mailing_list:
|
||||||
return self.name.replace(" ", "_") + "-info"
|
return self.name.replace(" ", "_") + "-info"
|
||||||
|
else:
|
||||||
|
return None
|
||||||
|
|
||||||
|
|
||||||
class CertificationDefinition(models.Model):
|
class CertificationDefinition(models.Model):
|
||||||
|
Loading…
Reference in New Issue
Block a user