summaryrefslogtreecommitdiffstats
path: root/engagements
diff options
context:
space:
mode:
authorMatthew Lemon <y@yulqen.org>2024-10-15 14:28:30 +0100
committerMatthew Lemon <y@yulqen.org>2024-10-15 14:28:30 +0100
commita47f71efc9a7643be548f7f805e162a1942d3db4 (patch)
tree97dfb055c67ec582765658c9ccfa3ca3012caf06 /engagements
parent9015934a186b8843cc6d5ec48e41c5e2408f3fcf (diff)
More CSS improvements and wip on profile page
- uses dividers between divs which I'm not sure I like - etc
Diffstat (limited to 'engagements')
-rw-r--r--engagements/models.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/engagements/models.py b/engagements/models.py
index bb1d2bd..7aa361e 100644
--- a/engagements/models.py
+++ b/engagements/models.py
@@ -5,8 +5,6 @@ from django.db import models
from django.db.models import Q
from django.utils.text import slugify
-from myuser.models import TeamUser
-
ES_YEAR_LENGTH = 3
@@ -145,7 +143,7 @@ class Engagement(Common):
proposed_end_date = models.DateField(null=True, blank=True)
engagement_type = models.ForeignKey(EngagementType, on_delete=models.CASCADE)
external_party = models.ForeignKey(Organisation, on_delete=models.CASCADE)
- officers = models.ManyToManyField(TeamUser)
+ officers = models.ManyToManyField("myuser.TeamUser")
objects = EngagementManager()
@@ -189,6 +187,9 @@ class Engagement(Common):
dscs.add(si)
return dscs
+ def alt_str(self):
+ return f"{self.engagement_type.name} at {self.external_party}"
+
def __str__(self):
return f"{self.engagement_type.name} at {self.external_party} ({self.proposed_start_date})"