update installers terminalino con try/catch e vari logs...
This commit is contained in:
+1
-1
@@ -64,7 +64,7 @@
|
||||
<add key="appName" value="GMW_Term" />
|
||||
<add key="SiteName" value="Tekal" />
|
||||
<add key="mainRev" value="2.5" />
|
||||
<add key="minRev" value="708" />
|
||||
<add key="minRev" value="710" />
|
||||
<add key="copyRight" value="SteamWare © 2010-2014" />
|
||||
<add key="_allowForceUser" value="true" />
|
||||
<add key="_safePages" value="jumper.aspx#unauthorized.aspx#allegati.aspx#forceUser.aspx#login.aspx#test.aspx#istruzioni.aspx#Test.aspx" />
|
||||
|
||||
@@ -11,6 +11,7 @@ namespace GMW_Term.WebUserControls
|
||||
{
|
||||
public partial class mod_makeMov : System.Web.UI.UserControl
|
||||
{
|
||||
protected int logLevel;
|
||||
/// <summary>
|
||||
/// wrapper traduzione termini
|
||||
/// </summary>
|
||||
@@ -27,6 +28,7 @@ namespace GMW_Term.WebUserControls
|
||||
/// <param name="e"></param>
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
logLevel = memLayer.ML.confReadInt("_logLevel");
|
||||
updateMakeMov();
|
||||
}
|
||||
/// <summary>
|
||||
@@ -34,10 +36,18 @@ namespace GMW_Term.WebUserControls
|
||||
/// </summary>
|
||||
public void updateMakeMov()
|
||||
{
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("chiamata updateMakeMov");
|
||||
}
|
||||
// recupero barcode e controllo sia valido
|
||||
string _UDC = memLayer.ML.StringSessionObj("UDC_sel");
|
||||
int _idxCella = memLayer.ML.IntSessionObj("IdxCella_sel");
|
||||
string _codCella = memLayer.ML.StringSessionObj("codCella_sel");
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog(string.Format("Valori letti: UDC {0}, IdxCella {1}, codCella {2}", _UDC, _idxCella, _codCella), tipoLog.INFO);
|
||||
}
|
||||
// aggiorno labels standard
|
||||
lblCella.Text = traduci("lblCella");
|
||||
lblUDC.Text = traduci("lblUDC");
|
||||
@@ -52,10 +62,18 @@ namespace GMW_Term.WebUserControls
|
||||
// SE cella vuota procedo!
|
||||
if (!MagClass.magazzino.cellaPiena(memLayer.ML.confReadString("codCS"), _idxCella))
|
||||
{
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Cella vuota, procedo a spstamento UDC");
|
||||
}
|
||||
spostaUdc(_UDC, _idxCella, _codCella);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Cella piena, chieodo conferma");
|
||||
}
|
||||
// se cella piena chiedo conferma
|
||||
btnConferma.Visible = true;
|
||||
btnAnnulla.Visible = true;
|
||||
@@ -63,6 +81,11 @@ namespace GMW_Term.WebUserControls
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Mancano UDC o Cella");
|
||||
}
|
||||
btnConferma.Visible = false;
|
||||
btnAnnulla.Visible = false;
|
||||
}
|
||||
@@ -75,13 +98,26 @@ namespace GMW_Term.WebUserControls
|
||||
/// <param name="_codCella"></param>
|
||||
private void spostaUdc(string _UDC, int _idxCella, string _codCella)
|
||||
{
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Spostamento UDC: step 1");
|
||||
}
|
||||
// controllo UDC sia spostabile (ovvero NON in RLP bloccata)
|
||||
if (MagClass.magazzino.checkUDC_mov(_UDC))
|
||||
{
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Spostamento UDC: step 2");
|
||||
}
|
||||
MagClass.magazzino.spostaUDC(memLayer.ML.confReadString("codCS"), _UDC, _idxCella, memLayer.ML.confReadBool("spostaUdcResettaLdp"), Request.UserHostName);
|
||||
btnConferma.Visible = false;
|
||||
btnAnnulla.Visible = false;
|
||||
lblEsito.Text = string.Format("{0} {1} --> {2} ", traduci("ConfermaSpostatoUDC"), _UDC, _codCella);
|
||||
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Spostamento UDC: step 3");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -101,17 +137,35 @@ namespace GMW_Term.WebUserControls
|
||||
int _idxCella = memLayer.ML.IntSessionObj("IdxCella_sel");
|
||||
string _codCella = memLayer.ML.StringSessionObj("codCella_sel");
|
||||
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Conferma Spostamento UDC: step 1");
|
||||
}
|
||||
// controllo UDC sia spostabile (ovvero NON in RLP bloccata)
|
||||
if (MagClass.magazzino.checkUDC_mov(_UDC))
|
||||
{
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Conferma Spostamento UDC: step 2");
|
||||
}
|
||||
// sposto UDC precedente in posizione preimpostata da web.config
|
||||
string codCellaErroriAnime = memLayer.ML.confReadString("codCellaErroriAnime");
|
||||
int idxCellaTo = MagClass.magazzino.taCelle.getByCodCella(codCellaErroriAnime)[0].IdxCella;
|
||||
string udc2move = MagClass.magazzino.udcInCella(memLayer.ML.confReadString("codCS"), _idxCella);
|
||||
// sposto udc in posizione "errori anime"...
|
||||
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Conferma Spostamento UDC: step 3");
|
||||
}
|
||||
MagClass.magazzino.spostaUDC(memLayer.ML.confReadString("codCS"), udc2move, idxCellaTo, memLayer.ML.confReadBool("spostaUdcResettaLdp"), Request.UserHostName);
|
||||
lblEsito.Text = string.Format("{0} {1} --> {2} ", traduci("ConfermaSpostatoUDC"), _UDC, _codCella);
|
||||
// sposto "vero" UDC
|
||||
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Conferma Spostamento UDC: step 4");
|
||||
}
|
||||
spostaUdc(_UDC, _idxCella, _codCella);
|
||||
}
|
||||
else
|
||||
@@ -119,6 +173,10 @@ namespace GMW_Term.WebUserControls
|
||||
lblEsito.Text = string.Format("{0} {1}", traduci("UdcNonSpostabile"), _UDC);
|
||||
}
|
||||
resetAndUpdate();
|
||||
if (logLevel > 6)
|
||||
{
|
||||
logger.lg.scriviLog("Conferma Spostamento UDC: step 5");
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// aggiorna visualizzazioni e resetta
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user