fix barra per cookie
This commit is contained in:
@@ -3,7 +3,10 @@
|
||||
<b>MP-TAB2 @(DateTime.Today.Year)</b> | <span class="small">v.@version</span>
|
||||
</div>
|
||||
<div class="col-4 d-flex flex-column justify-content-center">
|
||||
<ProgBar currVal="@CurrExpVal" maxVal="@MaxExpVal" singleLine="true" baseUM="m" yelLim="@yLimit" redLim="@rLimit"></ProgBar>
|
||||
@if (typeScadLogin > 0)
|
||||
{
|
||||
<ProgBar currVal="@CurrExpVal" maxVal="@MaxExpVal" singleLine="true" baseUM="m" yelLim="@yLimit" redLim="@rLimit"></ProgBar>
|
||||
}
|
||||
</div>
|
||||
<div class="col-4 text-end d-flex align-items-center justify-content-end">
|
||||
<span class="small">@($"{DateTime.Now:HH:mm:ss}")</span> | <a class="text-light text-decoration-none" href="https://www.egalware.com/" target="_blank"><img class="img-fluid" width="16" src="images/LogoEgw.png" /> Egalware </a>
|
||||
|
||||
@@ -29,8 +29,11 @@ namespace MP_TAB_SERV.Components
|
||||
|
||||
var pUpd = Task.Run(async () =>
|
||||
{
|
||||
var diffOfTime = DateTime.Now.Subtract(MsgServ.dtLastAction);
|
||||
CurrExpVal = MaxExpVal - diffOfTime.TotalMinutes;
|
||||
if (typeScadLogin > 0)
|
||||
{
|
||||
var diffOfTime = DateTime.Now.Subtract(MsgServ.dtLastAction);
|
||||
CurrExpVal = MaxExpVal - diffOfTime.TotalMinutes;
|
||||
}
|
||||
await InvokeAsync(() => StateHasChanged());
|
||||
});
|
||||
pUpd.Wait();
|
||||
@@ -64,11 +67,13 @@ namespace MP_TAB_SERV.Components
|
||||
|
||||
#region Protected Methods
|
||||
|
||||
protected int typeScadLogin { get; set; } = 0;
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
await Task.Delay(1);
|
||||
var rawVers = typeof(Program).Assembly.GetName().Version;
|
||||
version = rawVers != null ? rawVers : new Version("0.0.0.0");
|
||||
typeScadLogin = SMServ.GetConfInt("TAB_TypeScadLogin");
|
||||
dtScadLogin = SMServ.GetConfInt("TAB_dtTimerScadLogin");
|
||||
MaxExpVal = dtScadLogin;
|
||||
yLimit = MaxExpVal * 0.3;
|
||||
|
||||
@@ -107,11 +107,6 @@ namespace MP_TAB_SERV.Shared
|
||||
{
|
||||
NavMan.NavigateTo("logout");
|
||||
}
|
||||
else
|
||||
{
|
||||
MsgServ.dtLastAction = DateTime.Now;
|
||||
MsgServ.dtLastSave = DateTime.Now;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
if (tsDeltaAct.Minutes >= dtScadLogin)
|
||||
|
||||
Reference in New Issue
Block a user