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

Improved handling of return_url for object edit/delete views; removed manual definitions of initial data fields

This commit is contained in:
Jeremy Stretch
2017-04-13 13:11:23 -04:00
parent d5c3f9e780
commit f70f0f8d62
9 changed files with 65 additions and 63 deletions

View File

@ -1708,7 +1708,7 @@ class IPAddressForm(BootstrapMixin, CustomFieldForm):
self.fields['vrf'].empty_label = 'Global'
interfaces = device.interfaces.all()
interfaces = device.interfaces.order_naturally(method=device.device_type.interface_ordering)
self.fields['interface'].queryset = interfaces
self.fields['interface'].required = True