mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-17 20:46:30 -06:00
Move device/VM component tables outside of cards
This commit is contained in:
parent
dc8adfc546
commit
23be5694d0
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Console Ports</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DeviceConsolePortTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table consoleport_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_consoleport %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:consoleport_bulk_rename' %}?return_url={% url 'dcim:device_consoleports' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -44,8 +38,7 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=consoleport_table.paginator page=consoleport_table.page %}
|
||||
{% table_config_form consoleport_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=consoleport_table.paginator page=consoleport_table.page %}
|
||||
{% table_config_form consoleport_table %}
|
||||
{% endblock %}
|
||||
|
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Console Server Ports</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DeviceConsoleServerPortTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table consoleserverport_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_consoleserverport %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:consoleserverport_bulk_rename' %}?return_url={% url 'dcim:device_consoleserverports' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -44,8 +38,7 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=consoleserverport_table.paginator page=consoleserverport_table.page %}
|
||||
{% table_config_form consoleserverport_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=consoleserverport_table.paginator page=consoleserverport_table.page %}
|
||||
{% table_config_form consoleserverport_table %}
|
||||
{% endblock %}
|
||||
|
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Device Bays</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DeviceDeviceBayTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table devicebay_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_devicebay %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:devicebay_bulk_rename' %}?return_url={{ object.get_absolute_url }}%23tab_devicebays" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -41,8 +35,7 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=devicebay_table.paginator page=devicebay_table.page %}
|
||||
{% table_config_form devicebay_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=devicebay_table.paginator page=devicebay_table.page %}
|
||||
{% table_config_form devicebay_table %}
|
||||
{% endblock %}
|
||||
|
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5>Front Ports</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DeviceFrontPortTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table frontport_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_frontport %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:frontport_bulk_rename' %}?return_url={% url 'dcim:device_frontports' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -44,8 +38,7 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=frontport_table.paginator page=frontport_table.page %}
|
||||
{% table_config_form frontport_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=frontport_table.paginator page=frontport_table.page %}
|
||||
{% table_config_form frontport_table %}
|
||||
{% endblock %}
|
||||
|
@ -4,11 +4,8 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Interfaces</h5>
|
||||
<div class="float-end col-md-4 noprint table-controls mw-33">
|
||||
<div class="input-group input-group-sm">
|
||||
<input type="text" class="form-control interface-filter" placeholder="Filter" title="Filter text (regular expressions supported)" />
|
||||
@ -31,11 +28,8 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table interface_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_interface %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:interface_bulk_rename' %}?return_url={% url 'dcim:device_interfaces' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -61,8 +55,7 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=interface_table.paginator page=interface_table.page %}
|
||||
{% table_config_form interface_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=interface_table.paginator page=interface_table.page %}
|
||||
{% table_config_form interface_table %}
|
||||
{% endblock %}
|
||||
|
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Inventory Items</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DeviceInventoryItemTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table inventoryitem_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_inventoryitem %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:inventoryitem_bulk_rename' %}?return_url={% url 'dcim:device_inventory' pk=object.pk %}" class="btn btn-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -40,9 +34,7 @@
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=inventoryitem_table.paginator page=inventoryitem_table.page %}
|
||||
{% table_config_form inventoryitem_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=inventoryitem_table.paginator page=inventoryitem_table.page %}
|
||||
{% table_config_form inventoryitem_table %}
|
||||
{% endblock %}
|
||||
|
||||
|
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Power Outlets</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DevicePowerOutletTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table poweroutlet_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_powerport %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:poweroutlet_bulk_rename' %}?return_url={% url 'dcim:device_poweroutlets' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -44,8 +38,7 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=poweroutlet_table.paginator page=poweroutlet_table.page %}
|
||||
{% table_config_form poweroutlet_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=poweroutlet_table.paginator page=poweroutlet_table.page %}
|
||||
{% table_config_form poweroutlet_table %}
|
||||
{% endblock %}
|
||||
|
@ -4,21 +4,15 @@
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5 class="d-inline">Power Ports</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DevicePowerPortTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table powerport_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_powerport %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:powerport_bulk_rename' %}?return_url={% url 'dcim:device_powerports' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -42,9 +36,9 @@
|
||||
</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=powerport_table.paginator page=powerport_table.page %}
|
||||
{% table_config_form powerport_table %}
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=powerport_table.paginator page=powerport_table.page %}
|
||||
{% table_config_form powerport_table %}
|
||||
{% endblock %}
|
||||
|
@ -6,19 +6,13 @@
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h5>Rear Ports</h5>
|
||||
<div class="float-end noprint">
|
||||
{% if request.user.is_authenticated %}
|
||||
<button type="button" class="btn btn-outline-dark btn-sm" data-bs-toggle="modal" data-bs-target="#DeviceRearPortTable_config" title="Configure table"><i class="mdi mdi-cog"></i> Configure</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table rearport_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.dcim.change_rearport %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'dcim:rearport_bulk_rename' %}?return_url={% url 'dcim:device_rearports' pk=object.pk %}" class="btn btn-outline-warning btn-sm">
|
||||
<i class="mdi mdi-pencil-outline" aria-hidden="true"></i> Rename
|
||||
@ -44,7 +38,6 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% include 'inc/paginator.html' with paginator=rearport_table.paginator page=rearport_table.page %}
|
||||
{% table_config_form rearport_table %}
|
||||
|
@ -17,8 +17,7 @@
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
{% block tabs %}
|
||||
<ul class="nav nav-tabs">
|
||||
{% block tab_items %}
|
||||
<li class="nav-item" role="presentation">
|
||||
<a class="nav-link{% if not active_tab %} active{% endif %}" href="{{ object.get_absolute_url }}">Virtual Machine</a>
|
||||
</li>
|
||||
@ -34,15 +33,4 @@
|
||||
<a class="nav-link{% if active_tab == 'config-context' %} active{% endif %}" href="{% url 'virtualization:virtualmachine_configcontext' pk=object.pk %}">Config Context</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if perms.extras.view_journalentry %}
|
||||
<li class="nav-item" role="presentation">
|
||||
<a class="nav-link{% if active_tab == 'journal' %} active{% endif %}" href="{% url 'virtualization:virtualmachine_journal' pk=object.pk %}">Journal</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
{% if perms.extras.view_objectchange %}
|
||||
<li class="nav-item" role="presentation">
|
||||
<a class="nav-link{% if active_tab == 'changelog' %} active{% endif %}" href="{% url 'virtualization:virtualmachine_changelog' pk=object.pk %}">Change Log</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
{% endblock %}
|
||||
|
@ -6,10 +6,7 @@
|
||||
{% block content %}
|
||||
<form method="post">
|
||||
{% csrf_token %}
|
||||
<div class="card my-3">
|
||||
<div class="card-header">
|
||||
<h5>Interfaces</h5>
|
||||
<div class="float-end col-md-2 noprint table-controls">
|
||||
<div class="float-end col-md-4 noprint table-controls mw-33">
|
||||
<div class="input-group input-group-sm">
|
||||
<input type="text" class="form-control interface-filter" placeholder="Filter" title="Filter text (regular expressions supported)" />
|
||||
{% if request.user.is_authenticated %}
|
||||
@ -17,11 +14,8 @@
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{% render_table interface_table 'inc/table.html' %}
|
||||
</div>
|
||||
<div class="card-footer noprint">
|
||||
<div class="noprint">
|
||||
{% if perms.virtualization.change_vminterface %}
|
||||
<button type="submit" name="_rename" formaction="{% url 'virtualization:vminterface_bulk_rename' %}?return_url={% url 'virtualization:virtualmachine_interfaces' pk=object.pk %}" class="btn btn-warning btn-sm">
|
||||
<span class="mdi mdi-pencil" aria-hidden="true"></span> Rename
|
||||
@ -44,7 +38,6 @@
|
||||
{% endif %}
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{% table_config_form interface_table %}
|
||||
{% endblock %}
|
||||
|
Loading…
Reference in New Issue
Block a user