diff options
author | Matthew Lemon <matt@matthewlemon.com> | 2020-03-06 22:43:55 +0000 |
---|---|---|
committer | Matthew Lemon <matt@matthewlemon.com> | 2020-03-06 22:43:55 +0000 |
commit | a6afdd43f465099a8b77d72102bf44851b6960e1 (patch) | |
tree | 41677b63f66d3ecb01d24e39501de4fc3060ba64 | |
parent | 77a956b4cbf42c47dee6d5430db8c3a479e6625d (diff) |
working through formatting org page
-rw-r--r-- | ctrack/organisations/templates/organisations/organisation_detail.html | 55 | ||||
-rw-r--r-- | ctrack/organisations/views.py | 2 |
2 files changed, 55 insertions, 2 deletions
diff --git a/ctrack/organisations/templates/organisations/organisation_detail.html b/ctrack/organisations/templates/organisations/organisation_detail.html index d28723f..9dde56e 100644 --- a/ctrack/organisations/templates/organisations/organisation_detail.html +++ b/ctrack/organisations/templates/organisations/organisation_detail.html @@ -2,10 +2,61 @@ {% block content %} <div class="container"> + <div class="row"> <h2>{{ object.name }}</h2> </div> - <div class="row"> - <p>{{ object.submode }}</p> + + <div class="row text-muted"> + <p>{{ object.submode }}</p> + </div> + + <div class="row pt-3 text-info"> + <h4>Addresses</h4> + </div> + + <div class="row pl-3 pt-2 border rounded bg-light"> + <p>Address 1<br> + Address 2<br> + Address 3<br> + Address 4<br></p> + </div> + + <div class="row pt-3 text-info"> + <h4>People</h4> + </div> + + <div class="row pl-3 pt-2 border rounded bg-light"> + <div class="col"> + {% for p in people %} + <div class="row"> + <ul class="list-unstyled"> + <h4>{{ p.first_name }} {{ p.last_name }}</h4> + <table class="table-bordered"> + <tr> + <td>Primary NIS Contact:</td> + <td>{{ p.primary_nis_contact }}</td> + </tr> + <tr> + <td>Job Title:</td> + <td>{{ p.job_title }}</td> + </tr> + <tr> + <td>Email:</td> + <td><a href="mailto:{{ p.email }}">{{ p.email }}</a></td> + </tr> + <tr> + <td>Mobile:</td> + <td>{{ p.mobile }}</td> + </tr> + </table> + <li>{{ p.landline }}</li> + <li>Clearance: {{ p.clearance }}</li> + <li>Clearance Expiry: {{ p.clearance_expiry }}</li> + </ul> + </div> + {% endfor %} + </div> + </div> </div> {% endblock %} diff --git a/ctrack/organisations/views.py b/ctrack/organisations/views.py index 84f30c4..361fcf2 100644 --- a/ctrack/organisations/views.py +++ b/ctrack/organisations/views.py @@ -24,4 +24,6 @@ class OrganisationDetailView(LoginRequiredMixin, DetailView): context['no_addr'] = 1 addr = org.addresses.first() context['addr'] = addr + people = org.person_set.all() + context['people'] = people return context |