|
|
@@ -1,6 +1,6 @@
|
|
|
<template>
|
|
|
<basic-container>
|
|
|
- <el-row class="titlerow">
|
|
|
+ <el-row class="titlerow">
|
|
|
<el-col style="margin-bottom:0px;margin-top:8px">
|
|
|
<div style="position:relative" >
|
|
|
<!-- <el-button type="primary" size="medium" icon="el-icon-plus" class="mg-b-10" @click="addNodeHandle">新增节点</el-button>
|
|
|
@@ -11,7 +11,7 @@
|
|
|
<el-button class=" mg-b-10" size="medium" icon="el-icon-s-grid" @click="eleFormulaHandle" v-if="leftType==5">元素公式设置</el-button>
|
|
|
<el-button class=" mg-b-10" size="medium" icon="el-icon-s-grid" @click="eleHandle" v-else>元素设置</el-button>
|
|
|
<el-button class=" mg-b-10" size="medium" icon="el-icon-help" @click="nodeInfoHandle">节点参数设置</el-button>
|
|
|
-
|
|
|
+
|
|
|
</div>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
@@ -34,8 +34,8 @@
|
|
|
inline-prompt
|
|
|
active-text="按节点"
|
|
|
inactive-text="按表名"
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
/>
|
|
|
<el-button type="primary" @click="searchTreeClick">搜索</el-button>
|
|
|
</div>
|
|
|
@@ -73,21 +73,21 @@
|
|
|
<i
|
|
|
class="el-icon-menu "
|
|
|
@click.stop="showMenu($event,data, node)"
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
></i>
|
|
|
</el-link>
|
|
|
-
|
|
|
+
|
|
|
<!-- 因右键自定义菜单事件需要获取当前点击的位置,所以此处绑定动态样式来控制菜单实时跟踪鼠标右键点击位置 -->
|
|
|
<ul
|
|
|
v-show="menuvisible"
|
|
|
:style="{ left: menuleft + 'px', top: menutop + 'px' }"
|
|
|
class="contextmenu"
|
|
|
>
|
|
|
- <li v-for="item in menusData" :key="item" @click="menuClick($event,item,data)" v-if="node.level !== 1">
|
|
|
+ <li v-for="item in menusData" :key="item" @click="menuClick($event,item,data)" v-if="node.level !== 1">
|
|
|
<i :class="item.icon"></i>{{item.label}}
|
|
|
</li>
|
|
|
- <li v-for="item in menusData1" :key="item" @click="menuClick($event,item,data)" v-if="node.level ===1">
|
|
|
+ <li v-for="item in menusData1" :key="item" @click="menuClick($event,item,data)" v-if="node.level ===1">
|
|
|
<i :class="item.icon"></i>{{item.label}}
|
|
|
</li>
|
|
|
</ul>
|
|
|
@@ -122,17 +122,17 @@
|
|
|
class="el-icon-menu "
|
|
|
@click.stop="showMenu($event,data, node)"
|
|
|
v-if="node.level != 1"
|
|
|
-
|
|
|
+
|
|
|
></i>
|
|
|
</el-link>
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
<ul
|
|
|
v-show="menuvisible"
|
|
|
:style="{ left: menuleft + 'px', top: menutop + 'px' }"
|
|
|
class="contextmenu"
|
|
|
>
|
|
|
- <li v-for="item in menusData" :key="item" @click="menuClick($event,item,data)">
|
|
|
+ <li v-for="item in menusData" :key="item" @click="menuClick($event,item,data)">
|
|
|
<i :class="item.icon"></i>{{item.label}}
|
|
|
</li>
|
|
|
</ul>
|
|
|
@@ -1135,16 +1135,17 @@
|
|
|
align="center"
|
|
|
prop="dynamicDict"
|
|
|
label="动态字典"
|
|
|
-
|
|
|
+
|
|
|
>
|
|
|
<template slot="header">
|
|
|
-
|
|
|
+
|
|
|
<span>动态字典</span>
|
|
|
</template>
|
|
|
<template slot-scope="scope">
|
|
|
<el-select
|
|
|
v-model="scope.row.dynamicDict"
|
|
|
@change="setDefaultLength(scope.row)"
|
|
|
+ filterable
|
|
|
size="small"
|
|
|
placeholder="请选择"
|
|
|
>
|
|
|
@@ -1209,7 +1210,7 @@
|
|
|
</el-dialog>
|
|
|
|
|
|
<el-dialog
|
|
|
-
|
|
|
+
|
|
|
:title="(curEleTable.tableName?curEleTable.tableName:'')+' 元素公式(WBS级)'"
|
|
|
:visible.sync="editEleFormulaVisible"
|
|
|
width="800px"
|
|
|
@@ -1353,7 +1354,7 @@
|
|
|
v-model="scope.row.k"
|
|
|
placeholder="请选择"
|
|
|
class="w-100p"
|
|
|
-
|
|
|
+
|
|
|
>
|
|
|
<el-option
|
|
|
v-for="item in namelist"
|
|
|
@@ -1820,9 +1821,9 @@ export default {
|
|
|
{icon: 'el-icon-s-promotion', label: '编辑节点', key: "edit"},
|
|
|
{icon: 'el-icon-sort', label: '排序节点', key: "sort"},
|
|
|
{icon: 'el-icon-document-copy', label: '复制节点', key: "copy"},
|
|
|
-
|
|
|
+
|
|
|
{icon: 'el-icon-delete', label: '删除节点', key: "del"},
|
|
|
-
|
|
|
+
|
|
|
],//树组件操作菜单
|
|
|
menusData1:[{icon: 'el-icon-plus', label: '新增节点', key: "add"}],
|
|
|
menuKey:'',
|
|
|
@@ -1962,7 +1963,7 @@ export default {
|
|
|
type:this.searchType,
|
|
|
wbsId:this.id,
|
|
|
projectId:''
|
|
|
-
|
|
|
+
|
|
|
}).then((res)=>{
|
|
|
let arr = [];
|
|
|
if (Array.isArray(res.data.data)) {
|
|
|
@@ -1971,12 +1972,12 @@ export default {
|
|
|
}else{
|
|
|
this.searchTreeData=[]
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
})
|
|
|
}else{
|
|
|
this.isSearch=false
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
this.searchtreeLoad=false
|
|
|
},
|
|
|
clearSearch(){
|
|
|
@@ -1995,11 +1996,11 @@ export default {
|
|
|
res.data.data.parentName = parentName;
|
|
|
this.tableData = [res.data.data];
|
|
|
this.nodeDetail = Object.assign({}, res.data.data);
|
|
|
-
|
|
|
+
|
|
|
if(this.menuKey==='add'){
|
|
|
this.nodeDetail.nodeName=''
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
})
|
|
|
this.updateNodeTable();
|
|
|
|
|
|
@@ -2046,7 +2047,7 @@ export default {
|
|
|
subobj.parentId=this.curTreeData.id
|
|
|
subobj.parentName=this.curTreeData.title
|
|
|
|
|
|
-
|
|
|
+
|
|
|
update(subobj).then(() => {
|
|
|
this.updateTreeNewNode();
|
|
|
this.dialogVisible = false;
|
|
|
@@ -2098,12 +2099,12 @@ export default {
|
|
|
this.nodeDetail = {
|
|
|
parentId: res.data.data.id,
|
|
|
parentName: data.title,
|
|
|
-
|
|
|
+
|
|
|
};
|
|
|
|
|
|
-
|
|
|
+
|
|
|
} else {
|
|
|
-
|
|
|
+
|
|
|
this.nodeDetail = Object.assign({}, res.data.data);
|
|
|
this.mixRatioTestIds = this.toSplit(res.data.data.mixRatioTestIds)
|
|
|
}
|
|
|
@@ -2454,7 +2455,7 @@ export default {
|
|
|
// const newarr = [...checkedKeys, ...halfCheckedKeys]
|
|
|
const newarr = [...checkedKeys]
|
|
|
this.nodeDetail.mixRatioTestIds = this.toJoin(newarr)
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
// filterChange () {
|
|
|
// if (this.treeData.length > 0) {
|
|
|
@@ -2612,9 +2613,9 @@ export default {
|
|
|
this.formulaCurRow.elementType = false;
|
|
|
}else{
|
|
|
this.formulaCompVisible = true;
|
|
|
-
|
|
|
+
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
|
|
|
getNodeTypelist () {
|
|
|
@@ -2636,8 +2637,8 @@ export default {
|
|
|
{
|
|
|
code='wbs_node_type'//质检
|
|
|
}
|
|
|
- }
|
|
|
-
|
|
|
+ }
|
|
|
+
|
|
|
getDictionary({
|
|
|
code
|
|
|
// code: type === 2 ? 'trial_node_type':'wbs_node_type'
|
|
|
@@ -2766,7 +2767,7 @@ export default {
|
|
|
// if (!value) return true;
|
|
|
// return data.title.indexOf(value) !== -1;
|
|
|
// },
|
|
|
-
|
|
|
+
|
|
|
getReturnNode(node,_array,value){
|
|
|
let isPass = node.data && node.data.title && node.data.title.indexOf(value) !== -1;
|
|
|
isPass?_array.push(isPass):'';
|
|
|
@@ -2814,7 +2815,7 @@ export default {
|
|
|
let prams={
|
|
|
nodeId: this.jiedianId,
|
|
|
type: 0,
|
|
|
-
|
|
|
+
|
|
|
}
|
|
|
refrehPram(prams).then((res)=>{
|
|
|
console.log(res);
|
|
|
@@ -2931,8 +2932,8 @@ export default {
|
|
|
if( Array.isArray(res.data)){
|
|
|
this.nodeInfoTable = res.data
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
}
|
|
|
},
|
|
|
async saveOrUpdateBatch (da) {//保存
|
|
|
@@ -3098,7 +3099,7 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
|
|
|
//保存关联
|
|
|
@@ -3179,7 +3180,7 @@ export default {
|
|
|
}else{
|
|
|
this.$message.warning('请先选择关联元素')
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
},
|
|
|
|
|
|
//筛选元素
|
|
|
@@ -3344,7 +3345,7 @@ export default {
|
|
|
this.addNodeHandle()
|
|
|
this.menuKey='add'
|
|
|
}
|
|
|
-
|
|
|
+
|
|
|
else if(item.key==='edit'){
|
|
|
this.editNodeHandle()
|
|
|
this.menuKey='edit'
|