From 24e23ca8485d79f4559c8d8afc947ac5f7655c0b Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Wed, 27 Jul 2022 16:04:07 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=85=A5=E8=B4=A6?= =?UTF-8?q?=E7=AE=A1=E7=90=86=E6=B5=81=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/api/ruzhang/scmapplyinbound.js | 36 +- .../ruzhang/ruzhangguanli/ruzhangAdd.vue | 29 +- .../ruzhangguanli/ruzhangDaiBanInfo.vue | 21 +- .../ruzhangguanli/ruzhangEdit.vue | 697 +++++++++++++----- .../ruzhangguanli/ruzhangYiBanInfo.vue | 18 +- 5 files changed, 567 insertions(+), 234 deletions(-) diff --git a/anrui-scm/anrui-scm-ui/src/api/ruzhang/scmapplyinbound.js b/anrui-scm/anrui-scm-ui/src/api/ruzhang/scmapplyinbound.js index b9bc64522a..d54d304d82 100644 --- a/anrui-scm/anrui-scm-ui/src/api/ruzhang/scmapplyinbound.js +++ b/anrui-scm/anrui-scm-ui/src/api/ruzhang/scmapplyinbound.js @@ -40,10 +40,7 @@ export default { return request({ url: '/scm/v1/scmapplyinbound/complete', method: 'post', - data: params, - headers: { - 'Content-Type': 'application/json' - } + data: params }) }, // 代办任务驳回任务 @@ -51,10 +48,7 @@ export default { return request({ url: '/scm/v1/scmapplyinbound/reject', method: 'post', - data: params, - headers: { - 'Content-Type': 'application/json' - } + data: params }) }, // 代办任务终止任务 @@ -62,10 +56,7 @@ export default { return request({ url: '/scm/v1/scmapplyinbound/breakProcess', method: 'post', - data: params, - headers: { - 'Content-Type': 'application/json' - } + data: params }) }, // 代办任务撤回任务 @@ -73,31 +64,22 @@ export default { return request({ url: '/scm/v1/scmapplyinbound/revokeProcess', method: 'post', - data: params, - headers: { - 'Content-Type': 'application/json' - } + data: params }) }, getNextNodesForSubmit: function(data) { return request({ url: '/scm/v1/scmapplyinbound/getNextNodesForSubmit', - method: 'post', - data: data, - headers: { - 'Content-Type': 'application/json' - } + method: 'get', + params: data }) }, - getPreviousNodesForReject(formobj) { + getPreviousNodesForReject(data) { return request({ url: '/scm/v1/scmapplyinbound/getPreviousNodesForReject', - method: 'post', - data: formobj, - headers: { - 'Content-Type': 'application/json' - } + method: 'get', + params: data }) } } diff --git a/anrui-scm/anrui-scm-ui/src/views/ruzhang/ruzhangguanli/ruzhangAdd.vue b/anrui-scm/anrui-scm-ui/src/views/ruzhang/ruzhangguanli/ruzhangAdd.vue index 245eee6fb9..b0bc6c2a27 100644 --- a/anrui-scm/anrui-scm-ui/src/views/ruzhang/ruzhangguanli/ruzhangAdd.vue +++ b/anrui-scm/anrui-scm-ui/src/views/ruzhang/ruzhangguanli/ruzhangAdd.vue @@ -97,7 +97,7 @@ 可享受比例(%) - + 对应金额 @@ -111,7 +111,7 @@ 可享受比例(%) - + 对应金额 @@ -260,6 +260,17 @@ export default { UpNumber(e) { e.target.value = e.target.value.replace(/[^\d]/g, '') // 清除“数字”和“.”"-"以外的字符 }, + UpNumberRatio(e) { + e.target.value = e.target.value.replace(/[^\d.]/g, '') // 清除“数字”和“.”"-"以外的字符 + e.target.value = e.target.value.replace(/^00/, '0.') // 开头不能有两个0 + e.target.value = e.target.value.replace(/\.{2,}/g, '.') // 只保留第一个. 清除多余的 + e.target.value = e.target.value.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.') + e.target.value = e.target.value.replace(/^(\-)*(\d+)\.(\d\d).*$/, '$1$2.$3') // 只能输入两个小数 + if (e.target.value.indexOf('.') < 0 && e.target.value !== '') { + // 以上已经过滤,此处控制的是如果没有小数点,首位不能为类似于 01、02的金额 + e.target.value = parseFloat(e.target.value) + } + }, inputOnceFreight() { this.inputEligibleProportionTwo() this.inputEligibleProportionThree() @@ -289,7 +300,6 @@ export default { this.inputEligibleProportionTwo() this.inputEligibleProportionThree() } else { - this.formobj.moneyCount = 0 this.inputEligibleProportionTwo() this.inputEligibleProportionThree() } @@ -325,10 +335,14 @@ export default { this.formobj.corrMoneyTwo = this.multiplication(parseFloat(this.formobj.contractPrice), (parseFloat(this.formobj.eligibleProportionTwo) / 100)) } } - this.formobj.moneyCount = parseFloat(this.formobj.eligibleAmountOne) + parseFloat(this.formobj.corrMoneyTwo) + parseFloat(this.formobj.corrMoneyThree) } else { this.formobj.corrMoneyTwo = 0 } + if (this.formobj.eligibleAmountOne === '') { + this.formobj.moneyCount = parseFloat(0) + parseFloat(this.formobj.corrMoneyTwo) + parseFloat(this.formobj.corrMoneyThree) + } else { + this.formobj.moneyCount = parseFloat(this.formobj.eligibleAmountOne) + parseFloat(this.formobj.corrMoneyTwo) + parseFloat(this.formobj.corrMoneyThree) + } return this.formobj.corrMoneyTwo }, inputEligibleProportionThree() { @@ -394,10 +408,15 @@ export default { this.formobj.corrMoneyThree = this.multiplication((parseFloat(this.formobj.contractPrice)), (parseFloat(this.formobj.eligibleProportionThree) / 100)) } } - this.formobj.moneyCount = parseFloat(this.formobj.eligibleAmountOne) + parseFloat(this.formobj.corrMoneyTwo) + parseFloat(this.formobj.corrMoneyThree) + } else { this.formobj.corrMoneyThree = 0 } + if (this.formobj.eligibleAmountOne === '') { + this.formobj.moneyCount = parseFloat(0) + parseFloat(this.formobj.corrMoneyTwo) + parseFloat(this.formobj.corrMoneyThree) + } else { + this.formobj.moneyCount = parseFloat(this.formobj.eligibleAmountOne) + parseFloat(this.formobj.corrMoneyTwo) + parseFloat(this.formobj.corrMoneyThree) + } return this.formobj.corrMoneyThree }, inputMoneyCount() { diff --git a/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangDaiBanInfo.vue b/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangDaiBanInfo.vue index e0b381fc7c..361b59d583 100644 --- a/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangDaiBanInfo.vue +++ b/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangDaiBanInfo.vue @@ -186,16 +186,16 @@ - + -
当前环节:
- {{ current.taskName }}->{{ nextNode.name }} +
当前环节:
+ {{ current.taskName }}->{{ nextNode.name }}
- + -
意见:
- +
意见:
+
@@ -321,12 +321,12 @@ export default { }, '*') }, methods: { - showInfo(sid, row) { + showInfo(sid) { this.$nextTick(() => { this.$refs['form_obj'].clearValidate() }) this.viewTitle = '入账单' - console.log('编辑回显', sid, row) + console.log('编辑回显', sid) req.fetchBySid(sid).then(resp => { const data = resp.data this.formobj = data @@ -351,7 +351,7 @@ export default { this.policyThreeChecked = false } }).catch(e => { - this.formobj = row + this.formobj = {} }) }, magnify(val) { @@ -509,4 +509,7 @@ export default { .freight { color: #FFFFFF; } +.rowClass{ + border-top: 1px solid #E0E3EB; +} diff --git a/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangEdit.vue b/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangEdit.vue index 193d64acac..86a9304e59 100644 --- a/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangEdit.vue +++ b/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangEdit.vue @@ -1,75 +1,149 @@ - diff --git a/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangYiBanInfo.vue b/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangYiBanInfo.vue index 64dd8a1983..cf35ec3d3b 100644 --- a/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangYiBanInfo.vue +++ b/anrui-scm/anrui-scm-ui/src/views/workFlow/ruzhangguanliFlow/ruzhangguanli/ruzhangYiBanInfo.vue @@ -270,8 +270,6 @@ export default { this.linkByParameter.taskDefKey = obj.taskDefKey this.linkByParameter.orgSidPath = window.sessionStorage.getItem('orgSidPath') this.linkByParameter.userSid = window.sessionStorage.getItem('userSid') - this.current.taskDefKey = obj.taskDefKey - this.current.taskName = obj.taskName // 加载表单数据 this.showInfo(obj.businessSid) }, @@ -286,12 +284,12 @@ export default { }, '*') }, methods: { - showInfo(sid, row) { + showInfo(sid) { this.$nextTick(() => { this.$refs['form_obj'].clearValidate() }) this.viewTitle = '入账单' - console.log('编辑回显', sid, row) + console.log('编辑回显', sid) req.fetchBySid(sid).then(resp => { const data = resp.data this.formobj = data @@ -316,7 +314,7 @@ export default { this.policyThreeChecked = false } }).catch(e => { - this.formobj = row + this.formobj = {} }) }, magnify(val) { @@ -356,13 +354,6 @@ export default { code: 1 } }, '*') - } else { - this.$notify({ - title: '提示', - message: '执行失败', - type: 'error', - duration: 2000 - }) } }) } @@ -371,6 +362,9 @@ export default {