This commit is contained in:
Ccjcarkbla
2026-02-23 15:20:50 -05:00
parent 718ac72c57
commit b1d8173a1f
11 changed files with 234 additions and 28 deletions
+4 -1
View File
@@ -1,5 +1,6 @@
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.RazorPages;
using maintenance.Authentication.Core;
namespace maintenance.Pages;
@@ -12,9 +13,11 @@ public class IndexModel : PageModel
_logger = logger;
}
public bool IsAdmin { get; private set; }
public void OnGet()
{
IsAdmin = User.IsInRole(AuthRoles.Admin);
}
}