mirror of
https://github.com/Megghy/vtsuru.live.git
synced 2025-12-07 02:46:55 +08:00
update url
This commit is contained in:
@@ -108,7 +108,7 @@ const acceptVideos = computed(() => {
|
||||
|
||||
async function getData() {
|
||||
try {
|
||||
const data = await QueryGetAPI<VideoCollectDetail>(VIDEO_COLLECT_API_URL + 'get', { id: route.params.id })
|
||||
const data = await QueryGetAPI<VideoCollectDetail>(VIDEO_COLLECT_API_URL() + 'get', { id: route.params.id })
|
||||
if (data.code == 200) {
|
||||
updateModel.value = {
|
||||
id: data.data.table.id,
|
||||
@@ -120,7 +120,6 @@ async function getData() {
|
||||
return data.data
|
||||
}
|
||||
} catch (err) {
|
||||
console.error(err)
|
||||
message.error('获取失败')
|
||||
}
|
||||
return {} as VideoCollectDetail
|
||||
@@ -201,7 +200,7 @@ const rejectButtonGroup = (v: VideoInfo) =>
|
||||
])
|
||||
function setStatus(status: VideoStatus, video: VideoInfo) {
|
||||
isLoading.value = true
|
||||
QueryGetAPI(VIDEO_COLLECT_API_URL + 'set-status', {
|
||||
QueryGetAPI(VIDEO_COLLECT_API_URL() + 'set-status', {
|
||||
id: videoDetail.value.table.id,
|
||||
bvid: video.bvid,
|
||||
status: status,
|
||||
@@ -215,7 +214,6 @@ function setStatus(status: VideoStatus, video: VideoInfo) {
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err)
|
||||
message.error('设置失败')
|
||||
})
|
||||
.finally(() => {
|
||||
@@ -237,7 +235,7 @@ function dateDisabled(ts: number) {
|
||||
function updateTable() {
|
||||
isLoading.value = true
|
||||
updateModel.value.id = videoDetail.value.table.id
|
||||
QueryPostAPI<VideoCollectTable>(VIDEO_COLLECT_API_URL + 'update', updateModel.value)
|
||||
QueryPostAPI<VideoCollectTable>(VIDEO_COLLECT_API_URL() + 'update', updateModel.value)
|
||||
.then((data) => {
|
||||
if (data.code == 200) {
|
||||
message.success('更新成功')
|
||||
@@ -247,7 +245,6 @@ function updateTable() {
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err)
|
||||
message.error('更新失败')
|
||||
})
|
||||
.finally(() => {
|
||||
@@ -256,7 +253,7 @@ function updateTable() {
|
||||
}
|
||||
function deleteTable() {
|
||||
isLoading.value = true
|
||||
QueryGetAPI(VIDEO_COLLECT_API_URL + 'del', {
|
||||
QueryGetAPI(VIDEO_COLLECT_API_URL() + 'del', {
|
||||
id: videoDetail.value.table.id,
|
||||
})
|
||||
.then((data) => {
|
||||
@@ -270,7 +267,6 @@ function deleteTable() {
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err)
|
||||
message.error('删除失败')
|
||||
})
|
||||
.finally(() => {
|
||||
@@ -279,7 +275,7 @@ function deleteTable() {
|
||||
}
|
||||
function closeTable() {
|
||||
isLoading.value = true
|
||||
QueryGetAPI(VIDEO_COLLECT_API_URL + 'finish', {
|
||||
QueryGetAPI(VIDEO_COLLECT_API_URL() + 'finish', {
|
||||
id: videoDetail.value.table.id,
|
||||
finish: !videoDetail.value.table.isFinish,
|
||||
})
|
||||
@@ -292,7 +288,6 @@ function closeTable() {
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err)
|
||||
message.error('操作失败')
|
||||
})
|
||||
.finally(() => {
|
||||
|
||||
Reference in New Issue
Block a user