fix: 补充媒体详情订阅成功提示

This commit is contained in:
jxxghp
2026-05-20 05:56:08 +08:00
parent 07c9442ac8
commit e0ebc35178

View File

@@ -325,10 +325,11 @@ async function addSubscribe(season: number | null) {
function showSubscribeAddToast(result: boolean, title: string, season: number | null, message: string, best_version: number) {
if (season !== null) title = `${title} ${formatSeason(season.toString())}`
let subname = t('media.subscribe.normal')
if (best_version > 0) subname = t('media.subscribe.bestVersion')
let subname = t('subscribe.normalSub')
if (best_version > 0) subname = t('subscribe.versionSub')
if (!result) $toast.error(`${title} ${t('media.subscribe.addFailed', { reason: message })}`)
if (result) $toast.success(`${title} ${t('subscribe.addSuccess', { name: subname })}`)
else $toast.error(`${title} ${t('media.subscribe.addFailed', { reason: message })}`)
}
// 调用API取消订阅