mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-18 21:16:27 -06:00
Fixes #16679: Avoid overwriting custom JSON fields during bulk edit
This commit is contained in:
parent
224f157b75
commit
a704708caa
@ -490,7 +490,7 @@ class CustomField(CloningMixin, ExportTemplatesMixin, ChangeLoggedModel):
|
|||||||
|
|
||||||
# JSON
|
# JSON
|
||||||
elif self.type == CustomFieldTypeChoices.TYPE_JSON:
|
elif self.type == CustomFieldTypeChoices.TYPE_JSON:
|
||||||
field = JSONField(required=required, initial=json.dumps(initial) if initial else '')
|
field = JSONField(required=required, initial=json.dumps(initial) if initial else None)
|
||||||
|
|
||||||
# Object
|
# Object
|
||||||
elif self.type == CustomFieldTypeChoices.TYPE_OBJECT:
|
elif self.type == CustomFieldTypeChoices.TYPE_OBJECT:
|
||||||
|
Loading…
Reference in New Issue
Block a user