* remove routingpolicy template

* Correct get_type_display title
This commit is contained in:
Ryan Merolle 2022-07-10 10:21:18 -04:00 committed by GitHub
parent 1f7da36e45
commit a2e31c7d46
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 95 deletions

View File

@ -50,7 +50,7 @@
<td>{{ object.name }}</td>
</tr>
<tr>
<th scope="row">Default Action</th>
<th scope="row">Type</th>
<td>{{ object.get_type_display }}</td>
</tr>
<tr>

View File

@ -1,94 +0,0 @@
{% extends 'generic/object.html' %}
{% load buttons %}
{% load custom_links %}
{% load helpers %}
{% load plugins %}
{% load render_table from django_tables2 %}
{% block breadcrumbs %}
<li class="breadcrumb-item"><a href="{% url 'plugins:netbox_bgp:routingpolicy_list' %}">Routing Policies</a></li>
{% endblock %}
{% block controls %}
<div class="pull-right noprint">
{% if perms.netbox_bgp.change_policy %}
<a href="{% url 'plugins:netbox_bgp:routingpolicyrule_add' %}?routing_policy={{ object.pk }}" class="btn btn-success">
<span class="mdi mdi-plus-thick" aria-hidden="true"></span> Rule
</a>
{% endif %}
{% if perms.netbox_bgp.change_policy %}
<a href="{% url 'plugins:netbox_bgp:routingpolicy_edit' pk=object.pk %}" class="btn btn-warning">
<span class="mdi mdi-pencil" aria-hidden="true"></span> Edit
</a>
{% endif %}
{% if perms.netbox_bgp.delete_policy %}
<a href="{% url 'plugins:netbox_bgp:routingpolicy_delete' pk=object.pk %}" class="btn btn-danger">
<span class="mdi mdi-trash-can-outline" aria-hidden="true"></span> Delete
</a>
{% endif %}
</div>
{% endblock controls %}
{% block tabs %}
<ul class="nav nav-tabs px-3">
{% block tab_items %}
<li class="nav-item" role="presentation">
<a class="nav-link{% if not active_tab %} active{% endif %}" href="{{ object.get_absolute_url }}">{{ object|meta:"verbose_name"|bettertitle }}</a>
</li>
{% endblock tab_items %}
{% if perms.extras.view_objectchange %}
<li role="presentation" class="nav-item">
<a href="{% url 'plugins:netbox_bgp:routingpolicy_changelog' pk=object.pk %}" class="nav-link{% if active_tab == 'changelog'%} active{% endif %}">Change Log</a>
</li>
{% endif %}
</ul>
{% endblock tabs %}
{% block content %}
<div class="row mb-3">
<div class="col-md-4">
<div class="card">
<h5 class="card-header">
Routing Policy
</h5>
<div class="card-body">
<table class="table table-hover attr-table">
<tr>
<td>name</td>
<td>{{ object.name }}</td>
</tr>
<tr>
<td>Description</td>
<td>{{ object.description|placeholder }}</td>
</tr>
</table>
</div>
</div>
{% include 'inc/panels/custom_fields.html' %}
{% include 'inc/panels/tags.html' %}
{% plugin_left_page object %}
</div>
<div class="col-md-8">
<div class="card">
<h5 class="card-header">
Related BGP Sessions
</h5>
<div class="card-body">
{% render_table related_session_table 'inc/table.html' %}
</div>
{% plugin_right_page object %}
</div>
</div>
</div>
<div class="row">
<div class="col-md-12">
<div class="card">
<h5 class="card-header">
Rules
</h5>
<div class="card-body">
{% render_table rules_table 'inc/table.html' %}
</div>
{% plugin_full_width_page object %}
</div>
</div>
</div>
{% endblock %}