mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-17 12:42:52 -06:00
Update template script_result.html adding a download button to trigger
output download in ScriptResultView.get
This commit is contained in:
parent
5f47ba4fb2
commit
5d71a4e3e2
@ -53,7 +53,16 @@
|
|||||||
{# Script output. Legacy reports will not have this. #}
|
{# Script output. Legacy reports will not have this. #}
|
||||||
{% if 'output' in job.data %}
|
{% if 'output' in job.data %}
|
||||||
<div class="card mb-3">
|
<div class="card mb-3">
|
||||||
<h2 class="card-header">{% trans "Output" %}</h2>
|
<h2 class="card-header d-flex justify-content-between">
|
||||||
|
{% trans "Output" %}
|
||||||
|
{% if job.completed %}
|
||||||
|
<div>
|
||||||
|
<a href="?export=output" class="btn btn-primary lh-1" role="button">
|
||||||
|
<i class="mdi mdi-download" aria-hidden="true"></i> {% trans "Download" %}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
</h2>
|
||||||
{% if job.data.output %}
|
{% if job.data.output %}
|
||||||
<pre class="card-body font-monospace">{{ job.data.output }}</pre>
|
<pre class="card-body font-monospace">{{ job.data.output }}</pre>
|
||||||
{% else %}
|
{% else %}
|
||||||
|
Loading…
Reference in New Issue
Block a user