|
@@ -40,12 +40,12 @@
|
|
|
<el-input v-model="row.edbName"></el-input>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="频度" align="center" width="140">
|
|
|
+ <el-table-column :label="$t('Edb.Detail.e_fre')" align="center" width="140">
|
|
|
<template slot-scope="{row}">
|
|
|
<el-select v-model="row.frequency"></el-select>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column label="单位" align="center" width="140">
|
|
|
+ <el-table-column :label="$t('Edb.Detail.e_unit')" align="center" width="140">
|
|
|
<template slot-scope="{row}">
|
|
|
<el-input v-model="row.unit"></el-input>
|
|
|
</template>
|
|
@@ -53,12 +53,25 @@
|
|
|
<!-- 操作 -->
|
|
|
<el-table-column align="center">
|
|
|
<template slot="header" slot-scope="{row}">
|
|
|
- <span>指标库目录</span>
|
|
|
- <el-radio v-model="classifyType" :label="1" style="margin-right:5px;">分目录</el-radio>
|
|
|
- <el-radio v-model="classifyType" :label="2">同目录</el-radio>
|
|
|
+ <span>{{$t('EtaBasePage.catalogue_directory')}}</span>
|
|
|
+ <el-radio-group v-model="classifyType" @change="handleClassifyTypeChange">
|
|
|
+ <el-radio :label="1"><!-- 分目录 -->{{$t('EtaBasePage.subdirectory_radio')}}</el-radio>
|
|
|
+ <el-radio :label="2"><!-- 同目录 -->{{$t('EtaBasePage.directory_radio')}}</el-radio>
|
|
|
+ </el-radio-group>
|
|
|
</template>
|
|
|
- <template slot-scope="{row}">
|
|
|
- <el-input v-model="row.classify"></el-input>
|
|
|
+ <template slot-scope="{row,$index}">
|
|
|
+ <el-cascader
|
|
|
+ v-model="row.classify"
|
|
|
+ :options="edbClassifyList"
|
|
|
+ :props="{
|
|
|
+ label: 'ClassifyName',
|
|
|
+ value: 'ClassifyId',
|
|
|
+ children: 'Children',
|
|
|
+ checkStrictly: true,
|
|
|
+ emitPath:false
|
|
|
+ }"
|
|
|
+ :disabled="classifyType===1&&$index>0"
|
|
|
+ ></el-cascader>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
@@ -73,6 +86,7 @@
|
|
|
|
|
|
<script>
|
|
|
import { steelInterface } from "@/api/modules/thirdBaseApi";
|
|
|
+import { dataBaseInterface } from '@/api/api.js';
|
|
|
export default {
|
|
|
props:{
|
|
|
isOpenDialog:{
|
|
@@ -102,12 +116,14 @@ export default {
|
|
|
classify:''
|
|
|
} */
|
|
|
],
|
|
|
+ edbClassifyList:[],//指标库目录
|
|
|
selectEdbList:[]
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
|
initDia(){
|
|
|
this.getClassifyList()
|
|
|
+ this.getClassifyOpt()
|
|
|
this.searchClassify = ''
|
|
|
this.searchName = ''
|
|
|
this.edbList = []
|
|
@@ -120,6 +136,22 @@ export default {
|
|
|
this.classifyList = res.Data||[]
|
|
|
})
|
|
|
},
|
|
|
+ filterNodes(arr) {
|
|
|
+ arr.length &&
|
|
|
+ arr.forEach((item) => {
|
|
|
+ item.Children.length && this.filterNodes(item.Children);
|
|
|
+ if (!item.Children.length) {
|
|
|
+ delete item.Children;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
+ // 获取指标分类列表
|
|
|
+ async getClassifyOpt(){
|
|
|
+ const res=await dataBaseInterface.menuListV3()
|
|
|
+ if (res.Ret !== 200) return
|
|
|
+ this.filterNodes(res.Data.AllNodes||[]);
|
|
|
+ this.edbClassifyList = res.Data.AllNodes || [];
|
|
|
+ },
|
|
|
//获取对应目录下的钢联化工指标
|
|
|
getEdbList(){
|
|
|
this.edbList = [{
|
|
@@ -130,6 +162,7 @@ export default {
|
|
|
classify:''
|
|
|
}]
|
|
|
},
|
|
|
+ handleClassifyTypeChange(){},
|
|
|
handleAddEdb(){
|
|
|
//校验所选指标
|
|
|
},
|