Template cleanup

This commit is contained in:
jeremystretch 2023-03-24 15:57:48 -04:00
parent 87442f2a4f
commit 0d0e91102d
5 changed files with 5 additions and 26 deletions

View File

@ -12,7 +12,7 @@
{% if result.completed %}
Duration: <strong>{{ result.duration }}</strong>
{% endif %}
<span id="pending-result-label">{% include 'extras/inc/job_label.html' %}</span>
<span id="pending-result-label">{% badge result.get_status_display result.get_status_color %}</span>
</p>
{% if result.completed %}
<div class="card">

View File

@ -13,7 +13,7 @@
{% if result.completed %}
Duration: <strong>{{ result.duration }}</strong>
{% endif %}
<span id="pending-result-label">{% include 'extras/inc/job_label.html' %}</span>
<span id="pending-result-label">{% badge result.get_status_display result.get_status_color %}</span>
</p>
{% if result.completed %}
<div class="card mb-3">

View File

@ -1,15 +0,0 @@
{% if result.status == 'failed' %}
<span class="badge bg-danger">Failed</span>
{% elif result.status == 'errored' %}
<span class="badge bg-danger">Errored</span>
{% elif result.status == 'pending' %}
<span class="badge bg-info">Pending</span>
{% elif result.status == 'scheduled' %}
<span class="badge bg-info">Scheduled</span>
{% elif result.status == 'running' %}
<span class="badge bg-warning">Running</span>
{% elif result.status == 'completed' %}
<span class="badge bg-success">Completed</span>
{% else %}
<span class="badge bg-secondary">N/A</span>
{% endif %}

View File

@ -37,14 +37,14 @@
<i class="mdi mdi-file-document-outline"></i> {{ module.name|bettertitle }}
</h5>
<div class="card-body">
{% include 'inc/sync_warning.html' with object=module %}
<table class="table table-hover table-headings reports">
<thead>
<tr>
<th width="250">Name</th>
<th width="110">Status</th>
<th>Description</th>
<th>Last Run</th>
<th>Last Status</th>
<th>Status</th>
<th width="120"></th>
</tr>
</thead>
@ -55,9 +55,6 @@
<td>
<a href="{% url 'extras:report' module=report.module name=report.class_name %}" id="{{ report.module }}.{{ report.class_name }}">{{ report.name }}</a>
</td>
<td>
{% include 'extras/inc/job_label.html' with result=report.result %}
</td>
<td>{{ report.description|markdown|placeholder }}</td>
{% if last_result %}
<td>

View File

@ -36,11 +36,11 @@
<i class="mdi mdi-file-document-outline"></i> {{ module.name|bettertitle }}
</h5>
<div class="card-body">
{% include 'inc/sync_warning.html' with object=module %}
<table class="table table-hover table-headings reports">
<thead>
<tr>
<th width="250">Name</th>
<th width="110">Status</th>
<th>Description</th>
<th>Last Run</th>
<th class="text-end">Status</th>
@ -53,9 +53,6 @@
<td>
<a href="{% url 'extras:script' module=script_class.root_module name=script_name %}" name="script.{{ script_name }}">{{ script_class.name }}</a>
</td>
<td>
{% include 'extras/inc/job_label.html' with result=script_class.result %}
</td>
<td>
{{ script_class.Meta.description|markdown|placeholder }}
</td>