diff --git a/GMW_Term/App_Readme/README_SteamWare.txt b/GMW_Term/App_Readme/README_SteamWare.txt
new file mode 100644
index 00000000..bf60ed18
--- /dev/null
+++ b/GMW_Term/App_Readme/README_SteamWare.txt
@@ -0,0 +1,12 @@
+---------------------------------------------------------------
+------- SteamWareLib SDK -------
+---------------------------------------------------------------
+
+Libreria di utility base di SteamWare.
+
+Le dipendenze inserite sono necessarie al funzionamento dell'SDK.
+
+Sono inclusi a titolo di esempio vari files di conf:
+ * example-NLog.config
+
+Attenzione a configurare correttamente il file NLog.xml includendo il rule per la classe, vedere ad esempio il file example-NLog.config allegato.
\ No newline at end of file
diff --git a/GMW_Term/App_Readme/SteamWare_demo/example-NLog.config b/GMW_Term/App_Readme/SteamWare_demo/example-NLog.config
new file mode 100644
index 00000000..a11a39e6
--- /dev/null
+++ b/GMW_Term/App_Readme/SteamWare_demo/example-NLog.config
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GMW_Term/App_Readme/SteamWare_demo/example-app.config b/GMW_Term/App_Readme/SteamWare_demo/example-app.config
new file mode 100644
index 00000000..fb421650
--- /dev/null
+++ b/GMW_Term/App_Readme/SteamWare_demo/example-app.config
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/GMW_Term/App_Readme/SteamWare_demo/example-config-table.txt b/GMW_Term/App_Readme/SteamWare_demo/example-config-table.txt
new file mode 100644
index 00000000..dd0ab8ef
--- /dev/null
+++ b/GMW_Term/App_Readme/SteamWare_demo/example-config-table.txt
@@ -0,0 +1,30 @@
+# chiave valore valoreStd note
+_adminEmail samuele@steamware.net,info@steamware.net samuele@steamware.net,info@steamware.net info@steamware.net
+_allowForceUser true true abilita login forzato
+_commonPages menu menu pagina comune
+_emailPwd drmfsls16 drmfsls16 drmfsls16
+_emailUser steamwarebot@gmail.com steamwarebot@gmail.com steamwarebot@gmail.com
+_enableSSL true true true
+_fromEmail webmaster@admodelling.org webmaster@admodelling.org email mittente eventuali msg
+_righeDataGrid 30 30 Num righe datagrid std
+_righeDataGridAnagr 20 20 Num righe datagrid anagrafiche
+_righeDataGridLong 30 30 Num righe datagrid long
+_righeDataGridMed 15 15 Num righe datagrid med
+_righeDataGridShort 10 10 Num righe datagrid short
+_smtpCli smtp.gmail.com smtp.gmail.com smtp.gmail.com
+_useAIMSmtp false false impiego client posta elettronica alternativo
+_useAuthSmtp true true true
+AuthCookieName admodellingAuth admodellingAuth Cookie applicativo
+autoConfCmd true true Conferma automatica comandi barcode
+baseUrl http://site_name http://iis02/site_name URL base del sito
+cacheValSec 60 60 Validità cache dati in gestore Barcode
+cookieDayExp 365 365 Periodo validità cookie
+cookieUsed admodellingAuth admodellingAuth,CTrack_CodOpr,CTrack_CodPost Elenco dei cookie impiegati
+enableCookie true true Abilitazione uso cookie
+enableLogOut true false Abilita button logout COMPLETO in alto a sx
+enablePlain true true Abilitazione decode plain
+maxAuth 1000 1000 num auth minimo per NON consumare tokens
+serializeSession true true Serializzazione valori in sessione (REDIS)
+SiteName iis02/site_name iis02/site_name Nome sito
+enableDumpDiag false false abilitazione dumb diagnostico x eccezioni di default
+doShrinkFolder true true Imposta compressione area LOGS
\ No newline at end of file
diff --git a/GMW_Term/App_Readme/SteamWare_demo/example-favicon.ico b/GMW_Term/App_Readme/SteamWare_demo/example-favicon.ico
new file mode 100644
index 00000000..4f0e0ad0
Binary files /dev/null and b/GMW_Term/App_Readme/SteamWare_demo/example-favicon.ico differ
diff --git a/GMW_Term/Core/Compression/Snappy/lib/win/snappy32.dll b/GMW_Term/Core/Compression/Snappy/lib/win/snappy32.dll
new file mode 100644
index 00000000..afc82ca4
Binary files /dev/null and b/GMW_Term/Core/Compression/Snappy/lib/win/snappy32.dll differ
diff --git a/GMW_Term/Core/Compression/Snappy/lib/win/snappy64.dll b/GMW_Term/Core/Compression/Snappy/lib/win/snappy64.dll
new file mode 100644
index 00000000..36cd5fe7
Binary files /dev/null and b/GMW_Term/Core/Compression/Snappy/lib/win/snappy64.dll differ
diff --git a/GMW_Term/Core/Compression/Zstandard/lib/win/libzstd.dll b/GMW_Term/Core/Compression/Zstandard/lib/win/libzstd.dll
new file mode 100644
index 00000000..e669123c
Binary files /dev/null and b/GMW_Term/Core/Compression/Zstandard/lib/win/libzstd.dll differ
diff --git a/GMW_Term/GMW_Term.csproj b/GMW_Term/GMW_Term.csproj
index 7cffbc0f..679c2f87 100644
--- a/GMW_Term/GMW_Term.csproj
+++ b/GMW_Term/GMW_Term.csproj
@@ -150,6 +150,8 @@
+
+
true
@@ -179,31 +181,133 @@
false
-
- ..\packages\AjaxControlToolkit.18.1.0\lib\net40\AjaxControlToolkit.dll
+
+ ..\packages\AIM.1.0.3\lib\AegisImplicitMail.dll
+
+
+ ..\packages\AjaxControlToolkit.20.1.0\lib\net40\AjaxControlToolkit.dll
+
+
+ ..\packages\Crc32C.NET.1.0.5.0\lib\net20\Crc32C.NET.dll
+
+
+ ..\packages\DnsClient.1.3.2\lib\net45\DnsClient.dll
..\packages\elmah.corelibrary.1.2.2\lib\Elmah.dll
True
+
+ ..\packages\SharpZipLib.1.2.0\lib\net45\ICSharpCode.SharpZipLib.dll
+
..\packages\Microsoft.AspNet.FriendlyUrls.Core.1.0.2\lib\net45\Microsoft.AspNet.FriendlyUrls.dll
True
+
+ ..\packages\Microsoft.Bcl.AsyncInterfaces.1.1.1\lib\net461\Microsoft.Bcl.AsyncInterfaces.dll
+
..\packages\Microsoft.Web.RedisSessionStateProvider.2.2.5\lib\net40\Microsoft.Web.RedisSessionStateProvider.dll
-
- ..\packages\StackExchange.Redis.1.2.6\lib\net46\StackExchange.Redis.dll
+
+ ..\packages\MongoDB.Bson.2.11.2\lib\net452\MongoDB.Bson.dll
+
+
+ ..\packages\MongoDB.Driver.2.11.2\lib\net452\MongoDB.Driver.dll
+
+
+ ..\packages\MongoDB.Driver.Core.2.11.2\lib\net452\MongoDB.Driver.Core.dll
+
+
+ ..\packages\MongoDB.Libmongocrypt.1.0.0\lib\net452\MongoDB.Libmongocrypt.dll
+
+
+ ..\packages\Newtonsoft.Json.12.0.3\lib\net45\Newtonsoft.Json.dll
+
+
+ ..\packages\NLog.4.7.4\lib\net45\NLog.dll
+
+
+ ..\packages\PDFsharp.1.50.5147\lib\net20\PdfSharp.dll
+
+
+ ..\packages\PDFsharp.1.50.5147\lib\net20\PdfSharp.Charting.dll
+
+
+ ..\packages\Pipelines.Sockets.Unofficial.2.1.16\lib\net461\Pipelines.Sockets.Unofficial.dll
+
+
+ ..\packages\SharpCompress.0.26.0\lib\net46\SharpCompress.dll
+
+
+ ..\packages\Snappy.NET.1.1.1.8\lib\net45\Snappy.NET.dll
+
+
+ ..\packages\StackExchange.Redis.2.1.58\lib\net461\StackExchange.Redis.dll
..\packages\StackExchange.Redis.StrongName.1.2.6\lib\net46\StackExchange.Redis.StrongName.dll
+
+ ..\packages\SteamWare.4.9.2010.742\lib\net462\SteamWare.dll
+
+
+ ..\packages\SteamWare.Logger.4.9.2010.742\lib\net462\SteamWare.Logger.dll
+
+
+ ..\packages\System.Buffers.4.5.1\lib\net461\System.Buffers.dll
+
-
+
+ ..\packages\System.Diagnostics.PerformanceCounter.4.7.0\lib\net461\System.Diagnostics.PerformanceCounter.dll
+
+
+ ..\packages\System.IO.Compression.4.3.0\lib\net46\System.IO.Compression.dll
+
+
+ ..\packages\System.IO.Pipelines.4.7.2\lib\net461\System.IO.Pipelines.dll
+
+
+ ..\packages\System.Memory.4.5.4\lib\net461\System.Memory.dll
+
+
+ ..\packages\System.Net.Http.4.3.4\lib\net46\System.Net.Http.dll
+
+
+
+ ..\packages\System.Numerics.Vectors.4.5.0\lib\net46\System.Numerics.Vectors.dll
+
+
+ ..\packages\System.Runtime.CompilerServices.Unsafe.4.7.1\lib\net461\System.Runtime.CompilerServices.Unsafe.dll
+
+
+ ..\packages\System.Runtime.InteropServices.RuntimeInformation.4.3.0\lib\net45\System.Runtime.InteropServices.RuntimeInformation.dll
+
+
+
+ ..\packages\System.Security.Cryptography.Algorithms.4.3.1\lib\net461\System.Security.Cryptography.Algorithms.dll
+
+
+ ..\packages\System.Security.Cryptography.Encoding.4.3.0\lib\net46\System.Security.Cryptography.Encoding.dll
+
+
+ ..\packages\System.Security.Cryptography.Primitives.4.3.0\lib\net46\System.Security.Cryptography.Primitives.dll
+
+
+ ..\packages\System.Security.Cryptography.X509Certificates.4.3.2\lib\net461\System.Security.Cryptography.X509Certificates.dll
+
+
+
+ ..\packages\System.Threading.Channels.4.7.1\lib\net461\System.Threading.Channels.dll
+
+
+ ..\packages\System.Threading.Tasks.Extensions.4.5.4\lib\net461\System.Threading.Tasks.Extensions.dll
+
+
@@ -219,6 +323,12 @@
+
+
+
+
+
+
@@ -619,10 +729,6 @@
-
- {2872dcfe-8b46-43b2-baa0-842a816a2dd5}
- SteamWare
-
{47143721-A018-4BDA-B544-EC3E10BC87A2}
GMW_data
@@ -693,6 +799,9 @@
+
+
+
@@ -779,4 +888,15 @@
+
+
+
+ This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GMW_Term/NLog.config b/GMW_Term/NLog.config
new file mode 100644
index 00000000..a11a39e6
--- /dev/null
+++ b/GMW_Term/NLog.config
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GMW_Term/Web.config b/GMW_Term/Web.config
index 2b4be7b6..74c6013a 100644
--- a/GMW_Term/Web.config
+++ b/GMW_Term/Web.config
@@ -48,8 +48,8 @@
-
-
+
+
@@ -191,6 +191,42 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GMW_Term/WebUserControls/mod_barcode.ascx.cs b/GMW_Term/WebUserControls/mod_barcode.ascx.cs
index 95b80899..7b56fde0 100644
--- a/GMW_Term/WebUserControls/mod_barcode.ascx.cs
+++ b/GMW_Term/WebUserControls/mod_barcode.ascx.cs
@@ -9,628 +9,635 @@ using SteamWare;
namespace GMW_Term.WebUserControls
{
- public partial class mod_barcode : System.Web.UI.UserControl
- {
- // variabile per verificare se è operatore
- bool _validUserInSession = false;
- string _homeBtnText = "Home";
- string _homeBtnLink = "~/Home.aspx";
+ public partial class mod_barcode : System.Web.UI.UserControl
+ {
+ // variabile per verificare se è operatore
+ bool _validUserInSession = false;
+ string _homeBtnText = "Home";
+ string _homeBtnLink = "~/Home.aspx";
- ///
- /// wrapper traduzione termini
- ///
- ///
- ///
- public string traduci(string lemma)
- {
- return user_std.UtSn.Traduci(lemma);
- }
-
- #region area eventi
-
- public event EventHandler eh_scannedUser;
- public event EventHandler eh_resetUser;
- public event EventHandler eh_scannedUdc;
- public event EventHandler eh_scannedAL;
- public event EventHandler eh_scannedListaPrelievo;
- public event EventHandler eh_scannedParticolare;
- public event EventHandler eh_scannedCella;
-
- #endregion
-
- ///
- /// testo del pulsante HOME
- ///
- public string homeBtnText
- {
- set
- {
- _homeBtnText = value;
- traduciObj();
- }
- get
- {
- return _homeBtnText;
- }
- }
- ///
- /// link del pulsante HOME
- ///
- public string homeBtnLink
- {
- set
- {
- _homeBtnLink = value;
- traduciObj();
- }
- get
- {
- return _homeBtnLink;
- }
- }
- ///
- /// traduce stringhe oggetti
- ///
- protected void traduciObj()
- {
- // scrive label e text bottoni
- btnLoginPage.Text = string.Format("{0}\n[Alt+{1}]", traduci("Login"), 7);
- btnLoginPage.AccessKey = "7";
- btnButtonsHome.Text = string.Format("{0}\n[Alt+{1}]", traduci(_homeBtnText), 9);
- btnButtonsHome.AccessKey = "9";
- }
- ///
- /// setta focus su barcode
- ///
- public void setFocusBarcode()
- {
- txtInput.Focus();
- }
-
- ///
- /// metodi al caricamento della pagina
- ///
- ///
- ///
- protected void Page_Load(object sender, EventArgs e)
- {
- traduciObj();
-
- // se username è valorizzato...
- verificaOperatoreInSessione();
- if (_validUserInSession)
- {
- btnLoginPage.Text = string.Format("{0}\n[Alt+{1}]", traduci("Logout"), 7);
- btnLoginPage.Visible = memLayer.ML.confReadBool("showLogout");
- btnButtonsHome.Visible = true;
- // se ho un precedente valore barcode lo mostro...
- if (memLayer.ML.isInSessionObject("Barcode_sel"))
+ ///
+ /// wrapper traduzione termini
+ ///
+ ///
+ ///
+ public string traduci(string lemma)
{
- lblData.Text = memLayer.ML.StringSessionObj("Barcode_sel");
- }
- else
- {
- lblData.Text = traduci("Insert Data") + "...";
- }
- lblRev.Visible = false;
- }
- // se non è valorizzato chiede di effettuare login...
- else
- {
- if (memLayer.ML.confReadBool("SimpleLogin"))
- {
- // in questo caso fa login di default con l'operatore indicato...
- string codOperatore = memLayer.ML.confReadString("CodOperDefault");
- effettuaLoginOperatore(codOperatore);
- }
- else
- {
- // sistema visualizzazione
- btnLoginPage.Visible = false;
- btnButtonsHome.Visible = false;
- lblData.Text = traduci("Please Login");
- lblRev.Text = string.Format("{0} v.{1}", memLayer.ML.confReadString("appName"), System.Reflection.Assembly.GetExecutingAssembly().GetName().Version);
- //lblRev.Text = string.Format("{0} v.{1}.{2}", memLayer.ML.confReadString("appName"), memLayer.ML.confReadString("mainRev"), memLayer.ML.confReadString("minRev"));
- }
- }
- txtInput.Focus();
- }
- ///
- /// inserito testo nella TextBox
- ///
- ///
- ///
- protected void txtInput_TextChanged(object sender, EventArgs e)
- {
- // generico try/catch
- try
- {
- // salvo in sessione la scansione attuale...
- valoreScan = txtScansione;
- // verifica l'input immesso
- tipoCodiceBarcode answ = TermClass.Ter.riconosciBarcode(txtScansione);
- verificaOperatoreInSessione();
- if (!_validUserInSession) //controllo: se non c'è operatore in sessione
- {
- if (answ == tipoCodiceBarcode.Operatore)
- {
- effettuaLoginOperatore(txtScansione);
- }
- else
- {
- if (memLayer.ML.confReadBool("enableCookie"))
- {
- // provo a rifare login da operatore in cookie...
- try
- {
- effettuaLoginOperatore(memLayer.ML.getCookieVal("CodSoggetto"));
- logger.lg.scriviLog(string.Format("Rifatto login da cookie x operatore: {0}", memLayer.ML.getCookieVal("CodSoggetto")), tipoLog.STARTUP);
- }
- catch
- {
- logger.lg.scriviLog("Non sono riuscito a rifare login da cookie 'CodSoggetto' x operatore", tipoLog.EXCEPTION);
- }
- lblData.Text = traduci("Invalid Code");
- txtScansione = "";
- }
- }
- }
- else
- {
- switch (answ)
- {
- case tipoCodiceBarcode.ND:
- lblData.Text = traduci("Code Mismatch") + ": " + txtScansione;
- txtInput.Text = "";
- break;
- case tipoCodiceBarcode.Operatore:
- effettuaLoginOperatore(txtScansione);
- break;
- case tipoCodiceBarcode.ListaPrelievo:
- chekListaPrelievo();
- break;
- case tipoCodiceBarcode.UDC:
- verificaUdc();
- break;
- case tipoCodiceBarcode.AL:
- verificaAL();
- break;
- case tipoCodiceBarcode.Particolare:
- verificaParticolare();
- break;
- case tipoCodiceBarcode.Cella:
- verificaCella();
- break;
- default:
- lblData.Text = traduci("CodeNotRecognized") + ": " + txtScansione;
- txtInput.Text = "";
- break;
- }
- }
- lblData.Font.Italic = false;
- }
- catch (Exception exc)
- {
- logger.lg.scriviLog(string.Format("Errore in decodifica testo da input barcode: {0}", exc), tipoLog.EXCEPTION);
- if (memLayer.ML.confReadBool("forceResetToHome"))
- {
- Response.Redirect("Home.aspx");
- }
- }
- }
- ///
- /// verifica la lista di prelievo (se attivabile la attiva)
- ///
- private void chekListaPrelievo()
- {
- // verifica preliminare: se sia una chiamata di tipo "chiudi lista" e la lista sia quella dell'utente...
- bool isCloseCmd = false;
- try
- {
- isCloseCmd = txtScansione.EndsWith(memLayer.ML.confReadString("closeCodeLdp"));
- }
- catch
- { }
- if (isCloseCmd)
- {
- string codLista = txtScansione.Replace(memLayer.ML.confReadString("closeCodeLdp"), "");
- // controllo se sia la lista di prelievo assegnata all'utente
- bool isUserList = (codLista == MagClass.magazzino.codListaAttivaUtente);
- if (isUserList)
- {
- // chiudo!
- esitoOperazione esitoCompleta = GMW_data.MagClass.magazzino.completaListaPrelievo(memLayer.ML.StringSessionObj("CodCS"), codLista, MagClass.magazzino.CodSoggCurrUser, Request.UserHostName);
- if (esitoCompleta == esitoOperazione.ok)
- {
- // indico che la lista indicata è stata chiusa
- lblData.Text = string.Format("{0}: {1}", traduci("ListClosed"), codLista);
- }
- else if (esitoCompleta == esitoOperazione.errore_noUdc)
- {
- GMW_data.MagClass.magazzino.attivaListaPrelievo(memLayer.ML.StringSessionObj("CodCS"), codLista, MagClass.magazzino.CodSoggCurrUser);
- httpLog(string.Format("Lista di prelievo {0} rilasciata poiché senza UDC prelevati da parte dell'opertore {1}", codLista, MagClass.magazzino.CodSoggCurrUser), tipoLog.INFO);
- // tolgo dalla session la lista prelievo attuale...
- memLayer.ML.emptySessionVal("CodLista_sel");
- memLayer.ML.emptySessionVal("CodListaAttiva");
- memLayer.ML.emptySessionVal("activeTask");
- // indico che la lista indicata è stata rimessa in stato "attiva"
- lblData.Text = string.Format("{0}: {1}", traduci("ListReActivated"), codLista);
- }
- // svuoto cache!
- //memLayer.ML.emptySessionVal("UDC_sel");
- GMW_data.TermClass.Ter.resetScanBarcode(true, false, false);
- }
- else
- {
- // indico che il codice di chiusura NON è valido xché non ha in carico la lista indicata
- lblData.Text = string.Format("!!! {0}: {1}", traduci("ListNotCloseable"), codLista);
- }
- }
- else
- {
- // verifico se al lista di prelievo sia valida ed attivabile
- if (MagClass.magazzino.listaPrelevabile(txtScansione))
- {
- // verifico se l'utente ha delle lsite di prelievo attive e quindi NON PUO prenderne in carico altre
- if (!MagClass.magazzino.userHasActiveLP)
- {
- // indico la lista come attiva
- GMW_data.MagClass.magazzino.iniziaListaPrelievo(memLayer.ML.StringSessionObj("CodCS"), txtScansione, MagClass.magazzino.CodSoggCurrUser);
- // salvo in sessione che voglio mostrare il dettaglio della lista appena presa in carico
- memLayer.ML.setSessionVal("showDetListaPre", true, false);
-
- if (eh_scannedListaPrelievo != null)
- {
- eh_scannedListaPrelievo(this, new EventArgs());
- }
- }
- else
- {
- // indico l'errore: operatore già con una lista attiva
- lblData.Text = string.Format("!!! {0}: {1}", traduci("ListStillOpen"), MagClass.magazzino.codListaAttivaUtente);
- }
- }
- else
- {
- // se la lista è quella in carico rimando a quella
- if (txtScansione == MagClass.magazzino.codListaAttivaUtente)
- {
- // salvo in sessione che voglio mostrare il dettaglio della lista appena presa in carico
- memLayer.ML.setSessionVal("showDetListaPre", true, false);
-
- if (eh_scannedListaPrelievo != null)
- {
- eh_scannedListaPrelievo(this, new EventArgs());
- }
- }
- else
- {
- // indico l'errore: lista non valida o non attivabile
- lblData.Text = string.Format("!!! {0}: {1}", traduci("NotDownloadable"), txtScansione);
- }
- }
- }
- txtInput.Text = "";
- }
- ///
- /// verifica validità UDC
- ///
- private void verificaUdc()
- {
- // controllo l'UDC se sia valido (==esistente)
- bool barcodeOk = MagClass.magazzino.checkUDC(valoreScan);
- if (barcodeOk)
- {
- // salvo in session UDC selezionato
- memLayer.ML.setSessionVal("UDC_sel", valoreScan, false);
- // svuoto AL...
- memLayer.ML.emptySessionVal("AL_sel");
- if (eh_scannedUdc != null)
- {
- eh_scannedUdc(this, new EventArgs());
- }
- }
- else
- {
- lblData.Text = string.Format(traduci("UDCCodeInvalid") + ": " + "{0}", valoreScan);
- txtScansione = "";
- }
- }
- ///
- /// verifica validità AL
- ///
- private void verificaAL()
- {
- // controllo AL se sia valido (==esistente)
- bool barcodeOk = MagClass.magazzino.checkAL(valoreScan);
- if (barcodeOk)
- {
- // salvo in session AL selezionato
- memLayer.ML.setSessionVal("AL_sel", valoreScan, false);
- // svuoto UDC...
- memLayer.ML.emptySessionVal("UDC_sel");
- if (eh_scannedAL != null)
- {
- eh_scannedAL(this, new EventArgs());
- }
- }
- else
- {
- lblData.Text = string.Format(traduci("ALCodeInvalid") + ": " + "{0}", valoreScan);
- txtScansione = "";
- }
- }
- ///
- /// verifica validità cella
- ///
- private void verificaCella()
- {
- // controllo cod cella se sia valido (==esistente)
- bool barcodeOk = MagClass.magazzino.checkCella(valoreScan);
- if (barcodeOk)
- {
- // calcolo idxCella
- int idxCella = MagClass.magazzino.IdxCellaByCodCella(memLayer.ML.StringSessionObj("CodCS"), valoreScan);
- // salvo in session idxCella selezionata
- memLayer.ML.setSessionVal("IdxCella_sel", idxCella);
- memLayer.ML.setSessionVal("codCella_sel", valoreScan);
- memLayer.ML.setSessionVal("activeTask", string.Format("Cella: {0}", valoreScan));
- if (eh_scannedCella != null)
- {
- eh_scannedCella(this, new EventArgs());
- }
- }
- else
- {
- lblData.Text = string.Format(traduci("CellaCodeInvalid") + ": " + "{0}", valoreScan);
- txtScansione = "";
- }
- }
- ///
- /// verifica validità particolare
- ///
- private void verificaParticolare()
- {
- // controllo se sia valido il particolare (==esistente)
- bool barcodeOk = MagClass.magazzino.checkParticolare(memLayer.ML.StringSessionObj("CodCS"), valoreScan);
- if (barcodeOk)
- {
- // salvo in session particolare selezionato
- memLayer.ML.setSessionVal("Particolare_sel", txtScansione);
- memLayer.ML.setSessionVal("activeTask", string.Format("Particolare: {0}", valoreScan));
- if (eh_scannedParticolare != null)
- {
- eh_scannedParticolare(this, new EventArgs());
- }
- }
- else
- {
- lblData.Text = string.Format(traduci("PartCodeInvalid") + ": " + "{0}", valoreScan);
- txtScansione = "";
- }
- }
-
- ///
- /// effettua le chiamate per la login
- ///
- ///
- private void effettuaLoginOperatore(string dataIn)
- {
- // solo se ho un codice !=""
- if (dataIn != "")
- {
- // salvo in sessione valore barcode
- memLayer.ML.setSessionVal("CodSoggetto", dataIn);
- if (memLayer.ML.confReadBool("enableCookie"))
- {
- // salvo anche in cookie...
- memLayer.ML.setCookieVal("CodSoggetto", dataIn);
- }
- // verifico che il cod operatore passato sia valido per Rilpro.Anagoperatori e Soggetti2Utente
- httpLog(string.Format("Richiesta di login tramite barcode da {0}, IP {1}", Request.UserHostName, Request.UserHostAddress), tipoLog.STARTUP);
- esitoLoginTerm esito = TermClass.Ter.doUserLogin(dataIn);
- if (esito == esitoLoginTerm.ok)
- {
- // svuoto dati lista attiva e smartlist...
- memLayer.ML.emptySessionVal("CodListaAttiva");
- memLayer.ML.emptySessionVal("activeTask");
- // salvo i dati di CodCS
- memLayer.ML.setSessionVal("CodCS", memLayer.ML.confReadString("CodCS"), true);
- // in caso operatore abbia liste attive le carico...
- if (MagClass.magazzino.userHasActiveLP)
- {
- string codiceListaAttivo = "";
+ string answ = $"[{lemma}]";
try
{
- codiceListaAttivo = MagClass.magazzino.codListaAttivaUtente;
- // salvo la lista di prelievo come attiva
- memLayer.ML.setSessionVal("activeTask", string.Format("Lista Prelievo {0}", codiceListaAttivo));
- memLayer.ML.setSessionVal("CodListaAttiva", codiceListaAttivo);
+ answ = user_std.UtSn.Traduci(lemma);
}
catch
- {
- // c'era una lista attiva, non l'ho recuperata, segno errore!
- httpLog(string.Format(traduci("ErrorListDataRetrieval"), user_std.UtSn.utente), tipoLog.ERROR);
- }
- }
- else
- {
- memLayer.ML.setSessionVal("activeTask", "Selezionato Operatore");
- }
- txtInput.Text = "";
- // alza evento login!
- if (eh_scannedUser != null)
- {
- eh_scannedUser(this, new EventArgs());
- }
+ { }
+ return answ;
}
- else
+
+ #region area eventi
+
+ public event EventHandler eh_scannedUser;
+ public event EventHandler eh_resetUser;
+ public event EventHandler eh_scannedUdc;
+ public event EventHandler eh_scannedAL;
+ public event EventHandler eh_scannedListaPrelievo;
+ public event EventHandler eh_scannedParticolare;
+ public event EventHandler eh_scannedCella;
+
+ #endregion
+
+ ///
+ /// testo del pulsante HOME
+ ///
+ public string homeBtnText
{
- // avvisa che il codice è errato
- lblData.Text = string.Format("{0} {1} {2}", traduci("Single User"), txtInput.Text, traduci("NotInDb"));
- txtInput.Text = "";
+ set
+ {
+ _homeBtnText = value;
+ traduciObj();
+ }
+ get
+ {
+ return _homeBtnText;
+ }
+ }
+ ///
+ /// link del pulsante HOME
+ ///
+ public string homeBtnLink
+ {
+ set
+ {
+ _homeBtnLink = value;
+ traduciObj();
+ }
+ get
+ {
+ return _homeBtnLink;
+ }
+ }
+ ///
+ /// traduce stringhe oggetti
+ ///
+ protected void traduciObj()
+ {
+ // scrive label e text bottoni
+ btnLoginPage.Text = string.Format("{0}\n[Alt+{1}]", traduci("Login"), 7);
+ btnLoginPage.AccessKey = "7";
+ btnButtonsHome.Text = string.Format("{0}\n[Alt+{1}]", traduci(_homeBtnText), 9);
+ btnButtonsHome.AccessKey = "9";
+ }
+ ///
+ /// setta focus su barcode
+ ///
+ public void setFocusBarcode()
+ {
+ txtInput.Focus();
+ }
+
+ ///
+ /// metodi al caricamento della pagina
+ ///
+ ///
+ ///
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ traduciObj();
+
+ // se username è valorizzato...
+ verificaOperatoreInSessione();
+ if (_validUserInSession)
+ {
+ btnLoginPage.Text = string.Format("{0}\n[Alt+{1}]", traduci("Logout"), 7);
+ btnLoginPage.Visible = memLayer.ML.confReadBool("showLogout");
+ btnButtonsHome.Visible = true;
+ // se ho un precedente valore barcode lo mostro...
+ if (memLayer.ML.isInSessionObject("Barcode_sel"))
+ {
+ lblData.Text = memLayer.ML.StringSessionObj("Barcode_sel");
+ }
+ else
+ {
+ lblData.Text = traduci("Insert Data") + "...";
+ }
+ lblRev.Visible = false;
+ }
+ // se non è valorizzato chiede di effettuare login...
+ else
+ {
+ if (memLayer.ML.confReadBool("SimpleLogin"))
+ {
+ // in questo caso fa login di default con l'operatore indicato...
+ string codOperatore = memLayer.ML.confReadString("CodOperDefault");
+ effettuaLoginOperatore(codOperatore);
+ }
+ else
+ {
+ // sistema visualizzazione
+ btnLoginPage.Visible = false;
+ btnButtonsHome.Visible = false;
+ lblData.Text = traduci("Please Login");
+ lblRev.Text = string.Format("{0} v.{1}", memLayer.ML.confReadString("appName"), System.Reflection.Assembly.GetExecutingAssembly().GetName().Version);
+ //lblRev.Text = string.Format("{0} v.{1}.{2}", memLayer.ML.confReadString("appName"), memLayer.ML.confReadString("mainRev"), memLayer.ML.confReadString("minRev"));
+ }
+ }
+ txtInput.Focus();
+ }
+ ///
+ /// inserito testo nella TextBox
+ ///
+ ///
+ ///
+ protected void txtInput_TextChanged(object sender, EventArgs e)
+ {
+ // generico try/catch
+ try
+ {
+ // salvo in sessione la scansione attuale...
+ valoreScan = txtScansione;
+ // verifica l'input immesso
+ tipoCodiceBarcode answ = TermClass.Ter.riconosciBarcode(txtScansione);
+ verificaOperatoreInSessione();
+ if (!_validUserInSession) //controllo: se non c'è operatore in sessione
+ {
+ if (answ == tipoCodiceBarcode.Operatore)
+ {
+ effettuaLoginOperatore(txtScansione);
+ }
+ else
+ {
+ if (memLayer.ML.confReadBool("enableCookie"))
+ {
+ // provo a rifare login da operatore in cookie...
+ try
+ {
+ effettuaLoginOperatore(memLayer.ML.getCookieVal("CodSoggetto"));
+ logger.lg.scriviLog(string.Format("Rifatto login da cookie x operatore: {0}", memLayer.ML.getCookieVal("CodSoggetto")), tipoLog.STARTUP);
+ }
+ catch
+ {
+ logger.lg.scriviLog("Non sono riuscito a rifare login da cookie 'CodSoggetto' x operatore", tipoLog.EXCEPTION);
+ }
+ lblData.Text = traduci("Invalid Code");
+ txtScansione = "";
+ }
+ }
+ }
+ else
+ {
+ switch (answ)
+ {
+ case tipoCodiceBarcode.ND:
+ lblData.Text = traduci("Code Mismatch") + ": " + txtScansione;
+ txtInput.Text = "";
+ break;
+ case tipoCodiceBarcode.Operatore:
+ effettuaLoginOperatore(txtScansione);
+ break;
+ case tipoCodiceBarcode.ListaPrelievo:
+ chekListaPrelievo();
+ break;
+ case tipoCodiceBarcode.UDC:
+ verificaUdc();
+ break;
+ case tipoCodiceBarcode.AL:
+ verificaAL();
+ break;
+ case tipoCodiceBarcode.Particolare:
+ verificaParticolare();
+ break;
+ case tipoCodiceBarcode.Cella:
+ verificaCella();
+ break;
+ default:
+ lblData.Text = traduci("CodeNotRecognized") + ": " + txtScansione;
+ txtInput.Text = "";
+ break;
+ }
+ }
+ lblData.Font.Italic = false;
+ }
+ catch (Exception exc)
+ {
+ logger.lg.scriviLog(string.Format("Errore in decodifica testo da input barcode: {0}", exc), tipoLog.EXCEPTION);
+ if (memLayer.ML.confReadBool("forceResetToHome"))
+ {
+ Response.Redirect("Home.aspx");
+ }
+ }
+ }
+ ///
+ /// verifica la lista di prelievo (se attivabile la attiva)
+ ///
+ private void chekListaPrelievo()
+ {
+ // verifica preliminare: se sia una chiamata di tipo "chiudi lista" e la lista sia quella dell'utente...
+ bool isCloseCmd = false;
+ try
+ {
+ isCloseCmd = txtScansione.EndsWith(memLayer.ML.confReadString("closeCodeLdp"));
+ }
+ catch
+ { }
+ if (isCloseCmd)
+ {
+ string codLista = txtScansione.Replace(memLayer.ML.confReadString("closeCodeLdp"), "");
+ // controllo se sia la lista di prelievo assegnata all'utente
+ bool isUserList = (codLista == MagClass.magazzino.codListaAttivaUtente);
+ if (isUserList)
+ {
+ // chiudo!
+ esitoOperazione esitoCompleta = GMW_data.MagClass.magazzino.completaListaPrelievo(memLayer.ML.StringSessionObj("CodCS"), codLista, MagClass.magazzino.CodSoggCurrUser, Request.UserHostName);
+ if (esitoCompleta == esitoOperazione.ok)
+ {
+ // indico che la lista indicata è stata chiusa
+ lblData.Text = string.Format("{0}: {1}", traduci("ListClosed"), codLista);
+ }
+ else if (esitoCompleta == esitoOperazione.errore_noUdc)
+ {
+ GMW_data.MagClass.magazzino.attivaListaPrelievo(memLayer.ML.StringSessionObj("CodCS"), codLista, MagClass.magazzino.CodSoggCurrUser);
+ httpLog(string.Format("Lista di prelievo {0} rilasciata poiché senza UDC prelevati da parte dell'opertore {1}", codLista, MagClass.magazzino.CodSoggCurrUser), tipoLog.INFO);
+ // tolgo dalla session la lista prelievo attuale...
+ memLayer.ML.emptySessionVal("CodLista_sel");
+ memLayer.ML.emptySessionVal("CodListaAttiva");
+ memLayer.ML.emptySessionVal("activeTask");
+ // indico che la lista indicata è stata rimessa in stato "attiva"
+ lblData.Text = string.Format("{0}: {1}", traduci("ListReActivated"), codLista);
+ }
+ // svuoto cache!
+ //memLayer.ML.emptySessionVal("UDC_sel");
+ GMW_data.TermClass.Ter.resetScanBarcode(true, false, false);
+ }
+ else
+ {
+ // indico che il codice di chiusura NON è valido xché non ha in carico la lista indicata
+ lblData.Text = string.Format("!!! {0}: {1}", traduci("ListNotCloseable"), codLista);
+ }
+ }
+ else
+ {
+ // verifico se al lista di prelievo sia valida ed attivabile
+ if (MagClass.magazzino.listaPrelevabile(txtScansione))
+ {
+ // verifico se l'utente ha delle lsite di prelievo attive e quindi NON PUO prenderne in carico altre
+ if (!MagClass.magazzino.userHasActiveLP)
+ {
+ // indico la lista come attiva
+ GMW_data.MagClass.magazzino.iniziaListaPrelievo(memLayer.ML.StringSessionObj("CodCS"), txtScansione, MagClass.magazzino.CodSoggCurrUser);
+ // salvo in sessione che voglio mostrare il dettaglio della lista appena presa in carico
+ memLayer.ML.setSessionVal("showDetListaPre", true, false);
+
+ if (eh_scannedListaPrelievo != null)
+ {
+ eh_scannedListaPrelievo(this, new EventArgs());
+ }
+ }
+ else
+ {
+ // indico l'errore: operatore già con una lista attiva
+ lblData.Text = string.Format("!!! {0}: {1}", traduci("ListStillOpen"), MagClass.magazzino.codListaAttivaUtente);
+ }
+ }
+ else
+ {
+ // se la lista è quella in carico rimando a quella
+ if (txtScansione == MagClass.magazzino.codListaAttivaUtente)
+ {
+ // salvo in sessione che voglio mostrare il dettaglio della lista appena presa in carico
+ memLayer.ML.setSessionVal("showDetListaPre", true, false);
+
+ if (eh_scannedListaPrelievo != null)
+ {
+ eh_scannedListaPrelievo(this, new EventArgs());
+ }
+ }
+ else
+ {
+ // indico l'errore: lista non valida o non attivabile
+ lblData.Text = string.Format("!!! {0}: {1}", traduci("NotDownloadable"), txtScansione);
+ }
+ }
+ }
+ txtInput.Text = "";
+ }
+ ///
+ /// verifica validità UDC
+ ///
+ private void verificaUdc()
+ {
+ // controllo l'UDC se sia valido (==esistente)
+ bool barcodeOk = MagClass.magazzino.checkUDC(valoreScan);
+ if (barcodeOk)
+ {
+ // salvo in session UDC selezionato
+ memLayer.ML.setSessionVal("UDC_sel", valoreScan, false);
+ // svuoto AL...
+ memLayer.ML.emptySessionVal("AL_sel");
+ if (eh_scannedUdc != null)
+ {
+ eh_scannedUdc(this, new EventArgs());
+ }
+ }
+ else
+ {
+ lblData.Text = string.Format(traduci("UDCCodeInvalid") + ": " + "{0}", valoreScan);
+ txtScansione = "";
+ }
+ }
+ ///
+ /// verifica validità AL
+ ///
+ private void verificaAL()
+ {
+ // controllo AL se sia valido (==esistente)
+ bool barcodeOk = MagClass.magazzino.checkAL(valoreScan);
+ if (barcodeOk)
+ {
+ // salvo in session AL selezionato
+ memLayer.ML.setSessionVal("AL_sel", valoreScan, false);
+ // svuoto UDC...
+ memLayer.ML.emptySessionVal("UDC_sel");
+ if (eh_scannedAL != null)
+ {
+ eh_scannedAL(this, new EventArgs());
+ }
+ }
+ else
+ {
+ lblData.Text = string.Format(traduci("ALCodeInvalid") + ": " + "{0}", valoreScan);
+ txtScansione = "";
+ }
+ }
+ ///
+ /// verifica validità cella
+ ///
+ private void verificaCella()
+ {
+ // controllo cod cella se sia valido (==esistente)
+ bool barcodeOk = MagClass.magazzino.checkCella(valoreScan);
+ if (barcodeOk)
+ {
+ // calcolo idxCella
+ int idxCella = MagClass.magazzino.IdxCellaByCodCella(memLayer.ML.StringSessionObj("CodCS"), valoreScan);
+ // salvo in session idxCella selezionata
+ memLayer.ML.setSessionVal("IdxCella_sel", idxCella);
+ memLayer.ML.setSessionVal("codCella_sel", valoreScan);
+ memLayer.ML.setSessionVal("activeTask", string.Format("Cella: {0}", valoreScan));
+ if (eh_scannedCella != null)
+ {
+ eh_scannedCella(this, new EventArgs());
+ }
+ }
+ else
+ {
+ lblData.Text = string.Format(traduci("CellaCodeInvalid") + ": " + "{0}", valoreScan);
+ txtScansione = "";
+ }
+ }
+ ///
+ /// verifica validità particolare
+ ///
+ private void verificaParticolare()
+ {
+ // controllo se sia valido il particolare (==esistente)
+ bool barcodeOk = MagClass.magazzino.checkParticolare(memLayer.ML.StringSessionObj("CodCS"), valoreScan);
+ if (barcodeOk)
+ {
+ // salvo in session particolare selezionato
+ memLayer.ML.setSessionVal("Particolare_sel", txtScansione);
+ memLayer.ML.setSessionVal("activeTask", string.Format("Particolare: {0}", valoreScan));
+ if (eh_scannedParticolare != null)
+ {
+ eh_scannedParticolare(this, new EventArgs());
+ }
+ }
+ else
+ {
+ lblData.Text = string.Format(traduci("PartCodeInvalid") + ": " + "{0}", valoreScan);
+ txtScansione = "";
+ }
+ }
+
+ ///
+ /// effettua le chiamate per la login
+ ///
+ ///
+ private void effettuaLoginOperatore(string dataIn)
+ {
+ // solo se ho un codice !=""
+ if (dataIn != "")
+ {
+ // salvo in sessione valore barcode
+ memLayer.ML.setSessionVal("CodSoggetto", dataIn);
+ if (memLayer.ML.confReadBool("enableCookie"))
+ {
+ // salvo anche in cookie...
+ memLayer.ML.setCookieVal("CodSoggetto", dataIn);
+ }
+ // verifico che il cod operatore passato sia valido per Rilpro.Anagoperatori e Soggetti2Utente
+ httpLog(string.Format("Richiesta di login tramite barcode da {0}, IP {1}", Request.UserHostName, Request.UserHostAddress), tipoLog.STARTUP);
+ esitoLoginTerm esito = TermClass.Ter.doUserLogin(dataIn);
+ if (esito == esitoLoginTerm.ok)
+ {
+ // svuoto dati lista attiva e smartlist...
+ memLayer.ML.emptySessionVal("CodListaAttiva");
+ memLayer.ML.emptySessionVal("activeTask");
+ // salvo i dati di CodCS
+ memLayer.ML.setSessionVal("CodCS", memLayer.ML.confReadString("CodCS"), true);
+ // in caso operatore abbia liste attive le carico...
+ if (MagClass.magazzino.userHasActiveLP)
+ {
+ string codiceListaAttivo = "";
+ try
+ {
+ codiceListaAttivo = MagClass.magazzino.codListaAttivaUtente;
+ // salvo la lista di prelievo come attiva
+ memLayer.ML.setSessionVal("activeTask", string.Format("Lista Prelievo {0}", codiceListaAttivo));
+ memLayer.ML.setSessionVal("CodListaAttiva", codiceListaAttivo);
+ }
+ catch
+ {
+ // c'era una lista attiva, non l'ho recuperata, segno errore!
+ httpLog(string.Format(traduci("ErrorListDataRetrieval"), user_std.UtSn.utente), tipoLog.ERROR);
+ }
+ }
+ else
+ {
+ memLayer.ML.setSessionVal("activeTask", "Selezionato Operatore");
+ }
+ txtInput.Text = "";
+ // alza evento login!
+ if (eh_scannedUser != null)
+ {
+ eh_scannedUser(this, new EventArgs());
+ }
+ }
+ else
+ {
+ // avvisa che il codice è errato
+ lblData.Text = string.Format("{0} {1} {2}", traduci("Single User"), txtInput.Text, traduci("NotInDb"));
+ txtInput.Text = "";
+ }
+ }
+ }
+ ///
+ /// wrapper per log con salvataggio dell'IP del chiamante
+ ///
+ ///
+ ///
+ public bool httpLog(string _testoPre)
+ {
+ bool answ = false;
+ string postazione_IP = "";
+ try
+ {
+ postazione_IP = string.Format(" | {0} | ", Request.UserHostName);
+ }
+ catch
+ { }
+ logger.lg.scriviLog(postazione_IP + _testoPre);
+ return answ;
+ }
+ ///
+ /// wrapper per log con salvataggio dell'IP del chiamante
+ ///
+ ///
+ ///
+ public bool httpLog(string testoLog, tipoLog tipo)
+ {
+ bool answ = false;
+ string postazione_IP = "";
+ try
+ {
+ postazione_IP = string.Format(" | {0} | ", Request.UserHostName);
+ }
+ catch
+ { }
+ logger.lg.scriviLog(postazione_IP + testoLog, tipo);
+ return answ;
+ }
+ ///
+ /// effettua logout...
+ ///
+ ///
+ ///
+ protected void btnLoginPage_Click(object sender, EventArgs e)
+ {
+ TermUtils.TU.forceLogOut();
+ verificaOperatoreInSessione();
+ // evento reset
+ if (eh_resetUser != null)
+ {
+ eh_resetUser(this, new EventArgs());
+ }
+ }
+ ///
+ /// va alla pagina dei buttons principale
+ ///
+ ///
+ ///
+ protected void btnButtonsHome_Click(object sender, EventArgs e)
+ {
+ Response.Redirect(homeBtnLink);
+ }
+ ///
+ /// Verifica se c'è un valore in sessione di tipo operatore
+ ///
+ protected void verificaOperatoreInSessione()
+ {
+ if (string.IsNullOrEmpty(user_std.UtSn.utente))
+ {
+ _validUserInSession = false;
+ httpLog(string.Format("Errore: perso user da sessione: IP {0}, user-barcode '{1}'", Request.UserHostAddress, memLayer.ML.StringSessionObj("CodSoggetto")), tipoLog.ERROR);
+ }
+ else
+ {
+ _validUserInSession = true;
+ }
+ }
+ ///
+ /// testo contenuto nella textbox
+ ///
+ public string txtScansione
+ {
+ get
+ {
+ return txtInput.Text.Trim().ToUpper();
+ }
+ set
+ {
+ txtInput.Text = value;
+ }
+ }
+ ///
+ /// valore della scansione barcode
+ ///
+ public string valoreScan
+ {
+ get
+ {
+ return memLayer.ML.StringSessionObj("scannedValue");
+ }
+ set
+ {
+ memLayer.ML.setSessionVal("scannedValue", value, false);
+ }
+ }
+ ///
+ /// definisce se mostrare l'header text (Barcode input)
+ ///
+ public bool showHeaderText
+ {
+ get
+ {
+ return lblInput.Visible;
+ }
+ set
+ {
+ lblInput.Visible = value;
+ }
+ }
+ ///
+ /// definisce se mostrare testo di commento sotto barcode
+ ///
+ public bool showNoteText
+ {
+ get
+ {
+ return lblData.Visible;
+ }
+ set
+ {
+ lblData.Visible = value;
+ }
+ }
+ ///
+ /// numero minimo di caratteri x char autocomplete
+ ///
+ public int minCharAutocomplete
+ {
+ get
+ {
+ return aceParticolare.MinimumPrefixLength;
+ }
+ set
+ {
+ aceParticolare.MinimumPrefixLength = value;
+ }
+ }
+ ///
+ /// metodo di autocomplete extender da impiegare
+ ///
+ public string aceMethod
+ {
+ get
+ {
+ return aceParticolare.ServiceMethod;
+ }
+ set
+ {
+ aceParticolare.ServiceMethod = value;
+ }
}
- }
}
- ///
- /// wrapper per log con salvataggio dell'IP del chiamante
- ///
- ///
- ///
- public bool httpLog(string _testoPre)
- {
- bool answ = false;
- string postazione_IP = "";
- try
- {
- postazione_IP = string.Format(" | {0} | ", Request.UserHostName);
- }
- catch
- { }
- logger.lg.scriviLog(postazione_IP + _testoPre);
- return answ;
- }
- ///
- /// wrapper per log con salvataggio dell'IP del chiamante
- ///
- ///
- ///
- public bool httpLog(string testoLog, tipoLog tipo)
- {
- bool answ = false;
- string postazione_IP = "";
- try
- {
- postazione_IP = string.Format(" | {0} | ", Request.UserHostName);
- }
- catch
- { }
- logger.lg.scriviLog(postazione_IP + testoLog, tipo);
- return answ;
- }
- ///
- /// effettua logout...
- ///
- ///
- ///
- protected void btnLoginPage_Click(object sender, EventArgs e)
- {
- TermUtils.TU.forceLogOut();
- verificaOperatoreInSessione();
- // evento reset
- if (eh_resetUser != null)
- {
- eh_resetUser(this, new EventArgs());
- }
- }
- ///
- /// va alla pagina dei buttons principale
- ///
- ///
- ///
- protected void btnButtonsHome_Click(object sender, EventArgs e)
- {
- Response.Redirect(homeBtnLink);
- }
- ///
- /// Verifica se c'è un valore in sessione di tipo operatore
- ///
- protected void verificaOperatoreInSessione()
- {
- if (string.IsNullOrEmpty(user_std.UtSn.utente))
- {
- _validUserInSession = false;
- httpLog(string.Format("Errore: perso user da sessione: IP {0}, user-barcode '{1}'", Request.UserHostAddress, memLayer.ML.StringSessionObj("CodSoggetto")), tipoLog.ERROR);
- }
- else
- {
- _validUserInSession = true;
- }
- }
- ///
- /// testo contenuto nella textbox
- ///
- public string txtScansione
- {
- get
- {
- return txtInput.Text.Trim().ToUpper();
- }
- set
- {
- txtInput.Text = value;
- }
- }
- ///
- /// valore della scansione barcode
- ///
- public string valoreScan
- {
- get
- {
- return memLayer.ML.StringSessionObj("scannedValue");
- }
- set
- {
- memLayer.ML.setSessionVal("scannedValue", value, false);
- }
- }
- ///
- /// definisce se mostrare l'header text (Barcode input)
- ///
- public bool showHeaderText
- {
- get
- {
- return lblInput.Visible;
- }
- set
- {
- lblInput.Visible = value;
- }
- }
- ///
- /// definisce se mostrare testo di commento sotto barcode
- ///
- public bool showNoteText
- {
- get
- {
- return lblData.Visible;
- }
- set
- {
- lblData.Visible = value;
- }
- }
- ///
- /// numero minimo di caratteri x char autocomplete
- ///
- public int minCharAutocomplete
- {
- get
- {
- return aceParticolare.MinimumPrefixLength;
- }
- set
- {
- aceParticolare.MinimumPrefixLength = value;
- }
- }
- ///
- /// metodo di autocomplete extender da impiegare
- ///
- public string aceMethod
- {
- get
- {
- return aceParticolare.ServiceMethod;
- }
- set
- {
- aceParticolare.ServiceMethod = value;
- }
- }
- }
}
\ No newline at end of file
diff --git a/GMW_Term/packages.config b/GMW_Term/packages.config
index 47d4cad7..e88755ec 100644
--- a/GMW_Term/packages.config
+++ b/GMW_Term/packages.config
@@ -1,11 +1,45 @@
-
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/GMW_Terminus.sln b/GMW_Terminus.sln
index 35736d59..f4285975 100644
--- a/GMW_Terminus.sln
+++ b/GMW_Terminus.sln
@@ -1,7 +1,7 @@
Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 15
-VisualStudioVersion = 15.0.27004.2005
+# Visual Studio Version 16
+VisualStudioVersion = 16.0.32602.291
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GMW_data", "GMW_data\GMW_data.csproj", "{47143721-A018-4BDA-B544-EC3E10BC87A2}"
EndProject
@@ -9,8 +9,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GMW_Term", "GMW_Term\GMW_Te
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VersGen", "VersGen\VersGen.csproj", "{7C587950-A570-489C-9784-27256384E57E}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SteamWare", "..\SteamWare\SteamWareLib\SteamWare.csproj", "{2872DCFE-8B46-43B2-BAA0-842A816A2DD5}"
-EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -85,26 +83,6 @@ Global
{7C587950-A570-489C-9784-27256384E57E}.TK_prod|Any CPU.Build.0 = 218_SP|Any CPU
{7C587950-A570-489C-9784-27256384E57E}.TK_test|Any CPU.ActiveCfg = 218_SP|Any CPU
{7C587950-A570-489C-9784-27256384E57E}.TK_test|Any CPU.Build.0 = 218_SP|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS01_SP|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS01_SP|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS01_TK|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS01_TK|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS02_SP|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS02_SP|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS02_TK|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.IIS02_TK|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.Release|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.SP_prod|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.SP_prod|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.SP_test|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.SP_test|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.TK_prod|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.TK_prod|Any CPU.Build.0 = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.TK_test|Any CPU.ActiveCfg = Release|Any CPU
- {2872DCFE-8B46-43B2-BAA0-842A816A2DD5}.TK_test|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE