mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-24 17:38:37 -06:00
10903 add module type on manufacturer page
This commit is contained in:
parent
7401fd7050
commit
564884a774
@ -4,10 +4,24 @@
|
|||||||
{% load render_table from django_tables2 %}
|
{% load render_table from django_tables2 %}
|
||||||
|
|
||||||
{% block extra_controls %}
|
{% block extra_controls %}
|
||||||
{% if perms.dcim.add_devicetype %}
|
{% if perms.dcim.add_devicetype or perms.dcim.add_moduletype %}
|
||||||
<a href="{% url 'dcim:devicetype_add' %}?manufacturer={{ object.pk }}" class="btn btn-sm btn-primary">
|
<div class="dropdown">
|
||||||
<span class="mdi mdi-plus-thick" aria-hidden="true"></span> Add Device Type
|
<button id="add-components" type="button" class="btn btn-sm btn-primary dropdown-toggle" data-bs-toggle="dropdown" aria-expanded="false">
|
||||||
</a>
|
<i class="mdi mdi-plus-thick" aria-hidden="true"></i> Add
|
||||||
|
</button>
|
||||||
|
<ul class="dropdown-menu" aria-labeled-by="add-components">
|
||||||
|
{% if perms.dcim.add_devicetype %}
|
||||||
|
<li><a class="dropdown-item" href="{% url 'dcim:devicetype_add' %}?manufacturer={{ object.pk }}">
|
||||||
|
Add Device Type
|
||||||
|
</a></li>
|
||||||
|
{% endif %}
|
||||||
|
{% if perms.dcim.add_moduletype %}
|
||||||
|
<li><a class="dropdown-item" href="{% url 'dcim:moduletype_add' %}?manufacturer={{ object.pk }}">
|
||||||
|
Add Module Type
|
||||||
|
</a></li>
|
||||||
|
{% endif %}
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endblock extra_controls %}
|
{% endblock extra_controls %}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user