Closes #760: Redirect user back to device view after deleting an assigned IP address

This commit is contained in:
Jeremy Stretch
2017-01-18 12:25:07 -05:00
parent fc7f88d2a2
commit 9ff59ab686
3 changed files with 16 additions and 5 deletions

View File

@@ -13,7 +13,7 @@
</td>
<td class="text-right">
{% if perms.ipam.delete_ipaddress %}
<a href="{% url 'ipam:ipaddress_delete' pk=ip.pk %}" class="btn btn-danger btn-xs">
<a href="{% url 'ipam:ipaddress_delete' pk=ip.pk %}?return_url={{ device.get_absolute_url }}" class="btn btn-danger btn-xs">
<i class="glyphicon glyphicon-trash" aria-hidden="true" title="Delete IP address"></i>
</a>
{% endif %}