36 lines
943 B
C#
36 lines
943 B
C#
using Microsoft.AspNetCore.Components;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using TIAMWebApp.Shared.Application.Interfaces;
|
|
|
|
namespace TIAMSharedUI.Pages.Components
|
|
{
|
|
public partial class AuthComponent : ComponentBase
|
|
{
|
|
[Inject]
|
|
public ISessionService sessionService { get; set; }
|
|
public bool IsLoggedIn = false;
|
|
[Inject]
|
|
public IComponentUpdateService componentUpdateService { get; set; }
|
|
|
|
protected override async Task OnInitializedAsync()
|
|
{
|
|
await base.OnInitializedAsync();
|
|
IsLoggedIn = sessionService.IsAuthenticated;
|
|
componentUpdateService.CallRequestRefresh();
|
|
StateHasChanged();
|
|
}
|
|
|
|
protected override void OnAfterRender(bool firstRender)
|
|
{
|
|
base.OnAfterRender(firstRender);
|
|
|
|
|
|
}
|
|
|
|
}
|
|
}
|