Fix #3539 for Multiple click on login button

Updated the LoginBase, if the URI doesn't contain the login URL then the NavigationManager is updated.
This commit is contained in:
Leigh Pointer 2023-12-12 07:25:35 +01:00
parent 1d230bd4aa
commit 467e5423d2

View File

@ -28,6 +28,9 @@ namespace Oqtane.Themes.Controls
var returnurl = WebUtility.UrlEncode(PageState.Route.PathAndQuery);
// Check if not already actioned Login
if(!NavigationManager.Uri.ToString().Contains("login?returnurl=%2F"))
{
if (allowexternallogin && !allowsitelogin)
{
// external login
@ -40,6 +43,8 @@ namespace Oqtane.Themes.Controls
}
}
}
protected async Task LogoutUser()
{
await LoggingService.Log(PageState.Alias, PageState.Page.PageId, null, PageState.User?.UserId, GetType().AssemblyQualifiedName, "Logout", LogFunction.Security, LogLevel.Information, null, "User Logout For Username {Username}", PageState.User?.Username);