mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
* Introduce the isodate(), isotime(), and isodatetime() template filters * Display the relative time on mouse hover * Render journal entry times in ISO 8601 format * Use ISO 8601 format when displaying dates & times in a table * Standardize the use of DateTimeColumn across all tables
86 lines
2.6 KiB
HTML
86 lines
2.6 KiB
HTML
{% extends 'generic/object.html' %}
|
|
{% load buttons %}
|
|
{% load helpers %}
|
|
{% load perms %}
|
|
{% load i18n %}
|
|
|
|
{% block control-buttons %}
|
|
{% if request.user|can_delete:object %}
|
|
{% delete_button object %}
|
|
{% endif %}
|
|
{% endblock control-buttons %}
|
|
|
|
{% block content %}
|
|
<div class="row mb-3">
|
|
<div class="col col-md-6">
|
|
<div class="card">
|
|
<h5 class="card-header">{% trans "Job" %}</h5>
|
|
<table class="table table-hover attr-table">
|
|
<tr>
|
|
<th scope="row">{% trans "Object Type" %}</th>
|
|
<td>
|
|
<a href="{% url 'core:job_list' %}?object_type={{ object.object_type_id }}">{{ object.object_type }}</a>
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">{% trans "Name" %}</th>
|
|
<td>{{ object.name|placeholder }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">{% trans "Status" %}</th>
|
|
<td>{% badge object.get_status_display object.get_status_color %}</td>
|
|
</tr>
|
|
{% if object.error %}
|
|
<tr>
|
|
<th scope="row">{% trans "Error" %}</th>
|
|
<td>{{ object.error }}</td>
|
|
</tr>
|
|
{% endif %}
|
|
<tr>
|
|
<th scope="row">{% trans "Created By" %}</th>
|
|
<td>{{ object.user|placeholder }}</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="col col-md-6">
|
|
<div class="card">
|
|
<h5 class="card-header">{% trans "Scheduling" %}</h5>
|
|
<table class="table table-hover attr-table">
|
|
<tr>
|
|
<th scope="row">{% trans "Created" %}</th>
|
|
<td>{{ object.created|isodatetime }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">{% trans "Scheduled" %}</th>
|
|
<td>
|
|
{{ object.scheduled|isodatetime|placeholder }}
|
|
{% if object.interval %}
|
|
({% blocktrans with interval=object.interval %}every {{ interval }} minutes{% endblocktrans %})
|
|
{% endif %}
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">{% trans "Started" %}</th>
|
|
<td>{{ object.started|isodatetime|placeholder }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th scope="row">{% trans "Completed" %}</th>
|
|
<td>{{ object.completed|isodatetime|placeholder }}</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col col-12">
|
|
<div class="card">
|
|
<h5 class="card-header">{% trans "Data" %}</h5>
|
|
<div class="card-body">
|
|
<pre>{{ object.data|json }}</pre>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|