chore: 优化通知公告跳转消息中心的方式

This commit is contained in:
KAI
2025-04-09 01:03:38 +00:00
committed by Charles7c
parent 40280da314
commit e8bbfcc402
2 changed files with 3 additions and 2 deletions

View File

@@ -21,6 +21,7 @@
<script setup lang="ts">
import { onMounted } from 'vue'
import { type MessageResp, listMessage, readMessage } from '@/apis'
import router from '@/router'
const emit = defineEmits<{
(e: 'readall-success'): void
@@ -48,7 +49,7 @@ const getMessageData = async () => {
// 打开消息中心
const open = () => {
window.open('/user/message?tab=msg')
router.push({ path: '/user/message', query: { tab: 'msg' } })
}
// 全部已读

View File

@@ -60,7 +60,7 @@ const onDetail = (id: number) => {
// 打开消息中心
const open = () => {
window.open('/user/message?tab=notice')
router.push({ path: '/user/message', query: { tab: 'notice' } })
}
onMounted(() => {