按钮loading-产品标准流程

This commit is contained in:
zyn
2023-11-02 16:37:39 +08:00
parent 3ee543f92b
commit e9a0963c1f
17 changed files with 136 additions and 97 deletions
@@ -2984,6 +2984,7 @@
// } // }
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
this.fileInfoHandle() this.fileInfoHandle()
_formData.append('id', this.bpnId || '') _formData.append('id', this.bpnId || '')
@@ -2998,11 +2999,11 @@
commentText: this.commentText commentText: this.commentText
})) }))
saveTaskFirst(_formData).then(res => { saveTaskFirst(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -3150,8 +3151,6 @@
}, res => { }, res => {
if (res.ok) { if (res.ok) {
if (res.data === '操作成功') { if (res.data === '操作成功') {
this.submitLoading = false
this.isSubmit = false
if (this.$route.query.bpnId && this.$route.query.bpnId !== '') { if (this.$route.query.bpnId && this.$route.query.bpnId !== '') {
let taskId = { let taskId = {
id: this.$route.query.bpnId id: this.$route.query.bpnId
@@ -3166,7 +3165,12 @@
} else { } else {
this.$message.warning(res.data) this.$message.warning(res.data)
} }
this.submitLoading = false
this.isSubmit = false
}) })
} else {
this.submitLoading = false
this.isSubmit = false
} }
}) })
} }
@@ -1220,8 +1220,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1230,6 +1228,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2090,6 +2091,7 @@
// } // }
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
// _formData.append('id', this.bpnId) // _formData.append('id', this.bpnId)
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2109,11 +2111,11 @@
commentText: this.commentText commentText: this.commentText
})) }))
saveTaskFirst(_formData).then(res => { saveTaskFirst(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
// this.bpnId = res.result // this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2235,6 +2237,7 @@
this.$refs['formTongGuo'].validate((valid) => { this.$refs['formTongGuo'].validate((valid) => {
if (valid) { if (valid) {
this.isSubmit = true this.isSubmit = true
this.saveLoading = true
this.form.commentText = this.formTongGuo.commentText this.form.commentText = this.formTongGuo.commentText
this.form.approvalOpinion = this.formTongGuo.approvalOpinion this.form.approvalOpinion = this.formTongGuo.approvalOpinion
const json = JSON.stringify(this.form); const json = JSON.stringify(this.form);
@@ -2253,12 +2256,13 @@
this.$message.success(res.message) this.$message.success(res.message)
// this.processCreateLaws(json) // this.processCreateLaws(json)
} }
this.isSubmit = false
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
}, },
@@ -1220,8 +1220,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1230,6 +1228,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2090,6 +2091,7 @@
// } // }
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
// _formData.append('id', this.bpnId) // _formData.append('id', this.bpnId)
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2109,11 +2111,11 @@
commentText: this.commentText commentText: this.commentText
})) }))
saveTaskFirst(_formData).then(res => { saveTaskFirst(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
// this.bpnId = res.result // this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2235,6 +2237,7 @@
this.$refs['formTongGuo'].validate((valid) => { this.$refs['formTongGuo'].validate((valid) => {
if (valid) { if (valid) {
this.isSubmit = true this.isSubmit = true
this.saveLoading = true
this.form.commentText = this.formTongGuo.commentText this.form.commentText = this.formTongGuo.commentText
this.form.approvalOpinion = this.formTongGuo.approvalOpinion this.form.approvalOpinion = this.formTongGuo.approvalOpinion
const json = JSON.stringify(this.form); const json = JSON.stringify(this.form);
@@ -2253,12 +2256,13 @@
this.$message.success(res.message) this.$message.success(res.message)
// this.processCreateLaws(json) // this.processCreateLaws(json)
} }
this.isSubmit = false
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
}, },
@@ -1220,8 +1220,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1230,6 +1228,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2090,6 +2091,7 @@
// } // }
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
// _formData.append('id', this.bpnId) // _formData.append('id', this.bpnId)
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2112,8 +2114,9 @@
this.saveLoading = false this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
// this.bpnId = res.result // this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2235,6 +2238,7 @@
this.$refs['formTongGuo'].validate((valid) => { this.$refs['formTongGuo'].validate((valid) => {
if (valid) { if (valid) {
this.isSubmit = true this.isSubmit = true
this.saveLoading = true
this.form.commentText = this.formTongGuo.commentText this.form.commentText = this.formTongGuo.commentText
this.form.approvalOpinion = this.formTongGuo.approvalOpinion this.form.approvalOpinion = this.formTongGuo.approvalOpinion
const json = JSON.stringify(this.form); const json = JSON.stringify(this.form);
@@ -2253,12 +2257,13 @@
this.$message.success(res.message) this.$message.success(res.message)
// this.processCreateLaws(json) // this.processCreateLaws(json)
} }
this.isSubmit = false
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
}, },
@@ -1182,8 +1182,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1192,6 +1190,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
drawerCheckZRBM(data) { drawerCheckZRBM(data) {
@@ -2419,13 +2420,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.isSubmit = false
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.isSubmit = false this.saveLoading = false
this.saveLoading = false this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2578,8 +2577,6 @@
if (res.success) { if (res.success) {
// this.$message.success(res.message) // this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.processCreateBuss(json) this.processCreateBuss(json)
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2592,6 +2589,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}, },
handleSubmit() { handleSubmit() {
@@ -2349,8 +2349,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2363,6 +2361,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
} }
@@ -1220,8 +1220,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1230,6 +1228,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2342,8 +2343,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2356,6 +2355,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}else { }else {
this.$message.warning('请先上传文件,再提交流程') this.$message.warning('请先上传文件,再提交流程')
@@ -1207,8 +1207,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1217,6 +1215,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
drawerCheckZRBM(data) { drawerCheckZRBM(data) {
@@ -2467,6 +2468,7 @@
// } // }
this.fileInfoHandle() this.fileInfoHandle()
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
_formData.append('id', this.bpnId || '') _formData.append('id', this.bpnId || '')
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2481,11 +2483,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2616,8 +2618,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2630,6 +2630,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
// this.processModelHisOneCount(this.pId) // this.processModelHisOneCount(this.pId)
// .then(res => { // .then(res => {
@@ -1219,8 +1219,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1229,6 +1227,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2234,6 +2235,7 @@
this.$refs['formTongGuo'].validate((valid) => { this.$refs['formTongGuo'].validate((valid) => {
if (valid) { if (valid) {
this.isSubmit = true this.isSubmit = true
this.saveLoading = true
this.form.commentText = this.formTongGuo.commentText this.form.commentText = this.formTongGuo.commentText
this.form.approvalOpinion = this.formTongGuo.approvalOpinion this.form.approvalOpinion = this.formTongGuo.approvalOpinion
const json = JSON.stringify(this.form); const json = JSON.stringify(this.form);
@@ -2252,12 +2254,13 @@
this.$message.success(res.message) this.$message.success(res.message)
// this.processCreateLaws(json) // this.processCreateLaws(json)
} }
this.isSubmit = false
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
}, },
@@ -1635,8 +1635,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1645,6 +1643,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2546,6 +2547,7 @@
// this.summaryName=this.summaryList.map(item => item.name).join(",") // this.summaryName=this.summaryList.map(item => item.name).join(",")
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
_formData.append('id', this.bpnId || '') _formData.append('id', this.bpnId || '')
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2563,11 +2565,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2737,12 +2739,12 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
} }
}) })
@@ -1265,8 +1265,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1275,6 +1273,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
drawerCheckZRBM(data) { drawerCheckZRBM(data) {
@@ -2511,11 +2512,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2645,8 +2646,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2659,6 +2658,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
// this.processModelHisOneCount(this.pId) // this.processModelHisOneCount(this.pId)
// .then(res => { // .then(res => {
@@ -1286,8 +1286,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1296,6 +1294,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
drawerCheckZRBM(data) { drawerCheckZRBM(data) {
@@ -2518,6 +2519,7 @@
// } // }
this.fileInfoHandle() this.fileInfoHandle()
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
_formData.append('id', this.bpnId || '') _formData.append('id', this.bpnId || '')
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2532,11 +2534,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2666,8 +2668,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2680,6 +2680,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
// this.processModelHisOneCount(this.pId) // this.processModelHisOneCount(this.pId)
// .then(res => { // .then(res => {
@@ -2181,11 +2181,11 @@
commentText: this.commentText commentText: this.commentText
})) }))
saveTaskFirst(_formData).then(res => { saveTaskFirst(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
// this.bpnId = res.result // this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2289,8 +2289,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -2299,6 +2297,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
handleTransfer() { handleTransfer() {
@@ -2344,8 +2345,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2358,6 +2357,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
} }
@@ -1220,8 +1220,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1230,6 +1228,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2090,6 +2091,7 @@
// } // }
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
// _formData.append('id', this.bpnId) // _formData.append('id', this.bpnId)
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2109,11 +2111,11 @@
commentText: this.commentText commentText: this.commentText
})) }))
saveTaskFirst(_formData).then(res => { saveTaskFirst(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
// this.bpnId = res.result // this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2235,6 +2237,7 @@
this.$refs['formTongGuo'].validate((valid) => { this.$refs['formTongGuo'].validate((valid) => {
if (valid) { if (valid) {
this.isSubmit = true this.isSubmit = true
this.saveLoading = true
this.form.commentText = this.formTongGuo.commentText this.form.commentText = this.formTongGuo.commentText
this.form.approvalOpinion = this.formTongGuo.approvalOpinion this.form.approvalOpinion = this.formTongGuo.approvalOpinion
const json = JSON.stringify(this.form); const json = JSON.stringify(this.form);
@@ -2253,12 +2256,13 @@
this.$message.success(res.message) this.$message.success(res.message)
// this.processCreateLaws(json) // this.processCreateLaws(json)
} }
this.isSubmit = false
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
}, },
@@ -1220,8 +1220,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1230,6 +1228,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
checkedRole (data) { checkedRole (data) {
@@ -2090,6 +2091,7 @@
// } // }
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
// _formData.append('id', this.bpnId) // _formData.append('id', this.bpnId)
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2109,11 +2111,11 @@
commentText: this.commentText commentText: this.commentText
})) }))
saveTaskFirst(_formData).then(res => { saveTaskFirst(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
// this.bpnId = res.result // this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2235,6 +2237,7 @@
this.$refs['formTongGuo'].validate((valid) => { this.$refs['formTongGuo'].validate((valid) => {
if (valid) { if (valid) {
this.isSubmit = true this.isSubmit = true
this.saveLoading = true
this.form.commentText = this.formTongGuo.commentText this.form.commentText = this.formTongGuo.commentText
this.form.approvalOpinion = this.formTongGuo.approvalOpinion this.form.approvalOpinion = this.formTongGuo.approvalOpinion
const json = JSON.stringify(this.form); const json = JSON.stringify(this.form);
@@ -2253,12 +2256,13 @@
this.$message.success(res.message) this.$message.success(res.message)
// this.processCreateLaws(json) // this.processCreateLaws(json)
} }
this.isSubmit = false
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
}}) }})
}, },
@@ -1186,8 +1186,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1196,6 +1194,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
drawerCheckZRBM(data) { drawerCheckZRBM(data) {
@@ -2400,6 +2401,7 @@
// } // }
this.fileInfoHandle() this.fileInfoHandle()
this.saveLoading = true this.saveLoading = true
this.isSubmit = true
let _formData = new FormData() let _formData = new FormData()
_formData.append('id', this.bpnId || '') _formData.append('id', this.bpnId || '')
_formData.append('createUser', this.$store.getters.userInfo.userId) _formData.append('createUser', this.$store.getters.userInfo.userId)
@@ -2414,11 +2416,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2549,8 +2551,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2563,6 +2563,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
// this.processModelHisOneCount(this.pId) // this.processModelHisOneCount(this.pId)
// .then(res => { // .then(res => {
@@ -1274,8 +1274,6 @@
assignee: data[0].id, // 被委托人 assignee: data[0].id, // 被委托人
pId: this.$route.query.prcId, // 流程实例 pId: this.$route.query.prcId, // 流程实例
}).then(res => { }).then(res => {
this.isSubmit = false
this.saveLoading = false
if (res.success) { if (res.success) {
this.drawerModal = false this.drawerModal = false
this.$message.success('调整成功') this.$message.success('调整成功')
@@ -1284,6 +1282,9 @@
} else { } else {
this.$message.warning(res.message) this.$message.warning(res.message)
} }
}).finally(() => {
this.isSubmit = false
this.saveLoading = false
}) })
}, },
drawerCheckZRBM(data) { drawerCheckZRBM(data) {
@@ -2521,11 +2522,11 @@
commentText: this.formTongGuo.commentText commentText: this.formTongGuo.commentText
})) }))
saveTaskForPub(_formData).then(res => { saveTaskForPub(_formData).then(res => {
this.saveLoading = false
this.$message.success('保存成功') this.$message.success('保存成功')
this.bpnId = res.result this.bpnId = res.result
}).catch(e => { }).finally(() => {
this.saveLoading = false this.saveLoading = false
this.isSubmit = false
}) })
}, },
fileInfoHandle(){ fileInfoHandle(){
@@ -2655,8 +2656,6 @@
if (res.success) { if (res.success) {
this.$message.success(res.message) this.$message.success(res.message)
// 流程提交之后,应该流转至待办任务页面 // 流程提交之后,应该流转至待办任务页面
this.isSubmit = false
this.saveLoading = false
this.$router.push({path:'/processCenter?tabsName=ProcessCenter'}) this.$router.push({path:'/processCenter?tabsName=ProcessCenter'})
// if(this.formTongGuo.approvalOpinion === '1'){ // if(this.formTongGuo.approvalOpinion === '1'){
// this.$message.warning("驳回成功") // this.$message.warning("驳回成功")
@@ -2669,6 +2668,8 @@
}else { }else {
this.$message.success(res.message) this.$message.success(res.message)
} }
this.isSubmit = false
this.saveLoading = false
}) })
// this.processModelHisOneCount(this.pId) // this.processModelHisOneCount(this.pId)
// .then(res => { // .then(res => {