From 104d7fe0ef969a4527b312760378f9fab4a00012 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=96=BB=E5=8B=87=E7=A5=A5?= <237899745@qq.com> Date: Mon, 24 Nov 2025 18:57:50 +0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20=E4=BC=98=E5=8C=96=E9=82=AE?= =?UTF-8?q?=E4=BB=B6=E9=AA=8C=E8=AF=81=E5=92=8C=E5=AF=86=E7=A0=81=E9=87=8D?= =?UTF-8?q?=E7=BD=AE=E9=93=BE=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 修改邮件中的验证和重置链接,直接指向 app.html 页面 - 在落地页添加容错脚本,自动重定向带 token 的请求到应用页 - 提升用户体验,减少跳转步骤 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- backend/server.js | 6 +++--- frontend/index.html | 10 ++++++++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/backend/server.js b/backend/server.js index 673d673..688b3fc 100644 --- a/backend/server.js +++ b/backend/server.js @@ -827,7 +827,7 @@ app.post('/api/register', verification_expires_at: expiresAtMs }); - const verifyLink = `${getProtocol(req)}://${req.get('host')}/?verifyToken=${verifyToken}`; + const verifyLink = `${getProtocol(req)}://${req.get('host')}/app.html?verifyToken=${verifyToken}`; try { await sendMail( @@ -894,7 +894,7 @@ app.post('/api/resend-verification', [ const expiresAtMs = Date.now() + 30 * 60 * 1000; VerificationDB.setVerification(user.id, verifyToken, expiresAtMs); - const verifyLink = `${getProtocol(req)}://${req.get('host')}/?verifyToken=${verifyToken}`; + const verifyLink = `${getProtocol(req)}://${req.get('host')}/app.html?verifyToken=${verifyToken}`; await sendMail( user.email, '邮箱验证 - 玩玩云', @@ -959,7 +959,7 @@ app.post('/api/password/forgot', [ const expiresAtMs = Date.now() + 30 * 60 * 1000; PasswordResetTokenDB.create(user.id, token, expiresAtMs); - const resetLink = `${getProtocol(req)}://${req.get('host')}/?resetToken=${token}`; + const resetLink = `${getProtocol(req)}://${req.get('host')}/app.html?resetToken=${token}`; await sendMail( email, '密码重置 - 玩玩云', diff --git a/frontend/index.html b/frontend/index.html index 3893701..fb4d5f0 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -4,6 +4,16 @@ 玩玩云 - 现代化云存储管理平台 +