feat(SearchBar): 添加站点搜索功能,支持多选和过滤

This commit is contained in:
jxxghp
2025-02-20 13:03:37 +08:00
parent 8962a2c4ac
commit 59d4b1e544
2 changed files with 57 additions and 2 deletions
+5
View File
@@ -31,6 +31,9 @@ const year = route.query?.year
// 搜索季
const season = route.query?.season?.toString() ?? ''
// 搜索站点,以,分离多个
const sites = route.query?.sites?.toString() ?? ''
// 视图类型,从localStorage中读取
const viewType = ref<string>(localStorage.getItem('MPTorrentsViewType') ?? 'card')
@@ -97,6 +100,7 @@ async function fetchData() {
title,
year,
season,
sites,
},
})
} else {
@@ -104,6 +108,7 @@ async function fetchData() {
result = await api.get(`search/title`, {
params: {
keyword,
sites,
},
})
}