fix #3065 - redirect user if they are logged in and navigating to Login page
This commit is contained in:
parent
cb7fe364bc
commit
93be61e483
@ -11,9 +11,6 @@
|
||||
<Authorizing>
|
||||
<text>...</text>
|
||||
</Authorizing>
|
||||
<Authorized>
|
||||
<div>@Localizer["Info.SignedIn"]</div>
|
||||
</Authorized>
|
||||
<NotAuthorized>
|
||||
@if (!twofactor)
|
||||
{
|
||||
@ -174,6 +171,12 @@
|
||||
{
|
||||
await username.FocusAsync();
|
||||
}
|
||||
|
||||
// redirect logged in user to specified page
|
||||
if (PageState.User != null)
|
||||
{
|
||||
NavigationManager.NavigateTo(PageState.ReturnUrl);
|
||||
}
|
||||
}
|
||||
|
||||
private async Task Login()
|
||||
|
@ -231,7 +231,7 @@ namespace Oqtane.Infrastructure
|
||||
new Permission(PermissionNames.View, RoleNames.Admin, true),
|
||||
new Permission(PermissionNames.Edit, RoleNames.Admin, true)
|
||||
},
|
||||
Content = "<p>The page you requested does not exist.</p>"
|
||||
Content = "<p>The page you requested does not exist or you do not have sufficient rights to view it.</p>"
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -640,7 +640,7 @@ namespace Oqtane.Repository
|
||||
new Permission(PermissionNames.View, RoleNames.Admin, true),
|
||||
new Permission(PermissionNames.Edit, RoleNames.Admin, true)
|
||||
},
|
||||
Content = "<p>The page you requested does not exist.</p>"
|
||||
Content = "<p>The page you requested does not exist or you do not have sufficient rights to view it.</p>"
|
||||
}
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user