|
@@ -102,23 +102,32 @@
|
|
<el-col :span="10" class="h-100p">
|
|
<el-col :span="10" class="h-100p">
|
|
<div class="h-100p flex flex-d-c">
|
|
<div class="h-100p flex flex-d-c">
|
|
<p style="margin-top:2px">工程节点信息</p>
|
|
<p style="margin-top:2px">工程节点信息</p>
|
|
- <div class="flex">
|
|
|
|
|
|
+ <div class="flex " style="align-items: center;justify-content: space-between;">
|
|
<el-input
|
|
<el-input
|
|
placeholder="输入关键字进行过滤"
|
|
placeholder="输入关键字进行过滤"
|
|
v-model="filterText"
|
|
v-model="filterText"
|
|
- @input="filterChange"
|
|
|
|
clearable
|
|
clearable
|
|
|
|
+ style="width: 65%;margin-right: 15px;"
|
|
|
|
+ @clear="clearSearch"
|
|
></el-input>
|
|
></el-input>
|
|
- <!-- <el-button type="info" class="mg-l-20">导入划分</el-button> -->
|
|
|
|
|
|
+ <el-switch
|
|
|
|
+ v-model="searchType"
|
|
|
|
+ active-value="1"
|
|
|
|
+ inactive-value="2"
|
|
|
|
+ inline-prompt
|
|
|
|
+ active-text="按节点"
|
|
|
|
+ inactive-text="按表名"
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ />
|
|
|
|
+ <el-button type="primary" @click="searchTreeClick">搜索</el-button>
|
|
</div>
|
|
</div>
|
|
<div class="flex1 ov-hidden">
|
|
<div class="flex1 ov-hidden">
|
|
<el-scrollbar class="h-100p">
|
|
<el-scrollbar class="h-100p">
|
|
<div v-loading="treeLoad">
|
|
<div v-loading="treeLoad">
|
|
<el-tree
|
|
<el-tree
|
|
- v-show="!filterText"
|
|
|
|
class="filter-tree"
|
|
class="filter-tree"
|
|
lazy
|
|
lazy
|
|
- :data="treeData"
|
|
|
|
:load="loadNode"
|
|
:load="loadNode"
|
|
@node-click="getNodeDetail"
|
|
@node-click="getNodeDetail"
|
|
:props="defaultProps"
|
|
:props="defaultProps"
|
|
@@ -127,6 +136,7 @@
|
|
node-key="id"
|
|
node-key="id"
|
|
ref="tree"
|
|
ref="tree"
|
|
:default-expanded-keys="defaultExpandedKeys"
|
|
:default-expanded-keys="defaultExpandedKeys"
|
|
|
|
+ v-show="!isSearch"
|
|
>
|
|
>
|
|
<span
|
|
<span
|
|
class="custom-tree-node "
|
|
class="custom-tree-node "
|
|
@@ -171,16 +181,15 @@
|
|
</span>
|
|
</span>
|
|
</el-tree>
|
|
</el-tree>
|
|
<el-tree
|
|
<el-tree
|
|
- v-show="filterText"
|
|
|
|
- class="filter-tree"
|
|
|
|
- :data="treeData"
|
|
|
|
|
|
+ :load="searchtreeLoad"
|
|
|
|
+ :data="searchTreeData"
|
|
@node-click="getNodeDetail"
|
|
@node-click="getNodeDetail"
|
|
:props="defaultProps"
|
|
:props="defaultProps"
|
|
:expand-on-click-node="false"
|
|
:expand-on-click-node="false"
|
|
highlight-current
|
|
highlight-current
|
|
node-key="id"
|
|
node-key="id"
|
|
- :filter-node-method="filterNode"
|
|
|
|
- ref="treeall"
|
|
|
|
|
|
+ v-show="isSearch"
|
|
|
|
+ default-expand-all
|
|
>
|
|
>
|
|
<span
|
|
<span
|
|
class="custom-tree-node "
|
|
class="custom-tree-node "
|
|
@@ -201,7 +210,7 @@
|
|
></i>
|
|
></i>
|
|
</el-link>
|
|
</el-link>
|
|
|
|
|
|
- <!-- 因右键自定义菜单事件需要获取当前点击的位置,所以此处绑定动态样式来控制菜单实时跟踪鼠标右键点击位置 -->
|
|
|
|
|
|
+
|
|
<ul
|
|
<ul
|
|
v-show="menuvisible"
|
|
v-show="menuvisible"
|
|
:style="{ left: menuleft + 'px', top: menutop + 'px' }"
|
|
:style="{ left: menuleft + 'px', top: menutop + 'px' }"
|
|
@@ -216,7 +225,7 @@
|
|
|
|
|
|
</div>
|
|
</div>
|
|
</span>
|
|
</span>
|
|
- </el-tree>
|
|
|
|
|
|
+ </el-tree>
|
|
</div>
|
|
</div>
|
|
</el-scrollbar>
|
|
</el-scrollbar>
|
|
</div>
|
|
</div>
|
|
@@ -1446,6 +1455,7 @@
|
|
:initTableId="editElementQuery.initTableId"
|
|
:initTableId="editElementQuery.initTableId"
|
|
:nodeid="editElementQuery.nodeid"
|
|
:nodeid="editElementQuery.nodeid"
|
|
@hideDialog="editElementVisible = false"
|
|
@hideDialog="editElementVisible = false"
|
|
|
|
+ @adjustExcel="adjustExcel"
|
|
v-if="editElementVisible"
|
|
v-if="editElementVisible"
|
|
></EditElement>
|
|
></EditElement>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
@@ -1577,7 +1587,7 @@ import {
|
|
updateStatus,
|
|
updateStatus,
|
|
getParamElements,
|
|
getParamElements,
|
|
specifiedParamElements,
|
|
specifiedParamElements,
|
|
- delParamElements, selectPrivateFormElements,syncCurrentFormInProject
|
|
|
|
|
|
+ delParamElements, selectPrivateFormElements,syncCurrentFormInProject,getQueryValueByType
|
|
} from "@/api/manager/wbstree";
|
|
} from "@/api/manager/wbstree";
|
|
import {
|
|
import {
|
|
saveElement,
|
|
saveElement,
|
|
@@ -1600,6 +1610,7 @@ import {
|
|
syncNodeTable,
|
|
syncNodeTable,
|
|
syncNodeinfo,
|
|
syncNodeinfo,
|
|
tabTypeLazyTree,
|
|
tabTypeLazyTree,
|
|
|
|
+ syncContractTabSort
|
|
} from "@/api/manager/wbsprivate";
|
|
} from "@/api/manager/wbsprivate";
|
|
import { findProjectTree as getAlltree } from "@/api/manager/projectinfo";
|
|
import { findProjectTree as getAlltree } from "@/api/manager/projectinfo";
|
|
import { findProjectTreeTrial as getAlltreeTrial } from "@/api/manager/projectinfo";
|
|
import { findProjectTreeTrial as getAlltreeTrial } from "@/api/manager/projectinfo";
|
|
@@ -1687,6 +1698,11 @@ export default {
|
|
projectid: "",
|
|
projectid: "",
|
|
filterText: "",
|
|
filterText: "",
|
|
treeData: [],
|
|
treeData: [],
|
|
|
|
+ searchType:'1',
|
|
|
|
+ isSearch:false,
|
|
|
|
+ searchTreeData:[],
|
|
|
|
+ searchtreeLoad:false,
|
|
|
|
+
|
|
treeLoad: false,
|
|
treeLoad: false,
|
|
menuShow: false,
|
|
menuShow: false,
|
|
defaultProps: {
|
|
defaultProps: {
|
|
@@ -1833,7 +1849,8 @@ export default {
|
|
menusData:[
|
|
menusData:[
|
|
// {icon: 'el-icon-s-promotion', label: '新增节点', key: "add"},
|
|
// {icon: 'el-icon-s-promotion', label: '新增节点', key: "add"},
|
|
{icon: 'el-icon-s-promotion', label: '编辑节点', key: "edit",content:'编辑节点'},
|
|
{icon: 'el-icon-s-promotion', label: '编辑节点', key: "edit",content:'编辑节点'},
|
|
- {icon: 'el-icon-upload', label: '同步元素表单', key: "sync1",content:'同步元素表单'},
|
|
|
|
|
|
+ {icon: 'el-icon-upload', label: '同步新增元素表单', key: "sync1",content:'同步新增元素表单'},
|
|
|
|
+ {icon: 'el-icon-upload', label: '同步元素表单排序到合同段', key: "sync3",content:'同步元素表单排序到合同段'},
|
|
{icon: 'el-icon-s-promotion', label: '同步节点基础信息及表单URL', key: "sync2",content:'同步节点的基础信息、类型名称、表单url等信息'},
|
|
{icon: 'el-icon-s-promotion', label: '同步节点基础信息及表单URL', key: "sync2",content:'同步节点的基础信息、类型名称、表单url等信息'},
|
|
{icon: 'el-icon-sort', label: '调整排序', key: "sort",content:'调整排序'},
|
|
{icon: 'el-icon-sort', label: '调整排序', key: "sort",content:'调整排序'},
|
|
{icon: 'el-icon-s-promotion', label: '删除节点', key: "del",content:'删除节点'},
|
|
{icon: 'el-icon-s-promotion', label: '删除节点', key: "del",content:'删除节点'},
|
|
@@ -2328,7 +2345,9 @@ export default {
|
|
// }
|
|
// }
|
|
|
|
|
|
// });
|
|
// });
|
|
- getAlltree(this.projectid, this.id, this.curTreeData.primaryKeyId).then((res) => {
|
|
|
|
|
|
+ let pid=this.curTreeData.primaryKeyId?this.curTreeData.primaryKeyId:this.curTreeData.pKeyId
|
|
|
|
+
|
|
|
|
+ getAlltree(this.projectid, this.id, pid).then((res) => {
|
|
this.testTreeLoad = false;
|
|
this.testTreeLoad = false;
|
|
console.log(res.data.data,'data');
|
|
console.log(res.data.data,'data');
|
|
this.testTreeData=res.data.data
|
|
this.testTreeData=res.data.data
|
|
@@ -2346,22 +2365,53 @@ export default {
|
|
this.nodeDetail.mixRatioTestIds = this.toJoin(newarr);
|
|
this.nodeDetail.mixRatioTestIds = this.toJoin(newarr);
|
|
|
|
|
|
},
|
|
},
|
|
- filterChange() {
|
|
|
|
- if (this.treeData.length > 0) {
|
|
|
|
- this.$refs.treeall.filter(this.filterText);
|
|
|
|
- return;
|
|
|
|
|
|
+ // filterChange() {
|
|
|
|
+ // if (this.treeData.length > 0) {
|
|
|
|
+ // this.$refs.treeall.filter(this.filterText);
|
|
|
|
+ // return;
|
|
|
|
+ // }
|
|
|
|
+ // this.treeLoad = true;
|
|
|
|
+ // getAlltree(this.projectid, this.id).then((res) => {
|
|
|
|
+ // this.treeLoad = false;
|
|
|
|
+ // this.treeData = res.data.data;
|
|
|
|
+ // console.log(res.data.data,'res.data.data');
|
|
|
|
+ // this.$nextTick(() => {
|
|
|
|
+ // this.$refs.treeall.filter(this.filterText);
|
|
|
|
+ // });
|
|
|
|
+ // });
|
|
|
|
+ // },
|
|
|
|
+ //搜索树
|
|
|
|
+
|
|
|
|
+ //搜索树
|
|
|
|
+ searchTreeClick(){
|
|
|
|
+ if(this.filterText.length>0){
|
|
|
|
+ this.isSearch=true
|
|
|
|
+ this.searchtreeLoad=true
|
|
|
|
+ getQueryValueByType({
|
|
|
|
+ queryValue:this.filterText,
|
|
|
|
+ type:this.searchType,
|
|
|
|
+ wbsId:this.id,
|
|
|
|
+ projectId: this.projectid
|
|
|
|
+
|
|
|
|
+ }).then((res)=>{
|
|
|
|
+ let arr = [];
|
|
|
|
+ if (Array.isArray(res.data.data)) {
|
|
|
|
+ arr = res.data.data;
|
|
|
|
+ this.searchTreeData=arr
|
|
|
|
+ }else{
|
|
|
|
+ this.searchTreeData=[]
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ })
|
|
|
|
+ }else{
|
|
|
|
+ this.isSearch=false
|
|
}
|
|
}
|
|
- this.treeLoad = true;
|
|
|
|
- getAlltree(this.projectid, this.id).then((res) => {
|
|
|
|
- this.treeLoad = false;
|
|
|
|
- this.treeData = res.data.data;
|
|
|
|
- console.log(res.data.data,'res.data.data');
|
|
|
|
- this.$nextTick(() => {
|
|
|
|
- this.$refs.treeall.filter(this.filterText);
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
|
|
+
|
|
|
|
+ this.searchtreeLoad=false
|
|
|
|
+ },
|
|
|
|
+ clearSearch(){
|
|
|
|
+ this.isSearch=false
|
|
},
|
|
},
|
|
-
|
|
|
|
importTemplate(data) {
|
|
importTemplate(data) {
|
|
this.importTemplateVisible = true;
|
|
this.importTemplateVisible = true;
|
|
this.curTreeData = data;
|
|
this.curTreeData = data;
|
|
@@ -3322,7 +3372,7 @@ export default {
|
|
},
|
|
},
|
|
|
|
|
|
syncInfoHandle(item) {
|
|
syncInfoHandle(item) {
|
|
- if(this.curTreeData.primaryKeyId){
|
|
|
|
|
|
+ if(this.curTreeData.primaryKeyId||this.curTreeData.pKeyId){
|
|
this.$confirm("是否同步节点参数?", "提示", {
|
|
this.$confirm("是否同步节点参数?", "提示", {
|
|
confirmButtonText: "确定",
|
|
confirmButtonText: "确定",
|
|
cancelButtonText: "取消",
|
|
cancelButtonText: "取消",
|
|
@@ -3334,7 +3384,8 @@ export default {
|
|
ele.load=true
|
|
ele.load=true
|
|
}
|
|
}
|
|
})
|
|
})
|
|
- syncNodeParam(this.projectid,this.curTreeData.primaryKeyId)
|
|
|
|
|
|
+ let pid=this.curTreeData.primaryKeyId?this.curTreeData.primaryKeyId:this.curTreeData.pKeyId
|
|
|
|
+ syncNodeParam(this.projectid,pid)
|
|
.then(() => {
|
|
.then(() => {
|
|
this.$message({
|
|
this.$message({
|
|
type: "success",
|
|
type: "success",
|
|
@@ -3457,7 +3508,37 @@ export default {
|
|
});
|
|
});
|
|
});
|
|
});
|
|
},
|
|
},
|
|
-
|
|
|
|
|
|
+ //同步元素表单排序到合同段
|
|
|
|
+ syncSortHandle (data) {
|
|
|
|
+ this.$confirm("同步元素表单排序到合同段", "提示", {
|
|
|
|
+ confirmButtonText: "确定",
|
|
|
|
+ cancelButtonText: "取消",
|
|
|
|
+ type: "warning",
|
|
|
|
+ }).then(() => {
|
|
|
|
+ let notify = this.$notify({
|
|
|
|
+ title: "提示",
|
|
|
|
+ message: "节点数据同步中...",
|
|
|
|
+ duration: 0,
|
|
|
|
+ });
|
|
|
|
+ syncContractTabSort(this.projectid)
|
|
|
|
+ .then(() => {
|
|
|
|
+ this.updateNodeTable();
|
|
|
|
+ this.$message({
|
|
|
|
+ type: "success",
|
|
|
|
+ message: "同步成功",
|
|
|
|
+ });
|
|
|
|
+ })
|
|
|
|
+ .catch(() => {
|
|
|
|
+ this.$message({
|
|
|
|
+ type: "error",
|
|
|
|
+ message: "同步失败",
|
|
|
|
+ });
|
|
|
|
+ })
|
|
|
|
+ .finally(() => {
|
|
|
|
+ notify.close();
|
|
|
|
+ });
|
|
|
|
+ });
|
|
|
|
+ },
|
|
typeTreeLoadNode(node, resolve) {
|
|
typeTreeLoadNode(node, resolve) {
|
|
let pid = 0;
|
|
let pid = 0;
|
|
if (node.level != 0) {
|
|
if (node.level != 0) {
|
|
@@ -3491,7 +3572,7 @@ export default {
|
|
});
|
|
});
|
|
},
|
|
},
|
|
syncElectric(item){
|
|
syncElectric(item){
|
|
- if(this.curTreeData.primaryKeyId){
|
|
|
|
|
|
+ if(this.curTreeData.primaryKeyId||this.curTreeData.pKeyId){
|
|
console.log('同步电签默认信息');
|
|
console.log('同步电签默认信息');
|
|
this.$confirm("是否同步电签默认信息?", "提示", {
|
|
this.$confirm("是否同步电签默认信息?", "提示", {
|
|
confirmButtonText: "确定",
|
|
confirmButtonText: "确定",
|
|
@@ -3504,8 +3585,8 @@ export default {
|
|
ele.load=true
|
|
ele.load=true
|
|
}
|
|
}
|
|
})
|
|
})
|
|
-
|
|
|
|
- syncProjecteVisa(this.projectid,this.curTreeData.primaryKeyId)
|
|
|
|
|
|
+ let pid=this.curTreeData.primaryKeyId?this.curTreeData.primaryKeyId:this.curTreeData.pKeyId
|
|
|
|
+ syncProjecteVisa(this.projectid,pid)
|
|
.then(() => {
|
|
.then(() => {
|
|
this.$message({
|
|
this.$message({
|
|
type: "success",
|
|
type: "success",
|
|
@@ -3551,8 +3632,8 @@ export default {
|
|
tolinkEle(row){
|
|
tolinkEle(row){
|
|
this.curLinkEleTable = row;
|
|
this.curLinkEleTable = row;
|
|
this.linkCheckVisible = true;
|
|
this.linkCheckVisible = true;
|
|
-
|
|
|
|
- selectFormElements(row.id,{type:3,nodeId:this.curTreeData.primaryKeyId}).then((res) => {
|
|
|
|
|
|
+ let pid=this.curTreeData.primaryKeyId?this.curTreeData.primaryKeyId:this.curTreeData.pKeyId
|
|
|
|
+ selectFormElements(row.id,{type:3,nodeId:pid}).then((res) => {
|
|
res.data.data.forEach((ele)=>{
|
|
res.data.data.forEach((ele)=>{
|
|
ele.checked = false;
|
|
ele.checked = false;
|
|
ele.show = true;
|
|
ele.show = true;
|
|
@@ -3648,6 +3729,9 @@ export default {
|
|
}else if(item.key==='sync2'){
|
|
}else if(item.key==='sync2'){
|
|
this.syncProjectHandle(data)
|
|
this.syncProjectHandle(data)
|
|
}//
|
|
}//
|
|
|
|
+ else if(item.key==='sync3'){
|
|
|
|
+ this.syncSortHandle(data)
|
|
|
|
+ }
|
|
else if(item.key==='add'){
|
|
else if(item.key==='add'){
|
|
this.addNodeHandle()
|
|
this.addNodeHandle()
|
|
}
|
|
}
|