mirror of
https://github.com/netbox-community/netbox.git
synced 2025-08-08 16:48:16 -06:00
Fixes #16679: Avoid overwriting custom JSON fields during bulk edit
This commit is contained in:
parent
4857a87be5
commit
c2f85c90a6
@ -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