ali 1 éve
szülő
commit
3cd125050e

+ 5 - 1
src/components/FormBuilderCustumComponents/ContentCategorySelector.vue

@@ -88,9 +88,13 @@ export default {
     }
   },
   watch: {
-    value () {
+    value (newValue, oldValue) {
+      if (newValue && oldValue && newValue.toString() === oldValue.toString()) {
+        return
+      }
       if (this.value?.id) {
         this.getCategories()
+        // this.$emit('update:value', this.value.id)
       } else if (this.value) {
         this.inputData = this.value
       }

+ 2 - 2
src/components/FormBuilderCustumComponents/ProductSelector.vue

@@ -119,8 +119,8 @@ export default {
   },
   watch: {
     value: {
-      handler (newValue) {
-        if (!newValue) {
+      handler (newValue, oldValue) {
+        if (!newValue || (newValue && oldValue && newValue.toString() === oldValue.toString())) {
           return
         }
         if (this.selectionMode === 'multiple') {