From 1cf1cca3060bc2be30dd071a7e7c4ac9084b2b1d Mon Sep 17 00:00:00 2001 From: fanzongzhe0036 Date: Fri, 10 Jan 2025 17:43:22 +0800 Subject: [PATCH 01/14] =?UTF-8?q?=E8=BF=94=E5=88=A9=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E8=B0=83=E6=95=B43?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java index fc53286e8a..e623b13880 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java @@ -643,6 +643,8 @@ public class ScmVehRebateService extends MybatisBaseService data = baseVehicleFeign.vehicleRebateList(pq).getData(); BaseVehicleRebateVo baseVehicleRebateVo = data.getRecords().get(0); ScmVehRebate scmVehRebate = new ScmVehRebate(); + scmVehRebate.setPurchaseSystemSid(baseVehicleRebateVo.getPurchaseSystemSid()); + scmVehRebate.setPurchaseSystemName(baseVehicleRebateVo.getPurchaseSystemName()); scmVehRebate.setState(0); scmVehRebate.setCreateBySid(userSid); scmVehRebate.setBrandSid(baseVehicleRebateVo.getCarBrand()); From 9d2844c49f156b15ed2623841fdc1fdb6f5f9f16 Mon Sep 17 00:00:00 2001 From: fanzongzhe0036 Date: Fri, 10 Jan 2025 18:03:57 +0800 Subject: [PATCH 02/14] =?UTF-8?q?=E8=BF=94=E5=88=A9=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E8=B0=83=E6=95=B44?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java index e623b13880..81aeec4497 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java @@ -662,10 +662,15 @@ public class ScmVehRebateService extends MybatisBaseService Date: Fri, 10 Jan 2025 18:04:58 +0800 Subject: [PATCH 03/14] =?UTF-8?q?=E8=BF=94=E5=88=A9=E6=A8=A1=E6=9D=BF?= =?UTF-8?q?=E8=B0=83=E6=95=B45?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java index 81aeec4497..16948bb861 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmvehrebate/ScmVehRebateService.java @@ -665,7 +665,7 @@ public class ScmVehRebateService extends MybatisBaseService Date: Mon, 13 Jan 2025 08:56:28 +0800 Subject: [PATCH 04/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E9=87=91=E8=9E=8D?= =?UTF-8?q?=E8=B4=B4=E6=81=AF=E5=B7=AE=E5=BC=82=E8=B0=83=E6=95=B4=E7=94=B3?= =?UTF-8?q?=E8=AF=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../differenceManagement/differenceManagementAdd.vue | 10 ++++++++++ .../chayitiaozhengFlow/differenceManagementEdit.vue | 10 ++++++++++ 2 files changed, 20 insertions(+) diff --git a/anrui-scm/anrui-scm-ui/src/views/financialDiscount/differenceManagement/differenceManagementAdd.vue b/anrui-scm/anrui-scm-ui/src/views/financialDiscount/differenceManagement/differenceManagementAdd.vue index 96c739f2e8..22c3049651 100644 --- a/anrui-scm/anrui-scm-ui/src/views/financialDiscount/differenceManagement/differenceManagementAdd.vue +++ b/anrui-scm/anrui-scm-ui/src/views/financialDiscount/differenceManagement/differenceManagementAdd.vue @@ -263,8 +263,18 @@ export default { const choose = this.adjustWay_list.filter((item) => item.dictKey === value) if (choose !== null) { this.formobj.adjustWay = choose[0].dictValue + if (this.formobj.adjustWay === '公司认损') { + this.formobj.staffName = '' + this.formobj.staffSid = '' + this.formobj.salesManage = '' + this.formobj.salesManageSid = '' + } } else { this.formobj.adjustWay = '' + this.formobj.staffName = '' + this.formobj.staffSid = '' + this.formobj.salesManage = '' + this.formobj.salesManageSid = '' } }, changeStaff(value) { diff --git a/anrui-scm/anrui-scm-ui/src/views/workFlow/chayitiaozhengFlow/differenceManagementEdit.vue b/anrui-scm/anrui-scm-ui/src/views/workFlow/chayitiaozhengFlow/differenceManagementEdit.vue index bb819e83d3..4b4e1fe43e 100644 --- a/anrui-scm/anrui-scm-ui/src/views/workFlow/chayitiaozhengFlow/differenceManagementEdit.vue +++ b/anrui-scm/anrui-scm-ui/src/views/workFlow/chayitiaozhengFlow/differenceManagementEdit.vue @@ -245,8 +245,18 @@ export default { const choose = this.adjustWay_list.filter((item) => item.dictKey === value) if (choose !== null) { this.formobj.adjustWay = choose[0].dictValue + if (this.formobj.adjustWay === '公司认损') { + this.formobj.staffName = '' + this.formobj.staffSid = '' + this.formobj.salesManage = '' + this.formobj.salesManageSid = '' + } } else { this.formobj.adjustWay = '' + this.formobj.staffName = '' + this.formobj.staffSid = '' + this.formobj.salesManage = '' + this.formobj.salesManageSid = '' } }, changeStaff(value) { From 7663d7755b46b01a8e67e77505a488468c4075aa Mon Sep 17 00:00:00 2001 From: fanzongzhe0036 Date: Mon, 13 Jan 2025 08:59:00 +0800 Subject: [PATCH 05/14] =?UTF-8?q?=E9=87=91=E8=9E=8D=E8=B0=83=E5=B7=AE?= =?UTF-8?q?=E7=94=B3=E8=AF=B7=E5=88=A0=E9=99=A4=E6=8E=A5=E5=8F=A3=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../biz/scmfinanceadjustapply/ScmFinanceAdjustApplyRest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyRest.java b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyRest.java index 02f1323ae4..4641de8034 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyRest.java +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyRest.java @@ -95,7 +95,7 @@ public class ScmFinanceAdjustApplyRest implements ScmFinanceAdjustApplyFeign { @Override @ApiOperation("根据sid批量删除") - @PostMapping("/delBySids") + @DeleteMapping("/delBySids") public ResultBean delBySids(@RequestBody String[] sids){ ResultBean rb = ResultBean.fireFail(); //查询该sid中是否有流程不是待提交的 From 244e49e114ee3731ab788ea6f4028e9b6ebfb556 Mon Sep 17 00:00:00 2001 From: fanzongzhe0036 Date: Mon, 13 Jan 2025 09:32:25 +0800 Subject: [PATCH 06/14] =?UTF-8?q?=E9=87=91=E8=9E=8D=E8=B0=83=E5=B7=AE?= =?UTF-8?q?=E7=94=B3=E8=AF=B7=E5=88=A0=E9=99=A4=E6=8E=A5=E5=8F=A3=E4=BF=AE?= =?UTF-8?q?=E6=94=B92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../biz/scmfinanceadjustapply/ScmFinanceAdjustApplyMapper.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyMapper.xml b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyMapper.xml index 7c65cb8bcb..66c95757a8 100644 --- a/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyMapper.xml +++ b/anrui-scm/anrui-scm-biz/src/main/java/com/yxt/anrui/scm/biz/scmfinanceadjustapply/ScmFinanceAdjustApplyMapper.xml @@ -121,7 +121,7 @@ From c64f4859876876219bfd7069305993958909da29 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 09:53:00 +0800 Subject: [PATCH 07/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=8D=95=E8=BD=A6?= =?UTF-8?q?=E8=BF=94=E5=88=A9=E9=A2=84=E6=8F=90=20--=20=E9=87=8D=E6=8E=A8?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../bikerebate/bicyclerebatewithholding.js | 8 +++ .../bicyclerebatewithholding.vue | 52 +++++++++++++++++-- 2 files changed, 57 insertions(+), 3 deletions(-) diff --git a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js index 0033d5411c..29392bd904 100644 --- a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js +++ b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js @@ -19,6 +19,14 @@ export default { headers: { 'Content-Type': 'application/json' } }) }, + // 重推 + rePushVouche: function(data) { + return request({ + url: '/scm/v1/scmvehrebate/rePushVouche', + method: 'post', + params: data + }) + }, // 删除 delete: function(params) { return request({ diff --git a/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue b/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue index b32cb6e3d8..c00f8abfa6 100644 --- a/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue +++ b/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue @@ -94,7 +94,7 @@ import req from '@/api/bikerebate/bicyclerebatewithholding' import Pagination from '@/components/pagination' import pageye from '@/components/pagination/pageye' import ButtonBar from '@/components/ButtonBar' -import { getOrgSidByPath } from '@/api/cheliang/dictcommons' +import { getButtonPermissions, getOrgSidByPath } from '@/api/cheliang/dictcommons' import bicyclerebatewithholdingAdd from './bicyclerebatewithholdingAdd' import bicyclerebatewithholdingInfo from './bicyclerebatewithholdingInfo' import { getStorage } from '@/utils/auth' @@ -122,6 +122,13 @@ export default { btnKey: 'toAdd', btnLabel: '新增' }, + { + type: 'primary', + size: 'small', + icon: '', + btnKey: 'toRepush', + btnLabel: '重推' + }, { type: 'danger', size: 'small', @@ -144,6 +151,7 @@ export default { tableKey: 0, list: [], sids: [], + multipleSelection: [], FormLoading: false, listLoading: false, listQuery: { @@ -176,7 +184,18 @@ export default { mounted() { // 在外部vue的window上添加postMessage的监听,而且绑定处理函数handleMessage window.addEventListener('message', this.handleMessage) - this.$refs['btnbar'].setButtonList(this.btnList) + getButtonPermissions({ userSid: window.sessionStorage.getItem('userSid'), url: this.$route.path, type: 0 }).then((res) => { + if (res.success) { + for (var i = 0; i < res.data.length; i++) { + for (var k = 0; k < this.btnList.length; k++) { + if (res.data[i].buttonId === this.btnList[k].btnKey) { + this.btnList.splice(k, 1) + } + } + } + this.$refs['btnbar'].setButtonList(this.btnList) + } + }) }, methods: { async handleMessage(event) { @@ -231,6 +250,9 @@ export default { case 'toAdd': this.toAdd() break + case 'toRepush': + this.toRepush() + break case 'doDel': this.doDel() break @@ -249,11 +271,11 @@ export default { }, handleSelectionChange(row) { const aa = [] + this.multipleSelection = row row.forEach((element) => { aa.push(element.sid) }) this.sids = aa - console.log('sids', this.sids) }, // 查询列表信息 getList() { @@ -305,6 +327,30 @@ export default { this.viewState = 2 this.$refs['divAdd'].showAdd(this.listQuery.params.createOrgSid) }, + toRepush() { + if (this.multipleSelection.length === 1 && this.multipleSelection[0].nodeState === '已办结') { + const loading = this.$loading({ + lock: true, + text: 'Loading', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }) + req.rePushVouche({ sid: this.sids[0] }).then((resp) => { + if (resp.success) { + loading.close() + this.$message({ showClose: true, type: 'success', message: '重推成功' }) + this.getList() + } else { + loading.close() + } + }).catch(() => { + loading.close() + }) + } else { + this.$message({ showClose: true, type: 'error', message: '请选择一条记录且状态为已办结的进行重推操作' }) + return + } + }, toEdit(row) { this.viewState = 3 this.$refs['divAdd'].showEdit(row) From a95f638a125d73bcca1e3f1f8bdd8e762a7696d7 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 10:02:40 +0800 Subject: [PATCH 08/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=8D=95=E8=BD=A6?= =?UTF-8?q?=E8=BF=94=E5=88=A9=E9=A2=84=E6=8F=90=20--=20=E9=87=8D=E6=8E=A8?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js index 29392bd904..459053081e 100644 --- a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js +++ b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js @@ -22,7 +22,7 @@ export default { // 重推 rePushVouche: function(data) { return request({ - url: '/scm/v1/scmvehrebate/rePushVouche', + url: '/scm/v1/scmvehrebatewithapply/rePushVouche', method: 'post', params: data }) From fbf6dd153d3b445a36dc206f0819ee43f9f667a6 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 10:11:20 +0800 Subject: [PATCH 09/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=8D=95=E8=BD=A6?= =?UTF-8?q?=E8=BF=94=E5=88=A9=E9=A2=84=E6=8F=90=20--=20=E9=87=8D=E6=8E=A8?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/api/bikerebate/bicyclerebatewithholding.js | 4 ++-- .../bicyclerebatewithholding/bicyclerebatewithholding.vue | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js index 459053081e..9e616059cb 100644 --- a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js +++ b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatewithholding.js @@ -20,9 +20,9 @@ export default { }) }, // 重推 - rePushVouche: function(data) { + rePushVoucher: function(data) { return request({ - url: '/scm/v1/scmvehrebatewithapply/rePushVouche', + url: '/scm/v1/scmvehrebatewithapply/rePushVoucher', method: 'post', params: data }) diff --git a/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue b/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue index c00f8abfa6..5896a0bd9b 100644 --- a/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue +++ b/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatewithholding/bicyclerebatewithholding.vue @@ -335,7 +335,7 @@ export default { spinner: 'el-icon-loading', background: 'rgba(0, 0, 0, 0.7)' }) - req.rePushVouche({ sid: this.sids[0] }).then((resp) => { + req.rePushVoucher({ sid: this.sids[0] }).then((resp) => { if (resp.success) { loading.close() this.$message({ showClose: true, type: 'success', message: '重推成功' }) From e0768291d4164dfb4f0b5a20cbb21ef42972eec2 Mon Sep 17 00:00:00 2001 From: dimengzhe Date: Mon, 13 Jan 2025 10:17:55 +0800 Subject: [PATCH 10/14] =?UTF-8?q?oaform=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/yxt/anrui/oa/api/OaFormRest.java | 29 +++--- .../com/yxt/anrui/oa/api/OaMendApplyRest.java | 27 ++++- .../anrui/oa/biz/oaform/OaFormService.java | 94 ++++++++---------- .../oaform/flowable/BusinessVariablesDto.java | 66 +++++++++++++ .../oa/biz/oaform/flowable/CompleteDto.java | 4 +- .../{DelegateQuery.java => DelegateDto.java} | 2 +- .../oa/biz/oaform/flowable/SubmitDto.java | 6 +- .../flowable/{TaskQuery.java => TaskDto.java} | 2 +- .../biz/oamendapply/OaMendApplyService.java | 99 ++++++++++++------- 9 files changed, 219 insertions(+), 110 deletions(-) create mode 100644 yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/BusinessVariablesDto.java rename yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/{DelegateQuery.java => DelegateDto.java} (94%) rename yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/{TaskQuery.java => TaskDto.java} (97%) diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaFormRest.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaFormRest.java index 1edd211c64..b3e4160969 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaFormRest.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaFormRest.java @@ -4,7 +4,6 @@ import cn.hutool.core.bean.BeanUtil; import com.yxt.anrui.oa.biz.oaform.*; import com.yxt.anrui.oa.biz.oaform.flowable.*; import com.yxt.anrui.oa.feign.flowable.flow.BusinessVariables; -import com.yxt.anrui.oa.feign.flowable.flow2.FlowDelegateQuery; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; @@ -58,10 +57,10 @@ public class OaFormRest { @ApiOperation(value = "办理(同意)") @PostMapping("/complete") - public ResultBean complete(@Valid @RequestBody CompleteDto query) { - BusinessVariables bv = new BusinessVariables(); - BeanUtil.copyProperties(query, bv); - return oaFormService.complete(bv); + public ResultBean complete(@Valid @RequestBody CompleteDto dto) { + BusinessVariablesDto businessVariables = new BusinessVariablesDto(); + BeanUtil.copyProperties(dto, businessVariables); + return oaFormService.complete(businessVariables); } @ApiOperation(value = "获取上一个环节") @@ -78,33 +77,33 @@ public class OaFormRest { @ApiOperation(value = "驳回任务") @PostMapping(value = "/reject") - public ResultBean reject(@Valid @RequestBody TaskQuery query) { - return oaFormService.reject(query); + public ResultBean reject(@Valid @RequestBody TaskDto dto) { + return oaFormService.reject(dto); } @ApiOperation(value = "撤回流程") @PostMapping(value = "/revokeProcess") - public ResultBean revokeProcess(@Valid @RequestBody TaskQuery query) { - return oaFormService.revokeProcess(query); + public ResultBean revokeProcess(@Valid @RequestBody TaskDto dto) { + return oaFormService.revokeProcess(dto); } @ApiOperation(value = "终止任务") @PostMapping(value = "/breakProcess") - public ResultBean breakProcess(@Valid @RequestBody TaskQuery query) { - return oaFormService.breakProcess(query); + public ResultBean breakProcess(@Valid @RequestBody TaskDto dto) { + return oaFormService.breakProcess(dto); } @ApiOperation(value = "加签") @PostMapping(value = "/delegate") - public ResultBean delegate(@RequestBody DelegateQuery query) { - return oaFormService.delegate(query); + public ResultBean delegate(@RequestBody DelegateDto dto) { + return oaFormService.delegate(dto); } @ApiOperation(value = "转办") @PutMapping(value = "/assignTask") @ResponseBody - public ResultBean assignTask(@RequestBody DelegateQuery query) { - return oaFormService.assignTask(query); + public ResultBean assignTask(@RequestBody DelegateDto dto) { + return oaFormService.assignTask(dto); } } diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaMendApplyRest.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaMendApplyRest.java index 579a450cdd..519abf6c4c 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaMendApplyRest.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/api/OaMendApplyRest.java @@ -25,13 +25,11 @@ *********************************************************/ package com.yxt.anrui.oa.api; -import cn.hutool.core.bean.BeanUtil; import com.yxt.anrui.oa.biz.oaform.flowable.CompleteDto; import com.yxt.anrui.oa.biz.oaform.flowable.NodeQuery; import com.yxt.anrui.oa.biz.oaform.flowable.NodeVo; -import com.yxt.anrui.oa.biz.oaform.flowable.TaskQuery; +import com.yxt.anrui.oa.biz.oaform.flowable.TaskDto; import com.yxt.anrui.oa.biz.oamendapply.*; -import com.yxt.anrui.oa.feign.flowable.flow.BusinessVariables; import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; @@ -101,4 +99,27 @@ public class OaMendApplyRest { return oaMendApplyService.submit(dto); } + @ApiOperation(value = "办理(同意)") + @PostMapping("/complete") + public ResultBean complete(@Valid @RequestBody CompleteDto dto) { + return oaMendApplyService.complete(dto); + } + + @ApiOperation(value = "驳回任务") + @PostMapping(value = "/reject") + public ResultBean reject(@Valid @RequestBody TaskDto dto) { + return oaMendApplyService.reject(dto); + } + + @ApiOperation(value = "获取上一个环节") + @GetMapping(value = "/getPreviousNodesForReject") + public ResultBean> getPreviousNodesForReject(@Valid @SpringQueryMap NodeQuery query) { + return oaMendApplyService.getPreviousNodesForReject(query); + } + + @ApiOperation(value = "获取下一个环节") + @GetMapping(value = "/getNextNodesForSubmit") + public ResultBean> getNextNodesForSubmit(@Valid @SpringQueryMap NodeQuery query) { + return oaMendApplyService.getNextNodesForSubmit(query); + } } diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/OaFormService.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/OaFormService.java index 8d9074290d..893a211c04 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/OaFormService.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/OaFormService.java @@ -1,19 +1,15 @@ package com.yxt.anrui.oa.biz.oaform; import cn.hutool.core.bean.BeanUtil; -import cn.hutool.core.date.DateUtil; import com.alibaba.fastjson.JSON; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.google.common.util.concurrent.ThreadFactoryBuilder; import com.yxt.anrui.oa.biz.oaform.flowable.*; -import com.yxt.anrui.oa.biz.oamendapply.OaMendApply; -import com.yxt.anrui.oa.biz.oamendapply.SubmitOaMendApplyDto; import com.yxt.anrui.oa.feign.base.BillNo; import com.yxt.anrui.oa.feign.base.Rule; import com.yxt.anrui.oa.feign.flowable.flow.BusinessVariables; import com.yxt.anrui.oa.feign.flowable.flow.FlowableFeign; -import com.yxt.anrui.oa.feign.flowable.flow.ProcDefEnum; import com.yxt.anrui.oa.feign.flowable.flow.UpdateFlowFieldVo; import com.yxt.anrui.oa.feign.flowable.flow2.FlowDelegateQuery; import com.yxt.anrui.oa.feign.flowable.flow2.FlowFeign; @@ -37,7 +33,6 @@ import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; import org.apache.tomcat.util.threads.ThreadPoolExecutor; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.context.annotation.Bean; import org.springframework.stereotype.Service; import java.util.*; @@ -164,17 +159,12 @@ public class OaFormService extends MybatisBaseService { return baseMapper.updateFlowFiled(map); } - public ResultBean complete(BusinessVariables bv) { + public ResultBean complete(BusinessVariablesDto dto) { ResultBean rb = ResultBean.fireFail(); - String formSid = bv.getFormVariables().get("formSid").toString(); + BusinessVariables bv = new BusinessVariables(); + BeanUtil.copyProperties(dto, bv); String businessSid = bv.getBusinessSid(); - OaForm oaForm = fetchBySid(formSid); - //添加网关 - Map variables = bv.getFormVariables(); - Map appMap = new HashMap<>(); - appMap.put("sid", businessSid); - variables.put("app", appMap); - bv.setFormVariables(variables); + OaForm oaForm = fetchBySid(businessSid); SysOrganizationVo deptVo = sysOrganizationFeign.fetchBySid(oaForm.getDeptSid()).getData(); bv.setOrgSidPath(deptVo.getOrgSidPath()); bv.setModelId(oaForm.getProcDefId()); @@ -185,8 +175,7 @@ public class OaFormService extends MybatisBaseService { } UpdateFlowFieldVo ufVo = resultBean.getData(); OaFormFlowDto oaFormFlowDto = new OaFormFlowDto(); - BeanUtil.copyProperties(ufVo, oaFormFlowDto, "sid"); - oaFormFlowDto.setSid(formSid); + BeanUtil.copyProperties(ufVo, oaFormFlowDto); updateFlow(oaFormFlowDto); if ("Event_end".equals(resultBean.getData().getTaskDefKey())) { @@ -209,7 +198,7 @@ public class OaFormService extends MybatisBaseService { ufVo.setProcDefId(oaForms.getProcDefId()); ufVo.setProcInsId(oaForms.getProcInstId()); messageFlowableQuery.setUfVo(messageFlowVo); - messageFlowableQuery.setAppMap(appMap); + messageFlowableQuery.setAppMap((Map) bv.getFormVariables().get("app")); messageFlowableQuery.setBusinessSid(businessSid); messageFlowableQuery.setModuleName(oaForms.getFormType()); messageFlowableQuery.setMsgContent(oaForms.getCreateByName() + "提交的" + messageFlowableQuery.getModuleName() + ",请审批"); @@ -265,30 +254,25 @@ public class OaFormService extends MybatisBaseService { } - public ResultBean reject(TaskQuery query) { + public ResultBean reject(TaskDto dto) { ResultBean rb = ResultBean.fireFail(); - String businessSid = query.getBusinessSid(); + String businessSid = dto.getBusinessSid(); OaForm oaForm = fetchBySid(businessSid); if (oaForm == null) { return rb.setMsg("该申请不存在"); } String businessTaskId = oaForm.getTaskId(); if (StringUtils.isNotBlank(businessTaskId)) { - if (businessTaskId.equals(query.getTaskId())) { - if (StringUtils.isBlank(query.getComment())) { + if (businessTaskId.equals(dto.getTaskId())) { + if (StringUtils.isBlank(dto.getComment())) { return rb.setMsg("请填写意见"); } - if (StringUtils.isBlank(query.getUserSid())) { + if (StringUtils.isBlank(dto.getUserSid())) { return rb.setMsg("参数错误:userSid"); } FlowTaskVo flowTaskVo = new FlowTaskVo(); - BeanUtil.copyProperties(query, flowTaskVo); - Map variables = new HashMap<>(); - Map appMap = new HashMap<>(); - appMap.put("sid", businessSid); - variables.put("app", appMap); - //网关 - + BeanUtil.copyProperties(dto, flowTaskVo); + Map variables = dto.getFormVariables(); flowTaskVo.setValues(variables); ResultBean resultBean = flowableFeign.taskReject(flowTaskVo); if (!resultBean.getSuccess()) { @@ -316,7 +300,7 @@ public class OaFormService extends MybatisBaseService { ufVo.setProcInsId(oaForms.getProcInstId()); ufVo.setProcDefId(oaForms.getProcDefId()); messageFlowableQuery.setUfVo(messageFlowVo); - messageFlowableQuery.setAppMap(appMap); + messageFlowableQuery.setAppMap((Map) dto.getFormVariables().get("app")); messageFlowableQuery.setBusinessSid(businessSid); messageFlowableQuery.setModuleName(oaForms.getFormType()); ResultBean> listResultBean = flowTaskFeign.getLatestTasks(oaForms.getProcInstId()); @@ -340,17 +324,17 @@ public class OaFormService extends MybatisBaseService { return rb.setMsg("操作失败!提交的数据不一致!"); } - public ResultBean revokeProcess(TaskQuery query) { + public ResultBean revokeProcess(TaskDto dto) { ResultBean rb = ResultBean.fireFail(); - if (StringUtils.isBlank(query.getUserSid())) { + if (StringUtils.isBlank(dto.getUserSid())) { return rb.setMsg("参数错误:userSid"); } - OaForm oaForm = fetchBySid(query.getBusinessSid()); + OaForm oaForm = fetchBySid(dto.getBusinessSid()); String businessTaskId = oaForm.getTaskId(); if (StringUtils.isNotBlank(businessTaskId)) { - if (businessTaskId.equals(query.getTaskId())) { + if (businessTaskId.equals(dto.getTaskId())) { FlowTaskVo flowTaskVo = new FlowTaskVo(); - BeanUtil.copyProperties(query, flowTaskVo); + BeanUtil.copyProperties(dto, flowTaskVo); ResultBean resultBean = flowableFeign.revokeProcess(flowTaskVo); if (!resultBean.getSuccess()) { return rb.setMsg(resultBean.getMsg()); @@ -364,23 +348,23 @@ public class OaFormService extends MybatisBaseService { return rb.setMsg("操作失败,提交的数据不一致!"); } - public ResultBean breakProcess(TaskQuery query) { + public ResultBean breakProcess(TaskDto dto) { ResultBean rb = ResultBean.fireFail(); - if (StringUtils.isBlank(query.getInstanceId())) { + if (StringUtils.isBlank(dto.getInstanceId())) { return rb.setMsg("参数错误:instanceId"); } - if (StringUtils.isBlank(query.getUserSid())) { + if (StringUtils.isBlank(dto.getUserSid())) { return rb.setMsg("参数错误:userSid"); } - if (StringUtils.isBlank(query.getComment())) { + if (StringUtils.isBlank(dto.getComment())) { return rb.setMsg("请填写意见"); } - OaForm oaForm = fetchBySid(query.getBusinessSid()); + OaForm oaForm = fetchBySid(dto.getBusinessSid()); String businessTaskId = oaForm.getTaskId(); if (StringUtils.isNotBlank(businessTaskId)) { - if (query.getUserSid().equals(oaForm.getCreateBySid())) { + if (dto.getUserSid().equals(oaForm.getCreateBySid())) { FlowTaskVo flowTaskVo = new FlowTaskVo(); - BeanUtil.copyProperties(query, flowTaskVo); + BeanUtil.copyProperties(dto, flowTaskVo); ResultBean resultBean = flowableFeign.breakProcess(flowTaskVo); if (!resultBean.getSuccess()) { return rb.setMsg(resultBean.getMsg()); @@ -390,9 +374,9 @@ public class OaFormService extends MybatisBaseService { updateFlow(oaFormFlowDto); return rb.success().setData(resultBean.getData()); } else { - if (businessTaskId.equals(query.getTaskId())) { + if (businessTaskId.equals(dto.getTaskId())) { FlowTaskVo flowTaskVo = new FlowTaskVo(); - BeanUtil.copyProperties(query, flowTaskVo); + BeanUtil.copyProperties(dto, flowTaskVo); ResultBean resultBean = flowableFeign.breakProcess(flowTaskVo); if (!resultBean.getSuccess()) { return rb.setMsg(resultBean.getMsg()); @@ -407,18 +391,18 @@ public class OaFormService extends MybatisBaseService { return rb.setMsg("操作失败!提交的数据不一致!"); } - public ResultBean delegate(DelegateQuery query) { + public ResultBean delegate(DelegateDto dto) { ResultBean rb = ResultBean.fireFail(); FlowDelegateQuery delegateQuery = new FlowDelegateQuery(); - BeanUtil.copyProperties(query, delegateQuery); + BeanUtil.copyProperties(dto, delegateQuery); flowFeign.delegate(delegateQuery); return rb.success(); } - public ResultBean assignTask(DelegateQuery query) { + public ResultBean assignTask(DelegateDto dto) { ResultBean rb = ResultBean.fireFail(); FlowDelegateQuery delegateQuery = new FlowDelegateQuery(); - BeanUtil.copyProperties(query, delegateQuery); + BeanUtil.copyProperties(dto, delegateQuery); flowFeign.assignTask(delegateQuery); return rb.success(); } @@ -508,7 +492,9 @@ public class OaFormService extends MybatisBaseService { bv.setTaskDefKey(oaForm.getNodeId()); bv.setComment("重新提交"); bv.setInstanceId(oaForm.getProcInstId()); - return complete(bv); + BusinessVariablesDto businessVariablesDto = new BusinessVariablesDto(); + BeanUtil.copyProperties(bv, businessVariablesDto); + return complete(businessVariablesDto); } return rb; @@ -516,11 +502,13 @@ public class OaFormService extends MybatisBaseService { private synchronized int submitBusinessData(SubmitDto dto) { int r = 0; - if (dto.isNew()) { + OaForm oaForm = fetchBySid(dto.getBusinessSid()); + if (StringUtils.isBlank(oaForm.getTaskId()) && StringUtils.isBlank(dto.getNextNodeSid())) { + //新提交 r = 1; - } else { + } else if (StringUtils.isNotBlank(oaForm.getTaskId()) && oaForm.getTaskId().equals(dto.getNextNodeSid())) { + //二次提交//只有数据一致的时候才能进行下一步 r = 2; - } return r; } @@ -551,8 +539,10 @@ public class OaFormService extends MybatisBaseService { bv.setNextNodeUserSids(organizationVo.getManagerSid()); } else if (rule == OaFormRuleEnum.INSTITUTION.getRule()) { + //获取本机构链(含集团、事业部、分公司部门)中角色的用户(角色sid,发起人orgsidPath) } else if (rule == OaFormRuleEnum.OTHER_INSTITUTION.getRule()) { + //获取其他机构链角色的用户(角色sid,机构sid]) } else { bv.setNextNodeUserSids(""); diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/BusinessVariablesDto.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/BusinessVariablesDto.java new file mode 100644 index 0000000000..46e2cff07c --- /dev/null +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/BusinessVariablesDto.java @@ -0,0 +1,66 @@ +package com.yxt.anrui.oa.biz.oaform.flowable; + +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; + +import java.util.HashMap; +import java.util.Map; + +/** + * @description: + * @author: dimengzhe + * @date: 2025/1/13 + **/ +@Data +@Builder +@AllArgsConstructor +@NoArgsConstructor +public class BusinessVariablesDto { + + /** + * 分公司sid + */ + public static final String ORGPATH = "orgPath"; + /** + * 流程定义的id + */ + private String modelId; + /** + * 审批意见 + */ + private String comment; + /** + * 流程实例的id + */ + private String instanceId; + /** + * taskId + */ + private String taskId; + /** + * 当前用户的id + */ + private String userSid; + /** + * 当前用户部门的全路径 + */ + private String orgSidPath; + /** + * 业务sid + */ + private String businessSid; + /** + * 环节定义的ID + */ + private String taskDefKey; + /** + * nextNodeUserSids 下一环节的用户sid + */ + private String nextNodeUserSids; + /** + * 业务参数,按需传递 + */ + private Map formVariables = new HashMap<>(); +} diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/CompleteDto.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/CompleteDto.java index 3ed42f4ba2..6a97e80ef2 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/CompleteDto.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/CompleteDto.java @@ -25,9 +25,7 @@ public class CompleteDto implements Dto { @ApiModelProperty(value = "任务id") @NotBlank(message = "参数错误:taskId") private String taskId; - @ApiModelProperty(value = "流程id(PC)") - private String instanceId; - @ApiModelProperty(value = "流程id(移动)") + @ApiModelProperty(value = "流程实例id") private String procInsId; @ApiModelProperty(value = "意见") private String comment; diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/DelegateQuery.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/DelegateDto.java similarity index 94% rename from yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/DelegateQuery.java rename to yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/DelegateDto.java index d21917f4b7..eb2dcbdb03 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/DelegateQuery.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/DelegateDto.java @@ -9,7 +9,7 @@ import lombok.Data; * @date: 2025/1/9 **/ @Data -public class DelegateQuery { +public class DelegateDto { @ApiModelProperty private String userSid; diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/SubmitDto.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/SubmitDto.java index e33708258e..786dbcbb0d 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/SubmitDto.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/SubmitDto.java @@ -26,6 +26,8 @@ public class SubmitDto { private String nextNodeUserSids; @ApiModelProperty("下一处理人获取规则") private int rule; - @ApiModelProperty("是否是首次提交") - private boolean isNew; +// @ApiModelProperty("是否是首次提交") +// private boolean isNew; + @ApiModelProperty("任务id") + private String nextNodeSid; } diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/TaskQuery.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/TaskDto.java similarity index 97% rename from yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/TaskQuery.java rename to yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/TaskDto.java index 04890e7e14..470bd51a08 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/TaskQuery.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oaform/flowable/TaskDto.java @@ -13,7 +13,7 @@ import java.util.Map; * @date: 2025/1/9 **/ @Data -public class TaskQuery { +public class TaskDto { /** * 终止、驳回、撤回 diff --git a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oamendapply/OaMendApplyService.java b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oamendapply/OaMendApplyService.java index fb46400b4e..15a20a8ce2 100644 --- a/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oamendapply/OaMendApplyService.java +++ b/yxt-oa/src/main/java/com/yxt/anrui/oa/biz/oamendapply/OaMendApplyService.java @@ -28,23 +28,13 @@ package com.yxt.anrui.oa.biz.oamendapply; import cn.hutool.core.bean.BeanUtil; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; -import com.google.common.util.concurrent.ThreadFactoryBuilder; -import com.yxt.anrui.oa.biz.oaappendix.OaAppendix; import com.yxt.anrui.oa.biz.oaappendix.OaAppendixService; -import com.yxt.anrui.oa.biz.oaform.OaForm; import com.yxt.anrui.oa.biz.oaform.OaFormDto; import com.yxt.anrui.oa.biz.oaform.OaFormService; -import com.yxt.anrui.oa.biz.oaform.flowable.OaFormFlowDto; -import com.yxt.anrui.oa.biz.oaform.flowable.SubmitDto; +import com.yxt.anrui.oa.biz.oaform.flowable.*; import com.yxt.anrui.oa.feign.file.OaFileEnum; -import com.yxt.anrui.oa.feign.flowable.flow.BusinessVariables; import com.yxt.anrui.oa.feign.flowable.flow.ProcDefEnum; -import com.yxt.anrui.oa.feign.flowable.flow.UpdateFlowFieldVo; -import com.yxt.anrui.oa.feign.flowable.flow2.FlowFeign; -import com.yxt.anrui.oa.feign.message.MessageFeign; import com.yxt.anrui.oa.feign.portal.sysorganization.SysOrganizationFeign; -import com.yxt.anrui.oa.feign.portal.sysorganization.SysOrganizationVo; -import com.yxt.common.base.config.component.FileUploadComponent; import org.apache.commons.lang3.StringUtils; import com.yxt.common.base.service.MybatisBaseService; import com.yxt.common.base.utils.PagerUtil; @@ -52,13 +42,11 @@ import com.yxt.common.core.query.PagerQuery; import com.yxt.common.core.result.ResultBean; import com.yxt.common.core.vo.PagerVo; -import org.apache.tomcat.util.threads.ThreadPoolExecutor; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.util.*; -import java.util.concurrent.*; @Service public class OaMendApplyService extends MybatisBaseService { @@ -164,18 +152,15 @@ public class OaMendApplyService extends MybatisBaseService formVariables = dto.getFormVariables(); + //添加网关 +// formVariables.put("", ""); + Map appMap = new HashMap<>(); + appMap.put("sid", dto.getBusinessSid()); + formVariables.put("app", appMap); + dto.setFormVariables(formVariables); + BusinessVariablesDto businessVariablesDto = new BusinessVariablesDto(); + BeanUtil.copyProperties(dto, businessVariablesDto); + return oaFormService.complete(businessVariablesDto); + } + + /** + * 驳回 + * + * @param dto + * @return + */ + public ResultBean reject(TaskDto dto) { + Map formVariables = dto.getFormVariables(); + //添加网关 +// formVariables.put("", ""); + //若有移动端,则需和移动端沟通具体参数,若没有删去即可。 + Map appMap = new HashMap<>(); + appMap.put("sid", dto.getBusinessSid()); + formVariables.put("app", appMap); + dto.setFormVariables(formVariables); + + return oaFormService.reject(dto); + } + + public ResultBean> getPreviousNodesForReject(NodeQuery query) { + Map formVariables = query.getFormVariables(); + //添加网关 +// formVariables.put("", ""); + //若有移动端,则需和移动端沟通具体参数,若没有删去即可。 + Map appMap = new HashMap<>(); + appMap.put("sid", query.getBusinessSid()); + formVariables.put("app", appMap); + query.setFormVariables(formVariables); + return oaFormService.getPreviousNodesForReject(query); + } + + public ResultBean> getNextNodesForSubmit(NodeQuery query) { + Map formVariables = query.getFormVariables(); + //添加网关 +// formVariables.put("", ""); + //若有移动端,则需和移动端沟通具体参数,若没有删去即可。 + Map appMap = new HashMap<>(); + appMap.put("sid", query.getBusinessSid()); + formVariables.put("app", appMap); + query.setFormVariables(formVariables); + return oaFormService.getNextNodesForSubmit(query); + } } \ No newline at end of file From af90c19332209f9303df3e771ce7bb1905273048 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 10:32:40 +0800 Subject: [PATCH 11/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E4=BB=98=E6=AC=BE?= =?UTF-8?q?=E7=94=B3=E8=AF=B7=E8=AF=A6=E6=83=85=E9=A1=B5=E9=9D=A2=E4=BB=98?= =?UTF-8?q?=E6=AC=BE=E7=94=B3=E8=AF=B7=E5=A4=87=E6=B3=A8=E6=98=BE=E7=A4=BA?= =?UTF-8?q?=E9=94=99=E4=B9=B1=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../fukuanshenqing/paymentInfo.vue | 15 ++++++++++++++- .../fukuanguanli/fukuanDaiBanInfo.vue | 15 ++++++++++++++- .../fukuanguanli/fukuanYiBanInfo.vue | 15 ++++++++++++++- 3 files changed, 42 insertions(+), 3 deletions(-) diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue index b11fc48f2c..df53e5987f 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentInfo.vue @@ -47,7 +47,7 @@
付款单位
{{ formobj.payCompany }} - +
付款申请备注
{{ formobj.remarks }}
@@ -352,4 +352,17 @@ export default { .addinputInfo { margin-left: 140px !important; } +.tlineheightb { + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; +} +/deep/ .tlineheightb .el-form-item .el-form-item__content .addinputInfo { + line-height: 15px !important; + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; +} diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue index 717965ba15..a89cd035c4 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanDaiBanInfo.vue @@ -49,7 +49,7 @@
付款单位
{{ formobj.payCompany }}
- +
付款申请备注
{{ formobj.remarks }}
@@ -525,4 +525,17 @@ export default { .addinputInfo { margin-left: 140px !important; } +.tlineheightb { + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; +} +/deep/ .tlineheightb .el-form-item .el-form-item__content .addinputInfo { + line-height: 15px !important; + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; +} diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue index 2b7b8b3892..c57a1fdf5e 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanYiBanInfo.vue @@ -47,7 +47,7 @@
付款单位
{{ formobj.payCompany }}
- +
付款申请备注
{{ formobj.remarks }}
@@ -394,4 +394,17 @@ export default { .addinputInfo { margin-left: 140px !important; } +.tlineheightb { + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; +} +/deep/ .tlineheightb .el-form-item .el-form-item__content .addinputInfo { + line-height: 15px !important; + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; +} From dc1bbec9e4098dc1e6295d06196fb73a02eef869 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 10:39:04 +0800 Subject: [PATCH 12/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=8D=95=E8=BD=A6?= =?UTF-8?q?=E8=BF=94=E5=88=A9=E6=A0=B8=E5=AF=B9=20--=20=E9=87=8D=E6=8E=A8?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/api/bikerebate/bicyclerebatecheck.js | 8 +++ .../bicyclerebatecheck/bicyclerebatecheck.vue | 52 +++++++++++++++++-- 2 files changed, 57 insertions(+), 3 deletions(-) diff --git a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatecheck.js b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatecheck.js index b128f5f305..85c0330a2b 100644 --- a/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatecheck.js +++ b/anrui-scm/anrui-scm-ui/src/api/bikerebate/bicyclerebatecheck.js @@ -66,6 +66,14 @@ export default { headers: { 'Content-Type': 'application/json' } }) }, + // 重推 + rePushVoucher: function(data) { + return request({ + url: '/scm/v1/scmvehrebatecheckapply/rePushVoucher', + method: 'post', + params: data + }) + }, // 删除 delete: function(params) { return request({ diff --git a/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatecheck/bicyclerebatecheck.vue b/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatecheck/bicyclerebatecheck.vue index 4dd78578dc..a9108d88f0 100644 --- a/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatecheck/bicyclerebatecheck.vue +++ b/anrui-scm/anrui-scm-ui/src/views/bikerebate/bicyclerebatecheck/bicyclerebatecheck.vue @@ -102,7 +102,7 @@ import req from '@/api/bikerebate/bicyclerebatecheck' import Pagination from '@/components/pagination' import pageye from '@/components/pagination/pageye' import ButtonBar from '@/components/ButtonBar' -import { brandDown, getOrgSidByPath } from '@/api/cheliang/dictcommons' +import { brandDown, getButtonPermissions, getOrgSidByPath } from '@/api/cheliang/dictcommons' import bicyclerebatecheckAdd from './bicyclerebatecheckAdd' import bicyclerebatecheckInfo from './bicyclerebatecheckInfo' import { getStorage } from '@/utils/auth' @@ -123,6 +123,13 @@ export default { centerDialogVisible: false, btndisabled: false, btnList: [ + { + type: 'primary', + size: 'small', + icon: '', + btnKey: 'toRepush', + btnLabel: '重推' + }, { type: 'danger', size: 'small', @@ -145,6 +152,7 @@ export default { tableKey: 0, list: [], sids: [], + multipleSelection: [], FormLoading: false, listLoading: false, brand_list: '', @@ -174,7 +182,18 @@ export default { mounted() { // 在外部vue的window上添加postMessage的监听,而且绑定处理函数handleMessage window.addEventListener('message', this.handleMessage) - this.$refs['btnbar'].setButtonList(this.btnList) + getButtonPermissions({ userSid: window.sessionStorage.getItem('userSid'), url: this.$route.path, type: 0 }).then((res) => { + if (res.success) { + for (var i = 0; i < res.data.length; i++) { + for (var k = 0; k < this.btnList.length; k++) { + if (res.data[i].buttonId === this.btnList[k].btnKey) { + this.btnList.splice(k, 1) + } + } + } + this.$refs['btnbar'].setButtonList(this.btnList) + } + }) }, methods: { async handleMessage(event) { @@ -231,6 +250,9 @@ export default { btnHandle(btnKey) { console.log('XXXXXXXXXXXXXXX ' + btnKey) switch (btnKey) { + case 'toRepush': + this.toRepush() + break case 'doDel': this.doDel() break @@ -249,11 +271,11 @@ export default { }, handleSelectionChange(row) { const aa = [] + this.multipleSelection = row row.forEach((element) => { aa.push(element.sid) }) this.sids = aa - console.log('sids', this.sids) }, // 查询列表信息 getList() { @@ -301,6 +323,30 @@ export default { } this.init() }, + toRepush() { + if (this.multipleSelection.length === 1 && this.multipleSelection[0].nodeState === '已办结') { + const loading = this.$loading({ + lock: true, + text: 'Loading', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }) + req.rePushVoucher({ sid: this.sids[0] }).then((resp) => { + if (resp.success) { + loading.close() + this.$message({ showClose: true, type: 'success', message: '重推成功' }) + this.getList() + } else { + loading.close() + } + }).catch(() => { + loading.close() + }) + } else { + this.$message({ showClose: true, type: 'error', message: '请选择一条记录且状态为已办结的进行重推操作' }) + return + } + }, handleClick() { this.$parent.resetState() this.$parent.handleReset() From 683bc0274d0113745443105cd1347d8da9595d47 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 10:39:49 +0800 Subject: [PATCH 13/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E4=B8=93=E4=BF=AE?= =?UTF-8?q?=E8=BF=94=E5=88=A9=E6=A0=B8=E5=AF=B9=E3=80=81=E9=A2=84=E6=8F=90?= =?UTF-8?q?=20--=20=E9=87=8D=E6=8E=A8=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../api/specialrebate/specialrebatecheck.js | 8 +++ .../specialrebate/specialrebatewithholding.js | 8 +++ .../specialrebatecheck/specialrebatecheck.vue | 49 ++++++++++++++++-- .../specialrebatewithholding.vue | 50 +++++++++++++++++-- 4 files changed, 109 insertions(+), 6 deletions(-) diff --git a/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatecheck.js b/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatecheck.js index 3c07720e9b..cf7dad8f43 100644 --- a/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatecheck.js +++ b/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatecheck.js @@ -66,6 +66,14 @@ export default { headers: { 'Content-Type': 'application/json' } }) }, + // 重推 + rePushVoucher: function(data) { + return request({ + url: '/scm/v1/scmspecialrebatecheckapply/rePushVoucher', + method: 'post', + params: data + }) + }, // 删除 delete: function(params) { return request({ diff --git a/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatewithholding.js b/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatewithholding.js index 912cc866bb..872e8b8c33 100644 --- a/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatewithholding.js +++ b/anrui-scm/anrui-scm-ui/src/api/specialrebate/specialrebatewithholding.js @@ -19,6 +19,14 @@ export default { headers: { 'Content-Type': 'application/json' } }) }, + // 重推 + rePushVoucher: function(data) { + return request({ + url: '/scm/v1/scmspecialrebatewithapply/rePushVoucher', + method: 'post', + params: data + }) + }, // 删除 delete: function(params) { return request({ diff --git a/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/specialrebatecheck.vue b/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/specialrebatecheck.vue index 0029e443d0..a5896de497 100644 --- a/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/specialrebatecheck.vue +++ b/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatecheck/specialrebatecheck.vue @@ -102,7 +102,7 @@ import req from '@/api/specialrebate/specialrebatecheck' import Pagination from '@/components/pagination' import pageye from '@/components/pagination/pageye' import ButtonBar from '@/components/ButtonBar' -import { getOrgSidByPath } from '@/api/cheliang/dictcommons' +import { getButtonPermissions } from '@/api/cheliang/dictcommons' import specialrebatecheckAdd from './specialrebatecheckAdd' import specialrebatecheckInfo from './specialrebatecheckInfo' import { getStorage } from '@/utils/auth' @@ -123,6 +123,13 @@ export default { centerDialogVisible: false, btndisabled: false, btnList: [ + { + type: 'primary', + size: 'small', + icon: '', + btnKey: 'toRepush', + btnLabel: '重推' + }, { type: 'danger', size: 'small', @@ -145,6 +152,7 @@ export default { tableKey: 0, list: [], sids: [], + multipleSelection: [], FormLoading: false, listLoading: false, listQuery: { @@ -172,7 +180,18 @@ export default { mounted() { // 在外部vue的window上添加postMessage的监听,而且绑定处理函数handleMessage window.addEventListener('message', this.handleMessage) - this.$refs['btnbar'].setButtonList(this.btnList) + getButtonPermissions({ userSid: window.sessionStorage.getItem('userSid'), url: this.$route.path, type: 0 }).then((res) => { + if (res.success) { + for (var i = 0; i < res.data.length; i++) { + for (var k = 0; k < this.btnList.length; k++) { + if (res.data[i].buttonId === this.btnList[k].btnKey) { + this.btnList.splice(k, 1) + } + } + } + this.$refs['btnbar'].setButtonList(this.btnList) + } + }) }, methods: { async handleMessage(event) { @@ -233,11 +252,11 @@ export default { }, handleSelectionChange(row) { const aa = [] + this.multipleSelection = row row.forEach((element) => { aa.push(element.sid) }) this.sids = aa - console.log('sids', this.sids) }, // 查询列表信息 getList() { @@ -284,6 +303,30 @@ export default { } this.getList() }, + toRepush() { + if (this.multipleSelection.length === 1 && this.multipleSelection[0].nodeState === '已办结') { + const loading = this.$loading({ + lock: true, + text: 'Loading', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }) + req.rePushVoucher({ sid: this.sids[0] }).then((resp) => { + if (resp.success) { + loading.close() + this.$message({ showClose: true, type: 'success', message: '重推成功' }) + this.getList() + } else { + loading.close() + } + }).catch(() => { + loading.close() + }) + } else { + this.$message({ showClose: true, type: 'error', message: '请选择一条记录且状态为已办结的进行重推操作' }) + return + } + }, handleClick() { this.$parent.resetState() this.$parent.handleReset() diff --git a/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatewithholding/specialrebatewithholding.vue b/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatewithholding/specialrebatewithholding.vue index 65791cdc7a..b914a97af8 100644 --- a/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatewithholding/specialrebatewithholding.vue +++ b/anrui-scm/anrui-scm-ui/src/views/specialrebate/specialrebatewithholding/specialrebatewithholding.vue @@ -97,6 +97,7 @@ import ButtonBar from '@/components/ButtonBar' import specialrebatewithholdingAdd from './specialrebatewithholdingAdd' import specialrebatewithholdingInfo from './specialrebatewithholdingInfo' import { getStorage } from '@/utils/auth' +import { getButtonPermissions } from '@/api/cheliang/dictcommons' export default { name: 'ZhuanXiangFanLiYuTi', @@ -121,6 +122,13 @@ export default { btnKey: 'toAdd', btnLabel: '新增' }, + { + type: 'primary', + size: 'small', + icon: '', + btnKey: 'toRepush', + btnLabel: '重推' + }, { type: 'danger', size: 'small', @@ -143,6 +151,7 @@ export default { tableKey: 0, list: [], sids: [], + multipleSelection: [], FormLoading: false, listLoading: false, listQuery: { @@ -174,7 +183,18 @@ export default { mounted() { // 在外部vue的window上添加postMessage的监听,而且绑定处理函数handleMessage window.addEventListener('message', this.handleMessage) - this.$refs['btnbar'].setButtonList(this.btnList) + getButtonPermissions({ userSid: window.sessionStorage.getItem('userSid'), url: this.$route.path, type: 0 }).then((res) => { + if (res.success) { + for (var i = 0; i < res.data.length; i++) { + for (var k = 0; k < this.btnList.length; k++) { + if (res.data[i].buttonId === this.btnList[k].btnKey) { + this.btnList.splice(k, 1) + } + } + } + this.$refs['btnbar'].setButtonList(this.btnList) + } + }) }, methods: { async handleMessage(event) { @@ -238,11 +258,11 @@ export default { }, handleSelectionChange(row) { const aa = [] + this.multipleSelection = row row.forEach((element) => { aa.push(element.sid) }) this.sids = aa - console.log('sids', this.sids) }, // 查询列表信息 getList() { @@ -253,7 +273,7 @@ export default { req.listPage(this.listQuery).then((response) => { console.log('列表查询结果:', response) this.listLoading = false - if (response.success && response.data && response.data.total > 0) { + if (response.success) { this.list = response.data.records this.listQuery.total = response.data.total } else { @@ -293,6 +313,30 @@ export default { this.viewState = 2 this.$refs['divAdd'].showAdd() }, + toRepush() { + if (this.multipleSelection.length === 1 && this.multipleSelection[0].nodeState === '已办结') { + const loading = this.$loading({ + lock: true, + text: 'Loading', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }) + req.rePushVoucher({ sid: this.sids[0] }).then((resp) => { + if (resp.success) { + loading.close() + this.$message({ showClose: true, type: 'success', message: '重推成功' }) + this.getList() + } else { + loading.close() + } + }).catch(() => { + loading.close() + }) + } else { + this.$message({ showClose: true, type: 'error', message: '请选择一条记录且状态为已办结的进行重推操作' }) + return + } + }, toEdit(row) { this.viewState = 3 this.$refs['divAdd'].showEdit(row) From 4b90662a369c74fdefcd6f2a238ad57ddb0a5e65 Mon Sep 17 00:00:00 2001 From: yunuo970428 <405378304@qq.com> Date: Mon, 13 Jan 2025 10:59:51 +0800 Subject: [PATCH 14/14] =?UTF-8?q?=E5=AE=8C=E5=96=84=E4=BB=98=E6=AC=BE?= =?UTF-8?q?=E7=94=B3=E8=AF=B7--=E4=BB=98=E6=AC=BE=E6=98=8E=E7=BB=86?= =?UTF-8?q?=E8=A1=A8=E5=8E=82=E5=AE=B6=E5=9B=9E=E6=AC=BE=E9=80=9A=E8=B7=AF?= =?UTF-8?q?--=E6=94=B6=E6=AC=BE=E5=8D=95=E4=BD=8D=E5=90=8D=E7=A7=B0?= =?UTF-8?q?=E8=B5=8B=E5=80=BC=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue | 2 +- .../views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue index e4b22ef05d..d78cbb1a89 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/anruifinmanagement/fukuanshenqing/paymentAdd.vue @@ -640,7 +640,7 @@ export default { const choose = this.actualPay_list.filter((item) => item.actualPay === value) if (choose.length > 0 && choose !== null) { row.actualPay = choose[0].actualPay - row.receiveCompany = choose[0].manufacturerName + row.receiveCompany = choose[0].accountName row.bank = choose[0].depositBank row.receivingAccount = choose[0].bankAccount } else { diff --git a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue index be83be0aa8..ffce22ff96 100644 --- a/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue +++ b/anrui-buscenter/anrui-finmanage-ui/src/views/workFlow/fukuanguanliFlow/fukuanguanli/fukuanEdit.vue @@ -631,7 +631,7 @@ export default { const choose = this.actualPay_list.filter((item) => item.actualPay === value) if (choose.length > 0 && choose !== null) { row.actualPay = choose[0].actualPay - row.receiveCompany = choose[0].manufacturerName + row.receiveCompany = choose[0].accountName row.bank = choose[0].depositBank row.receivingAccount = choose[0].bankAccount } else {