Files
Print_server/ConfigurationPannel/Pages/Index.cshtml.cs
2026-01-13 09:06:47 +01:00

25 lines
567 B
C#

using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.RazorPages;
namespace ConfigurationPannel.Pages
{
public class IndexModel : PageModel
{
private readonly ILogger<IndexModel> _logger;
public IndexModel(ILogger<IndexModel> logger)
{
_logger = logger;
}
public IActionResult OnGet()
{
if (User.Identity?.IsAuthenticated == true)
{
return RedirectToPage("/Configure");
}
return RedirectToPage("/Login");
}
}
}