mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-14 19:22:53 -06:00
Fixes #5533: Fix bulk editing of objects with required custom fields
This commit is contained in:
parent
6f39e6599d
commit
cc1a43e5d9
@ -7,6 +7,7 @@
|
|||||||
* [#5301](https://github.com/netbox-community/netbox/issues/5301) - Fix misleading error when racking a device with invalid parameters
|
* [#5301](https://github.com/netbox-community/netbox/issues/5301) - Fix misleading error when racking a device with invalid parameters
|
||||||
* [#5311](https://github.com/netbox-community/netbox/issues/5311) - Update child objects when a rack group is moved to a new site
|
* [#5311](https://github.com/netbox-community/netbox/issues/5311) - Update child objects when a rack group is moved to a new site
|
||||||
* [#5518](https://github.com/netbox-community/netbox/issues/5518) - Fix persistent vertical scrollbar
|
* [#5518](https://github.com/netbox-community/netbox/issues/5518) - Fix persistent vertical scrollbar
|
||||||
|
* [#5533](https://github.com/netbox-community/netbox/issues/5533) - Fix bulk editing of objects with required custom fields
|
||||||
* [#5540](https://github.com/netbox-community/netbox/issues/5540) - Fix exception when viewing a provider with one or more tags assigned
|
* [#5540](https://github.com/netbox-community/netbox/issues/5540) - Fix exception when viewing a provider with one or more tags assigned
|
||||||
* [#5543](https://github.com/netbox-community/netbox/issues/5543) - Fix rendering of config contexts with cluster assignment for devices
|
* [#5543](https://github.com/netbox-community/netbox/issues/5543) - Fix rendering of config contexts with cluster assignment for devices
|
||||||
|
|
||||||
|
@ -798,8 +798,8 @@ class BulkEditView(GetReturnURLMixin, ObjectPermissionRequiredMixin, View):
|
|||||||
# Update custom fields
|
# Update custom fields
|
||||||
for name in custom_fields:
|
for name in custom_fields:
|
||||||
if name in form.nullable_fields and name in nullified_fields:
|
if name in form.nullable_fields and name in nullified_fields:
|
||||||
obj.custom_field_data.pop(name, None)
|
obj.custom_field_data[name] = None
|
||||||
else:
|
elif form.cleaned_data.get(name) not in (None, ''):
|
||||||
obj.custom_field_data[name] = form.cleaned_data[name]
|
obj.custom_field_data[name] = form.cleaned_data[name]
|
||||||
|
|
||||||
obj.full_clean()
|
obj.full_clean()
|
||||||
|
Loading…
Reference in New Issue
Block a user