62 lines
1.1 KiB
Plaintext
62 lines
1.1 KiB
Plaintext
@inherits LayoutComponentBase
|
|
@using TIAMWebApp.Shared.Application.Interfaces
|
|
@using TIAMSharedUI.Pages
|
|
@inject IUserDataService UserDataService;
|
|
@inject IJSRuntime jsRuntime
|
|
|
|
<div class="page">
|
|
<div class="my-sidebar">
|
|
<NavMenu />
|
|
</div>
|
|
|
|
<main>
|
|
|
|
<ChooseDestionation>
|
|
</ChooseDestionation>
|
|
|
|
<article class="content">
|
|
@{
|
|
if(isUserLoggedIn)
|
|
{
|
|
<TopRow></TopRow>
|
|
}
|
|
}
|
|
|
|
@Body
|
|
</article>
|
|
</main>
|
|
</div>
|
|
|
|
@code {
|
|
|
|
bool isUserLoggedIn;
|
|
int userType = 0;
|
|
int currentUserRole = 249;
|
|
//add a new dictionary for the role types
|
|
|
|
|
|
|
|
|
|
protected override async Task OnInitializedAsync()
|
|
{
|
|
var user = await UserDataService.IsLoggedInAsync();
|
|
isUserLoggedIn = user.IsLoggedIn;
|
|
|
|
}
|
|
|
|
protected override void OnAfterRender(bool isFirst)
|
|
{
|
|
LogToBrowserConsole("0 ");
|
|
|
|
}
|
|
|
|
|
|
|
|
public void LogToBrowserConsole(string message)
|
|
{
|
|
jsRuntime.InvokeVoidAsync("console.log", message);
|
|
}
|
|
|
|
|
|
}
|