diff --git a/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.cs b/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.cs
index 4f23db4..f3e9c2f 100644
--- a/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.cs
+++ b/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.cs
@@ -266,6 +266,23 @@ namespace GPW_Admin.WebUserControls
grView.DataBind();
}
+ protected void lbtRegenUserKey_Click(object sender, EventArgs e)
+ {
+ // rigenera TUTTE le userkey utente
+ var elencoDip = licenzeGPW.getDipAttivi().ToList();
+ // ciclo x ogni utente...
+ foreach (var dipendente in elencoDip)
+ {
+ DateTime adesso = DateTime.Now;
+ string newKey = $"{dipendente.CF}-{adesso:yyMMdd-HHmmss}";
+ string md5UserAuthKey = SteamCrypto.EncryptString(newKey, "AuthGPW");
+ // aggiorno su DB
+ DataProxy.DP.taDipendenti.stp_Dip_setAuthKey(dipendente.idxDipendente, md5UserAuthKey);
+ // chiama resync dati licenza (cod impiego / codAuth)
+ bool fatto = licenzeGPW.tryRefreshActivation(DataProxy.DP.hashCodImpiego(dipendente), md5UserAuthKey).Result;
+ }
+ }
+
///
/// Richiesta selezione utente
///
@@ -350,11 +367,8 @@ namespace GPW_Admin.WebUserControls
grView.EditIndex = -1;
grView.DataBind();
}
-
}
}
-
-
}
}
}
diff --git a/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.designer.cs b/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.designer.cs
index 7dd66a5..666cf79 100644
--- a/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.designer.cs
+++ b/GPW_Admin/WebUserControls/mod_adminDipendenti.ascx.designer.cs
@@ -59,6 +59,15 @@ namespace GPW_Admin.WebUserControls
///
protected global::System.Web.UI.WebControls.LinkButton lbtShowTickets;
+ ///
+ /// lbtRegenUserKey control.
+ ///
+ ///
+ /// Auto-generated field.
+ /// To modify move field declaration from designer file to code-behind file.
+ ///
+ protected global::System.Web.UI.WebControls.LinkButton lbtRegenUserKey;
+
///
/// chkshowAll control.
///
diff --git a/GPW_Admin/WebUserControls/mod_adminFasi.ascx b/GPW_Admin/WebUserControls/mod_adminFasi.ascx
index 3642f13..266fc82 100644
--- a/GPW_Admin/WebUserControls/mod_adminFasi.ascx
+++ b/GPW_Admin/WebUserControls/mod_adminFasi.ascx
@@ -12,14 +12,12 @@
Progetti