From c44be70682f2c38d65e5c8c94827309aa23b32a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=98=AF=E5=B0=8F=E7=8E=8B=E5=91=80=5C24601?= <819653817@qq.com> Date: Mon, 10 Feb 2025 16:14:53 +0800 Subject: [PATCH] =?UTF-8?q?=E7=8A=B6=E6=80=81=E4=B8=BA=E5=B7=B2=E6=8F=90?= =?UTF-8?q?=E4=BA=A4=E7=9A=84=E6=97=B6=E5=80=99=EF=BC=8C=E4=B8=8D=E6=98=BE?= =?UTF-8?q?=E7=A4=BA=E8=B0=83=E6=95=B4=EF=BC=8C=20=E8=B0=83=E6=95=B4?= =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=B8=BA=E4=B8=8D=E5=90=8C=E7=9A=84=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../smartExcel/cpts/acceptingPersonel.vue | 31 ++++++++++++++----- .../base/smartExcel/cpts/excel-info.vue | 1 + .../cpts/excel-template-confirmation.vue | 12 +++---- .../base/smartExcel/cpts/filling-info.vue | 2 +- 4 files changed, 32 insertions(+), 14 deletions(-) diff --git a/src/views/modules/base/smartExcel/cpts/acceptingPersonel.vue b/src/views/modules/base/smartExcel/cpts/acceptingPersonel.vue index ad90fa662..6c334fd6f 100644 --- a/src/views/modules/base/smartExcel/cpts/acceptingPersonel.vue +++ b/src/views/modules/base/smartExcel/cpts/acceptingPersonel.vue @@ -96,7 +96,7 @@ export default { }, created() { }, methods: { - handleConfirm() { + async handleConfirm() { console.log(this.selfTag),"dsfkljdslk"; let userIdList = this.selfTag.map(item => { return item.staffId @@ -106,8 +106,8 @@ export default { userIdList: userIdList, taskId: this.taskId, } - this.updateState() - requestPost('/actual/base/communityOneTablePeriodPublish/changeAssignWorker', parms).then(res => { + + await requestPost('/actual/base/communityOneTablePeriodPublish/changeAssignWorker', parms).then(res => { if (res.code === 0) { this.$message.success('转派成功') return this.$emit('handelPersonel') @@ -115,14 +115,15 @@ export default { this.$message.error(res.internalMsg) } }); + this.updateState() } else if (this.showType == "adjust1") { let parms = { userId: userIdList.toString(), id: this.taskId, reassignedReason: "" } - this.updateState() - requestPost('/actual/base/communityOneTablePeriodPublish/reAssignWorker', parms).then(res => { + + await requestPost('/actual/base/communityOneTablePeriodPublish/reAssignWorker', parms).then(res => { if (res.code === 0) { this.$message.success('转派成功') return this.$emit('handelPersonel') @@ -130,6 +131,7 @@ export default { this.$message.error(res.internalMsg) } }); + this.updateState() } else { let parms = { @@ -145,8 +147,21 @@ export default { }, async updateState() { - const url = '/actual/base/communityOneTablePeriodPublish/update' - console.log(this.formDatas); + if(this.showType=="adjust1"){ + const url = '/actual/base/communityOneTablePeriodPublish/update' + console.log(this.formDatas,"sdfkljslkdjf"); + const { id, taskId, taskTitle, taskPeriod, taskType, taskIntroduction } = this.formDatas; + const parm = { id, taskId, taskTitle, taskPeriod, taskType, taskIntroduction } + parm.taskState = 'reassigned'; + const { code, msg } = await requestPost(url, parm) + if (code === 0) { + // this.$message.success('转派成功') + } else { + console.log(msg); + } + }else{ + const url = '/actual/base/communityOneTablePublish/update' + console.log(this.formDatas,"sdfkljslkdjf"); const { id, taskId, taskTitle, taskPeriod, taskType, taskIntroduction } = this.formDatas; const parm = { id, taskId, taskTitle, taskPeriod, taskType, taskIntroduction } parm.taskState = 'reassigned'; @@ -155,7 +170,9 @@ export default { // this.$message.success('转派成功') } else { console.log(msg); + } } + }, getPeriodPublish() { diff --git a/src/views/modules/base/smartExcel/cpts/excel-info.vue b/src/views/modules/base/smartExcel/cpts/excel-info.vue index dcad6f170..de6720e4c 100644 --- a/src/views/modules/base/smartExcel/cpts/excel-info.vue +++ b/src/views/modules/base/smartExcel/cpts/excel-info.vue @@ -134,6 +134,7 @@ export default { }, handelPersonel() { this.showPersonel = false; + this.getDetail() }, oncClickPersonel(){ this.showType="adjust" diff --git a/src/views/modules/base/smartExcel/cpts/excel-template-confirmation.vue b/src/views/modules/base/smartExcel/cpts/excel-template-confirmation.vue index 5cc4dc41c..9ea632b2f 100644 --- a/src/views/modules/base/smartExcel/cpts/excel-template-confirmation.vue +++ b/src/views/modules/base/smartExcel/cpts/excel-template-confirmation.vue @@ -72,12 +72,12 @@ export default { }, mounted() { console.log(this.fileUrl, 'fileUrl===');//测试用'http://localhost:9001/epmet-work-pc/test1.xlsx' - // const newUrl = this.fileUrl.replace( - // /^https:\/\/elink-esua-epdc\.oss-cn-qingdao\.aliyuncs\.com/, - // `${location.origin}` - // ); - // this.urlToFile(newUrl,this.fileName) - this.urlToFile('http://localhost:9001/epmet-work-pc/test1.xlsx',this.fileName) + const newUrl = this.fileUrl.replace( + /^https:\/\/elink-esua-epdc\.oss-cn-qingdao\.aliyuncs\.com/, + `${location.origin}` + ); + this.urlToFile(newUrl,this.fileName) + // this.urlToFile('http://localhost:9001/epmet-work-pc/test1.xlsx',this.fileName) }, props: { diff --git a/src/views/modules/base/smartExcel/cpts/filling-info.vue b/src/views/modules/base/smartExcel/cpts/filling-info.vue index 4d34b142a..518e96b1c 100644 --- a/src/views/modules/base/smartExcel/cpts/filling-info.vue +++ b/src/views/modules/base/smartExcel/cpts/filling-info.vue @@ -45,7 +45,7 @@
{{ formData.userName }}
- 转派其他接收人