feat: 搜索点击tag、分类需要重入

This commit is contained in:
Tim
2025-08-01 12:15:36 +08:00
parent e8e77b6467
commit 873db304d1

View File

@@ -92,9 +92,13 @@ export default {
router.push(`/posts/${opt.postId}#comment-${opt.id}`)
}
} else if (opt.type === 'category') {
router.push({ path: '/', query: { category: opt.id } })
router.push({ path: '/', query: { category: opt.id } }).then(() => {
window.location.reload()
})
} else if (opt.type === 'tag') {
router.push({ path: '/', query: { tags: opt.id } })
router.push({ path: '/', query: { tags: opt.id } }).then(() => {
window.location.reload()
})
}
selected.value = null
keyword.value = ''