瀏覽代碼

初始化数据表编辑的校验结果

lph 1 年之前
父節點
當前提交
25e33fe074
共有 1 個文件被更改,包括 9 次插入0 次删除
  1. 9 0
      ruoyi-ui/src/views/tool/datasheet/index.vue

+ 9 - 0
ruoyi-ui/src/views/tool/datasheet/index.vue

@@ -269,6 +269,15 @@ export default {
       tableInfo(data).then((response) => {
         console.log(response);
         this.experienceData = response.data;
+        // 初始化校验规则
+        this.experienceData.forEach((val, index) => {
+          this.handleSelected(
+            this.dict.type[this.databaseType + "_data_type"].find(
+              (item) => item.label === val.fieldType
+            ),
+            { $index: index, row: val }
+          );
+        });
         this.form.tableName = tableName;
         this.form.tableComment = tableComment;
       });