1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

#8366: Misc cleanup

This commit is contained in:
jeremystretch
2022-12-12 15:27:37 -05:00
parent ad78f9e075
commit 758030733c
5 changed files with 54 additions and 23 deletions

View File

@@ -34,33 +34,32 @@
{% block content %}
<div role="tabpanel" class="tab-pane active" id="report">
{% if perms.extras.run_report %}
<div class="row">
<div class="col">
<div class="row">
<div class="col">
<form action="{% url 'extras:report' module=report.module name=report.class_name %}" method="post" class="form-object-edit">
{% csrf_token %}
{% render_form form %}
<div class="float-end">
<button type="submit" name="_run" class="btn btn-primary">
{% if report.result %}
<i class="mdi mdi-replay"></i> Run Again
{% else %}
<i class="mdi mdi-play"></i> Run Report
{% endif %}
</button>
</div>
{% csrf_token %}
{% render_form form %}
<div class="float-end">
<button type="submit" name="_run" class="btn btn-primary">
{% if report.result %}
<i class="mdi mdi-replay"></i> Run Again
{% else %}
<i class="mdi mdi-play"></i> Run Report
{% endif %}
</button>
</div>
</form>
</div>
</div>
{% endif %}
<div class="row">
<div class="col col-md-12">
{% if report.result %}
Last run: <a href="{% url 'extras:report_result' job_result_pk=report.result.pk %}">
<strong>{{ report.result.created|annotated_date }}</strong>
</a>
{% endif %}
</div>
<div class="col col-md-12">
{% if report.result %}
Last run: <a href="{% url 'extras:report_result' job_result_pk=report.result.pk %}">
<strong>{{ report.result.created|annotated_date }}</strong>
</a>
{% endif %}
</div>
</div>
</div>
{% endblock content %}