Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Hooke
/
meihua-island-book
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
hookehuyr
2023-12-21 16:48:49 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
a3991f9b80d6d218e78202d36618131e73e53716
a3991f9b
1 parent
d8f09650
登录跳转逻辑优化
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
8 deletions
src/pages/detail/index.vue
src/pages/login/index.vue
src/pages/my/index.vue
src/pages/detail/index.vue
View file @
a3991f9
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2023-12-21 16:
05:43
* @LastEditTime: 2023-12-21 16:
28:56
* @FilePath: /meihuaApp/src/pages/detail/index.vue
* @Description: 房间详情页面
-->
...
...
@@ -153,7 +153,7 @@ const goToConfirm = () => {
});
} else {
Taro.navigateTo({
url: `/pages/login/index`,
url: `/pages/login/index
?page=detail
`,
});
}
}
...
...
src/pages/login/index.vue
View file @
a3991f9
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2023-12-2
0 10:25:15
* @LastEditTime: 2023-12-2
1 16:45:56
* @FilePath: /meihuaApp/src/pages/login/index.vue
* @Description: 文件描述
-->
...
...
@@ -43,6 +43,7 @@
import Taro from '@tarojs/taro'
import { IconFont } from '@nutui/icons-vue-taro';
import { ref, nextTick } from "vue";
import { getCurrentPageParam } from "@/utils/weapp";
let countdownIntervalId; // 用于存储倒计时的计时器 ID
...
...
@@ -119,9 +120,17 @@ const login = () => {
duration: 2000,
success: () => {
setTimeout(() => {
Taro.reLaunch({
url: '/pages/index/index'
})
let params = getCurrentPageParam();
if (params.page === 'detail') { // 详情页
Taro.navigateBack({
delta: 1
});
}
if (params.page === 'my') { // 登录页
Taro.redirectTo({
url: '/pages/myInfo/index'
});
}
}, 1000);
}
});
...
...
src/pages/my/index.vue
View file @
a3991f9
<!--
* @Date: 2023-12-13 11:13:13
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2023-12-21 16:
03:09
* @LastEditTime: 2023-12-21 16:
34:26
* @FilePath: /meihuaApp/src/pages/my/index.vue
* @Description: 我的页面
-->
...
...
@@ -127,7 +127,7 @@ const goToEdit = () => {
});
} else {
Taro.navigateTo({
url: '/pages/login/index',
url: '/pages/login/index
?page=my
',
});
}
}
...
...
Please
register
or
login
to post a comment