add a quick way to add a host and the OS

it might be nice to have a seperate form for both of them however this is just
much quicker to add and when I limit the hosts they will be limited here as
well. So for the moment this is good enough.
This commit is contained in:
Andreas Zweili 2020-06-28 17:17:39 +02:00
parent 3bb63bc44d
commit d08a1f0557
1 changed files with 10 additions and 4 deletions

View File

@ -28,19 +28,25 @@
<h2>Host</h2>
{% if device.host %}
<ul>
<li><a href="{% url 'computer' device.host.id %}">{{ device.host }}</a></li>
<li>
<a href="{% url 'computer' device.host.id %}">{{ device.host }}</a>
<a href="{% url 'computer_update' pk %}" class="edit" title="Edit" data-toggle="tooltip"><i class="material-icons">edit</i></a>
</li>
</ul>
{% else %}
<p><a href="{% url 'warranty_create' pk %}" class="add" title="Add" data-toggle="tooltip"><i class="material-icons">add</i></a></p>
<p><a href="{% url 'computer_update' pk %}" class="add" title="Add" data-toggle="tooltip"><i class="material-icons">add</i></a></p>
{% endif %}
<h2>Operating System</h2>
{% if device.os %}
<ul>
<li>{{ device.os }}</li>
<li>
{{ device.os }}
<a href="{% url 'computer_update' pk %}" class="edit" title="Edit" data-toggle="tooltip"><i class="material-icons">edit</i></a>
</li>
</ul>
{% else %}
<p><a href="{% url 'warranty_create' pk %}" class="add" title="Add" data-toggle="tooltip"><i class="material-icons">add</i></a></p>
<p><a href="{% url 'computer_update' pk %}" class="add" title="Add" data-toggle="tooltip"><i class="material-icons">add</i></a></p>
{% endif %}
<h2>Software</h2>