feat(游戏王活动): 非阿语区展示不同的奖励政策图片

This commit is contained in:
hzj 2026-05-26 19:19:16 +08:00
parent bd6900bb1d
commit 1d0e180036

View File

@ -1102,7 +1102,13 @@ const Days = ref(0)
// //
const apiGetRegionByUserId = async () => { const apiGetRegionByUserId = async () => {
try { try {
const response = await getRegionByUserId(getUserId()) const userId = getUserId()
if (!userId) {
console.warn('用户ID为空跳过用户区域获取')
return
}
const response = await getRegionByUserId(userId)
if (response.status) { if (response.status) {
userRegion.value = response.body userRegion.value = response.body
} }
@ -1411,20 +1417,17 @@ const preloadOtherImages = async () => {
// 使APP // 使APP
const connectToAppHandler = async () => { const connectToAppHandler = async () => {
await connectToApp(() => { await connectToApp(async () => {
// await apiGetRegionByUserId()
completePreloading() // await completePreloading()
preloadOtherImages()
checkShow()
}) })
} }
// //
onMounted(async () => { onMounted(async () => {
await apiGetRegionByUserId()
connectToAppHandler() connectToAppHandler()
preloadOtherImages() //
checkShow() //
getCountdown() getCountdown()
timer = setInterval(getCountdown, 1000) // timer = setInterval(getCountdown, 1000) //
}) })