Merge pull request #4900 from ruibaby/refactor/signup-event

refactor: redirect to user center by default after registration
pull/4904/head
John Niang 2023-11-23 23:56:33 +08:00 committed by GitHub
commit a56f7e89f5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 1 deletions

View File

@ -21,6 +21,10 @@ function onLoginSucceed() {
window.location.reload();
}
function onSignupSucceed() {
window.location.href = "/uc";
}
const type = useRouteQuery<string>("type", "");
function handleChangeType() {
@ -45,7 +49,7 @@ watch(
<div class="flex h-screen flex-col items-center bg-white/90 pt-[30vh]">
<IconLogo class="mb-8" />
<div class="flex w-72 flex-col">
<SignupForm v-if="type === 'signup'" @succeed="onLoginSucceed" />
<SignupForm v-if="type === 'signup'" @succeed="onSignupSucceed" />
<LoginForm v-else @succeed="onLoginSucceed" />
<SocialAuthProviders />
<div