Browse Source

ai-table code completed

hare8999@163.com 2 years ago
parent
commit
dc6f8eab9c

+ 0 - 1
src/components/MxCondition/condition-mixins-data.js

@@ -486,7 +486,6 @@ export default {
 
         const invoker = function(){
           formRef.validate((valid, errors) => {
-            //debugger
             if (valid) resolve(valid)
             else reject(errors) // 经这一步转化,可以外抛errors
           })

+ 10 - 10
src/views/elective/select/components/elective-ai-table.vue

@@ -81,21 +81,21 @@ export default {
       const options = this.generation.options
       if (!options || !this.generation.active) return {}
       const dynamicColumns = {}
-      this.generation.activeModels.forEach(model => {
-        if (model.generation != this.generation.active) return // 暂只执行一步
-        const resolverKey = model.option.key + 'AIResolver'
-        const resolver = this[resolverKey]
-        if (typeof resolver === 'function') {
-          const genColumns = resolver(model, this.generation.activeModel, dynamicColumns)
-          Object.assign(dynamicColumns, genColumns)
-        }
-      })
+
+      const model = this.generation.activeModel
+      const resolverKey = model.option.key + 'AIResolver'
+      const resolver = this[resolverKey]
+      if (typeof resolver === 'function') {
+        const genColumns = resolver(model, model, dynamicColumns)
+        Object.assign(dynamicColumns, genColumns)
+      }
+
       return dynamicColumns
     },
     formatCols() {
+      const _ = this.resolveDynamicTable // Note: force execute!
       return {
         ...this.resolveTablePrefix,
-        ...this.resolveDynamicTable,
         ...this.resolveDynamicAITable,
         ...this.resolveTableSuffix
       }

+ 0 - 1
src/views/permission/round-score-import.vue

@@ -338,7 +338,6 @@ export default {
     },
     // 文件上传中处理
     handleFileUploadProgress(event, file, fileList) {
-      debugger
       this.upload.isUploading = true
     },
     // 文件上传成功处理