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

Add in in-line vlan editing and Bulk vlan editing (#3350)

* Fixes #3341 - Added in-line vlan editing
* Fixes #2160 - Added bulk vlan editing

Inconsequential behaviour changes:

* APISelect can now take "full=True" to return a non-brief set
* Select2 will no group by "group & site, group, site, global" if full=True is set in APISelect
This commit is contained in:
Daniel Sheppard
2019-09-06 12:45:37 -05:00
committed by GitHub
parent 8f5e73a598
commit 9c6dbd7337
7 changed files with 155 additions and 157 deletions

View File

@@ -298,6 +298,7 @@ class APISelect(SelectWithDisabled):
conditional_query_params=None,
additional_query_params=None,
null_option=False,
full=False,
*args,
**kwargs
):
@@ -306,6 +307,8 @@ class APISelect(SelectWithDisabled):
self.attrs['class'] = 'netbox-select2-api'
self.attrs['data-url'] = '/{}{}'.format(settings.BASE_PATH, api_url.lstrip('/')) # Inject BASE_PATH
if full:
self.attrs['data-full'] = full
if display_field:
self.attrs['display-field'] = display_field
if value_field: