diff --git a/biz/models.py b/biz/models.py index b4eb180..9eb0410 100644 --- a/biz/models.py +++ b/biz/models.py @@ -89,6 +89,12 @@ class Prospect(BaseModel): return last_activity.status return Status.NONE + def current_activity_type(self): + last_activity = self.activities.exclude(status=None).order_by('-creation_date').first() + if last_activity: + return last_activity.type + return None + def current_text(self): last_activity = self.activities.exclude(status=None).order_by('-creation_date').first() if last_activity: diff --git a/biz/templates/admin/biz/dashboard.html b/biz/templates/admin/biz/dashboard.html index 2ba1ab1..f79cc1c 100644 --- a/biz/templates/admin/biz/dashboard.html +++ b/biz/templates/admin/biz/dashboard.html @@ -58,6 +58,7 @@ .prospect-table { width: 100%; border-collapse: collapse; + table-layout: fixed; } .prospect-table thead { @@ -74,6 +75,36 @@ border-bottom: 1px solid #ddd; } + .prospect-table th:nth-child(1), + .prospect-table td:nth-child(1) { + width: 150px; + } + + .prospect-table th:nth-child(2), + .prospect-table td:nth-child(2) { + width: auto; + } + + .prospect-table th:nth-child(3), + .prospect-table td:nth-child(3) { + width: 120px; + } + + .prospect-table th:nth-child(4), + .prospect-table td:nth-child(4) { + width: 140px; + } + + .prospect-table th:nth-child(5), + .prospect-table td:nth-child(5) { + width: 130px; + } + + .prospect-table th:nth-child(6), + .prospect-table td:nth-child(6) { + width: 130px; + } + .prospect-table tbody tr { border-bottom: 1px solid #eee; transition: background-color 0.2s; @@ -104,6 +135,8 @@ .prospect-entity { color: #666; font-style: italic; + overflow: hidden; + text-overflow: ellipsis; } .prospect-date { @@ -153,6 +186,7 @@