From d9ec20d0ad57f5a025f19f16a32f462bfc33b43b Mon Sep 17 00:00:00 2001 From: e <2432808546@qq.com> Date: Wed, 8 Sep 2021 16:39:08 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E5=AE=8C=E6=96=B0=E5=A2=9E=E5=8A=9F?= =?UTF-8?q?=E8=83=BD=EF=BC=8C=E6=9A=82=E6=97=B6=E6=B2=A1=E7=9C=8B=E5=88=B0?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/common/Sidebar.vue | 3 - src/components/common/flowPathMoudle.vue | 6 +- src/components/common/left-sidebar.vue | 1 - src/components/page/Login.vue | 2 - .../page/afterLoan/afterInsurance.vue | 82 ++++++++++--------- src/components/page/afterLoan/collection.vue | 5 +- src/components/page/afterLoan/complete.vue | 72 ++++++++++------ src/components/page/afterLoan/progress.vue | 12 +-- src/main.js | 1 - 9 files changed, 95 insertions(+), 89 deletions(-) diff --git a/src/components/common/Sidebar.vue b/src/components/common/Sidebar.vue index c04f846..093ea14 100644 --- a/src/components/common/Sidebar.vue +++ b/src/components/common/Sidebar.vue @@ -160,7 +160,6 @@ export default { handleCommand(command) { if(command == 'loginout'){ // sessionStorage.removeItem('ms_username') - console.log('触发用户名下拉菜单') this.$router.push('/login'); this.$store.getters.clear resetRouter()//重载路由 @@ -182,7 +181,6 @@ export default { let homeMenu = this.$store.state.homeMenu, len = homeMenu.length, items = [] - console.log(homeMenu,'homeMenu') for(let i=0;i{ return data.clientName.toLowerCase().includes(this.search.toLowerCase()) || data.applicant.toLowerCase().includes(this.search.toLowerCase()) }) this.TotalPage = this.tableData.length this.handleCurrentChange(1) // this.$forceUpdate(); - console.log(this.tableData,'筛选后的值'); + // console.log(this.tableData,'筛选后的值'); } }, // 判断函数,判断节点,判断操作状态,进行跳转处理 @@ -956,7 +956,6 @@ export default { }, copymeCurrentChange(val){ // 抄送-前端分页 this.copyPage = val - console.log(this.copyPage,val,'当前val',); if (val != 1) val =(val-1) * 10 // 需要size改这里 this.copyData = this.copyClient.slice(val-1, val+9)// 修改size,10也改 }, @@ -985,7 +984,6 @@ export default { } if(this.copyParam.clientName==='客户'){ this.searchClient = true - console.log('查询客户'); let obj = JSON.parse(JSON.stringify(this.copyParam)) obj.size = 99999 obj.page = 1 diff --git a/src/components/common/left-sidebar.vue b/src/components/common/left-sidebar.vue index 5cafc04..91eb0a9 100644 --- a/src/components/common/left-sidebar.vue +++ b/src/components/common/left-sidebar.vue @@ -53,7 +53,6 @@ export default { return {}; }, created(){ - console.log(this.menus,'this.menus',this.title); }, methods:{ diff --git a/src/components/page/Login.vue b/src/components/page/Login.vue index 8707f2e..57d3508 100644 --- a/src/components/page/Login.vue +++ b/src/components/page/Login.vue @@ -149,7 +149,6 @@ export default { password: this.param.password, tenDayEffective: this.tenDayEffective }).then(res => { - console.log('登录接口完成') sessionStorage.setItem("token",res.data.token); sessionStorage.setItem("userID",res.data.id); this.$store.commit("userNameData", { userName: res.data.account, userPhone: this.param.username,headerImg:res.data.headPortaritUrl }); @@ -169,7 +168,6 @@ export default { }, getNowRole(){ return getNowRole().then(res=>{ - console.log('进行权限请求') if(res.success){ sessionStorage.setItem("now-roleBtn",res.data); this.$nextTick(()=>{ diff --git a/src/components/page/afterLoan/afterInsurance.vue b/src/components/page/afterLoan/afterInsurance.vue index 67a1796..4c78b8f 100644 --- a/src/components/page/afterLoan/afterInsurance.vue +++ b/src/components/page/afterLoan/afterInsurance.vue @@ -283,11 +283,10 @@ - - + - + {{StatisticsData.repaymentSum}} @@ -372,7 +371,7 @@ {{StatisticsData.overdueSum}} - + {{StatisticsData.alreadyPaymentSum}} @@ -723,6 +722,7 @@ import core from '../../../utils/core'; }, totalRepayment(){ if(isNaN(parseFloat(this.repaymentForm.otherExpenses)) || this.repaymentForm.otherExpenses == ''){ + // 本次利息加本次还款,如果为NaN if (isNaN(parseFloat(this.repaymentForm.currentRepayment) + parseFloat(this.repaymentForm.interest))) { return '' } else { @@ -781,6 +781,7 @@ import core from '../../../utils/core'; this.comp = {} this.liquidate ={} this.$store.commit('discernEdit',false) + this.$forceUpdate(); this.getData() } if(val == 2){ @@ -794,7 +795,6 @@ import core from '../../../utils/core'; otherExpenses: '', overdueDays: 0 } - console.log(this.guaranteeForm,'kanxia gura') // 处于编辑状态,额外添加一个编辑中的状态判断 if(this.status!=='newLoans'||this.discernEdit) this.getDetail() if(this.loanbackStatus == '查看' || this.loanbackStatus == '编辑'){ @@ -817,12 +817,10 @@ import core from '../../../utils/core'; }) }, status:function (params) { - console.log(params,'status'); } }, created(){ - console.log(this.btn,'mate',this.$router.currentRoute.meta.btn) this.liquidateList() if(this.bankSelect.length===0){ allBankName().then(res=>{ @@ -918,7 +916,6 @@ import core from '../../../utils/core'; edit(row,val){ this.$store.commit('disabledAll',false) if(!row){// 进入新建业务界面 - console.log('进入新增业务'); this.loanStatus = 2 this.$store.commit("loanStatusData", { loanStatus: 2 }); this.$store.commit('setNewOrOld','newLoans') @@ -927,14 +924,9 @@ import core from '../../../utils/core'; this.$store.commit('entering',true) this.id = val.id this.$store.commit("idData", { id: val.id });// 存业务id用于刷新复现 - console.log(this.entering,'ent') } val?this.$store.commit('discernEdit',true):this.$store.commit('discernEdit',false) - console.log('新建',this.discernEdit); }else{// 进入还款录入,添加个额外判断进入编辑界面 - console.log(row.id,'当前业务ID') - console.log('进入录入或者编辑业务') - this.$store.commit('entering',false) // 不可编辑业务编辑区域 this.$store.commit('discernEdit',true)// 区分是否可编辑业务 this.$store.commit('setNewOrOld','oldLoans')// 区分进入还款或者新建 @@ -982,7 +974,6 @@ import core from '../../../utils/core'; id: this.id }); this.guaranteeLoading = false - console.log(res.data,'此处guar被赋值'); this.guaranteeForm = res.data.insuranceList this.starEndDate = [this.guaranteeForm.loanStartTime,this.guaranteeForm.loanEndTime] // 处理银行字符串 @@ -1039,7 +1030,7 @@ import core from '../../../utils/core'; }, //录入提交 saveAdd(repaymentForm){ - // 判断是否新增 + // 判断是否新增业务 if(this.status==='newLoans'){ this.saveInsurance() }else{// 处于编辑/新增录入,需要判断该业务是否新增的,或是流转的,有不同处理方式 @@ -1053,8 +1044,6 @@ import core from '../../../utils/core'; }) }) Promise.all([this.saveInsurance(),form2]).then(()=>{ - console.log(this.RepaymentId,'id有无') - console.log(this.discernEdit,'是否为编辑') if(this.RepaymentId == ''){ this.repaymentForm.insuranceId = this.id this.repaymentForm.totalRepayment = this.totalRepayment @@ -1106,9 +1095,8 @@ import core from '../../../utils/core'; async statistics(){ let res = await repaymentStatistics({ insuranceId: this.hisidId, - guaranteeAmount: this.guaranteeAmount + // guaranteeAmount: this.guaranteeAmount }); - console.log(res,'当前的res--11'); this.StatisticsData = res.data }, // 还款记录列表 @@ -1123,7 +1111,6 @@ import core from '../../../utils/core'; res.data.list.map(e =>{ e.repaymentStatus = this.core.stcStatus(e.repaymentStatus) }) - console.log(res,'记录列表信息') this.repaymentData = res.data.list this.histotals = res.data.totalCount }, @@ -1257,18 +1244,15 @@ import core from '../../../utils/core'; }) }, principalNode(val){// 组织架构选择人员 - console.log(val,'组织架构选人'); this.$set(this.liquidate,'personLiable',val[0].name) this.liquidate.personLiableId = val[0].id }, principalSeleted(){// 选择清收负责人 - console.log('确定选择'); this.principal = false }, searchClientChange(val,state){// 实时搜索客户详细信息 companyInfoBySth({name:val}).then(res=>{ - // console.log(res,'请求客户接口取值,取得客户资料'); let data = res.data this.$set(this.guaranteeForm,'phone',data.legalPhone) this.$set(this.guaranteeForm,'legalName',data.legalName) @@ -1326,7 +1310,6 @@ import core from '../../../utils/core'; }, blurOrganization(item,index){// 清收组织保存 item.edit = true - console.log(index,item,'当前的值'); this.liquidateEdit('',item) }, starEndTimeFn(val){// 贷款起止日期的处理 @@ -1344,7 +1327,6 @@ import core from '../../../utils/core'; }) }, liquidateEdit(val,item){// 清收组编辑活新增 - console.log(item,'传进来的值'); let param = { groupName:item.groupName,// 清收组名称 } @@ -1352,7 +1334,6 @@ import core from '../../../utils/core'; param.id = item.id } liquidateEdit(param).then(res=>{ - console.log(res); this.liquidateList() }) }, @@ -1378,10 +1359,40 @@ import core from '../../../utils/core'; } }) }) - + // 同时处理多个表单的验证 - return Promise.all([form1,form3]).then(()=>{ - this.$confirm('确定保存该记录?', '提示', {type:"info"}).then(()=>{ + return Promise.all([form1,form3]).then(()=>{ + if(this.status==='newLoans'){// 新增需要提示 + this.$confirm('确定保存该记录?', '提示', {type:"info"}).then(()=>{ + let obj ={} + // 如果处于编辑业务状态 或者是还款录入状态 + if(this.discernEdit) obj.insuranceId = this.id + Object.assign(obj,this.comp,this.liquidate) + let param = { + alInsuranceList:this.guaranteeForm,// 担保信息 + alReimbursement:obj// 代偿清收相关 + } + if(this.discernEdit){// 处于编辑状态下,且 + editInsurance(param).then(res=>{ + if(this.entering){ + this.$message.success('编辑业务成功!') + this.$store.commit("loanStatusData", { loanStatus: 1 }); + } + }) + }else{// 处于新增状态下 + param.source = 1 + saveInsurance(param).then(res=>{ + // 新增业务,返回上一页 + if(this.status==='newLoans'){ + this.$message.success('新增业务成功!') + this.$store.commit("loanStatusData", { loanStatus: 1 }); + } + }).catch(err=>{ + }) + } + }).catch(e=>{ + }) + }else{// 编辑不需要提示 let obj ={} // 如果处于编辑业务状态 或者是还款录入状态 if(this.discernEdit) obj.insuranceId = this.id @@ -1392,31 +1403,25 @@ import core from '../../../utils/core'; } if(this.discernEdit){// 处于编辑状态下,且 editInsurance(param).then(res=>{ - console.log(res,'编辑业务'); if(this.entering){ this.$message.success('编辑业务成功!') this.$store.commit("loanStatusData", { loanStatus: 1 }); } - }) - }else{// 处于新增状态下 + param.source = 1 saveInsurance(param).then(res=>{ // 新增业务,返回上一页 if(this.status==='newLoans'){ this.$message.success('新增业务成功!') this.$store.commit("loanStatusData", { loanStatus: 1 }); } + }).catch(err=>{ }) } - - }).catch(e=>{ - console.log(e,'取消保存记录') - }) - + } }).catch(()=>{ // alert('验证错误') - console.log(err,'err') return false }) }, @@ -1427,7 +1432,6 @@ import core from '../../../utils/core'; }).then(() => { deleteInsurance(row.id).then(res=>{ this.getData() - console.log(res,'res'); }) }) }, diff --git a/src/components/page/afterLoan/collection.vue b/src/components/page/afterLoan/collection.vue index ca81e48..9d75bd4 100644 --- a/src/components/page/afterLoan/collection.vue +++ b/src/components/page/afterLoan/collection.vue @@ -780,7 +780,7 @@ async statistics(){ let res = await repaymentStatistics({ insuranceId: this.hisidId, - guaranteeAmount: this.guaranteeAmount + // guaranteeAmount: this.guaranteeAmount }); this.StatisticsData = res.data }, @@ -862,7 +862,6 @@ ); }, uploadSuccess(response, file, fileList) { - console.log(response,file,'file') if(response.code==99999){ fileList.splice(0,1) return this.$message.error(`上传失败,请重新上传!错误码${response.code}`) @@ -913,7 +912,6 @@ if(this.collectionHandle.collectionMethod!=='3') this.$set(this.collectionHandle,"other",'') this.$refs[collectionHandle].validate((valid) => { if (valid) { - console.log(this.collectionHandle,'this.uploadList') if(this.collectionHandle.collectionMethod=='3'&&!this.collectionHandle.other) return this.$message.error("请输入其他催收方式说明!"); // if(this.uploadList.length == 0) return this.$message.error("请先上传附件文件!"); this.collectionHandle.enclosureFiles = this.uploadList.map(e => e.url) @@ -1003,7 +1001,6 @@ enclosureFiles: res.data.enclosureFiles } this.uploadList = [] - console.log(res.data.enclosureFiles,'res.data.enclosureFiles') if(res.data.enclosureFiles.length>0&&res.data.enclosureFiles[0]){ const newArr = res.data.enclosureFiles.map(item => ({name: item,url:item})) newArr.map(item => { diff --git a/src/components/page/afterLoan/complete.vue b/src/components/page/afterLoan/complete.vue index cf14784..8782c3d 100644 --- a/src/components/page/afterLoan/complete.vue +++ b/src/components/page/afterLoan/complete.vue @@ -11,7 +11,7 @@
- +