From 11eb5f2db86ca1a8bc0e08ec9446e487198efbba Mon Sep 17 00:00:00 2001 From: DevOps Date: Wed, 7 Jan 2026 12:38:28 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=A3=81=E5=88=A4=E7=AB=AF=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E9=80=80=E5=87=BA=E7=99=BB=E5=BD=95=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在评分列表页导航栏添加退出按钮 - 点击后弹出确认框,确认后清除登录信息并返回登录页 Co-authored-by: factory-droid[bot] <138933559+factory-droid[bot]@users.noreply.github.com> --- src/pages/score-list/score-list.vue | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/src/pages/score-list/score-list.vue b/src/pages/score-list/score-list.vue index 2ab02a8..3b16caf 100644 --- a/src/pages/score-list/score-list.vue +++ b/src/pages/score-list/score-list.vue @@ -4,6 +4,7 @@ 评分系统 + 退出 ··· @@ -294,6 +295,20 @@ export default { return scored + '/' + total }, + handleLogout() { + uni.showModal({ + title: "提示", + content: "确定要退出登录吗?", + success: (res) => { + if (res.confirm) { + uni.removeStorageSync("judgeInfo") + uni.removeStorageSync("token") + uni.reLaunch({ url: "/pages/login/login" }) + } + } + }) + }, + async handleRefresh() { if (this.isLoading) return uni.showToast({ title: '刷新中...', icon: 'loading', duration: 1000 }) @@ -437,6 +452,15 @@ export default { gap: 20rpx; } +.logout-btn { + font-size: 26rpx; + color: #FFFFFF; + background: rgba(255, 255, 255, 0.2); + padding: 8rpx 20rpx; + border-radius: 20rpx; + margin-right: 10rpx; +} + .nav-dots, .nav-circle { font-size: 32rpx; color: #FFFFFF;