Просмотр исходного кода

Merge branch 'hjw-222' into 'master'

家庭渠道导出全部、工作流选人优化

See merge request spfm/spfm-market-front!491
徐兴安 1 год назад
Родитель
Сommit
63a9e83883

+ 1 - 0
.gitignore

@@ -3,6 +3,7 @@ node_modules
 /dist
 dist.zip
 /dist-test
+/dist-production
 dist.zip
 # local env files
 .env.local

+ 80 - 14
src/components/workflowBase.vue

@@ -131,6 +131,8 @@ export default {
       manyReassignment: false,
       actives: "",
       resourceId: '',
+      paramsJson: '',
+      getNextPathindex: 0
     };
   },
   props: {
@@ -419,7 +421,13 @@ export default {
         processId: processDefinitionKey,
       };
       e ? (list.resourceId = e) : list;
-
+      console.log(this.paramsJson);
+      console.log(this.getNextPathindex);
+      // if (this.getNextPathindex == 3) {
+      if (this.paramsJson.length > 1) {
+        list.paramsJson = this.paramsJson
+      }
+      // }
       this.$http({
         url: "/market/waf/queryPath",
         method: "post",
@@ -467,7 +475,57 @@ export default {
             this.node = res.data.body;
           } else {
             this.resourceId = res.data.body.nextShapes[0].resourceId
-            this.getNextPath(res.data.body.nextShapes[0].resourceId, 2);
+            // alert(111)
+            // if (this.getNextPathindex == 2) {
+            let paramsJson = '|'
+            let biggestNum = 0;
+            this.$http({
+              url: "/market/CfgWorkflowChooseNode/queryList",//筛选自定义候选节点
+              method: "post",
+              headers: {
+                "Content-Type": "application/json",
+              },
+              data: {
+                tableName: this.requestForm.processDefinitionKey,
+                fresourceId: this.requestForm.fresourceId,
+                resourceid: this.resourceId,
+              },
+            }).then((ress) => {
+              let arr = []
+              if (ress.data.length > 0) {
+                ress.data.map((item) => {
+                  if (item.paramsJson.length > biggestNum) {
+                    biggestNum = item.paramsJson.length
+                    arr = item.paramsJson.split('|').slice(1)
+                    arr.pop()
+                    console.log(arr);
+
+                  }
+                })
+                arr.map((items, index) => {
+                  console.log(items.split(':'));
+                  paramsJson += items.split(':')[0] + ':' + this.list[items.split(':')[0]] + '|'
+                })
+                // this.getNextPathindex = 0
+                // for (var key in JSON.parse(ress.data[0].paramsJson)) {
+                //   console.log(key, JSON.parse(ress.data[0].paramsJson)[key])
+                //   if (this.requestForm.processDefinitionKey == ress.data[0].tableName) {
+                //     
+                //   }
+                // }
+                // console.log(key)
+              }
+              // paramsJson.nodeResourceId=ress.data[0].nodeResourceId
+              console.log(paramsJson);
+              this.paramsJson = paramsJson
+              this.getNextPathindex++
+              this.getNextPath(res.data.body.nextShapes[0].resourceId, 2);
+            })
+            // }
+
+            // console.log(this.paramsJson);
+
+
           }
         }
         if (status === 3) {
@@ -489,9 +547,10 @@ export default {
     },
     //查询候选人接口
     getTreeLists(e, status) {
-
+      let paramsJson = {}
+      let biggestNum = 0;
       this.$http({
-        url: "/market/CfgWorkflowChoosePerson/queryList",
+        url: "/market/CfgWorkflowChoosePerson/queryList",//筛选自定义候选人
         method: "post",
         headers: {
           "Content-Type": "application/json",
@@ -499,14 +558,25 @@ export default {
         data: {
           tableName: this.requestForm.processDefinitionKey,
           fresourceId: this.requestForm.fresourceId,
+          resourceid: this.resourceId,
         },
       }).then((res) => {
         if (res.data.length > 0) {
-          for (var key in JSON.parse(res.data[0].paramsJson)) {
-            console.log(key, JSON.parse(res.data[0].paramsJson)[key])
-          }
-          console.log(key)
+          res.data.map((item) => {
+            if (item.paramsJson.length > biggestNum) {
+              biggestNum = item.paramsJson.length
+              for (var key in JSON.parse(item.paramsJson)) {
+                console.log(key, JSON.parse(item.paramsJson)[key])
+                if (this.requestForm.processDefinitionKey == item.tableName) {
+                  paramsJson[key] = this.list[key]
+                }
+              }
+            }
+          })
+
+          // console.log(key)
         }
+        console.log(paramsJson);
         // console.log(this.list);
         // console.log(this.requestForm);
 
@@ -517,18 +587,14 @@ export default {
             : e.nextShapes[0].properties.documentation;
         console.log(id);
 
-        let paramsJson = {}
+
         // if (this.requestForm.processDefinitionKey == 'BOMC_process' || this.requestForm.processDefinitionKey == 'ZHQX_process' || this.requestForm.processDefinitionKey == 'ZYSQ_process') {
         //   paramsJson.proposerType = this.list.proposerType
         // }
         // if (this.requestForm.processDefinitionKey == 'YHBG_process') {
         //   paramsJson.changeType = this.list.changeType
         // }
-        if (res.data.length > 0) {
-          if (this.requestForm.processDefinitionKey == res.data[0].tableName) {
-            paramsJson[key] = this.list[key]
-          }
-        }
+
         this.$http({
           url: "/market/api/user/info/queryNodePers?params=" + id,
           method: "post",

+ 387 - 341
src/pages/main/memberFamily/dataStatistics.vue

@@ -2,9 +2,13 @@
 	<fullscreen :fullscreen.sync="fullscreen" class="container">
 		<div class="container-box">
 			<div class="dc">
-				<el-button type="primary" style="margin-right: 20px;" @click="outexl">导出</el-button>
-				<span style="margin-right: 20px;">共 {{fillCnt}} 条数据</span>
-				<span>更新日期:{{lastUpdateTime}}</span>
+				<el-button type="primary" style="margin-right: 10px;" @click="outexl">导出</el-button>
+				<el-button type="primary" @click="outexlAll" v-if="btnout" style="margin:0px 10px;">导出全部</el-button>
+
+				<span style="margin-right: 20px;">共 {{ fillCnt }} 条数据</span>
+				<span>更新日期:{{ lastUpdateTime }}</span>
+
+
 			</div>
 			<div class="tabbox">
 				<el-table height="calc(100% - 40px)" class="com-table" ref="multipleTable" :data="tableData"
@@ -13,234 +17,276 @@
 					<!-- <el-table-column type="selection" width="55">
 					</el-table-column> -->
 					<el-table-column prop="regionName" label="区域名称">
-                        <template slot-scope="scope">
-                            {{scope.row.regionName}}{{scope.row.areaName}}
-                        </template>
+						<template slot-scope="scope">
+							{{ scope.row.regionName }}{{ scope.row.areaName }}
+						</template>
 					</el-table-column>
 					<el-table-column prop="regionDutyName" label="负责人">
-                        <template slot-scope="scope">
-                            {{scope.row.regionDutyName}}{{scope.row.areaDutyName}}
-                        </template>
+						<template slot-scope="scope">
+							{{ scope.row.regionDutyName }}{{ scope.row.areaDutyName }}
+						</template>
 					</el-table-column>
 					<el-table-column prop="cnt" label="员工总数">
 					</el-table-column>
 					<el-table-column label="操作" width="160px" align="center" v-if="look">
 						<template slot-scope="scope">
-							<el-button size="mini" type="primary" @click="choseperson(scope.row)" >查看</el-button>
+							<el-button size="mini" type="primary" @click="choseperson(scope.row)">查看</el-button>
 						</template>
 					</el-table-column>
 				</el-table>
 				<el-pagination class="pageBox" @current-change="currchange" layout="prev, pager, next" background
-                    :total="total">
-                </el-pagination>
+					:total="total">
+				</el-pagination>
 			</div>
 		</div>
 	</fullscreen>
-
 </template>
 <script>
-	import mySearch from "../../../components/search.vue";
-	import myMessage from "../../../components/myMessage.vue"
-	import toolList from '../../../components/toolList'
+import mySearch from "../../../components/search.vue";
+import myMessage from "../../../components/myMessage.vue"
+import toolList from '../../../components/toolList'
 
-	export default {
-		components: {
-			mySearch,
-			myMessage,
-			toolList
+export default {
+	components: {
+		mySearch,
+		myMessage,
+		toolList
+	},
+	data() {
+		return {
+			searchList: [{
+				type: 'input',
+				tit: '供应商名称',
+				value: '',
+				width: '98%',
+			}],
+			tooltit: '人员进度跟踪',
+			fullscreen: false,
+			total: 0,
+			pageSize: 1,
+			tableData: [{}],
+			dialogStatus: false,
+			disableStatus: false,
+			titname: '',
+			infolist: {},
+			userInfo: {},
+			params: {},
+			centerDialogVisible: false,
+			messTit: '',
+			delid: '',
+			loading: false,
+			loadinged: false,
+			btnout: true,
+			look: false,
+			time: '',
+			num: '',
+			fillCnt: '',
+			lastUpdateTime: '',
+			sts: 1,
+			companyFlag: '',
+			isRegionName: '',
+			regionName: '',
+			// excelCityparam: ""
+			memberFamilyBtnShow: "-1"
+		}
+	},
+	methods: {
+		outexlAll() {
+			let url = '/market/cMemberWo/excelExportDetailSummary';
+			let paramsf = {};
+			// if (window.sessionStorage.excelCityparam) {
+			// 	paramsf.regionName = window.sessionStorage.excelCityparam
+			// }
+			if (this.companyFlag == 0) {
+
+			} else if (this.companyFlag == 1) {
+				paramsf.regionName = this.userInfo.cityName
+			}
+			this.$http({
+				url: url,
+				method: "post",
+				responseType: 'blob',
+				headers: {
+					"Content-Type": "application/json",
+				},
+				data: paramsf,
+			}).then((response) => {
+				if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+					let blob = new Blob([response.data], {
+						type: response.data.type
+					});
+					window.navigator.msSaveOrOpenBlob(blob, 'adv.xlsx');
+				} else {
+					/* 火狐谷歌的文件下载方式 */
+					// console.log(response.data.type)
+					var blob = new Blob([response.data])
+					var downloadElement = document.createElement('a')
+					var href = window.URL.createObjectURL(blob);
+					downloadElement.href = href;
+					downloadElement.download = 'adv.xlsx';
+					document.body.appendChild(downloadElement);
+					downloadElement.click();
+					document.body.removeChild(downloadElement);
+					window.URL.revokeObjectURL(href);
+				}
+			});
 		},
-		data() {
-			return {
-				searchList: [{
-					type: 'input',
-					tit: '供应商名称',
-					value: '',
-					width: '98%',
-				}],
-				tooltit: '人员进度跟踪',
-				fullscreen: false,
-				total: 0,
-				pageSize: 1,
-				tableData: [{}],
-				dialogStatus: false,
-				disableStatus: false,
-				titname: '',
-				infolist: {},
-				userInfo: {},
-				params: {},
-				centerDialogVisible: false,
-				messTit: '',
-				delid: '',
-				loading: false,
-				loadinged: false,
-				look:false,
-				time: '',
-				num: '',
-				fillCnt: '',
-				lastUpdateTime: '',
-                sts:1,
-                companyFlag:'',
-                isRegionName:'',
-				regionName:'',
-				// excelCityparam: ""
-				memberFamilyBtnShow: "-1"
+		outexl() {
+			let url = '';
+			let paramsf = {};
+			if (window.sessionStorage.excelCityparam) {
+				paramsf.regionName = window.sessionStorage.excelCityparam
+			}
+			if (this.sts == 1) {
+				url = '/market/cMemberWo/excelExportSummaryByProv';
+			} else {
+				url = '/market/cMemberWo/excelExportSummaryByArea';
 			}
+			this.$http({
+				url: url,
+				method: "post",
+				responseType: 'blob',
+				headers: {
+					"Content-Type": "application/json",
+				},
+				data: paramsf,
+			}).then((response) => {
+				if (window.navigator && window.navigator.msSaveOrOpenBlob) {
+					let blob = new Blob([response.data], {
+						type: response.data.type
+					});
+					window.navigator.msSaveOrOpenBlob(blob, 'adv.xlsx');
+				} else {
+					/* 火狐谷歌的文件下载方式 */
+					// console.log(response.data.type)
+					var blob = new Blob([response.data])
+					var downloadElement = document.createElement('a')
+					var href = window.URL.createObjectURL(blob);
+					downloadElement.href = href;
+					downloadElement.download = 'adv.xlsx';
+					document.body.appendChild(downloadElement);
+					downloadElement.click();
+					document.body.removeChild(downloadElement);
+					window.URL.revokeObjectURL(href);
+				}
+			});
 		},
-		methods: {
-            outexl(){
-                let url = '';
-                let paramsf = {};
-				if(window.sessionStorage.excelCityparam){
-					paramsf.regionName = window.sessionStorage.excelCityparam
+		choseperson(v) {
+			if (this.btnout) {
+				this.btnout = false
+			}
+			if (v.showButton) {
+				window.sessionStorage.memberFamilyBtnShow = v.showButton;
+			}
+			if (this.companyFlag == 0) {
+				if (v.regionName == "省公司") {
+					this.$router.push({
+						path: "/employeeInfo",
+						query: {
+							regionName: v.regionName,
+							isRegionName: v.isRegionName
+						}
+					});
+					this.setabList("员工信息", "/employeeInfo?regionName=" + v.regionName);
+					return
 				}
-                if(this.sts == 1){
-                    url = '/market/cMemberWo/excelExportSummaryByProv';
-                }else{
-                    url = '/market/cMemberWo/excelExportSummaryByArea';
-                }
-                this.$http({
-                    url: url,
-                    method: "post",
-                    responseType: 'blob',
-                    headers: {
-                        "Content-Type": "application/json",
-                    },
-                    data: paramsf,
-                }).then((response) => {
-                    if (window.navigator && window.navigator.msSaveOrOpenBlob) {
-                        let blob = new Blob([response.data], {
-                            type: response.data.type
-                        });
-                        window.navigator.msSaveOrOpenBlob(blob, 'adv.xlsx');
-                    } else {
-                        /* 火狐谷歌的文件下载方式 */
-                        // console.log(response.data.type)
-                        var blob = new Blob([response.data])
-                        var downloadElement = document.createElement('a')
-                        var href = window.URL.createObjectURL(blob);
-                        downloadElement.href = href;
-                        downloadElement.download = 'adv.xlsx';
-                        document.body.appendChild(downloadElement);
-                        downloadElement.click();
-                        document.body.removeChild(downloadElement);
-                        window.URL.revokeObjectURL(href);
-                    }
-                });
-            },
-			choseperson(v){
-			
-				if(v.showButton){
-					window.sessionStorage.memberFamilyBtnShow = v.showButton;
+				// if(v.areaName == "省公司"){
+				// 	this.$router.push({
+				//     	path: "/employeeInfo",
+				//         query:{
+				//             regionName:v.areaName
+				//         }
+				//     });
+				//     this.setabList("员工信息", "/employeeInfo?regionName="+v.areaName);
+				// 	return
+				// }
+				if (this.sts == 2) {
+					this.$router.push({
+						path: "/employeeInfo",
+						query: {
+							regionName: v.areaName,
+							isRegionName: v.isRegionName
+						}
+					});
+					this.setabList("员工信息", "/employeeInfo?regionName=" + v.areaName);
+					return
 				}
-                if(this.companyFlag == 0){
-					if(v.regionName == "省公司"){
-						 this.$router.push({
-                        	path: "/employeeInfo",
-                            query:{
-                                regionName:v.regionName,
-								isRegionName:v.isRegionName
-                            }
-                        });
-                        this.setabList("员工信息", "/employeeInfo?regionName="+v.regionName);
-						return
-					}
-					// if(v.areaName == "省公司"){
-					// 	this.$router.push({
-                    //     	path: "/employeeInfo",
-                    //         query:{
-                    //             regionName:v.areaName
-                    //         }
-                    //     });
-                    //     this.setabList("员工信息", "/employeeInfo?regionName="+v.areaName);
-					// 	return
-					// }
-                    if(this.sts == 2){
-                        this.$router.push({
-                        	path: "/employeeInfo",
-                            query:{
-                                regionName:v.areaName,
-								isRegionName:v.isRegionName
-                            }
-                        });
-                        this.setabList("员工信息", "/employeeInfo?regionName="+v.areaName);
-                        return
-                    }
-					window.sessionStorage.excelCityparam = v.regionName;
-                    this.$http({
-                    	url: "/market/cMemberWo/querySummaryByAreaPage",
-                    	method: "post",
-                    	headers: {
-                    		"Content-Type": "application/json",
-                    		"page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
-                    	},
-                    	data: {regionName:v.regionName},
-                    }).then((res) => {
-                    	this.tableData = res.data.data;
-                    	this.total = res.data.totalRecord;
-                    	this.loading = false;
-						this.isRegionName = res.data.data.isRegionName;
-                        this.sts = 2;
-                    });
-					
-                }else{
-                    this.$router.push({
-                    	path: "/employeeInfo?regionName="+v.areaName,
-                        query:{
-                            regionName:v.areaName,
-							isRegionName:v.isRegionName
-                        }
-                    });
-					
-                    this.setabList("员工信息", "/employeeInfo?regionName="+v.areaName);
-                }
-			},
-			setabList(n, p) {
-				let params = {
-					children: "",
-					name: n,
-					rountPath: p,
-					target: "_self",
-				};
-				for (let i = 0; i < this.$store.state.tabList.length; i++) {
-					if (this.$store.state.tabList[i].name === params.name) {
-						this.$store.state.tabList[i] = params;
+				window.sessionStorage.excelCityparam = v.regionName;
+				this.$http({
+					url: "/market/cMemberWo/querySummaryByAreaPage",
+					method: "post",
+					headers: {
+						"Content-Type": "application/json",
+						"page": '{"pageNo":"' + 1 + '","pageSize":"100"}'
+					},
+					data: { regionName: v.regionName },
+				}).then((res) => {
+					this.tableData = res.data.data;
+					this.total = res.data.totalRecord;
+					this.loading = false;
+					this.isRegionName = res.data.data.isRegionName;
+					this.sts = 2;
+				});
+
+			} else {
+				this.$router.push({
+					path: "/employeeInfo?regionName=" + v.areaName,
+					query: {
+						regionName: v.areaName,
+						isRegionName: v.isRegionName
 					}
+				});
+
+				this.setabList("员工信息", "/employeeInfo?regionName=" + v.areaName);
+			}
+		},
+		setabList(n, p) {
+			let params = {
+				children: "",
+				name: n,
+				rountPath: p,
+				target: "_self",
+			};
+			for (let i = 0; i < this.$store.state.tabList.length; i++) {
+				if (this.$store.state.tabList[i].name === params.name) {
+					this.$store.state.tabList[i] = params;
 				}
-				let set = new Set([...this.$store.state.tabList, params]);
-				set.add(params);
-				this.$store.commit("setDefaultActive", params.rountPath);
-				this.$store.commit("setTabList", Array.from(set));
-			},
-			handleSelectionChange(val) {
-				// console.log(val) 
-			},
-			//搜索数据
-			searchInfo(v) {
-				this.params = {};
-				v[0] ? this.params.supplierName = v[0] : '';
-				this.getList(this.params, this.pageSize);
-			},
-			//获取列表
-			getList(v, n) {
-		
-				this.pageSize = n;
-				let _this = this;
-				this.loading = true;
-				this.tableData = [];
-                let url = '';
-				if(this.companyFlag == 2){
-					this.$router.push({
-                    	path: "/employeeInfo?regionName="+v.areaName,
-                        query:{
-                            regionName:this.regionName,
-							isRegionName:v.isRegionName
-                        }
-                    });
-					
-                    this.setabList("员工信息", "/employeeInfo?regionName="+v.areaName);
-				}else if(this.companyFlag == 0){
-                    url="/market/cMemberWo/querySummaryByProvPage"
-					this.$http({
+			}
+			let set = new Set([...this.$store.state.tabList, params]);
+			set.add(params);
+			this.$store.commit("setDefaultActive", params.rountPath);
+			this.$store.commit("setTabList", Array.from(set));
+		},
+		handleSelectionChange(val) {
+			// console.log(val) 
+		},
+		//搜索数据
+		searchInfo(v) {
+			this.params = {};
+			v[0] ? this.params.supplierName = v[0] : '';
+			this.getList(this.params, this.pageSize);
+		},
+		//获取列表
+		getList(v, n) {
+
+			this.pageSize = n;
+			let _this = this;
+			this.loading = true;
+			this.tableData = [];
+			let url = '';
+			if (this.companyFlag == 2) {
+				this.$router.push({
+					path: "/employeeInfo?regionName=" + v.areaName,
+					query: {
+						regionName: this.regionName,
+						isRegionName: v.isRegionName
+					}
+				});
+
+				this.setabList("员工信息", "/employeeInfo?regionName=" + v.areaName);
+			} else if (this.companyFlag == 0) {
+				url = "/market/cMemberWo/querySummaryByProvPage"
+				this.$http({
 					url: url,
 					method: "post",
 					headers: {
@@ -253,14 +299,14 @@
 					this.total = res.data.totalRecord;
 					this.loading = false;
 					// this.isRegionName = res.data.data.isRegionName;
-					
+
 				});
-                }else if(this.companyFlag == 1){
-                    url="/market/cMemberWo/querySummaryByAreaPage"
-                    v.regionName = this.userInfo.cityName
-					window.sessionStorage.excelCityparam = this.userInfo.cityName;
-					this.sts = 2
-                
+			} else if (this.companyFlag == 1) {
+				url = "/market/cMemberWo/querySummaryByAreaPage"
+				v.regionName = this.userInfo.cityName
+				window.sessionStorage.excelCityparam = this.userInfo.cityName;
+				this.sts = 2
+
 				this.$http({
 					url: url,
 					method: "post",
@@ -274,161 +320,161 @@
 					this.total = res.data.totalRecord;
 					this.loading = false;
 					// this.isRegionName = res.data.data.isRegionName;
-					
+
 				});
-				}
-			},
-			judgment(){
-				this.userInfo = JSON.parse(window.sessionStorage.userInfo);
-				if(this.userInfo.duty <= 9){
-					if(this.userInfo.loginNoStr == "kanyanli"){
-						this.look = true;
-					}else{
-						this.look = false;
-					}
-					
-				}else{
+			}
+		},
+		judgment() {
+			this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+			if (this.userInfo.duty <= 9) {
+				if (this.userInfo.loginNoStr == "kanyanli") {
 					this.look = true;
+				} else {
+					this.look = false;
 				}
-			},
-			// 分页
-			currchange(v) {
-				this.pageSize = v;
-				this.getList(this.params, this.pageSize);
-			},
-			//申请
-			dialogCheck(v, n) {
-				this.dialogStatus = true;
-				this.infolist = Object.assign({}, n);
-				if (v === 1) {
-					this.titname = '查看';
-					this.disableStatus = true;
-					return
-				} else if (v === 2) {
-					this.titname = '修改';
-					this.disableStatus = false;
-				} else if (v === 3) {
-					this.titname = '添加';
-					this.disableStatus = false;
-				}
-				this.infolist.opNo = this.userInfo.loginNo;
-				this.infolist.opName = this.userInfo.loginName;
-			},
-			//功能栏
-			iconCli(v) {
-				if (v === 1) {
-					this.getList(this.params, this.pageSize);
-				}
-				if (v === 2) {
-					this.fullscreen = !this.fullscreen
-				}
-			},
-			getUser() {
-				this.userInfo = JSON.parse(window.sessionStorage.userInfo);
-                this.$http({
-                	url: "/market/cMemberFillDetail/querySummaryInfo",
-                	method: "post",
-                	headers: {
-                		"Content-Type": "application/json",
-                	},
-                	data: {},
-                }).then((res) => {
-                    this.fillCnt = res.data.fillCnt;
-                    this.lastUpdateTime = res.data.lastUpdateTime;
-                });
 
-                this.$http({
-                    url: "/sysmgr/csysuserinfo/queryUserInfoByLoginNo",
-                    method: "post",
-                    headers: {
-                        "Content-Type": "application/json",
-                    },
-                    data: {},
-                }).then((res) => {
-                    this.companyFlag = res.data.companyFlag;
-					this.regionName = res.data.groupName;
-                     this.getList({}, 1);
-                });
+			} else {
+				this.look = true;
 			}
 		},
-		mounted() {
-			this.getUser();
-			this.judgment();
-			window.sessionStorage.memberFamilyBtnShow = this.memberFamilyBtnShow
+		// 分页
+		currchange(v) {
+			this.pageSize = v;
+			this.getList(this.params, this.pageSize);
+		},
+		//申请
+		dialogCheck(v, n) {
+			this.dialogStatus = true;
+			this.infolist = Object.assign({}, n);
+			if (v === 1) {
+				this.titname = '查看';
+				this.disableStatus = true;
+				return
+			} else if (v === 2) {
+				this.titname = '修改';
+				this.disableStatus = false;
+			} else if (v === 3) {
+				this.titname = '添加';
+				this.disableStatus = false;
+			}
+			this.infolist.opNo = this.userInfo.loginNo;
+			this.infolist.opName = this.userInfo.loginName;
 		},
-		created() {
+		//功能栏
+		iconCli(v) {
+			if (v === 1) {
+				this.getList(this.params, this.pageSize);
+			}
+			if (v === 2) {
+				this.fullscreen = !this.fullscreen
+			}
+		},
+		getUser() {
+			this.userInfo = JSON.parse(window.sessionStorage.userInfo);
+			this.$http({
+				url: "/market/cMemberFillDetail/querySummaryInfo",
+				method: "post",
+				headers: {
+					"Content-Type": "application/json",
+				},
+				data: {},
+			}).then((res) => {
+				this.fillCnt = res.data.fillCnt;
+				this.lastUpdateTime = res.data.lastUpdateTime;
+			});
 
+			this.$http({
+				url: "/sysmgr/csysuserinfo/queryUserInfoByLoginNo",
+				method: "post",
+				headers: {
+					"Content-Type": "application/json",
+				},
+				data: {},
+			}).then((res) => {
+				this.companyFlag = res.data.companyFlag;
+				this.regionName = res.data.groupName;
+				this.getList({}, 1);
+			});
 		}
+	},
+	mounted() {
+		this.getUser();
+		this.judgment();
+		window.sessionStorage.memberFamilyBtnShow = this.memberFamilyBtnShow
+	},
+	created() {
+
 	}
+}
 </script>
 <style scoped lang="scss">
-	.onetab {
-		margin-bottom: 20px;
-		padding: 0 20px;
-	}
+.onetab {
+	margin-bottom: 20px;
+	padding: 0 20px;
+}
 
-	.titbox {
-		div {
-			float: right;
+.titbox {
+	div {
+		float: right;
 
-			i {
-				font-size: 22px;
-				margin-left: 20px;
-				cursor: pointer;
-			}
+		i {
+			font-size: 22px;
+			margin-left: 20px;
+			cursor: pointer;
 		}
 	}
+}
 
-	.tabbox {
-		margin-top: 15px;
-	}
+.tabbox {
+	margin-top: 15px;
+}
 
-	.pageBox {
-		text-align: right;
-		margin-top: 10px;
-	}
+.pageBox {
+	text-align: right;
+	margin-top: 10px;
+}
 
-	.info-line {
-		width: 100%;
-		display: block;
-		padding-left: 20px;
+.info-line {
+	width: 100%;
+	display: block;
+	padding-left: 20px;
 
-		div {
-			width: 50%;
-			display: inline-block;
-		}
+	div {
+		width: 50%;
+		display: inline-block;
+	}
 
-		span {
-			width: 80px;
-			display: inline-block;
-			text-align: left;
+	span {
+		width: 80px;
+		display: inline-block;
+		text-align: left;
 
-			i {
-				color: red;
-				display: inline-block;
-				padding-right: 5px;
-			}
+		i {
+			color: red;
+			display: inline-block;
+			padding-right: 5px;
 		}
+	}
 
-		.el-select,
-		.el-input {
-			width: calc(100% - 100px);
-		}
+	.el-select,
+	.el-input {
+		width: calc(100% - 100px);
 	}
+}
 
-	.online {
-		width: 100%;
+.online {
+	width: 100%;
 
-		.el-select {
-			width: calc(100% - 100px);
-		}
+	.el-select {
+		width: calc(100% - 100px);
+	}
 
-		span {
-			vertical-align: top;
-		}
+	span {
+		vertical-align: top;
+	}
 
-		.el-textarea {
-			width: calc(100% - 100px);
-		}
+	.el-textarea {
+		width: calc(100% - 100px);
 	}
+}
 </style>

+ 247 - 17
src/pages/main/workflowdef/qathList.vue

@@ -1,14 +1,14 @@
 <template>
     <div class="flex-box1">
         <Seach :list="filterDataTwo" @seachList="seachList"></Seach>
-        <el-table :data="tableData" style="width: 100%;min-height: 600px;" ref="refTable" height="600px">
+        <el-table :data="tableData" v-loading="loading" style="width: 100%;min-height: 600px;" ref="refTable"
+            height="600px">
             <el-table-column type="expand">
                 <template slot-scope="props">
                     <el-table :data="props.row.nextNodes" size="mini" style="width: 95%;margin-left: 5%;"
                         @cell-click="getRowList">
                         <el-table-column label="下一步环节" prop="name"></el-table-column>
                         <el-table-column label="resourceId" prop="resourceId"></el-table-column>
-
                     </el-table>
                 </template>
             </el-table-column>
@@ -20,15 +20,17 @@
                 <template slot-scope="scope">
                     <el-button size="mini" type="text" @click="getRiskadminform(scope.row)">
                         配置候选人</el-button>
+                    <el-button size="mini" type="text" @click="getRiskadminform2(scope.row)">
+                        配置候选节点</el-button>
                 </template>
             </el-table-column>
         </el-table>
 
 
-        <el-dialog title="配置信息" :visible.sync="dialogStatus" width="100%" style="height: 100%" :fullscreen="true"
+        <el-dialog title="配置候选人信息" :visible.sync="dialogStatus" width="100%" style="height: 100%" :fullscreen="true"
             :before-close="handleClose1" :modal="false" v-if="dialogStatus" :destroy-on-close="true">
             <el-button type="primary" @click="dialogTreeStatus2 = true">新增</el-button>
-            <el-button type="primary" v-if="delarr.length>0" @click="delarrbtn">批量删除</el-button>
+            <el-button type="primary" v-if="delarr.length > 0" @click="delarrbtn">批量删除</el-button>
             <el-table :data="tableData2" v-loading="loading" style="width: 100%;min-height: 600px;" ref="refTable"
                 height="600px" @selection-change="selectionChange">
                 <!-- 是否多选 -->
@@ -53,26 +55,125 @@
                 :total="adminpageData.total" @size-change="adminhandleSizeChange"
                 @current-change="adminhandleCurrentChange" />
         </el-dialog>
+        <el-dialog title="配置节点信息" :visible.sync="dialogStatus2" width="100%" style="height: 100%" :fullscreen="true"
+            :before-close="handleClose4" :modal="false" v-if="dialogStatus2" :destroy-on-close="true">
+            <!-- <el-button type="primary" @click="dialogTreeStatus3 = true">新增</el-button> -->
+            <!-- <el-button type="primary" v-if="delarr.length > 0" @click="delarrbtn2">批量删除</el-button> -->
+            <div style="display: flex;">
+                <el-table :data="tableData3" style="width: 100%;min-height: 600px;" ref="refTable4" height="600px"
+                    @selection-change="selectionChange">
+                    <!-- 是否多选 -->
+                    <!-- <el-table-column type="selection" width="55">
+                    </el-table-column> -->
+                    <el-table-column type="expand">
+                        <template slot-scope="props">
+                            <el-table :data="props.row.nextNodes" size="mini" style="width: 95%;margin-left: 5%;"
+                                @cell-click="getRowList">
+                                <el-table-column type="expand">
+                                    <template slot-scope="props">
+                                        <el-table :data="props.row.nextNodes" size="mini"
+                                            style="width: 95%;margin-left: 5%;" @cell-click="getRowList">
+                                            <el-table-column label="name" prop="name"></el-table-column>
+                                            <el-table-column label="resourceId" prop="resourceId"></el-table-column>
+                                            <el-table-column label="json" prop="json">
+                                            </el-table-column>
+                                            <el-table-column label="操作" align="center">
+                                                <template slot-scope="scope">
+                                                    <el-button size="mini" type="text" @click="jiedianedit(scope.row)">
+                                                        配置字段</el-button>
+                                                    <el-button size="mini" type="text" @click="delarrbtn2(scope.row)">
+                                                        删除字段</el-button>
+                                                </template>
+                                            </el-table-column>
+                                        </el-table>
+                                    </template>
+                                </el-table-column>
+                                <el-table-column label="name" prop="name"></el-table-column>
+                                <el-table-column label="resourceId" prop="resourceId"></el-table-column>
+                                <el-table-column label="json" prop="json">
+                                </el-table-column>
+                                <el-table-column label="操作" align="center">
+                                    <template slot-scope="scope">
+                                        <el-button size="mini" type="text" @click="jiedianedit(scope.row)">
+                                            配置字段</el-button>
+                                        <el-button size="mini" type="text" @click="delarrbtn2(scope.row)">
+                                            删除字段</el-button>
+                                    </template>
+                                </el-table-column>
+                            </el-table>
+                        </template>
+                    </el-table-column>
+                    <el-table-column label="name" prop="name">
+                    </el-table-column>
+                    <el-table-column label="resourceId" prop="resourceId">
+                    </el-table-column>
+                    <el-table-column label="json" prop="json">
+                    </el-table-column>
+                    <el-table-column label="操作" align="center">
+                        <template slot-scope="scope">
+                            <el-button size="mini" type="text" @click="jiedianedit(scope.row)">
+                                配置字段</el-button>
+                            <el-button size="mini" type="text" @click="delarrbtn2(scope.row)">
+                                删除字段</el-button>
+                        </template>
+                    </el-table-column>
+                </el-table>
 
-        <el-dialog title="配置字段" :visible.sync="dialogTreeStatus2" width="100%" style="height: 100%" :fullscreen="true"
+            </div>
+         
+        </el-dialog>
+
+        <el-dialog title="配置候选人字段" :visible.sync="dialogTreeStatus2" width="100%" style="height: 100%" :fullscreen="true"
             :before-close="handleClose2" :modal="false" v-if="dialogTreeStatus2" :destroy-on-close="true">
             <div style="height: 100%">
                 <div style="height: 100%">
                     <el-form ref="form" :model="fromList" :rules="rule" label-width="130px" style="margin-top: 30px">
-                        <div class="flex-header">
-                            <el-form-item label="字段名称:" prop="needName">
-                                <el-input v-model="fromList.needName"></el-input>
+                        <div v-for="(item, index) in fromList.limitList">
+                            <el-form-item label="字段名称:">
+                                <el-input v-model="item.needName"></el-input>
                             </el-form-item>
-                        </div>
-                        <div class="flex-header">
-                            <el-form-item label="字段值:" prop="needCode">
-                                <el-input v-model="fromList.needCode"></el-input>
+                            <el-form-item label="字段值:">
+                                <el-input v-model="item.needCode"></el-input>
                             </el-form-item>
                         </div>
                     </el-form>
+
                     <div style="text-align: center; margin-top: 30px">
+                        <el-button style="width: 80px;margin-right: 20px;margin-left: 40px" @click="addNewLimitAuth()">添加
+                        </el-button>
                         <el-button type="primary" @click="clickSave(1)">确 定</el-button>
                         <el-button @click="dialogTreeStatus2 = false;">取 消</el-button>
+                        <el-button style="width: 80px;margin-right: 20px;margin-left: 40px" type="danger"
+                            v-if="fromList.limitList.length > 1" @click="delNewLimitAuth()">删除
+                        </el-button>
+                    </div>
+                </div>
+            </div>
+        </el-dialog>
+        <el-dialog title="配置节点字段" :visible.sync="dialogTreeStatus3" width="100%" style="height: 100%" :fullscreen="true"
+            :before-close="handleClose5" :modal="false" v-if="dialogTreeStatus3" :destroy-on-close="true">
+            <div style="height: 100%">
+                <div style="height: 100%">
+                    <!-- 上一级resourceId: <el-input v-model="resourceId"></el-input> -->
+                    <el-form ref="form" :model="fromList" :rules="rule" label-width="130px" style="margin-top: 30px">
+                        <div v-for="(item, index) in fromList.limitList">
+                            <el-form-item label="字段名称:">
+                                <el-input v-model="item.needName"></el-input>
+                            </el-form-item>
+                            <el-form-item label="字段值:">
+                                <el-input v-model="item.needCode"></el-input>
+                            </el-form-item>
+                        </div>
+                    </el-form>
+
+                    <div style="text-align: center; margin-top: 30px">
+                        <el-button style="width: 80px;margin-right: 20px;margin-left: 40px" @click="addNewLimitAuth()">添加
+                        </el-button>
+                        <el-button type="primary" @click="clickSave(3)">确 定</el-button>
+                        <el-button @click="dialogTreeStatus3 = false;">取 消</el-button>
+                        <el-button style="width: 80px;margin-right: 20px;margin-left: 40px" type="danger"
+                            v-if="fromList.limitList.length > 1" @click="delNewLimitAuth()">删除
+                        </el-button>
                     </div>
                 </div>
             </div>
@@ -107,8 +208,10 @@ export default {
         return {
             loading: false,
             dialogStatus: false,
+            dialogStatus2: false,
             dialogTreeStatus: false,
             dialogTreeStatus2: false,
+            dialogTreeStatus3: false,
             rule: {
                 needCode: [
                     { required: true, message: "请添加字段值", trigger: "blur" },
@@ -138,25 +241,57 @@ export default {
             searchBox: {},
             tableData: [],
             tableData2: [],
+            tableData3: [],
             adminpageData: {
                 total: 15, // 总条数
                 pageSizes: 10, // 每页数量
                 pageNum: 1, // 页码
             },
-            fromList: {},
+            fromList: {
+                limitList: [{}]
+            },
             resourceId: '',
+            nodeResourceId: '',
             treeListonly: [],
             defaultList: [],
             delarr: [],
             depttype: 0,
             closeList: false,
+            updatestatusId: '',
+
 
         }
     },
     methods: {
+        addNewLimitAuth() {
+            var _this = this;
+            console.log(_this.fromList.limitList);
+            _this.fromList.limitList.push({
+                index: 1
+            });
+        },
+        delNewLimitAuth() {
+            this.fromList.limitList.pop()
+        },
         getRowList() {
 
         },
+        jiedianedit(v) {
+            console.log(v);
+            if (v.id) {
+                this.updatestatusId = v.id
+            } else {
+                this.updatestatusId = ''
+            }
+            this.resourceId = v.parentResourceId
+            this.nodeResourceId = v.resourceId
+            this.dialogTreeStatus3 = true
+        },
+        jiedianadd(v) {
+
+            this.nodeResourceId = v.resourceId
+            this.dialogTreeStatus3 = true
+        },
         delarrbtn() {///CfgWorkflowChoosePerson/delBatch
             this.$http({
                 url: "/market/CfgWorkflowChoosePerson/delBatch",
@@ -174,6 +309,27 @@ export default {
                 this.getRiskadminform(this.resourceId)
             });
         },
+        delarrbtn2(v) {///CfgWorkflowChoosePerson/delBatch
+            this.$http({
+                url: "/market/CfgWorkflowChooseNode/del",
+                method: "post",
+                headers: {
+                    "Content-Type": "application/json",
+                },
+                data: {
+                    id: v.id
+                },
+            }).then((res) => {
+                this.$notify({
+                    title: res.data.desc,
+                    message: res.data.desc,
+                    type: "success",
+                });
+                this.dialogStatus2 = false;
+                this.getRiskadminList(this.searchBox)
+                this.getRiskadminList(this.searchBox)
+            });
+        },
         del(v) {///CfgWorkflowChoosePerson/delBatch
             this.$http({
                 url: "/market/CfgWorkflowChoosePerson/del",
@@ -203,7 +359,7 @@ export default {
         },
         selectionChange(val) {
             console.log(val);
-            this.delarr=val
+            this.delarr = val
         },
         getRiskadminform(v) {///CfgWorkflowChoosePerson/queryPage
             console.log(v);
@@ -229,6 +385,21 @@ export default {
             });
 
         },
+        getRiskadminform2(v) {///CfgWorkflowChoosePerson/queryPage
+            console.log(v);
+            let list = this.searchBox
+            // list.resourceid = v.resourceId
+            // list.tableName = v.processId
+            // list.type='1'
+            if (v.resourceId) {
+                this.resourceId = v.resourceId
+            }
+            // this.loading = true
+            this.tableData3 = v.nextNodes
+            this.dialogStatus2 = true
+         
+
+        },
         async clickSave(v) {
             if (v == 1) {
                 this.$refs.form.validate((valid) => {
@@ -239,14 +410,19 @@ export default {
                         return false;
                     }
                 });
-            } else {
+            } else if (v == 2) {
                 // console.log(this.treeListonly);
                 // console.log(this.fromList);
                 // console.log(this.resourceId);
                 // console.log(this.searchBox);
                 let paramsJson = {}
-                paramsJson[this.fromList.needName] = this.fromList.needCode
-                // console.log(paramsJson);
+                this.fromList.limitList.map((item) => {
+                    console.log(item);
+                    paramsJson[item.needName] = item.needCode
+                })
+
+
+                console.log(paramsJson);
                 let arr = []
                 this.treeListonly.map((item) => {
                     arr.push({
@@ -274,6 +450,49 @@ export default {
                     this.dialogStatus = false;
                     this.dialogTreeStatus2 = false;
                 });
+            } else if (v == 3) {
+                console.log(this.fromList);
+                console.log(this.nodeResourceId);
+                let paramsJson = '|'
+                this.fromList.limitList.map((item) => {
+                    console.log(item);
+                    paramsJson += item.needName + ':' + item.needCode + '|'
+                })
+                let url = '/market/CfgWorkflowChooseNode/add'
+                let list = {
+                    tableName: this.searchBox.processId,
+                    fresourceid: this.searchBox.fresourceId,
+                    resourceid: this.resourceId,
+                    nodeResourceId: this.nodeResourceId,
+                    paramsJson: paramsJson,
+                }
+                if (this.updatestatusId) {
+                    url = '/market/CfgWorkflowChooseNode/update'
+                    list.id = this.updatestatusId
+                }
+
+                console.log(paramsJson);
+
+                this.$http({
+                    url: url,
+                    method: "post",
+                    headers: {
+                        "Content-Type": "application/json",
+                    },
+                    data: list,
+                }).then((res) => {
+                    this.$notify({
+                        title: res.data.desc,
+                        message: res.data.desc,
+                        type: "success",
+                    });
+                    this.dialogTreeStatus = false;
+                    this.dialogStatus = false;
+                    this.dialogStatus2 = false;
+                    this.dialogTreeStatus3 = false;
+                    this.getRiskadminList(this.searchBox)
+                    this.getRiskadminList(this.searchBox)
+                });
             }
 
 
@@ -290,6 +509,12 @@ export default {
         handleClose1() {//关闭弹窗
             this.dialogStatus = false;
         },
+        handleClose4() {//关闭弹窗
+            this.dialogStatus2 = false;
+        },
+        handleClose5() {//关闭弹窗
+            this.dialogTreeStatus3 = false;
+        },
         handleClose2() {//关闭弹窗
             this.dialogTreeStatus2 = false;
         },
@@ -297,6 +522,10 @@ export default {
             this.dialogTreeStatus = false;
         },
         getRiskadminList(e) {
+            let form = {}
+            form = this.searchBox
+            // form.type = '0'
+            this.loading = true
             this.$http({
                 url: "/market/waf/queryPathList",
                 method: "post",
@@ -306,6 +535,7 @@ export default {
                 data: this.searchBox,
             }).then((res) => {
                 this.tableData = res.data.body;
+                this.loading = false
 
             });
         },