rework to prevent dup loading

This commit is contained in:
tbotnz 2025-05-21 12:05:17 +12:00 committed by Jason Novinger
parent ffacced2b1
commit e73127b390

View File

@ -1,10 +1,10 @@
{% load i18n %}
<div style="margin-left: -30px">
<div
hx-get="{% url 'dcim-api:rack-elevation' pk=object.pk %}?face={{ face }}&render=svg{% if extra_params %}&{{ extra_params }}{% endif %}"
hx-trigger="intersect"
hx-swap="innerHTML"
hx-swap="outerHTML"
aria-label="{% trans 'Rack elevation' %}"
style="margin-left: -30px"
>
<div class="d-flex justify-content-center align-items-center" style="min-height: 200px; margin-left: 30px;">
<div class="spinner-border" role="status">
@ -12,6 +12,7 @@
</div>
</div>
</div>
</div>
<div class="text-center mt-3">
<a class="btn btn-outline-primary" href="{% url 'dcim-api:rack-elevation' pk=object.pk %}?face={{face}}&render=svg{% if extra_params %}&{{ extra_params }}{% endif %}" hx-boost="false">
<i class="mdi mdi-file-download"></i> {% trans "Download SVG" %}