| 
					
				 | 
			
			
				@@ -1,4 +1,4 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-<template xmlns:v-slot="http://www.w3.org/1999/XSL/Transform"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+<template xmlns:v-slot="http://www.w3.org/1999/XSL/Transform" xmlns:c="http://www.w3.org/1999/XSL/Transform"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 	<div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		<el-form :model="inputForm" ref="inputForm" v-loading="loading" :class="method==='view'?'readonly':''" :disabled=" method==='view' || status === 'audit' ||status === 'taskFormDetail'" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				 label-width="100px" @submit.native.prevent> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -285,6 +285,15 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					<el-button style="margin-left: 20px" type="primary" :disabled="method==='view' || status === 'audit' || status === 'taskFormDetail'" @click="insertEvent('project')" plain> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 						新增 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					</el-button> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					<el-button v-if="inputForm.id" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						ref="exportButton" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						style="margin-left: 20px" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						type="primary" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						@click="exportReimbursementProjectFileById()" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						:disabled="false" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						plain> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						导出报销详情 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					</el-button> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				</el-divider> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				<el-row  :gutter="15" > 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					<el-col :span="24"> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -445,6 +454,16 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 	import PaymentByUserIdForm from './PaymentByUserIdForm' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 	import ProjectForm from '@/views/materialManagement/userSeal/ProjectForm' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 	export default { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+		updated() { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			this.$nextTick(() => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				const button = this.$refs.exportButton; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				if (button) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					button.$el.disabled = false; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					button.$el.classList.remove('is-disabled'); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			}); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+		}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		props: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			businessId: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				type: String, 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -461,6 +480,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		data () { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			return { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				isButtonDisabled: false, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				validRules: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					userName: [ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 						{required: true, message: '报销人不能为空'} 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -574,6 +594,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			getUpload () { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			init (method, id) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.method = method 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.inputForm = { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -700,6 +721,21 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					this.inputForm.amountInfos.splice(rowIndex, 1) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			// 下载文档 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			exportReimbursementProjectFileById () { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				this.loading = true 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				this.reimbursementService.exportReimbursementProjectFileById(this.inputForm.id).then((res) => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					// 将二进制流文件写入excel表,以下为重要步骤 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.$utils.downloadExcel(res, '项目报销数据导出') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.loading = false 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				}).catch(function (err) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.loading = false 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					if (err.response) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						console.log(err.response) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			// 新增 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			async insertEvent (type) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				if (type === 'borrows') { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -1006,13 +1042,24 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			openProgramPageForm3 (rowIndex, row) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			openProgramPageForm3: async function (rowIndex, row) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				if (this.commonJS.isEmpty(row.typeName)) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					this.$message.error('请选择报销类型') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					return 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				console.log("row信息:", row) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.indexRow = rowIndex 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				this.$refs.projectForm.init('', true) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				//根据报销类型查询判定项目是否单选还是多选 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				await this.reimbursementApprovalTypeService.findReimbursementTypeSingleSelectById(row.typeId).then((data) => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						console.log('name', data.name) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						console.log('data', data) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						let name = data.name.toString() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						if (name === '业务绩效费用报销') { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+							this.$refs.projectForm.init('', 1) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						} else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+							this.$refs.projectForm.init('', true) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+						} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			openProgramPageForm4 (rowIndex, row) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				if (this.commonJS.isEmpty(row.typeName)) { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -1048,7 +1095,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.$forceUpdate() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			getProgram (rows) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				console.log('rows',rows) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				console.log('rows:',rows) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.inputForm.infoProjects[this.indexRow].projectId = rows.map(item => { return item.id }).join(',') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.inputForm.infoProjects[this.indexRow].projectName = rows.map(item => { return item.name }).join(',') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				// this.inputForm.infoProjects[this.indexRow].reportNumber = rows[0].no 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -1102,6 +1149,8 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			getProgramForType4 (rows) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.inputForm.infoProjects[this.indexRow].typeId = rows.id 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.inputForm.infoProjects[this.indexRow].typeName = rows.name 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				this.inputForm.infoProjects[this.indexRow].projectId = "" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				this.inputForm.infoProjects[this.indexRow].projectName = "" 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.indexRow = '' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.$forceUpdate() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			}, 
			 |