mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-05-11 18:10:49 +08:00
fix browser
This commit is contained in:
@@ -4,7 +4,7 @@ import axios from 'axios'
|
||||
|
||||
// 创建axios实例
|
||||
const api = axios.create({
|
||||
baseURL: 'http://localhost:3001/api/v1',
|
||||
baseURL: 'http://localhost:3001/api/v1/',
|
||||
})
|
||||
|
||||
// 添加请求拦截器
|
||||
|
||||
@@ -43,7 +43,7 @@ const getChipColor = (type: string) => {
|
||||
<VChip
|
||||
variant="elevated"
|
||||
size="small"
|
||||
:class="getChipColor(props.media?.type||'')"
|
||||
:class="getChipColor('')"
|
||||
class="absolute right-2 top-2 bg-opacity-80 shadow-md text-white font-bold">
|
||||
{{ props.media?.vote_average }}
|
||||
</VChip>
|
||||
|
||||
@@ -3,13 +3,15 @@ import MediaCardListView from '@/views/discover/MediaCardListView.vue';
|
||||
|
||||
// 输入参数
|
||||
const props = defineProps({
|
||||
type: String,
|
||||
type: Array as PropType<string[]>,
|
||||
});
|
||||
|
||||
console.log(props.type);
|
||||
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<MediaCardListView :apipath="props.type"/>
|
||||
<MediaCardListView :apipath="props.type?.join('/')"/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -8,7 +8,7 @@ import MediaCardSlideView from '@/views/discover/MediaCardSlideView.vue';
|
||||
TMDB流行趋势
|
||||
</p>
|
||||
|
||||
<MediaCardSlideView apipath="/tmdb/trending"/>
|
||||
<MediaCardSlideView apipath="tmdb/trending"/>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -87,7 +87,7 @@ const router = createRouter({
|
||||
},
|
||||
},
|
||||
{
|
||||
path: 'browse/:type',
|
||||
path: '/browse/:type+',
|
||||
component: () => import('../pages/browse.vue'),
|
||||
props: true,
|
||||
meta: {
|
||||
|
||||
@@ -20,7 +20,7 @@ const dataList = ref<TransferHistory[]>([]);
|
||||
// 获取订阅列表数据
|
||||
const fetchData = async () => {
|
||||
try {
|
||||
dataList.value = await api.get("/history/transfer");
|
||||
dataList.value = await api.get("history/transfer");
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ const dataList = ref<Subscribe[]>([]);
|
||||
// 获取订阅列表数据
|
||||
const fetchData = async () => {
|
||||
try {
|
||||
dataList.value = await api.get("/subscribe");
|
||||
dataList.value = await api.get("subscribe");
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user