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

Closes #33: Add ability to clone objects (pre-populate form fields)

This commit is contained in:
Jeremy Stretch
2019-12-06 16:13:52 -05:00
parent 47fefbec07
commit 446acbdf82
23 changed files with 186 additions and 34 deletions

View File

@@ -1,4 +1,5 @@
{% extends '_base.html' %}
{% load buttons %}
{% load custom_links %}
{% load helpers %}
@@ -27,6 +28,9 @@
</div>
</div>
<div class="pull-right noprint">
{% if perms.virtualization.add_cluster %}
{% clone_button 'virtualization:cluster_add' cluster %}
{% endif %}
{% if perms.virtualization.change_cluster %}
<a href="{% url 'virtualization:cluster_edit' pk=cluster.pk %}" class="btn btn-warning">
<span class="fa fa-pencil" aria-hidden="true"></span>

View File

@@ -1,4 +1,5 @@
{% extends '_base.html' %}
{% load buttons %}
{% load custom_links %}
{% load helpers %}
@@ -26,6 +27,9 @@
</div>
</div>
<div class="pull-right noprint">
{% if perms.virtualization.add_virtualmachine %}
{% clone_button 'virtualization:virtualmachine_add' virtualmachine %}
{% endif %}
{% if perms.virtualization.change_virtualmachine %}
<a href="{% url 'virtualization:virtualmachine_edit' pk=virtualmachine.pk %}" class="btn btn-warning">
<span class="fa fa-pencil"></span>