Browse Source

fix(form): schemas update problem

修复某些情况下重设schemas数据不会生效的问题

fixed #688
无木 3 năm trước cách đây
mục cha
commit
808328dc7e
1 tập tin đã thay đổi với 7 bổ sung0 xóa
  1. 7 0
      src/components/Form/src/BasicForm.vue

+ 7 - 0
src/components/Form/src/BasicForm.vue

@@ -196,6 +196,13 @@
       );
 
       watch(
+        () => unref(getProps).schemas,
+        (schemas) => {
+          resetSchema(schemas ?? []);
+        }
+      );
+
+      watch(
         () => getSchema.value,
         (schema) => {
           nextTick(() => {