diff --git a/front/src/views/home/apply.vue b/front/src/views/home/apply.vue index 2a3bb77c..c58a256b 100644 --- a/front/src/views/home/apply.vue +++ b/front/src/views/home/apply.vue @@ -426,8 +426,17 @@ } if (!applyAll) { let ids = [] + let falgNum = 0 + let sxt = true formName.system = [] console.log('list==================', list.value) + list.value.map((val) => { + val.arr.map((item) => { + if (item.type !== '基础设施') { + falgNum++ + } + }) + }) list.value.map((val) => { val.arr.map((item) => { if (item.type !== '基础设施') { @@ -435,6 +444,7 @@ resourceId: item.resourceId, resourceName: item.resourceName, }) + falgNum++ console.log(item.id) if (item.id) { ids.push(item.id) @@ -456,8 +466,14 @@ // applySuccess.value = false console.log('摄像头申请================>', res) if (item.id) { - sgcDel({ ids: [item.id] }).then((res) => { - if (res.data.msg === 'success') { + sgcDel({ ids: [item.id] }).then((res1) => { + if (res1.data.msg === 'success') { + if (falgNum == 0 && sxt) { + message.success( + '申请提交成功,请到消息中心查看!' + ) + sxt = false + } mybus.emit('getSgcNum') router.push({ path: '/DetailsPageconetent', @@ -468,6 +484,10 @@ } }) } else { + if (res.data.msg === 'success' && falgNum == 0 && sxt) { + message.success('申请提交成功,请到消息中心查看!') + sxt = false + } router.push({ path: '/DetailsPageconetent', query: {