Commit 571d4f0dbdf7537f37d34de97b561ea3c5e5c838
1 parent
c893d5d2
Update json value for correct working
Showing
1 changed file
with
2 additions
and
1 deletions
@@ -114,7 +114,7 @@ export class ValueInputComponent implements OnInit, ControlValueAccessor { | @@ -114,7 +114,7 @@ export class ValueInputComponent implements OnInit, ControlValueAccessor { | ||
114 | } | 114 | } |
115 | 115 | ||
116 | updateView() { | 116 | updateView() { |
117 | - if (this.inputForm.valid || this.valueType === ValueType.BOOLEAN || this.valueType === ValueType.JSON) { | 117 | + if (this.inputForm.valid || this.valueType === ValueType.BOOLEAN) { |
118 | this.propagateChange(this.modelValue); | 118 | this.propagateChange(this.modelValue); |
119 | } else { | 119 | } else { |
120 | this.propagateChange(null); | 120 | this.propagateChange(null); |
@@ -126,6 +126,7 @@ export class ValueInputComponent implements OnInit, ControlValueAccessor { | @@ -126,6 +126,7 @@ export class ValueInputComponent implements OnInit, ControlValueAccessor { | ||
126 | this.modelValue = false; | 126 | this.modelValue = false; |
127 | } else if (this.valueType === ValueType.JSON) { | 127 | } else if (this.valueType === ValueType.JSON) { |
128 | this.modelValue = {}; | 128 | this.modelValue = {}; |
129 | + this.inputForm.form.get('value').patchValue({}); | ||
129 | } else { | 130 | } else { |
130 | this.modelValue = null; | 131 | this.modelValue = null; |
131 | } | 132 | } |