mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
added admin and api views for listing all plugins, and refactored urls import
This commit is contained in:
6
netbox/templates/admin/index.html
Normal file
6
netbox/templates/admin/index.html
Normal file
@@ -0,0 +1,6 @@
|
||||
{% extends "django_rq/index.html" %}
|
||||
|
||||
{% block sidebar %}
|
||||
{{ block.super }}
|
||||
{% include 'extras/admin/plugins_index.html' %}
|
||||
{% endblock %}
|
14
netbox/templates/extras/admin/plugins_index.html
Normal file
14
netbox/templates/extras/admin/plugins_index.html
Normal file
@@ -0,0 +1,14 @@
|
||||
<div id="django-rq">
|
||||
<div class="module">
|
||||
<table>
|
||||
<caption>Plugins</caption>
|
||||
<tbody>
|
||||
<tr>
|
||||
<th>
|
||||
<a href = "{% url 'plugins_list' %}">Installed plugins</a>
|
||||
</th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
60
netbox/templates/extras/admin/plugins_list.html
Normal file
60
netbox/templates/extras/admin/plugins_list.html
Normal file
@@ -0,0 +1,60 @@
|
||||
{% extends "admin/base_site.html" %}
|
||||
|
||||
{% block title %}Installed Plugins {{ block.super }}{% endblock %}
|
||||
|
||||
|
||||
{% block breadcrumbs %}
|
||||
<div class="breadcrumbs">
|
||||
<a href="{% url 'admin:index' %}">Home</a> ›
|
||||
<a href="{% url 'plugins_list' %}">Installed Plugins</a>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block content_title %}<h1>Installed Plugins{{ queue.name }}</h1>{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
<div id="content-main">
|
||||
<div class="module" id="changelist">
|
||||
<div class="results">
|
||||
<table id="result_list">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><div class = 'text'><span>Name</span></div></th>
|
||||
<th><div class = 'text'><span>Package Name</span></div></th>
|
||||
<th><div class = 'text'><span>Author</span></div></th>
|
||||
<th><div class = 'text'><span>Author Email</span></div></th>
|
||||
<th><div class = 'text'><span>Description</span></div></th>
|
||||
<th><div class = 'text'><span>Version</span></div></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for plugin in plugins %}
|
||||
<tr class = "{% cycle 'row1' 'row2' %}">
|
||||
<td>
|
||||
{{ plugin.verbose_name }}
|
||||
</td>
|
||||
<td>
|
||||
{{ plugin.name }}
|
||||
</td>
|
||||
<td>
|
||||
{{ plugin.author }}
|
||||
</td>
|
||||
<td>
|
||||
{{ plugin.author_email }}
|
||||
</td>
|
||||
<td>
|
||||
{{ plugin.description }}
|
||||
</td>
|
||||
<td>
|
||||
{{ plugin.version }}
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
Reference in New Issue
Block a user