1
0
mirror of https://github.com/netbox-community/netbox.git synced 2024-05-10 07:54:54 +00:00

Merge branch 'feature' of https://github.com/netbox-community/netbox into feature

# Conflicts:
#	netbox/dcim/tables/template_code.py
#	netbox/netbox/views/__init__.py
#	netbox/project-static/css/base.css
#	netbox/templates/base.html
#	netbox/templates/circuits/circuit.html
#	netbox/templates/circuits/circuittermination_edit.html
#	netbox/templates/circuits/inc/circuit_termination.html
#	netbox/templates/circuits/provider.html
#	netbox/templates/dcim/device.html
#	netbox/templates/dcim/device/base.html
#	netbox/templates/dcim/device_component.html
#	netbox/templates/dcim/devicetype.html
#	netbox/templates/dcim/inc/device_napalm_tabs.html
#	netbox/templates/dcim/rack.html
#	netbox/templates/dcim/site.html
#	netbox/templates/dcim/virtualchassis.html
#	netbox/templates/extras/configcontext.html
#	netbox/templates/extras/object_journal.html
#	netbox/templates/extras/tag.html
#	netbox/templates/generic/object.html
#	netbox/templates/generic/object_list.html
#	netbox/templates/home.html
#	netbox/templates/inc/nav_menu.html
#	netbox/templates/ipam/aggregate.html
#	netbox/templates/ipam/ipaddress.html
#	netbox/templates/ipam/prefix.html
#	netbox/templates/ipam/vlan.html
#	netbox/templates/ipam/vlangroup_edit.html
#	netbox/templates/ipam/vlangroup_vlans.html
#	netbox/templates/secrets/secret.html
#	netbox/templates/tenancy/tenant.html
#	netbox/templates/users/api_tokens.html
#	netbox/templates/virtualization/cluster.html
#	netbox/templates/virtualization/vminterface_edit.html
#	netbox/utilities/forms/fields.py
#	netbox/utilities/templates/buttons/export.html
This commit is contained in:
checktheroads
2021-04-14 11:30:15 -07:00
256 changed files with 5928 additions and 2111 deletions

View File

@@ -0,0 +1,39 @@
{% extends 'generic/object.html' %}
{% load buttons %}
{% load helpers %}
{% load custom_links %}
{% block breadcrumbs %}
<li class="breadcrumb-item">
<a href="{% url 'ipam:prefix_list' %}">Prefixes</a>
</li>
{% if object.vrf %}
<li class="breadcrumb-item">
<a href="{% url 'ipam:vrf' pk=object.vrf.pk %}">{{ object.vrf }}</a>
</li>
{% endif %}
<li class="breadcrumb-item">
{{ object }}
</li>
{% endblock %}
{% block tab_items %}
<li role="presentation" class="nav-item">
<a class="nav-link{% if not active_tab %} active{% endif %}" href="{% url 'ipam:prefix' pk=object.pk %}">
Prefix
</a>
</li>
<li role="presentation" class="nav-item">
<a class="nav-link{% if active_tab %} active{% endif %}" href="{% url 'ipam:prefix_prefixes' pk=object.pk %}">
Child Prefixes <span class="badge bg-primary">{{ object.get_child_prefixes.count }}</span>
</a>
</li>
{% if perms.ipam.view_ipaddress and object.status != 'container' %}
<li role="presentation" class="nav-item">
<a class="nav-link{% if active_tab %} active{% endif %}" href="{% url 'ipam:prefix_ipaddresses' pk=object.pk %}">
IP Addresses <span class="badge bg-primary">{{ object.get_child_ips.count }}</span>
</a>
</li>
{% endif %}
{% endblock %}

View File

@@ -0,0 +1,9 @@
{% extends 'ipam/prefix/base.html' %}
{% block content %}
<div class="row">
<div class="col-md-12">
{% include 'utilities/obj_table.html' with table=ip_table table_template='panel_table.html' heading='IP Addresses' bulk_edit_url='ipam:ipaddress_bulk_edit' bulk_delete_url='ipam:ipaddress_bulk_delete' %}
</div>
</div>
{% endblock %}

View File

@@ -0,0 +1,25 @@
{% extends 'ipam/prefix/base.html' %}
{% block buttons %}
{% include 'ipam/inc/toggle_available.html' %}
{% if perms.ipam.add_prefix and active_tab == 'prefixes' and first_available_prefix %}
<a href="{% url 'ipam:prefix_add' %}?prefix={{ first_available_prefix }}&vrf={{ object.vrf.pk }}&site={{ object.site.pk }}&tenant_group={{ object.tenant.group.pk }}&tenant={{ object.tenant.pk }}" class="btn btn-success">
<i class="mdi mdi-plus-thick" aria-hidden="true"></i> Add Child Prefix
</a>
{% endif %}
{% if perms.ipam.add_ipaddress and active_tab == 'ip-addresses' and first_available_ip %}
<a href="{% url 'ipam:ipaddress_add' %}?address={{ first_available_ip }}&vrf={{ object.vrf.pk }}&tenant_group={{ object.tenant.group.pk }}&tenant={{ object.tenant.pk }}" class="btn btn-success">
<span class="mdi mdi-plus-thick" aria-hidden="true"></span>
Add an IP Address
</a>
{% endif %}
{{ block.super }}
{% endblock %}
{% block content %}
<div class="row">
<div class="col-md-12">
{% include 'utilities/obj_table.html' with table=prefix_table table_template='panel_table.html' heading='Child Prefixes' bulk_edit_url='ipam:prefix_bulk_edit' bulk_delete_url='ipam:prefix_bulk_delete' parent=prefix %}
</div>
</div>
{% endblock %}