feat():新的数据结构,新的作用域
parent
cd0fffcb81
commit
bc907798b0
|
@ -233,11 +233,12 @@
|
||||||
<div slot="header" class="clearfix">
|
<div slot="header" class="clearfix">
|
||||||
<span>{{this.ruleEngineInfo.ruleLevelId === 1 ? "选择资产集" : "选择资产记录"}}</span>
|
<span>{{this.ruleEngineInfo.ruleLevelId === 1 ? "选择资产集" : "选择资产记录"}}</span>
|
||||||
</div>
|
</div>
|
||||||
<el-table :data="dataModeMapList" max-height="200px"
|
<el-table :data="dataModeMapList" max-height="300px"
|
||||||
@selection-change="changeDataRow">
|
@selection-change="changeDataRow">
|
||||||
<el-table-column type="selection" width="55" v-if="this.ruleEngineInfo.ruleLevelId === 1 "/>
|
<el-table-column type="selection" width="100" v-if="this.ruleEngineInfo.ruleLevelId === 1 "/>
|
||||||
<el-table-column v-for="dataModel in dataModelList" :label="dataModel.comment" :prop="dataModel.name"/>
|
<el-table-column v-for="dataModel in dataModelList" :label="dataModel" :prop="dataModel"/>
|
||||||
<el-table-column label="操作" v-if="this.ruleEngineInfo.ruleLevelId === 1 ">
|
<el-table-column label="操作" v-if="this.ruleEngineInfo.ruleLevelId === 2 ">
|
||||||
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button type="text" @click="dataRecordSelect(scope.row)">选择</el-button>
|
<el-button type="text" @click="dataRecordSelect(scope.row)">选择</el-button>
|
||||||
</template>
|
</template>
|
||||||
|
@ -271,6 +272,7 @@
|
||||||
import Encoding from "@/components/Encoding/index.vue";
|
import Encoding from "@/components/Encoding/index.vue";
|
||||||
import {compiledCode, generateClazz, getVersionList, insertRuleVersion} from "@/api/dataSource/ruleVersion";
|
import {compiledCode, generateClazz, getVersionList, insertRuleVersion} from "@/api/dataSource/ruleVersion";
|
||||||
import {queryBigStructure} from "@/api/dataSource/data";
|
import {queryBigStructure} from "@/api/dataSource/data";
|
||||||
|
import {getShowModel} from "@/api/dataSource/dataKvt";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "EngineVersion",
|
name: "EngineVersion",
|
||||||
|
@ -502,6 +504,26 @@ export default {
|
||||||
},
|
},
|
||||||
getFields() {
|
getFields() {
|
||||||
console.log("tableId",this.assets)
|
console.log("tableId",this.assets)
|
||||||
|
getShowModel(this.assets).then(
|
||||||
|
res => {
|
||||||
|
this.dataModeMapList = []
|
||||||
|
this.dataModelList = []
|
||||||
|
console.log("引擎作用域",this.ruleEngineInfo.ruleLevelId)
|
||||||
|
let data = res.data;
|
||||||
|
data.forEach(da => {
|
||||||
|
const obj = {};
|
||||||
|
da.forEach(d => {
|
||||||
|
if (!this.dataModelList.includes(d.fieldsName)){
|
||||||
|
|
||||||
|
this.dataModelList.push(d.fieldsName)
|
||||||
|
}
|
||||||
|
obj[d.fieldsName] = d.fieldsValue;
|
||||||
|
})
|
||||||
|
this.dataModeMapList.push(obj)
|
||||||
|
})
|
||||||
|
console.log("获取到的dataList",this.dataModeMapList)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
},
|
},
|
||||||
saveCoding(){
|
saveCoding(){
|
||||||
|
|
Loading…
Reference in New Issue