fix: 修复流程中当发起流程时,如果没有草稿时,后端接口报错的BUG,此处在前端页面增加判断逻辑防止如果没有草稿数据时接口报错的BUG

This commit is contained in:
zyd
2022-07-13 22:22:25 +08:00
parent b9ca214c0f
commit 32370c07e7
4 changed files with 74 additions and 57 deletions
@@ -373,6 +373,8 @@
this.foldFormFlag = !this.foldFormFlag
},
getData () {
const queryId = this.$route.query.bpnId
if(queryId !== null && queryId !== undefined && queryId !==''){
queryTaskFirst({
bpnId: this.$route.query.bpnId
}).then(res => {
@@ -387,6 +389,7 @@
this.roleForm = mes.roleForm
this.commentText1 = mes.commentText1 || ''
})
}
},
checkedRole2 (data) {
var idList = ''
@@ -597,9 +600,11 @@
let taskId = {
id: this.$route.query.bpnId
}
if(taskId !=='' && taskId !== undefined && taskId !== null){
taskDel(taskId).then(res=>{
return res
})
}
this.$router.push('/processCenter')
}
this.isSubmit = false
@@ -589,9 +589,11 @@ export default {
let taskId = {
id: this.$route.query.bpnId
}
if(taskId !== '' && taskId !== undefined && taskId !== null){
taskDel(taskId).then(res=>{
return res
})
}
this.$router.push('/processCenter')
}
this.isSubmit = false
@@ -862,6 +862,8 @@
this.itermsConditionsTitle = row.replace(/''/g, '\'')
},
getData () {
const queryId =this.$route.query.bpnId
if(queryId !== null && queryId !== undefined && queryId !==''){
queryTaskFirst({
bpnId: this.$route.query.bpnId
}).then(res => {
@@ -878,6 +880,7 @@
this.itemList = mes.itemList
this.sarType = mes.sarType
})
}
},
setMap(data){
data.forEach(item => {
@@ -1136,9 +1139,11 @@
let taskId = {
id: this.$route.query.bpnId
}
if(taskId !== '' && taskId !== undefined && taskId !== null){
taskDel(taskId).then(res=>{
return res
})
}
this.$router.push('/processCenter')
}
})
@@ -661,6 +661,8 @@ export default {
window.open(routeUrl.href, '_blank')
},
getData() {
const queryId = this.$route.query.bpnId
if(queryId !== null && queryId !== undefined && queryId !==''){
queryTaskFirst({
bpnId: this.$route.query.bpnId
}).then(res => {
@@ -685,6 +687,7 @@ export default {
})
}
})
}
},
addZqyjList() {
this.title = '国内外标准库'
@@ -860,9 +863,11 @@ export default {
let taskId = {
id: this.$route.query.bpnId
}
if(taskId !== '' && taskId !== undefined && taskId !== null){
taskDel(taskId).then(res=>{
return res
})
}
this.$router.push('/processCenter')
}
})