|
@@ -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
|
|
|
}
|