更新:访客模式可以查看图书首页

This commit is contained in:
2025-12-12 14:33:47 +08:00
parent 04e2196942
commit 34d6cfdf9e
10 changed files with 43 additions and 53 deletions

View File

@@ -457,17 +457,11 @@ const requestAll = async () => {
* 页面挂载
*/
onMounted(() => {
if(!userStore.token) {
uni.navigateTo({
url: '/pages/login/login'
});
}
// 重置分类索引
currentIndex.value = 0
// 请求所有数据
requestAll()
console.log('进来了2');
})
/**
@@ -485,7 +479,7 @@ onShow(() => {
// 刷新数据
// requestAll()
if(userStore.token){
if(uni.getStorageSync('token')){
getLearnCourse()
}
})