diff --git a/src/ui/ManagementPortal/components/JSONEditorDialog.vue b/src/ui/ManagementPortal/components/JSONEditorDialog.vue index 7a7214596..19afe70f1 100644 --- a/src/ui/ManagementPortal/components/JSONEditorDialog.vue +++ b/src/ui/ManagementPortal/components/JSONEditorDialog.vue @@ -9,12 +9,19 @@ @@ -36,7 +43,7 @@ export default { visible: { type: Boolean, - required: true, + required: false, }, }, @@ -55,13 +62,16 @@ export default { this.json = this.modelValue; }, }, + }, - json: { - deep: true, - handler() { - if (JSON.stringify(this.modelValue) === JSON.stringify(this.json)) return; - this.modelValue = this.json; - }, + methods: { + handleSave() { + this.$emit('update:modelValue', this.json); + this.handleClose(); + }, + + handleClose() { + this.$emit('update:visible', false); }, }, };