Display Instance Details #50

Merged
rixx merged 17 commits from 28-instance-details into main 2025-04-17 15:04:15 +00:00
Showing only changes of commit 40811cbc08 - Show all commits

View file

@ -96,6 +96,41 @@
</div>
</div>
{% endif %}
{% if instance.spec %}
<div class="col-12">
<div class="card">
<div class="card-header">
<h4>{% translate "Specification" %}</h4>
</div>
<div class="card-body">
<div class="table-responsive">
<table class="table table-bordered">
<thead>
<tr>
<th>{% translate "Property" %}</th>
<th>{% translate "Value" %}</th>
</tr>
</thead>
<tbody>
{% for key, value in instance.spec.items %}
<tr>
<td>{{ key }}</td>
<td>
{% if value|default:""|stringformat:"s"|slice:":1" == "{" or value|default:""|stringformat:"s"|slice:":1" == "[" %}
<pre>{{ value|pprint }}</pre>
{% else %}
{{ value }}
{% endif %}
</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
</div>
</div>
{% endif %}
</div>
</section>
{% endblock content %}