ok logout post scadenza chiave

This commit is contained in:
zaccaria.majid
2023-12-13 16:23:24 +01:00
parent ceac06f5dd
commit db9d67e841
8 changed files with 24 additions and 15 deletions
+5
View File
@@ -0,0 +1,5 @@
{
"recommendations": [
"cweijan.dbclient-jdbc"
]
}
+8 -7
View File
@@ -63,7 +63,7 @@ namespace MP_TAB_SERV.Components
protected async Task RefreshLogIn(string decodValue)
{
bool done = await MsgServ.DoLogIn(decodValue);
bool done = await MsgServ.DoLogIn(decodValue, false);
if (done)
{
if (!string.IsNullOrEmpty(LastOpenedPage) && !string.IsNullOrEmpty(CurrMacc))
@@ -137,23 +137,24 @@ namespace MP_TAB_SERV.Components
// NavMan.NavigateTo("logout");
//}
//else
if (MsgServ.RigaOper == null)
{
await RefreshLogIn(decodedUrl);
}
CurrOprTknRedis = await TDService.OperatoreGetRedis(MatrOpr);
if (CurrOprTknRedis == "")
if (string.IsNullOrEmpty(CurrOprTknRedis))
{
if (!NavMan.Uri.Contains("reg-new-device"))
{
NavMan.NavigateTo("reg-new-device", true);
}
}
else if (CurrOprTknRedis != "")
else if (!string.IsNullOrEmpty(CurrOprTknRedis))
{
if (MsgServ.RigaOper == null)
{
await RefreshLogIn(decodedUrl);
}
//if (!NavMan.Uri.Contains("status-map"))
//{
//}
+1 -1
View File
@@ -3,7 +3,7 @@
<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<Nullable>enable</Nullable>
<Version>6.16.2312.1311</Version>
<Version>6.16.2312.1315</Version>
<ImplicitUsings>enable</ImplicitUsings>
<RootNamespace>MP_TAB_SERV</RootNamespace>
</PropertyGroup>
+1 -1
View File
@@ -1,6 +1,6 @@
<body>
<i>Modulo MAPOSPEC </i>
<h4>Versione: 6.16.2312.1311</h4>
<h4>Versione: 6.16.2312.1315</h4>
<br /> Note di rilascio:
<ul>
<li>
+1 -1
View File
@@ -1 +1 @@
6.16.2312.1311
6.16.2312.1315
+1 -1
View File
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<item>
<version>6.16.2312.1311</version>
<version>6.16.2312.1315</version>
<url>https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/MP-TAB-SERV.zip</url>
<changelog>https://nexus.steamware.net/repository/SWS/MP-TAB-SERV/stable/LAST/ChangeLog.html</changelog>
<mandatory>false</mandatory>
+2 -2
View File
@@ -113,7 +113,7 @@ namespace MP_TAB_SERV.Shared
var userTkn = await TDataService.OperatoreGetRedis(MatrOpr);
if (!string.IsNullOrEmpty(userTkn))
{
await MsgServ.DoLogIn(userTkn);
await MsgServ.DoLogIn(userTkn, true);
MsgServ.dtLastAction = DateTime.Now;
MsgServ.dtLastSave = DateTime.Now;
}
@@ -130,7 +130,7 @@ namespace MP_TAB_SERV.Shared
var userTkn = await TDataService.OperatoreGetRedis(MatrOpr);
if (!string.IsNullOrEmpty(userTkn))
{
await MsgServ.DoLogIn(userTkn);
await MsgServ.DoLogIn(userTkn, true);
MsgServ.dtLastAction = DateTime.Now;
MsgServ.dtLastSave = DateTime.Now;
}
+5 -2
View File
@@ -248,7 +248,7 @@ namespace MP.Data.Services
return SteamCrypto.DecryptString(encData, Constants.passPhrase);
}
public async Task<bool> DoLogIn(string decodValue)
public async Task<bool> DoLogIn(string decodValue, bool saveOpr)
{
bool answ = false;
expDays = SMService.GetConfInt("cookieDayExpire");
@@ -272,7 +272,10 @@ namespace MP.Data.Services
RigaOper = rigaOpr;
await SetLastMatrOprAsync(rigaOpr.MatrOpr);
await SetCurrOperDtoAsync(hash);
await TDService.OperatoreSetRedis(rigaOpr.MatrOpr, hash);
if (saveOpr)
{
await TDService.OperatoreSetRedis(rigaOpr.MatrOpr, hash);
}
answ = true;
}
}