Skip to content

Commit

Permalink
feat: redirect to the login page
Browse files Browse the repository at this point in the history
  • Loading branch information
cubewhy committed Oct 27, 2024
1 parent dc083b1 commit 99798a6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main/resources/templates/user/register.html
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,7 @@ <h2 class="text-3xl font-extrabold text-center text-gray-800 mb-8">注册</h2>

if (response.ok) {
alert('兑换成功!');
window.location.href = "/user/login"; // redirect to login
} else {
const errorData = await response.json();
errorMessage.textContent = errorData.message || '兑换失败,请重试。';
Expand Down

0 comments on commit 99798a6

Please sign in to comment.