From 837289ce22d21c8f54baca050c8e8506a22b199b Mon Sep 17 00:00:00 2001 From: e <2432808546@qq.com> Date: Tue, 28 Sep 2021 09:56:25 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=9D=E5=90=8E=E5=92=8C=E9=81=97=E7=95=99bu?= =?UTF-8?q?g=E5=85=A8=E9=83=A8=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package-lock.json | 13 + src/assets/css/main.css | 3 + src/components/common/Letter.vue | 24 +- src/components/common/Notice.vue | 15 +- src/components/common/Payment.vue | 16 +- src/components/common/Sidebar.vue | 9 +- .../common/businessApplyDepartment.vue | 2 +- .../common/complianceDepartment.vue | 9 +- src/components/common/flowPathMoudle.vue | 9 +- src/components/common/messageDepartment.vue | 2 +- src/components/common/processTemp.vue | 7 +- src/components/common/propertyDepartment.vue | 2 +- src/components/page/Workbench.vue | 97 +++- .../page/afterLoan/afterInsurance.vue | 321 ++++++++--- src/components/page/afterLoan/afterLoan.vue | 8 +- src/components/page/afterLoan/collection.vue | 116 +++- src/components/page/afterLoan/complete.vue | 497 ++++++++++++++---- src/components/page/afterLoan/progress.vue | 39 +- src/store/modules/guarantee.js | 4 + src/store/modules/loan.js | 13 +- src/utils/api.js | 4 + src/utils/core.js | 81 ++- src/utils/http.js | 4 +- 23 files changed, 1067 insertions(+), 228 deletions(-) diff --git a/package-lock.json b/package-lock.json index b368751..9981617 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4900,6 +4900,11 @@ "integrity": "sha1-P7rwIL/XlIhAcuomsel5HUWmKfA=", "dev": true }, + "downloadjs": { + "version": "1.4.7", + "resolved": "https://registry.npm.taobao.org/downloadjs/download/downloadjs-1.4.7.tgz", + "integrity": "sha1-9p+W+UDg0FU9rCkROYZaPNAQHjw=" + }, "duplexer": { "version": "0.1.2", "resolved": "https://registry.npm.taobao.org/duplexer/download/duplexer-0.1.2.tgz", @@ -14202,6 +14207,14 @@ "resolved": "https://registry.npm.taobao.org/vue-i18n/download/vue-i18n-8.22.0.tgz?cache=0&sync_timestamp=1602001179053&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fvue-i18n%2Fdownload%2Fvue-i18n-8.22.0.tgz", "integrity": "sha1-ZAM4Gm6rHSKeUVpirdspsv86v+0=" }, + "vue-json-excel": { + "version": "0.3.0", + "resolved": "https://registry.npm.taobao.org/vue-json-excel/download/vue-json-excel-0.3.0.tgz", + "integrity": "sha1-csvkoARyAlntxlVVo/ByGYz3kUY=", + "requires": { + "downloadjs": "^1.4.7" + } + }, "vue-loader": { "version": "15.9.3", "resolved": "https://registry.npm.taobao.org/vue-loader/download/vue-loader-15.9.3.tgz?cache=0&sync_timestamp=1600850354305&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fvue-loader%2Fdownload%2Fvue-loader-15.9.3.tgz", diff --git a/src/assets/css/main.css b/src/assets/css/main.css index 1442e49..14cb572 100644 --- a/src/assets/css/main.css +++ b/src/assets/css/main.css @@ -426,3 +426,6 @@ input[type="number"]{ color: #00B9FF; text-decoration: underline; } +.el-tooltip__popper{ + max-width: 700px; +} \ No newline at end of file diff --git a/src/components/common/Letter.vue b/src/components/common/Letter.vue index de62578..d5ff34e 100644 --- a/src/components/common/Letter.vue +++ b/src/components/common/Letter.vue @@ -152,12 +152,9 @@ -
- - - +
@@ -299,6 +296,14 @@ export default { // 判断是否由待处理哪里跳转过来的,每次触发后删除 if(sessionStorage.getItem('decideJump')){ let data = JSON.parse(sessionStorage.getItem('decideJump')) + this.letterValue = { + businessId: data.businessId,//业务id + id:data.id,//rowID + auditStatus:data.auditStatus,//审批状态 + handleStatus:data.operationStatus,//操作状态 + roleId:data.roleId,//角色id + } + this.$store.commit("letterData", { letterValue: this.letterValue }); data.id = data.detailId data.status = data.approveStatus data.handleStatus = data.operatingStatus @@ -428,6 +433,7 @@ export default { }, //列表操作-详情 letterData(row,operationType){ + console.log(row,'当前的确定行内值') this.loans = false //判断详情显示 this.operationType = operationType //列表操作状态 //担保函数据 @@ -443,6 +449,7 @@ export default { auditOpinion: row.auditOpinion,//审核意见 roleId: row.roleId //角色id } + console.log(this.letterValue,'存起来的值') this.fileList = row.file.split(",") this.$store.commit("fileData", { fileList: this.fileList }); this.$store.commit("loansData", { loans: this.loans }); @@ -485,17 +492,22 @@ export default { }, // 提交审核意见 sumbitOpinion(text,type){ + const values = this.$store.state.guarantee.letterValue + console.log(text,type,'当前跳转的值',values,'this.$store.state.guarantee.letterValue.businessId') this.$confirm(`确定要${text}该审核意见吗?`, '提示', { type: 'warning' }).then(() => { if(type == 4 && this.letterValue.auditOpinion == ''){ return this.$message.error("请先填写审核意见!") } + let params = { auditOpinion: this.letterValue.auditOpinion, - businessId: this.letterValue.businessId, + // businessId: values.businessId, + businessId: this.letterValue.businessId||this.$store.state.guarantee.businessId, status: type } + console.log(params,'提交的值') updateStatus(params).then(res => { this.$message.success(`${text}成功`); let btnPermissionsStr = sessionStorage.getItem("now-roleBtn").split(','); diff --git a/src/components/common/Notice.vue b/src/components/common/Notice.vue index dde2410..01ca606 100644 --- a/src/components/common/Notice.vue +++ b/src/components/common/Notice.vue @@ -140,9 +140,9 @@
-
+
@@ -236,8 +236,15 @@ export default { if(data.btn==='确认'){ this.operationType = 3 this.loanNoticeDetail(data)// 取得详情 - this.operationType = operationType //列表操作状态 + this.operationType = this.operationType //列表操作状态 this.$store.commit("loansData", { loans: this.loans }); + this.letterValue = { + businessId: data.businessId,//业务id + id:data.id,//rowID + auditStatus:data.auditStatus,//审批状态 + handleStatus:data.operationStatus,//操作状态 + roleId:data.roleId,//角色id + } this.$store.commit("letterData", { operationType: this.operationType, letterValue: this.letterValue }); } sessionStorage.removeItem('decideJump') @@ -409,7 +416,7 @@ export default { } let params = { auditOpinion: this.letterValue.auditOpinion, - businessId: this.letterValue.businessId, + businessId: this.letterValue.businessId||this.$store.state.guarantee.businessId, status: type } updateLoanNotice(params).then(res => { diff --git a/src/components/common/Payment.vue b/src/components/common/Payment.vue index 0866c20..e186dbc 100644 --- a/src/components/common/Payment.vue +++ b/src/components/common/Payment.vue @@ -125,9 +125,9 @@
-
+

附件

@@ -305,11 +305,19 @@ export default { if(data.btn==='确认'){ this.operationType = 3 this.paymentDetail(data)// 取得详情 - this.operationType = operationType //列表操作状态 + this.operationType = this.operationType //列表操作状态 this.isFgJl = data.isFgJl //是否是法规部经理 this.$store.commit("isFgJlData", { isFgJl: data.isFgJl }); this.$store.commit("loansData", { loans: this.loans }); + + this.letterValue = { + businessId: data.businessId,//业务id + id:data.id,//rowID + auditStatus:data.auditStatus,//审批状态 + handleStatus:data.operationStatus,//操作状态 + roleId:data.roleId,//角色id + } this.$store.commit("letterData", { operationType: this.operationType, letterValue: this.letterValue }); } sessionStorage.removeItem('decideJump') @@ -544,7 +552,7 @@ export default { let imgFile = this.imgListT.map(e =>e.url).join() let params = { auditOpinion: this.letterValue.auditOpinion, - businessId: this.letterValue.businessId, + businessId: this.letterValue.businessId||this.$store.state.guarantee.businessId, status: type, imgFile: imgFile } diff --git a/src/components/common/Sidebar.vue b/src/components/common/Sidebar.vue index 093ea14..98469b0 100644 --- a/src/components/common/Sidebar.vue +++ b/src/components/common/Sidebar.vue @@ -117,7 +117,7 @@ export default { watch:{ $route(to,from){ this.notice() - this.handleSelect(this.activeIndex)// 触发高亮的值 + if(to!=this.activeIndex) this.handleSelect(this.activeIndex)// 触发高亮的值 }, pop(now,before){ // this @@ -135,7 +135,6 @@ export default { // if( this.$store.state.login.headerImg){ // this.headerImg = this.$store.state.login.headerImg // } - // 通过 Event Bus 进行组件间通信,来折叠侧边栏 bus.$on('collapse', msg => { this.collapse = msg; bus.$emit('collapse-content', msg); @@ -151,7 +150,11 @@ export default { this.activeIndex = index sessionStorage.setItem('sideBar',index) if(val!=='start') sessionStorage.removeItem('fromCopyTo') // 删除抄送的值,没有把流程拆成路由没法在beforeeach判断 - + if(index=='workbench'){// 删除工作台的记录 + console.log('触发删除') + this.$store.commit("leftSidebarData", { leftStatus: '0' }); + this.$store.commit("loanStatusData", { loanStatus: 1 });// 切换页面状态 + } }, goto(path) { this.$router.push('/' + path); diff --git a/src/components/common/businessApplyDepartment.vue b/src/components/common/businessApplyDepartment.vue index 950c245..3d3e0cd 100644 --- a/src/components/common/businessApplyDepartment.vue +++ b/src/components/common/businessApplyDepartment.vue @@ -1738,7 +1738,7 @@ methods:{ }) }else{ // this.$message('丢失customerId!') - this.$message('请先输入企业编号或名称后,再进行关联人操作!') + if(this.businessApply.isExistRelated==1) return this.$message('请先输入企业编号或名称后,再进行关联人操作!') } }, // 关联人checkbox diff --git a/src/components/common/complianceDepartment.vue b/src/components/common/complianceDepartment.vue index 474d5c0..4821792 100644 --- a/src/components/common/complianceDepartment.vue +++ b/src/components/common/complianceDepartment.vue @@ -1041,13 +1041,17 @@ mounted(){ // 判断是否由待处理哪里跳转过来的,每次触发后删除 if(sessionStorage.getItem('decideJump')){ let data = JSON.parse(sessionStorage.getItem('decideJump')) + + + + console.log(data,'取得item的值') data.iid = data.detailId data.status = data.approveStatus data.handleStatus = data.operatingStatus // 判断操作 if(data.btn==='指派'){ data.row = {} - data.row.iid = data.id + data.row.iid = data.iid data.row.businessId = data.businessId data.row.companyId = data.companyId this.gotoSurvey(data,'compliance') @@ -1208,6 +1212,7 @@ methods:{ return this.$message.error('请先选取角色!') } obj.userId = this.assetDesignateC + console.log(obj,'当前的obj') complianceAssign(obj).then(res=>{ if(res.success){ this.$message.success('操作成功') @@ -1505,7 +1510,7 @@ methods:{ this.linkManLoading = false }) }else{ - this.$message('请先输入企业编号或名称后,再进行关联人操作!') + if(this.businessApply.isExistRelated==1) return this.$message('请先输入企业编号或名称后,再进行关联人操作!') } }, // 关联人checkbox diff --git a/src/components/common/flowPathMoudle.vue b/src/components/common/flowPathMoudle.vue index fe974c3..25a199e 100644 --- a/src/components/common/flowPathMoudle.vue +++ b/src/components/common/flowPathMoudle.vue @@ -477,6 +477,13 @@ export default { decide(item){ if(item.operatingStatus===1){// 二次验证是否为处理 sessionStorage.setItem('decideJump',JSON.stringify(item)) + console.log(item.taskNode,'当前的task',item) + /* 后三个步骤处理不同,非得从列表取得数据导致的问题,处理逻辑异常 */ + // if(item.taskNode=='担保函'||item.taskNode=='财务确认'||item.taskNode=='放款通知'){ + // console.log(item.businessId,'zhi') + // console.log(this.$store.state.guarantee.letterValue,'this.$store.state.guarantee.businessId') + this.$store.commit("businessId",item.businessId); + // } this.jumpToFrom(item.taskNode) // switch (item.taskNode) { // // 拥有十套不同的按钮判断逻辑,按钮根据取得的状态进行判断操作 @@ -1041,11 +1048,9 @@ export default { break; case '财务确认': nodeCode = 9 - // 最后三部都记录对应的消息应用 break; case '放款通知': nodeCode = 10 - // 最后三部都记录对应的消息应用 break; default: break; diff --git a/src/components/common/messageDepartment.vue b/src/components/common/messageDepartment.vue index 891750e..f67fbc6 100644 --- a/src/components/common/messageDepartment.vue +++ b/src/components/common/messageDepartment.vue @@ -1484,7 +1484,7 @@ methods:{ this.linkManLoading = false }) }else{ - this.$message('请先输入企业编号或名称后,再进行关联人操作!') + if(this.businessApply.isExistRelated==1) return this.$message('请先输入企业编号或名称后,再进行关联人操作!') } }, // 关联人checkbox diff --git a/src/components/common/processTemp.vue b/src/components/common/processTemp.vue index 20e1385..4f9d786 100644 --- a/src/components/common/processTemp.vue +++ b/src/components/common/processTemp.vue @@ -116,15 +116,18 @@ export default { }; }, mounted(){ + console.log(this.$store.state.guarantee.businessId,'this.$store.state.guarantee.businessId') + this.getAuditProcess() this.getAuditProcess2() this.queryCopySendUser()// 抄送人 }, methods: { async getAuditProcess(){ + let params = { // 从vuex取值 - businessId: this.$store.state.guarantee.letterValue.businessId, + businessId: this.$store.state.guarantee.letterValue.businessId||this.$store.state.guarantee.businessId, processId: this.$store.state.guarantee.topSidebarVal } let res = await auditProcessList(params) @@ -132,7 +135,7 @@ export default { }, async getAuditProcess2(){ let params = { - businessId: this.$store.state.guarantee.letterValue.businessId, + businessId: this.$store.state.guarantee.letterValue.businessId||this.$store.state.guarantee.businessId, processId: '' } let res = await auditProcessList(params) diff --git a/src/components/common/propertyDepartment.vue b/src/components/common/propertyDepartment.vue index 903705b..ccc0a53 100644 --- a/src/components/common/propertyDepartment.vue +++ b/src/components/common/propertyDepartment.vue @@ -1099,7 +1099,7 @@ methods:{ this.linkManLoading = false }) }else{ - this.$message('请先输入企业编号或名称后,再进行关联人操作!') + if(this.businessApply.isExistRelated==1) return this.$message('请先输入企业编号或名称后,再进行关联人操作!') } }, // 关联人checkbox diff --git a/src/components/page/Workbench.vue b/src/components/page/Workbench.vue index e1757db..9ae131e 100644 --- a/src/components/page/Workbench.vue +++ b/src/components/page/Workbench.vue @@ -5,7 +5,14 @@

基础应用

+
+
@@ -32,7 +39,7 @@ export default { data(){ return{ url:false, - + test:10.22, } }, watch:{ @@ -54,6 +61,94 @@ export default { if(this.$route.fullPath!=='/workbench')this.url = true }, methods:{ + fMoney4(money) { + if(!money) return '' + console.clear() + //汉字的数字 + let cnNums = new Array('零', '壹', '贰', '叁', '肆', '伍', '陆', '柒', '捌', '玖'); + let cnIntRadice = new Array('', '拾', '佰', '仟'); //基本单位 + let cnIntUnits = new Array('', '万', '亿', '兆'); //对应整数部分扩展单位 + let cnDecUnits = new Array('仟', '佰', '拾', '元', '角' , '分'); //对应小数部分单位 + let cnInteger = '元'; //整数金额时后面跟的字符 + let cnIntLast = '万'; //整数无小数点的单位 + let zero = "零" + let int; //金额整数部分 + let dot; //金额小数部分 + let chineseStr = ''; //输出的中文金额字符串 + let parts; //分离金额后用的数组,预定义 + if (money == '') { + return ''; + } + //转换为字符串,获取小数点后的值与整数分离 + money = money.toString(); + console.log(money,money.indexOf('.'),'判断小数点') + if (money.indexOf('.') == -1) {// 取得小树点后面的值 + int = money; + dot = ''; + } else { + parts = money.split('.'); //整数小数分离 + int = parts[0]; + dot = parts[1].substr(0, 6); //最多六位小数,计算到 角,分 + } + console.log(parseInt(int, 10),'parseInt(int, 10)') + //十进制转换,处理整数部分单位 + if (parseInt(int, 10) > 0) { + console.log('进入十进制转换') + let zeroCount = 0; + let IntLen = int.length; + for (let i = 0; i < IntLen; i++) { + //循环整数部分,给每个位赋值,且判断是否整除4,添加额外赋值 + let n = int.substr(i, 1); + let p = IntLen - i - 1; // 长度 -i -1 取得 + let q = p / 4; + let m = p % 4; + console.log(n,p,q,m,"q,m") + if (n == '0') { + zeroCount++; + } else { + if (zeroCount > 0) { + chineseStr += cnNums[0]; + } + //归零 + zeroCount = 0; + chineseStr += cnNums[parseInt(n)] + cnIntRadice[m]; + } + // + if (m == 0 && zeroCount < 4) { + chineseStr += cnIntUnits[q]; + } + } + chineseStr += cnIntLast; + } + //小数部分 + console.log(dot,'dot') + if (dot != '') { + console.log('进入小数处理部分') + let decLen = dot.length;// 循环小数后面的位数 + for (let i = 0; i < decLen; i++) { + let n = dot.substr(i, 1); + if (n != '0') { + chineseStr += cnNums[Number(n)] + cnDecUnits[i]; + } + console.log(i,'i',n,'n',dot) + /* + 如果 indexof 第一个非0数字,后面带有连续的0,或者间隔的0 + */ + if(i==3 && n=='0' ){ // 如果i处于千百十的时候,加个元 + chineseStr += cnInteger + } + } + } + // if (chineseStr == '') {// 为0时, + // chineseStr += cnNums[0] + cnIntLast + cnInteger; + // } + // else if (dot == '') {//小数点为空值时 + + // chineseStr += cnInteger; // 加上元 + // } + return chineseStr; + }, + // 跳转方法,传一个字符串地址 goto(path) { this.$router.push('/' + path); diff --git a/src/components/page/afterLoan/afterInsurance.vue b/src/components/page/afterLoan/afterInsurance.vue index e0cb652..dc54b36 100644 --- a/src/components/page/afterLoan/afterInsurance.vue +++ b/src/components/page/afterLoan/afterInsurance.vue @@ -150,7 +150,9 @@
- + + {{ChinaCost(guaranteeForm.guaranteeAmount)}} +
@@ -184,13 +186,13 @@ - + + {{ChinaCost(comp.compensationAmount)}} + - - + - + + {{ChinaCost(comp.compensatoryBalance)}} + @@ -224,7 +227,7 @@
- + 自定义 @@ -237,14 +240,16 @@
- - + + - + @@ -468,7 +474,15 @@ - + + +