diff --git a/GMW/GMW.sln b/GMW/GMW.sln index 9e5ab3e8..30d943ad 100644 --- a/GMW/GMW.sln +++ b/GMW/GMW.sln @@ -7,14 +7,14 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SteamWare", "..\SteamWare\S EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GMW_data", "GMW_data\GMW_data.csproj", "{47143721-A018-4BDA-B544-EC3E10BC87A2}" EndProject -Project("{2CFEAB61-6A3B-4EB8-B523-560B4BEEF521}") = "GMW_deploy", "GMW_deploy\GMW_deploy.wdproj", "{28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}" -EndProject Project("{54435603-DBB4-11D2-8724-00A0C9A8B90C}") = "GMW_installer", "GMW_installer\GMW_installer.vdproj", "{E5FC0485-009D-44F9-B05C-E0C8146AA9A3}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SetDirPerm", "..\SetDirectoryPermission\SetDirPerm.csproj", "{FB6006EA-4630-4ECB-82E4-FAC0866789D9}" EndProject Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "IISConsoleVB", "..\IISCustomActionVB\IISConsoleVB\IISConsoleVB.vbproj", "{67AF6121-D250-44E3-9C4E-0FC36599AAE4}" EndProject +Project("{2CFEAB61-6A3B-4EB8-B523-560B4BEEF521}") = "GMW_deploy", "GMW_deploy\GMW_deploy.wdproj", "{F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -59,16 +59,6 @@ Global {47143721-A018-4BDA-B544-EC3E10BC87A2}.Installer|Any CPU.Build.0 = Release|Any CPU {47143721-A018-4BDA-B544-EC3E10BC87A2}.Release|Any CPU.ActiveCfg = Release|Any CPU {47143721-A018-4BDA-B544-EC3E10BC87A2}.Release|Any CPU.Build.0 = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Deploy|Any CPU.ActiveCfg = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Deploy|Any CPU.Build.0 = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Installer_Offline|Any CPU.ActiveCfg = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Installer_Offline|Any CPU.Build.0 = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Installer_test|Any CPU.ActiveCfg = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Installer_test|Any CPU.Build.0 = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Installer|Any CPU.ActiveCfg = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Installer|Any CPU.Build.0 = Release|Any CPU - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D}.Release|Any CPU.ActiveCfg = Release|Any CPU {E5FC0485-009D-44F9-B05C-E0C8146AA9A3}.Debug|Any CPU.ActiveCfg = Debug {E5FC0485-009D-44F9-B05C-E0C8146AA9A3}.Deploy|Any CPU.ActiveCfg = Release {E5FC0485-009D-44F9-B05C-E0C8146AA9A3}.Installer_Offline|Any CPU.ActiveCfg = Release @@ -90,6 +80,18 @@ Global {67AF6121-D250-44E3-9C4E-0FC36599AAE4}.Installer|Any CPU.ActiveCfg = Release|Any CPU {67AF6121-D250-44E3-9C4E-0FC36599AAE4}.Installer|Any CPU.Build.0 = Release|Any CPU {67AF6121-D250-44E3-9C4E-0FC36599AAE4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Deploy|Any CPU.ActiveCfg = Debug|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Deploy|Any CPU.Build.0 = Debug|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Installer_Offline|Any CPU.ActiveCfg = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Installer_Offline|Any CPU.Build.0 = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Installer_test|Any CPU.ActiveCfg = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Installer_test|Any CPU.Build.0 = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Installer|Any CPU.ActiveCfg = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Installer|Any CPU.Build.0 = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE diff --git a/GMW/GMW/Web.config b/GMW/GMW/Web.config index e0e5411f..f1e99997 100644 --- a/GMW/GMW/Web.config +++ b/GMW/GMW/Web.config @@ -62,7 +62,7 @@ - + diff --git a/GMW/GMW/WebUserControls/mod_unauthorized.ascx b/GMW/GMW/WebUserControls/mod_unauthorized.ascx index 97c1fc44..a32b2a81 100644 --- a/GMW/GMW/WebUserControls/mod_unauthorized.ascx +++ b/GMW/GMW/WebUserControls/mod_unauthorized.ascx @@ -2,7 +2,7 @@ diff --git a/GMW/GMW/WebUserControls/mod_unauthorized.ascx.designer.cs b/GMW/GMW/WebUserControls/mod_unauthorized.ascx.designer.cs index e9b6e8e2..7d5054f0 100644 --- a/GMW/GMW/WebUserControls/mod_unauthorized.ascx.designer.cs +++ b/GMW/GMW/WebUserControls/mod_unauthorized.ascx.designer.cs @@ -12,6 +12,15 @@ public partial class mod_unauthorized { + /// + /// lblTitleMain control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblTitleMain; + /// /// lblTitle control. /// diff --git a/GMW/GMW/bin/GMW.dll b/GMW/GMW/bin/GMW.dll index f3a40378..ca3542a9 100644 Binary files a/GMW/GMW/bin/GMW.dll and b/GMW/GMW/bin/GMW.dll differ diff --git a/GMW/GMW/bin/GMW_data.dll b/GMW/GMW/bin/GMW_data.dll index 0d05ebbe..5b47395c 100644 Binary files a/GMW/GMW/bin/GMW_data.dll and b/GMW/GMW/bin/GMW_data.dll differ diff --git a/GMW/GMW/bin/SteamWare.dll b/GMW/GMW/bin/SteamWare.dll index 9c3c4166..827bff76 100644 Binary files a/GMW/GMW/bin/SteamWare.dll and b/GMW/GMW/bin/SteamWare.dll differ diff --git a/GMW/GMW/mazzAppSettings.config b/GMW/GMW/mazzAppSettings.config index 56bd1d1d..07d7a961 100644 --- a/GMW/GMW/mazzAppSettings.config +++ b/GMW/GMW/mazzAppSettings.config @@ -7,7 +7,7 @@ - + diff --git a/GMW/GMW/obj/Debug/GMW.dll b/GMW/GMW/obj/Debug/GMW.dll index f3a40378..019ae7dc 100644 Binary files a/GMW/GMW/obj/Debug/GMW.dll and b/GMW/GMW/obj/Debug/GMW.dll differ diff --git a/GMW/GMW/obj/Debug/ResolveAssemblyReference.cache b/GMW/GMW/obj/Debug/ResolveAssemblyReference.cache index f8968af5..f2b0952a 100644 Binary files a/GMW/GMW/obj/Debug/ResolveAssemblyReference.cache and b/GMW/GMW/obj/Debug/ResolveAssemblyReference.cache differ diff --git a/GMW/GMW/obj/Release/GMW.dll b/GMW/GMW/obj/Release/GMW.dll index e410e7c4..ca3542a9 100644 Binary files a/GMW/GMW/obj/Release/GMW.dll and b/GMW/GMW/obj/Release/GMW.dll differ diff --git a/GMW/GMW/obj/Release/ResolveAssemblyReference.cache b/GMW/GMW/obj/Release/ResolveAssemblyReference.cache index 0db27b52..88ae29fc 100644 Binary files a/GMW/GMW/obj/Release/ResolveAssemblyReference.cache and b/GMW/GMW/obj/Release/ResolveAssemblyReference.cache differ diff --git a/GMW/GMW_Term/Barcode.aspx.cs b/GMW/GMW_Term/Barcode.aspx.cs index 9a7f0729..f1bd302c 100644 --- a/GMW/GMW_Term/Barcode.aspx.cs +++ b/GMW/GMW_Term/Barcode.aspx.cs @@ -15,33 +15,39 @@ namespace GMW_Term mod_barcode1.eh_scannedParticolare += new EventHandler(mod_barcode1_eh_scannedParticolare); mod_barcode1.eh_scannedUdc += new EventHandler(mod_barcode1_eh_scannedUdc); mod_barcode1.eh_scannedUser += new EventHandler(mod_barcode1_eh_scannedUser); + mod_barcode1.eh_scannedCella += new EventHandler(mod_barcode1_eh_scannedCella); mod_barcode1.eh_resetUser += new EventHandler(mod_barcode1_eh_resetUser); } + void mod_barcode1_eh_scannedCella(object sender, EventArgs e) + { + Response.Redirect("~/Cella.aspx"); + } + void mod_barcode1_eh_resetUser(object sender, EventArgs e) { TermUtils.TU.forceLogOut(); - Response.Redirect("Barcode.aspx"); + Response.Redirect("~/Barcode.aspx"); } void mod_barcode1_eh_scannedUser(object sender, EventArgs e) { - Response.Redirect("Home.aspx"); + Response.Redirect("~/Home.aspx"); } void mod_barcode1_eh_scannedUdc(object sender, EventArgs e) { - Response.Redirect("UDC.aspx"); + Response.Redirect("~/UDC.aspx"); } void mod_barcode1_eh_scannedParticolare(object sender, EventArgs e) { - //throw new NotImplementedException(); + Response.Redirect("~/Particolare.aspx"); } void mod_barcode1_eh_scannedListaPrelievo(object sender, EventArgs e) { - //throw new NotImplementedException(); + Response.Redirect("~/ListePrelievo.aspx"); } } } diff --git a/GMW/GMW_Term/Web.config b/GMW/GMW_Term/Web.config index 068391a2..bedb0da5 100644 --- a/GMW/GMW_Term/Web.config +++ b/GMW/GMW_Term/Web.config @@ -57,7 +57,7 @@ - + diff --git a/GMW/GMW_Term/WebUserControls/mod_barcode.ascx.cs b/GMW/GMW_Term/WebUserControls/mod_barcode.ascx.cs index b7968319..dd6a29a6 100644 --- a/GMW/GMW_Term/WebUserControls/mod_barcode.ascx.cs +++ b/GMW/GMW_Term/WebUserControls/mod_barcode.ascx.cs @@ -31,6 +31,7 @@ namespace GMW_Term.WebUserControls public event EventHandler eh_scannedUdc; public event EventHandler eh_scannedListaPrelievo; public event EventHandler eh_scannedParticolare; + public event EventHandler eh_scannedCella; #endregion @@ -109,8 +110,10 @@ namespace GMW_Term.WebUserControls verificaUdc(); break; case tipoCodiceBarcode.Particolare: - lblData.Text = traduci("Particular Code") + ": " + txtScansione; - txtInput.Text = ""; + verificaParticolare(); + break; + case tipoCodiceBarcode.Cella: + verificaCella(); break; default: lblData.Text = traduci("Code Not Recognized") + ": " + txtScansione; @@ -135,8 +138,13 @@ namespace GMW_Term.WebUserControls 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); - // mando alla pagina liste di prelievo - Response.Redirect("~/ListePrelievo.aspx"); + + //// mando alla pagina liste di prelievo + //Response.Redirect("~/ListePrelievo.aspx"); + if (eh_scannedListaPrelievo != null) + { + eh_scannedListaPrelievo(this, new EventArgs()); + } } else { @@ -151,8 +159,13 @@ namespace GMW_Term.WebUserControls { // salvo in sessione che voglio mostrare il dettaglio della lista appena presa in carico memLayer.ML.setSessionVal("showDetListaPre", true, false); - // mando alla pagina liste di prelievo - Response.Redirect("~/ListePrelievo.aspx"); + + //// mando alla pagina liste di prelievo + //Response.Redirect("~/ListePrelievo.aspx"); + if (eh_scannedListaPrelievo != null) + { + eh_scannedListaPrelievo(this, new EventArgs()); + } } else { @@ -181,10 +194,57 @@ namespace GMW_Term.WebUserControls } else { - lblData.Text = string.Format(traduci("UDC Code Invalid") + ": " + "{0}", valoreScan); + lblData.Text = string.Format(traduci("UDCCodeInvalid") + ": " + "{0}", valoreScan); txtScansione = ""; } } + /// + /// verifica validità cella + /// + private void verificaCella() + { + // controllo cod cella se sia valido (==esistente) + bool barcodeOk = MagClass.magazzino.checkCella(valoreScan); + if (barcodeOk) + { + // salvo in session UDC selezionato + memLayer.ML.setSessionVal("IdxCella_sel", txtScansione); + memLayer.ML.setSessionVal("activeTask", string.Format("Cella: {0}", memLayer.ML.StringSessionObj("scannedValue"))); + 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 UDC selezionato + memLayer.ML.setSessionVal("Particolare_sel", txtScansione); + memLayer.ML.setSessionVal("activeTask", string.Format("Particolare: {0}", memLayer.ML.StringSessionObj("scannedValue"))); + 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 /// diff --git a/GMW/GMW_Term/WebUserControls/mod_execCella.ascx b/GMW/GMW_Term/WebUserControls/mod_execCella.ascx index 08244060..6b999b95 100644 --- a/GMW/GMW_Term/WebUserControls/mod_execCella.ascx +++ b/GMW/GMW_Term/WebUserControls/mod_execCella.ascx @@ -1,6 +1,67 @@ <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_execCella.ascx.cs" Inherits="GMW_Term.WebUserControls.mod_execCella" %> -
- W.I.P. +<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> +
+
+ + +
+
+ + + + + + + + + + + + + + <%-- + + + + --%> + + + + + +
+ +
+
+
+ + + + +  -  + +
+ - + +
+
+
+
+
+    + + + + + + +
- \ No newline at end of file diff --git a/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.cs b/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.cs index 9f9d43db..f6ca48ac 100644 --- a/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.cs +++ b/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.cs @@ -1,17 +1,360 @@ using System; -using System.Collections.Generic; -using System.Linq; -using System.Web; +using System.Data; using System.Web.UI; using System.Web.UI.WebControls; +using SteamWare; +using GMW_data; namespace GMW_Term.WebUserControls { public partial class mod_execCella : System.Web.UI.UserControl { + #region area da NON modificare + + #region area protected + + protected string _idxGridView; + protected string _idxGridViewExt; + protected string _tabCache; + protected bool _showNewBtn = false; + + /// + /// wrapper traduzione termini + /// + /// + /// + public string traduci(string lemma) + { + return user_std.UtSn.Traduci(lemma); + } + + /// + /// recupera i dati di un nuovo record contenuti nel footer di un gridView; + /// questi devono esses opportunamente nominati (es: txt{0}, dl{0}, ...) + /// + /// + /// + protected void recuperaFooter(object sender, ObjectDataSourceMethodEventArgs e) + { + //recupero la riga footer... + DataColumnCollection colonne = colonneObj(); + string nomeCol; + string tipoColonna = ""; + foreach (DataColumn colonna in colonne) + { + nomeCol = colonna.ColumnName; + // cerco un textbox o quello che sia... + if (grView.FooterRow.FindControl(string.Format("txt{0}", nomeCol)) != null) + { + tipoColonna = "textBox"; + } + else if (grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol)) != null) + { + tipoColonna = "dropDownList"; + } + else if (grView.FooterRow.FindControl(string.Format("chk{0}", nomeCol)) != null) + { + tipoColonna = "checkBox"; + } + else if (grView.FooterRow.FindControl(string.Format("selAjax_{0}", nomeCol)) != null) + { + tipoColonna = "selAjax"; + } + // in base al tipo salvo negli inputparameters dell'ODS + switch (tipoColonna) + { + case "textBox": + e.InputParameters[nomeCol] = ((TextBox)grView.FooterRow.FindControl(string.Format("txt{0}", nomeCol))).Text; + break; + case "dropDownList": + e.InputParameters[nomeCol] = ((DropDownList)grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol))).SelectedValue; + break; + case "checkBox": + e.InputParameters[nomeCol] = ((CheckBox)grView.FooterRow.FindControl(string.Format("chk{0}", nomeCol))).Checked; + break; + default: + break; + } + tipoColonna = ""; + } + } + /// + /// inserisce nuovo valore da footer + /// + /// + /// + protected void lblIns_click(object sender, EventArgs e) + { + // click su inserimento, chiamo il metodo insert dell'ObjectDataSource + ods.Insert(); + SteamWare.memLayer.ML.emptyCacheVal(_tabCache); + } + /// + /// annulla inserimento nuovo valore da footer + /// + /// + /// + protected void lblCanc_click(object sender, EventArgs e) + { + // annullo inserimento: nascondo footer, bind controlli... + grView.FooterRow.Visible = false; + } + + + /// + /// traduce gli header delle colonne + /// + /// + /// + protected void grView_DataBound(object sender, EventArgs e) + { + if (grView.Rows.Count > 0) + { + LinkButton lb; + // aggiorno gli headers + foreach (TableCell cella in grView.HeaderRow.Cells) + { + try + { + lb = (LinkButton)cella.Controls[0]; + lb.Text = traduci(lb.Text); + } + catch + { } + } + int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); + lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); + } + else + { + lblNumRec.Text = ""; + } + } + /// + /// gestione evento richeista nuovo valore (mostra footer, ...) + /// + /// + /// + protected void btnNew_Click(object sender, EventArgs e) + { + // reset selezione... + resetSelezione(); + // mostro il footer oppure la riga dei dettagli x nuovo... + if (grView.FooterRow != null) + { + grView.FooterRow.Visible = true; + } + // sollevo evento nuovo valore... + if (eh_nuovoValore != null) + { + eh_nuovoValore(this, new EventArgs()); + } + } + /// + /// reset della selezione + /// + /// + /// + protected void btnReset_Click(object sender, EventArgs e) + { + resetSelezione(); + } + + #endregion + + #region gestione eventi + + public event EventHandler eh_resetSelezione; + public event EventHandler eh_nuovoValore; + public event EventHandler eh_selValore; + + #endregion + + #region public + + /// + /// definisce visibilità btnNew + /// + public bool showNewBtn + { + get + { + return _showNewBtn; + } + set + { + _showNewBtn = value; + } + } + /// + /// effettua update del modulo + /// + public void doUpdate() + { + resetSelezione(); + } + + #endregion + + #endregion + + /// + /// metodi al caricamento della pagina + /// + /// + /// protected void Page_Load(object sender, EventArgs e) { + // scrive label e text bottoni + btnLoginPage.Text = "[7]-LogOut"; + btnLoginPage.AccessKey = "7"; + btnButtonsHome.Text = "[9]-Home"; + btnButtonsHome.AccessKey = "9"; + } + /// + /// effettua logout... + /// + /// + /// + protected void btnLoginPage_Click(object sender, EventArgs e) + { + TermUtils.TU.forceLogOut(); + Response.Redirect("~/Barcode.aspx"); + } + /// + /// va alla pagina dei buttons principale + /// + /// + /// + protected void btnButtonsHome_Click(object sender, EventArgs e) + { + Response.Redirect("~/Home.aspx"); + } + + /// + /// elenco colonne del datagrid + /// + /// + protected DataColumnCollection colonneObj() + { + DS_magazzino.V_DettMagPartDataTable tabella = new DS_magazzino.V_DettMagPartDataTable(); + DataColumnCollection colonne = tabella.Columns; + return colonne; + } + /// + /// inizializzazione valori di default + /// + /// + protected override void OnInit(EventArgs e) + { + base.OnInit(e); + _idxGridView = "TipoSearch"; + + aggiornaControlliDataGL(); + } + /// + /// aggiorna controlli datagrid e numero righe in pagina + /// + protected void aggiornaControlliDataGL() + { + grView.PageSize = 6; + } + + /// + /// gestione cambio selezione valore + /// + /// + /// + protected void grView_SelectedIndexChanged(object sender, EventArgs e) + { + } + /// + /// resetta la selezione dei valori in caso di modifiche su altri controlli + /// + public void resetSelezione() + { + SteamWare.memLayer.ML.emptySessionVal(string.Format("{0}_sel", _idxGridView)); + grView.SelectedIndex = -1; + grView.DataBind(); + lblWarning.Visible = false; + } + + /// + /// salvo in session che il prox comando è iniziare lista prelievo... + /// + /// + /// + protected void imgAzioneLista_Click(object sender, ImageClickEventArgs e) + { + ImageButton imgb = (ImageButton)sender; + SteamWare.memLayer.ML.setSessionVal("nextObjCommand", imgb.CommandArgument); + } + /// + /// in caso di aggiornamento verifico se sia salvato un comando inizia o completa lista prelievo... + /// + /// + /// + protected void grView_RowUpdating(object sender, GridViewUpdateEventArgs e) + { + //// carico l'idx dell'oggetto + //string tipo = e.Keys["tipo"].ToString(); + //string valore = e.Keys["valore"].ToString(); + //// quale comando? + //string _comando = ""; + //if (SteamWare.memLayer.ML.isInSessionObject("nextObjCommand")) + //{ + // _comando = SteamWare.memLayer.ML.StringSessionObj("nextObjCommand"); + // SteamWare.memLayer.ML.emptySessionVal("nextObjCommand"); + //} + //string CodSoggetto = MagClass.magazzino.CodSoggCurrUser; + //switch (_comando) + //{ + // case "UDC": + // // salvo in sessione + // memLayer.ML.setSessionVal("UDC_sel", valore); + // // blocco update! + // e.Cancel = true; + // // faccio redirect + // Response.Redirect("~/UDC.aspx"); + // break; + // case "Particolare": + // // salvo in sessione + // memLayer.ML.setSessionVal("Particolare_sel", valore); + // // blocco update! + // e.Cancel = true; + // // faccio redirect + // Response.Redirect("~/Particolare.aspx"); + // break; + // case "Cella": + // // salvo in sessione + // memLayer.ML.setSessionVal("IdxCella_sel", valore); + // // blocco update! + // e.Cancel = true; + // // faccio redirect + // Response.Redirect("~/Cella.aspx"); + // break; + // default: + // // faccio update! + // break; + //} + } + + /// + /// ssitema visualizzazione dal filtraggi + /// + private void checkFixOds() + { + // chiamo procedura che aggiorna ods principale + grView.SelectedIndex = -1; + updateOds(); + } + /// + /// aggiorno il gridview + /// + protected void updateOds() + { + grView.DataBind(); } } } \ No newline at end of file diff --git a/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.designer.cs b/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.designer.cs index 79847f6d..4c887273 100644 --- a/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.designer.cs +++ b/GMW/GMW_Term/WebUserControls/mod_execCella.ascx.designer.cs @@ -14,12 +14,57 @@ namespace GMW_Term.WebUserControls { public partial class mod_execCella { /// - /// Image1 control. + /// btnLoginPage control. /// /// /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// - protected global::System.Web.UI.WebControls.Image Image1; + protected global::System.Web.UI.WebControls.Button btnLoginPage; + + /// + /// btnButtonsHome control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Button btnButtonsHome; + + /// + /// grView control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.GridView grView; + + /// + /// lblNumRec control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblNumRec; + + /// + /// lblWarning control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblWarning; + + /// + /// ods control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.ObjectDataSource ods; } } diff --git a/GMW/GMW_Term/WebUserControls/mod_execParticolare.ascx.cs b/GMW/GMW_Term/WebUserControls/mod_execParticolare.ascx.cs index 83f1a342..855ec48d 100644 --- a/GMW/GMW_Term/WebUserControls/mod_execParticolare.ascx.cs +++ b/GMW/GMW_Term/WebUserControls/mod_execParticolare.ascx.cs @@ -297,58 +297,49 @@ namespace GMW_Term.WebUserControls /// protected void grView_RowUpdating(object sender, GridViewUpdateEventArgs e) { - // carico l'idx dell'oggetto - string tipo = e.Keys["tipo"].ToString(); - string valore = e.Keys["valore"].ToString(); - // quale comando? - string _comando = ""; - if (SteamWare.memLayer.ML.isInSessionObject("nextObjCommand")) - { - _comando = SteamWare.memLayer.ML.StringSessionObj("nextObjCommand"); - SteamWare.memLayer.ML.emptySessionVal("nextObjCommand"); - } - string CodSoggetto = MagClass.magazzino.CodSoggCurrUser; - switch (_comando) - { - case "UDC": - // salvo in sessione - memLayer.ML.setSessionVal("UDC_sel", valore); - // blocco update! - e.Cancel = true; - // faccio redirect - Response.Redirect("~/UDC.aspx"); - break; - case "Particolare": - // salvo in sessione - memLayer.ML.setSessionVal("Particolare_sel", valore); - // blocco update! - e.Cancel = true; - // faccio redirect - Response.Redirect("~/Particolare.aspx"); - break; - case "Cella": - // salvo in sessione - memLayer.ML.setSessionVal("IdxCella_sel", valore); - // blocco update! - e.Cancel = true; - // faccio redirect - Response.Redirect("~/Cella.aspx"); - break; - default: - // faccio update! - break; - } + //// carico l'idx dell'oggetto + //string tipo = e.Keys["tipo"].ToString(); + //string valore = e.Keys["valore"].ToString(); + //// quale comando? + //string _comando = ""; + //if (SteamWare.memLayer.ML.isInSessionObject("nextObjCommand")) + //{ + // _comando = SteamWare.memLayer.ML.StringSessionObj("nextObjCommand"); + // SteamWare.memLayer.ML.emptySessionVal("nextObjCommand"); + //} + //string CodSoggetto = MagClass.magazzino.CodSoggCurrUser; + //switch (_comando) + //{ + // case "UDC": + // // salvo in sessione + // memLayer.ML.setSessionVal("UDC_sel", valore); + // // blocco update! + // e.Cancel = true; + // // faccio redirect + // Response.Redirect("~/UDC.aspx"); + // break; + // case "Particolare": + // // salvo in sessione + // memLayer.ML.setSessionVal("Particolare_sel", valore); + // // blocco update! + // e.Cancel = true; + // // faccio redirect + // Response.Redirect("~/Particolare.aspx"); + // break; + // case "Cella": + // // salvo in sessione + // memLayer.ML.setSessionVal("IdxCella_sel", valore); + // // blocco update! + // e.Cancel = true; + // // faccio redirect + // Response.Redirect("~/Cella.aspx"); + // break; + // default: + // // faccio update! + // break; + //} } - /// - /// chiamato post modifica valore check/selezione nel selettore filtro stato - /// - /// - /// - public void eh_selectedStato(object sender, EventArgs e) - { - checkFixOds(); - } /// /// ssitema visualizzazione dal filtraggi /// @@ -365,105 +356,6 @@ namespace GMW_Term.WebUserControls { grView.DataBind(); } - /// - /// chiamato post modifica valore check/selezione nel selettore filtro tipo - /// - /// - /// - public void eh_selectedTipo(object sender, EventArgs e) - { - checkFixOds(); - } - - /// - /// restituisce URL immagine del codice da mostrare x TIPO lista - /// - /// - /// - public string pathImgTipo(object codice) - { - string answ = ""; - string tipo = codice.ToString(); - switch (tipo) - { - case "UDC": - answ = string.Format("~/images/UDC.png", codice); - break; - case "Particolare": - answ = string.Format("~/images/Part.png", codice); - break; - case "Cella": - answ = string.Format("~/images/Cella.png", codice); - break; - default: - break; - } - return answ; - } - /// - /// restituisce tooltip da mostrare x TIPO lista - /// - /// - /// - public string tooltipTipo(object codice) - { - return traduci(codice.ToString()); - } - - /// - /// formatta una stringa di descrizione a aprtire dal tipo oggetto - /// - /// - /// - /// - public string descOggetto(object _tipo, object _valore) - { - string tipo = _tipo.ToString(); - string valore = _valore.ToString(); - string answ = ""; - switch (tipo) - { - case "UDC": - try - { - DS_magazzino.v_UdcDetailRow rigaUdc = MagClass.magazzino.taDettUDC.getByFullUdc(valore, memLayer.ML.StringSessionObj("CodCS"))[0]; - answ = string.Format("{0} {1:##} pz M:{2} C:{3}", rigaUdc.Particolare, rigaUdc.Qta, rigaUdc.CodMag, rigaUdc.CodCella); - } - catch (Exception e) - { - logger.lg.scriviLog(string.Format("Eccezione {0}", e), tipoLog.EXCEPTION); - answ = string.Format("{0} - {1}", tipo, valore); - } - break; - case "Particolare": - try - { - DS_magazzino.V_ParticolariOverviewRow rigaPart = MagClass.magazzino.taVParticolariOverwiew.getByParticolareFull(valore, memLayer.ML.StringSessionObj("CodCS"))[0]; - answ = string.Format("UDC: {0} ({2} a mag.) - {1:##} pz", rigaPart.NumUDC, rigaPart.TotQta, rigaPart.NumInMag); - } - catch (Exception e) - { - logger.lg.scriviLog(string.Format("Eccezione {0}", e), tipoLog.EXCEPTION); - answ = string.Format("{0} - {1}", tipo, valore); - } - break; - case "Cella": - try - { - DS_magazzino.V_statoCelleCapienzaAssegnatiRow rigaCelle = MagClass.magazzino.taStatoCelle.getByIdxCella(Convert.ToInt32(valore))[0]; - answ = string.Format("{0} / {1}", rigaCelle.UdcAssegnati, rigaCelle.Capienza); - } - catch (Exception e) - { - logger.lg.scriviLog(string.Format("Eccezione {0}", e), tipoLog.EXCEPTION); - answ = string.Format("{0} - {1}", tipo, valore); - } - break; - default: - break; - } - return answ; - } } } \ No newline at end of file diff --git a/GMW/GMW_Term/bin/GMW_Term.dll b/GMW/GMW_Term/bin/GMW_Term.dll index 00a5930b..823955ba 100644 Binary files a/GMW/GMW_Term/bin/GMW_Term.dll and b/GMW/GMW_Term/bin/GMW_Term.dll differ diff --git a/GMW/GMW_Term/bin/GMW_data.dll b/GMW/GMW_Term/bin/GMW_data.dll index 0d05ebbe..944d571d 100644 Binary files a/GMW/GMW_Term/bin/GMW_data.dll and b/GMW/GMW_Term/bin/GMW_data.dll differ diff --git a/GMW/GMW_Term/mazzAppSettings.config b/GMW/GMW_Term/mazzAppSettings.config index 607440f2..e13fd98b 100644 --- a/GMW/GMW_Term/mazzAppSettings.config +++ b/GMW/GMW_Term/mazzAppSettings.config @@ -7,7 +7,7 @@ - + diff --git a/GMW/GMW_Term/obj/Debug/GMW_Term.dll b/GMW/GMW_Term/obj/Debug/GMW_Term.dll index 00a5930b..823955ba 100644 Binary files a/GMW/GMW_Term/obj/Debug/GMW_Term.dll and b/GMW/GMW_Term/obj/Debug/GMW_Term.dll differ diff --git a/GMW/GMW_Term/obj/Debug/ResolveAssemblyReference.cache b/GMW/GMW_Term/obj/Debug/ResolveAssemblyReference.cache index 42e10086..c480fc6b 100644 Binary files a/GMW/GMW_Term/obj/Debug/ResolveAssemblyReference.cache and b/GMW/GMW_Term/obj/Debug/ResolveAssemblyReference.cache differ diff --git a/GMW/GMW_Term_installer/GMW_Term_installer.vdproj b/GMW/GMW_Term_installer/GMW_Term_installer.vdproj index 11451645..3da458dc 100644 --- a/GMW/GMW_Term_installer/GMW_Term_installer.vdproj +++ b/GMW/GMW_Term_installer/GMW_Term_installer.vdproj @@ -344,14 +344,14 @@ { "Name" = "8:Microsoft Visual Studio" "ProductName" = "8:GMW_Term" - "ProductCode" = "8:{7BFDEF48-8EA1-48D5-8EA7-5271A37E55B2}" - "PackageCode" = "8:{95F5A680-7B4C-4484-9B43-1442B90D595C}" + "ProductCode" = "8:{2E188AAF-6A1E-471C-86FC-4103092C7169}" + "PackageCode" = "8:{A313C926-EA92-4707-8331-1FA09A0F430A}" "UpgradeCode" = "8:{B348C50D-8DAD-4430-AEF0-60800C94CB78}" "RestartWWWService" = "11:TRUE" "RemovePreviousVersions" = "11:TRUE" "DetectNewerInstalledVersion" = "11:TRUE" "InstallAllUsers" = "11:FALSE" - "ProductVersion" = "8:1.0.230" + "ProductVersion" = "8:1.0.235" "Manufacturer" = "8:SteamWare s.r.l." "ARPHELPTELEPHONE" = "8:+39-035460560" "ARPHELPLINK" = "8:http://www.steamware.net" diff --git a/GMW/GMW_Term_installer/Release/GMW_Term_installer.msi b/GMW/GMW_Term_installer/Release/GMW_Term_installer.msi index 44641ae5..ff5d1454 100644 Binary files a/GMW/GMW_Term_installer/Release/GMW_Term_installer.msi and b/GMW/GMW_Term_installer/Release/GMW_Term_installer.msi differ diff --git a/GMW/GMW_data/MagClass.cs b/GMW/GMW_data/MagClass.cs index 9b9f28eb..46985af0 100644 --- a/GMW/GMW_data/MagClass.cs +++ b/GMW/GMW_data/MagClass.cs @@ -441,6 +441,39 @@ namespace GMW_data { } return answ; } + /// + /// verifica la cella indicata sia valida, ovvero esistente + /// + /// + /// + public bool checkCella(string CodCella) + { + bool answ = false; + try + { + answ = (taCelle.getByCodCella(CodCella).Rows.Count > 0); + } + catch + { } + return answ; + } + /// + /// verifica se il particolare indicato sia valido, ovvero esistente + /// + /// Codice company/sito + /// + /// + public bool checkParticolare(string CodCS, string Particolare) + { + bool answ = false; + try + { + answ = (taVParticolariOverwiew.getByParticolareFull(Particolare, CodCS).Rows.Count > 0); + } + catch + { } + return answ; + } #endregion diff --git a/GMW/GMW_data/SqlScripts/GMW_00230.sql b/GMW/GMW_data/SqlScripts/GMW_00230.sql new file mode 100644 index 00000000..98374fa8 --- /dev/null +++ b/GMW/GMW_data/SqlScripts/GMW_00230.sql @@ -0,0 +1,163 @@ +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +-- ============================================= +-- Author: Samuele E. Locatelli +-- Create date: 2009-09-13 +-- Description: trigger x inserimento valori in archivio storico alla cancellazione/modifica del dato +-- ============================================= +create TRIGGER trg_storico + ON PosizioneUdcCorrente + AFTER DELETE,UPDATE +AS +BEGIN + -- SET NOCOUNT ON added to prevent extra result sets from + -- interfering with SELECT statements. + SET NOCOUNT ON; + + -- metto in storico la posizione attuale dell'UDC (SE esiste) CANCELLATO + INSERT INTO PosizioneUdcStorico(UDC, IdxCella, CodCS, DataInizio, DataFine) + ( + SELECT UDC, IdxCella, CodCS, DataRif as DataInizio, GETDATE() as DataFine + FROM deleted + ) + +END +go + +commit +go + + +-- + +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +/*************************************** +* STORED stp_spostaUdc +* +* sposta un UDC, salvandone la posizione precedente (se esiste) nella tab storica +* +* Steamware, S.E.L. +* mod: 2010.06.11 +* +****************************************/ +alter PROCEDURE stp_spostaUdc +( + @CodCS VARCHAR(2), + @UDC VARCHAR(50), + @IdxCellaTo INT +) +AS + +BEGIN TRAN + /* + -- inizio mettendo in storico la posizione attuale dell'UDC (SE esiste) + INSERT INTO PosizioneUdcStorico(UDC, IdxCella, CodCS, DataInizio, DataFine) + ( + SELECT UDC, IdxCella, CodCS, DataRif as DataInizio, GETDATE() as DataFine + FROM PosizioneUdcCorrente + WHERE UDC = @UDC + ) + */ + + -- libero la posizione attuale dell'UDC (se c'è...) + DELETE + FROM PosizioneUdcCorrente + WHERE UDC = @UDC-- AND IdxCella = @IdxCellaFrom + + -- creo una nuova posizione per l'UDC + INSERT INTO PosizioneUdcCorrente(UDC, IdxCella, CodCS, DataRif) + VALUES(@UDC, @IdxCellaTo, @CodCS, GETDATE()) + +COMMIT TRAN + +RETURN +go + +commit +go + + +-- + +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +/*************************************** +* STORED stp_UDC_delibera +* +* fa la delibera dell'UDC andando a processare la state machien e quindi eventualmente cambiando la sua posizione +* +* Steamware, S.E.L. +* mod: 2010.09.13 +* +************************************/ +alter PROCEDURE stp_UDC_delibera +( + @CodTipoDelibera NVARCHAR(50), + @UDC NVARCHAR(50), + @CodSoggetto NVARCHAR(17), + @CodCS VARCHAR(2) +) + +AS + +BEGIN TRAN + DECLARE @IdxPosizioneTo AS INT + DECLARE @IdxCellaTo AS INT + + -- registro delibera + INSERT INTO DELIBERE + VALUES (@CodTipoDelibera, @UDC, GETDATE(), @CodSoggetto) + + -- ricavo nuova posizione + SET @IdxPosizioneTo = (SELECT tt.IdxPosizioneTo + FROM TabTranPosizEventi tt INNER JOIN AnagTipoDelibere atd ON tt.CodEvento = atd.CodEvento + WHERE (atd.CodTipoDelibera = @CodTipoDelibera)) + + -- calcolo la prima cella della nuova posizione... + SET @IdxCellaTo = ( + SELECT TOP 1 IdxCella FROM Celle + WHERE IdxBlocco = ( + SELECT IdxBlocco FROM Blocchi + WHERE CodMag=CAST(@IdxPosizioneTo AS VARCHAR(50))) + ) + + -- faccio update posizione + UPDATE ElencoCartellini + SET IdxPosizione = @IdxPosizioneTo + WHERE UDC = @UDC + + -- ora cambio anche la posizione corrente dell'UDC (e tramite trigger storicizza...) + EXEC stp_spostaUdc @CodCS, @UDC, @IdxCellaTo + +COMMIT TRAN + + +RETURN +go + +commit +go + + diff --git a/GMW/GMW_data/bin/Debug/GMW_data.dll b/GMW/GMW_data/bin/Debug/GMW_data.dll index 0d05ebbe..944d571d 100644 Binary files a/GMW/GMW_data/bin/Debug/GMW_data.dll and b/GMW/GMW_data/bin/Debug/GMW_data.dll differ diff --git a/GMW/GMW_data/bin/Release/GMW_data.dll b/GMW/GMW_data/bin/Release/GMW_data.dll index dc0c9bd2..7a19a52a 100644 Binary files a/GMW/GMW_data/bin/Release/GMW_data.dll and b/GMW/GMW_data/bin/Release/GMW_data.dll differ diff --git a/GMW/GMW_data/bin/Release/GMW_data.dll.config b/GMW/GMW_data/bin/Release/GMW_data.dll.config index 450b760e..a6f63976 100644 --- a/GMW/GMW_data/bin/Release/GMW_data.dll.config +++ b/GMW/GMW_data/bin/Release/GMW_data.dll.config @@ -4,7 +4,7 @@ \ No newline at end of file diff --git a/GMW/GMW_data/bin/Release/SteamWare.dll b/GMW/GMW_data/bin/Release/SteamWare.dll index 185f5a3f..827bff76 100644 Binary files a/GMW/GMW_data/bin/Release/SteamWare.dll and b/GMW/GMW_data/bin/Release/SteamWare.dll differ diff --git a/GMW/GMW_data/obj/Debug/GMW_data.dll b/GMW/GMW_data/obj/Debug/GMW_data.dll index 0d05ebbe..944d571d 100644 Binary files a/GMW/GMW_data/obj/Debug/GMW_data.dll and b/GMW/GMW_data/obj/Debug/GMW_data.dll differ diff --git a/GMW/GMW_data/obj/Debug/TempPE/DS_magazzino.Designer.cs.dll b/GMW/GMW_data/obj/Debug/TempPE/DS_magazzino.Designer.cs.dll index ae58f4dc..9bfe8686 100644 Binary files a/GMW/GMW_data/obj/Debug/TempPE/DS_magazzino.Designer.cs.dll and b/GMW/GMW_data/obj/Debug/TempPE/DS_magazzino.Designer.cs.dll differ diff --git a/GMW/GMW_data/obj/Release/GMW_data.dll b/GMW/GMW_data/obj/Release/GMW_data.dll index dc0c9bd2..7a19a52a 100644 Binary files a/GMW/GMW_data/obj/Release/GMW_data.dll and b/GMW/GMW_data/obj/Release/GMW_data.dll differ diff --git a/GMW/GMW_data/obj/Release/ResolveAssemblyReference.cache b/GMW/GMW_data/obj/Release/ResolveAssemblyReference.cache index 0f446fcd..0252f01c 100644 Binary files a/GMW/GMW_data/obj/Release/ResolveAssemblyReference.cache and b/GMW/GMW_data/obj/Release/ResolveAssemblyReference.cache differ diff --git a/GMW/GMW_data/obj/Release/TempPE/DS_Applicazione.Designer.cs.dll b/GMW/GMW_data/obj/Release/TempPE/DS_Applicazione.Designer.cs.dll index 7213858b..310fdf1c 100644 Binary files a/GMW/GMW_data/obj/Release/TempPE/DS_Applicazione.Designer.cs.dll and b/GMW/GMW_data/obj/Release/TempPE/DS_Applicazione.Designer.cs.dll differ diff --git a/GMW/GMW_data/obj/Release/TempPE/DS_SM.Designer.cs.dll b/GMW/GMW_data/obj/Release/TempPE/DS_SM.Designer.cs.dll index 17674786..8121bb76 100644 Binary files a/GMW/GMW_data/obj/Release/TempPE/DS_SM.Designer.cs.dll and b/GMW/GMW_data/obj/Release/TempPE/DS_SM.Designer.cs.dll differ diff --git a/GMW/GMW_deploy/GMW_deploy.wdproj b/GMW/GMW_deploy/GMW_deploy.wdproj index f46f9ed0..98970d7f 100644 --- a/GMW/GMW_deploy/GMW_deploy.wdproj +++ b/GMW/GMW_deploy/GMW_deploy.wdproj @@ -9,22 +9,18 @@ AnyCPU 9.0.21022 2.0 - {28E4C4DF-7F24-4D23-A44C-F10F8168FC7D} + {F6B68E94-B7A6-4DC7-A08C-E760B9F95F9F} ..\GMW {F8710519-CA62-4482-9045-02577B939A79}|GMW\GMW.csproj /GMW.csproj v3.5 - false + true .\Debug true true GMW_deploy - true - true - true - true false @@ -32,37 +28,10 @@ true true GMW_deploy - true - true - true - true - - -
appSettings
-
- -
connectionStrings
-
-
- - -
appSettings
-
- -
connectionStrings
-
-
- - - - - - -
- +