aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Lemon <lemon@matthewlemon.com>2020-10-02 15:39:54 +0100
committerMatthew Lemon <lemon@matthewlemon.com>2020-10-02 15:39:54 +0100
commit186d34bcbb4617bccec81412cf53adcf5e47afdb (patch)
tree1b6a71a35cc520913a2ff1fa42ae49a95e0c4275
parenta38fce358643f5f8e1b2d7ec8e17342f760e16d4 (diff)
after much pain aligning badges - we have badges on CAF detail page
-rw-r--r--ctrack/caf/templates/caf/caf_detail.html59
-rw-r--r--ctrack/organisations/templates/organisations/essential_service_detail.html13
-rw-r--r--ctrack/organisations/templates/organisations/organisation_detail.html37
-rw-r--r--ctrack/templates/base.html1
4 files changed, 66 insertions, 44 deletions
diff --git a/ctrack/caf/templates/caf/caf_detail.html b/ctrack/caf/templates/caf/caf_detail.html
index bfdff0c..a52cad5 100644
--- a/ctrack/caf/templates/caf/caf_detail.html
+++ b/ctrack/caf/templates/caf/caf_detail.html
@@ -7,9 +7,12 @@
<div class="container mt-3">
<div class="row">
- <div class="col-12">
+ <div class="col-10">
<h4>{{ object }}</h4>
</div>
+ <div class="col-2">
+ <h2><span class="badge badge-info float-right m-1">{{ object.quality_grading }}</span> <span class="badge badge-secondary float-right m-1">{{ object.confidence_grading }}</span></h2>
+ </div>
</div>
<div class="row">
@@ -63,7 +66,8 @@
<div class="card bg-light">
<div class="card-body">
<div class="card-title text-muted">NIS Systems <a
- href="{% url "caf:as_create_from_caf" object.pk %}" class="btn btn-outline-primary btn-sm float-right">Add
+ href="{% url "caf:as_create_from_caf" object.pk %}"
+ class="btn btn-outline-primary btn-sm float-right">Add
new...</a></div>
<div>
<table class="table table-responsive">
@@ -93,33 +97,34 @@
<div class="col-md-12">
<div class="card bg-light">
<div class="card-body">
- <div class="card-title text-muted">CAF History <a href="#" class="btn btn-outline-primary btn-sm float-right">Add new...</a></div>
- <div class="table table-responsive">
- <table class="table">
- <thead>
- <tr>
- <th>Date</th>
- <th>Event</th>
- <th>Inspector</th>
- <th>Comments</th>
- </tr>
- </thead>
- <tbody>
- {% for event in object.get_events %}
- <tr>
- <td>{{ event.date|date:"j F Y"}}</td>
- <td>{{ event.type }}</td>
- <td>{{ event.user }}</td>
- <td>{{ event.comments }}</td>
- </tr>
- {% endfor %}
+ <div class="card-title text-muted">CAF History <a href="#" class="btn btn-outline-primary btn-sm float-right">Add
+ new...</a></div>
+ <div class="table table-responsive">
+ <table class="table">
+ <thead>
+ <tr>
+ <th>Date</th>
+ <th>Event</th>
+ <th>Inspector</th>
+ <th>Comments</th>
+ </tr>
+ </thead>
+ <tbody>
+ {% for event in object.get_events %}
+ <tr>
+ <td>{{ event.date|date:"j F Y" }}</td>
+ <td>{{ event.type }}</td>
+ <td>{{ event.user }}</td>
+ <td>{{ event.comments }}</td>
+ </tr>
+ {% endfor %}
- <tr>
+ <tr>
- </tr>
- </tbody>
- </table>
- </div>
+ </tr>
+ </tbody>
+ </table>
+ </div>
</div>
</div>
</div>
diff --git a/ctrack/organisations/templates/organisations/essential_service_detail.html b/ctrack/organisations/templates/organisations/essential_service_detail.html
index d66c0da..34830ff 100644
--- a/ctrack/organisations/templates/organisations/essential_service_detail.html
+++ b/ctrack/organisations/templates/organisations/essential_service_detail.html
@@ -14,17 +14,22 @@
<h3>{{ es.name }}</h3>
</div>
</div>
+ <div class="row">
+ <div class="col-12 bg bg-light">
+ <h2>{{ es.organisation }}</h2>
+ </div>
+ </div>
</div>
</div>
<div class="row">
- <div class="col-sm-6 pl-0 my-2">
+ <div class="col-sm-12 pl-0 my-2">
<h5>Description of Service</h5>
<hr>
- <p>{{ es.description }}</p>
+ <p>{{ es.description }}</p>
</div>
</div>
<div class="row">
- <div class="col-sm-6 pl-0 my-2">
+ <div class="col-sm-12 pl-0 my-2">
<h5>Systems which support this service</h5>
<ul class="list-group list-group-flush">
{% for ass in asses %}
@@ -34,7 +39,7 @@
</div>
</div>
<div class="row">
- <div class="col-sm-6 pl-0 my-2">
+ <div class="col-sm-12 pl-0 my-2">
<h5>CAFs which apply to this Service</h5>
<ul class="list-group list-group-flush">
{% for caf in cafs %}
diff --git a/ctrack/organisations/templates/organisations/organisation_detail.html b/ctrack/organisations/templates/organisations/organisation_detail.html
index 492bd31..5cf96f1 100644
--- a/ctrack/organisations/templates/organisations/organisation_detail.html
+++ b/ctrack/organisations/templates/organisations/organisation_detail.html
@@ -10,24 +10,30 @@
<div class="col-sm-12 pl-0 my-2">
<div class="row" id="organisation-title">
<div class="col-12">
- <h4>{{ object.name }}</h4>
+ {% if object.oes %}
+ <h4>{{ object.name }} | <span class="text-muted">{{ object.submode }}</span> <span
+ class="badge badge-success float-right">OES</span></h4>
+ {% else %}
+ <h4>{{ object.name }} | <span class="text-muted">{{ object.submode }}</span> <span
+ class="badge badge-secondary float-right">NOT OES</span></h4>
+ {% endif %}
</div>
</div>
<div class="row">
- <div class="col-12">
- <h6>{{ object.submode }}</h6>
+ <div class="col-3 text-muted">
+ Last updated: {{ object.date_updated|date:"j M Y" }}
</div>
</div>
<div class="row" id="top-row">
- <div class="col-md-6">
+ <div class="col-md-12 my-2">
<div class="card bg-light">
<div class="card-body">
<div class="card-title" style="font-size: 1.1rem;">Company Information</div>
<div class="card-text">
<div>
- <table class="table table-sm table-bordered">
+ <table class="table table-bordered">
<tr>
<td class="w-25"><strong>Designation Type:</strong></td>
<td>{{ object.designation_type }}</td>
@@ -67,14 +73,14 @@
</div>
</div>
- <div class="col-md-6">
+ <div class="col-md-12 mb-2">
<div class="row pb-2">
<div class="col-sm">
<div class="card bg-light">
<div class="card-body">
<div class="card-title" style="font-size: 1.1rem;">Essential Services</div>
- <table class="table table-sm table-bordered">
+ <table class="table table-bordered">
{% if applicable_systems|length > 0 %}
{% for es in essential_services %}
<tr>
@@ -104,7 +110,7 @@
new...</a>
</div>
<div class="table">
- <table class="table table-sm table-bordered">
+ <table class="table table-bordered">
{% if applicable_systems|length > 0 %}
{% for ass in applicable_systems %}
<tr>
@@ -134,9 +140,11 @@
<div class="col-md-12 my-2">
<div class="card bg-light">
<div class="card-body">
- <div class="card-title" style="font-size: 1.1rem;">CAFs <a href="#" class="btn btn-outline-primary btn-sm float-right">Add new...</a></div>
+ <div class="card-title" style="font-size: 1.1rem;">CAFs <a href="#"
+ class="btn btn-outline-primary btn-sm float-right">Add
+ new...</a></div>
<div class="table-responsive">
- <table class="table table-sm table-bordered">
+ <table class="table table-sm table-striped table-bordered">
<thead>
<tr>
<th>Version</th>
@@ -200,9 +208,10 @@
<div class="card-body">
<div class="card-title" style="font-size: 1.1rem;">
Engagements & Compliance Events
- <a href="{% url "register:create" object.slug %}" class="btn btn-outline-primary btn-sm float-right">Add new...</a></div>
+ <a href="{% url "register:create" object.slug %}" class="btn btn-outline-primary btn-sm float-right">Add
+ new...</a></div>
<div class="table table-responsive">
- <table class="table table-sm table-bordered">
+ <table class="table table-sm table-striped table-bordered">
<thead>
<tr>
<th>Date</th>
@@ -239,7 +248,9 @@
<td>NA</td>
{% endif %}
{% endif %}
- <td><a class="btn btn-sm btn-outline-primary" href="#" role="button">Edit</a> <a href="{% url "register:ee_delete" event.pk object.slug %}" class="btn btn-sm btn-outline-danger" role="button">Delete</a></td>
+ <td><a class="badge badge-success" href="#" role="button">Edit</a> <a
+ href="{% url "register:ee_delete" event.pk object.slug %}" class="badge badge-danger"
+ role="button">Delete</a></td>
</tr>
{% endfor %}
{% endif %}
diff --git a/ctrack/templates/base.html b/ctrack/templates/base.html
index 1ac77b5..40d6e5e 100644
--- a/ctrack/templates/base.html
+++ b/ctrack/templates/base.html
@@ -27,6 +27,7 @@
<link href="{% static 'css/project.css' %}" rel="stylesheet">
{# <link rel="stylesheet" type="text/css" href="css/DataTables/datatables.min.css"/>#}
+{# <link rel="stylesheet" type="text/css" href="{{ STATIC_URL }}/css/bootstrap.css" />#}
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/v/dt/dt-1.10.20/af-2.3.4/b-1.6.1/b-print-1.6.1/cr-1.5.2/r-2.2.3/datatables.min.css"/>
{% endblock %}