diff --git a/Lieb/Pages/Raids/RaidDetails.razor b/Lieb/Pages/Raids/RaidDetails.razor index 9a8dd75..e5d40c2 100644 --- a/Lieb/Pages/Raids/RaidDetails.razor +++ b/Lieb/Pages/Raids/RaidDetails.razor @@ -46,7 +46,7 @@ bool isSignedUp = userRole != null; DateTime flexTime = _raid.FreeForAllDate.Date + _raid.FreeForAllTime.TimeOfDay; bool isSignUoAllowed = !_raid.IsRandomized && (user.RoleAssignments.FirstOrDefault(a => a.LiebRole.RoleName == _raid.RequiredRole) != null || flexTime < DateTime.Now); - isSignedUp = isSignedUp && user.GuildWars2Accounts.Count > 0 && (_raid.RaidType == RaidType.Planned || user.GuildWars2Accounts.FirstOrDefault()?.EquippedBuilds.Count > 0); + isSignUoAllowed = isSignUoAllowed && user.GuildWars2Accounts.Count > 0 && (_raid.RaidType == RaidType.Planned || user.GuildWars2Accounts.FirstOrDefault()?.EquippedBuilds.Count > 0); diff --git a/Lieb/Pages/User/ManageAccount.razor b/Lieb/Pages/User/ManageAccount.razor index 757d33a..9a87b15 100644 --- a/Lieb/Pages/User/ManageAccount.razor +++ b/Lieb/Pages/User/ManageAccount.razor @@ -22,12 +22,12 @@

-

+ @*

-

+

*@

diff --git a/Lieb/Shared/MainLayout.razor b/Lieb/Shared/MainLayout.razor index efaa7b1..40400e8 100644 --- a/Lieb/Shared/MainLayout.razor +++ b/Lieb/Shared/MainLayout.razor @@ -12,10 +12,9 @@
- About - Hello, @context.User.Identity.Name! + Hello, @context.User.Identity.Name! Log out @@ -27,43 +26,5 @@
@Body
-
-

@_authMessage

- -@if (_claims.Count() > 0) -{ - -} - -

@_surnameMessage

- -@code { - private string _authMessage; - private string _surnameMessage; - private IEnumerable _claims = Enumerable.Empty(); - - private async Task GetClaimsPrincipalData() - { - var authState = await AuthenticationStateProvider.GetAuthenticationStateAsync(); - var user = authState.User; - - if (user.Identity.IsAuthenticated) - { - _authMessage = $"{user.Identity.Name} is authenticated."; - _claims = user.Claims; - _surnameMessage = - $"Surname: {user.FindFirst(c => c.Type == ClaimTypes.Surname)?.Value}"; - } - else - { - _authMessage = "The user is NOT authenticated."; - } - } -} \ No newline at end of file