fix(projects): fix login success notification. fixed #688
This commit is contained in:
parent
56760245d4
commit
60dd22624b
@ -102,9 +102,9 @@ export function useRouterPush(inSetup = true) {
|
||||
const redirect = route.value.query?.redirect as string;
|
||||
|
||||
if (needRedirect && redirect) {
|
||||
routerPush(redirect);
|
||||
await routerPush(redirect);
|
||||
} else {
|
||||
toHome();
|
||||
await toHome();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -71,14 +71,12 @@ export const useAuthStore = defineStore(SetupStoreId.Auth, () => {
|
||||
if (pass) {
|
||||
await redirectFromLogin(redirect);
|
||||
|
||||
if (routeStore.isInitAuthRoute) {
|
||||
window.$notification?.success({
|
||||
title: $t('page.login.common.loginSuccess'),
|
||||
content: $t('page.login.common.welcomeBack', { userName: userInfo.userName }),
|
||||
duration: 4500
|
||||
});
|
||||
}
|
||||
}
|
||||
} else {
|
||||
resetStore();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user