diff --git a/GMW/GMW/WebUserControls/mod_anagBlocchi.ascx.cs b/GMW/GMW/WebUserControls/mod_anagBlocchi.ascx.cs index e8dbed9c..4e0f1507 100644 --- a/GMW/GMW/WebUserControls/mod_anagBlocchi.ascx.cs +++ b/GMW/GMW/WebUserControls/mod_anagBlocchi.ascx.cs @@ -209,7 +209,7 @@ namespace GMW.WebUserControls protected void grView_SelectedIndexChanged(object sender, EventArgs e) { // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), grView.SelectedValue, true); + SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), grView.SelectedValue, false); // sollevo evento nuovo valore... if (eh_selValore != null) { @@ -407,7 +407,7 @@ namespace GMW.WebUserControls switch (_comando) { case "creaChildObj": - utils.obj.taSTP.stp_celleCreaMancantiBlocco(memLayer.ML.confReadString("CodCS"), _idxBlocco); + utils.obj.taSTP.stp_celleCreaMancantiBlocco(memLayer.ML.confReadString("CodCS"),memLayer.ML.StringSessionObj("CodMag_sel"), _idxBlocco); updateOdsDaFiltro(); grView.EditIndex = -1; grView.DataBind(); diff --git a/GMW/GMW/WebUserControls/mod_anagCelle.ascx b/GMW/GMW/WebUserControls/mod_anagCelle.ascx index 86046842..5788d910 100644 --- a/GMW/GMW/WebUserControls/mod_anagCelle.ascx +++ b/GMW/GMW/WebUserControls/mod_anagCelle.ascx @@ -25,7 +25,8 @@ + DataKeyNames="IdxCella" DataSourceID="ods" + onpageindexchanged="grView_PageIndexChanged" onsorted="grView_Sorted"> @@ -68,33 +69,34 @@ - + - + - + - + + - +    - \ No newline at end of file + + + + + + + + + + + + + diff --git a/GMW/GMW/WebUserControls/mod_anagCelle.ascx.cs b/GMW/GMW/WebUserControls/mod_anagCelle.ascx.cs index 371f7d6e..78b297cf 100644 --- a/GMW/GMW/WebUserControls/mod_anagCelle.ascx.cs +++ b/GMW/GMW/WebUserControls/mod_anagCelle.ascx.cs @@ -343,7 +343,7 @@ namespace GMW.WebUserControls // salvo in sessione il valore selezionato... if (mod_filtroBlock.valoreInt != 0) { - memLayer.ML.setSessionVal("IdxBlocco_sel", mod_filtroBlock.valoreInt); + memLayer.ML.setSessionVal("IdxBlocco_sel", mod_filtroBlock.valoreInt, false); } else { @@ -358,7 +358,7 @@ namespace GMW.WebUserControls // salvo in sessione il valore selezionato... if (mod_filtroMag.valore != "") { - memLayer.ML.setSessionVal("CodMag_sel", mod_filtroMag.valore); + memLayer.ML.setSessionVal("CodMag_sel", mod_filtroMag.valore, false); } else { @@ -494,6 +494,45 @@ namespace GMW.WebUserControls { } return answ; } + /// + /// restituisce il codice tipoCella dato il suo idx + /// + /// + /// + public string TipoCellaDaIdx(object idx) + { + string answ = "nd"; + int _idxTipoCella = Convert.ToInt32(idx); + try + { + DS_Utility.v_selTipoCellaRow riga = utils.obj.taSelTipoCella.getByValue(_idxTipoCella)[0]; + answ = riga.label; + } + catch + { } + return answ; + } + /// + /// chiamata post page change gridview + /// + /// + /// + protected void grView_PageIndexChanged(object sender, EventArgs e) + { + // sistemazione dell'ods post evento cambio pagina + checkFixOds(); + } + /// + /// chiamata post sort gridview + /// + /// + /// + protected void grView_Sorted(object sender, EventArgs e) + { + // sistemazione dell'ods post evento sort + checkFixOds(); + } + #endregion } diff --git a/GMW/GMW/WebUserControls/mod_anagCelle.ascx.designer.cs b/GMW/GMW/WebUserControls/mod_anagCelle.ascx.designer.cs index ef57fe96..f46fb662 100644 --- a/GMW/GMW/WebUserControls/mod_anagCelle.ascx.designer.cs +++ b/GMW/GMW/WebUserControls/mod_anagCelle.ascx.designer.cs @@ -84,5 +84,23 @@ namespace GMW.WebUserControls { /// To modify move field declaration from designer file to code-behind file. /// protected global::System.Web.UI.WebControls.Label lblWarning; + + /// + /// odsBlocco control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.ObjectDataSource odsBlocco; + + /// + /// odsTipoCella control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.ObjectDataSource odsTipoCella; } } diff --git a/GMW/GMW/bin/GMW.dll b/GMW/GMW/bin/GMW.dll index 1b405811..a6d088eb 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 6dce9d00..6ebe2d59 100644 Binary files a/GMW/GMW/bin/GMW_data.dll and b/GMW/GMW/bin/GMW_data.dll differ diff --git a/GMW/GMW/obj/Debug/GMW.dll b/GMW/GMW/obj/Debug/GMW.dll index 1b405811..a6d088eb 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 7bd3011a..030d374a 100644 Binary files a/GMW/GMW/obj/Debug/ResolveAssemblyReference.cache and b/GMW/GMW/obj/Debug/ResolveAssemblyReference.cache differ diff --git a/GMW/GMW_data/DS_Utility.Designer.cs b/GMW/GMW_data/DS_Utility.Designer.cs index 3338415f..a1f25ddd 100644 --- a/GMW/GMW_data/DS_Utility.Designer.cs +++ b/GMW/GMW_data/DS_Utility.Designer.cs @@ -29,6 +29,8 @@ namespace GMW_data { private v_selBloccoDataTable tablev_selBlocco; + private v_selTipoCellaDataTable tablev_selTipoCella; + private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema; [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -61,6 +63,9 @@ namespace GMW_data { if ((ds.Tables["v_selBlocco"] != null)) { base.Tables.Add(new v_selBloccoDataTable(ds.Tables["v_selBlocco"])); } + if ((ds.Tables["v_selTipoCella"] != null)) { + base.Tables.Add(new v_selTipoCellaDataTable(ds.Tables["v_selTipoCella"])); + } this.DataSetName = ds.DataSetName; this.Prefix = ds.Prefix; this.Namespace = ds.Namespace; @@ -97,6 +102,15 @@ namespace GMW_data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Browsable(false)] + [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)] + public v_selTipoCellaDataTable v_selTipoCella { + get { + return this.tablev_selTipoCella; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.ComponentModel.BrowsableAttribute(true)] [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)] @@ -162,6 +176,9 @@ namespace GMW_data { if ((ds.Tables["v_selBlocco"] != null)) { base.Tables.Add(new v_selBloccoDataTable(ds.Tables["v_selBlocco"])); } + if ((ds.Tables["v_selTipoCella"] != null)) { + base.Tables.Add(new v_selTipoCellaDataTable(ds.Tables["v_selTipoCella"])); + } this.DataSetName = ds.DataSetName; this.Prefix = ds.Prefix; this.Namespace = ds.Namespace; @@ -204,6 +221,12 @@ namespace GMW_data { this.tablev_selBlocco.InitVars(); } } + this.tablev_selTipoCella = ((v_selTipoCellaDataTable)(base.Tables["v_selTipoCella"])); + if ((initTable == true)) { + if ((this.tablev_selTipoCella != null)) { + this.tablev_selTipoCella.InitVars(); + } + } } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -217,6 +240,8 @@ namespace GMW_data { base.Tables.Add(this.tablev_selMag); this.tablev_selBlocco = new v_selBloccoDataTable(); base.Tables.Add(this.tablev_selBlocco); + this.tablev_selTipoCella = new v_selTipoCellaDataTable(); + base.Tables.Add(this.tablev_selTipoCella); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -229,6 +254,11 @@ namespace GMW_data { return false; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + private bool ShouldSerializev_selTipoCella() { + return false; + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) { if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) { @@ -286,6 +316,8 @@ namespace GMW_data { public delegate void v_selBloccoRowChangeEventHandler(object sender, v_selBloccoRowChangeEvent e); + public delegate void v_selTipoCellaRowChangeEventHandler(object sender, v_selTipoCellaRowChangeEvent e); + /// ///Represents the strongly named DataTable class. /// @@ -830,6 +862,288 @@ namespace GMW_data { } } + /// + ///Represents the strongly named DataTable class. + /// + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")] + [global::System.Serializable()] + [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")] + public partial class v_selTipoCellaDataTable : global::System.Data.TypedTableBase { + + private global::System.Data.DataColumn columnvalue; + + private global::System.Data.DataColumn columnlabel; + + private global::System.Data.DataColumn columnCodMag; + + private global::System.Data.DataColumn columnCodCS; + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaDataTable() { + this.TableName = "v_selTipoCella"; + this.BeginInit(); + this.InitClass(); + this.EndInit(); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + internal v_selTipoCellaDataTable(global::System.Data.DataTable table) { + this.TableName = table.TableName; + if ((table.CaseSensitive != table.DataSet.CaseSensitive)) { + this.CaseSensitive = table.CaseSensitive; + } + if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) { + this.Locale = table.Locale; + } + if ((table.Namespace != table.DataSet.Namespace)) { + this.Namespace = table.Namespace; + } + this.Prefix = table.Prefix; + this.MinimumCapacity = table.MinimumCapacity; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected v_selTipoCellaDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) : + base(info, context) { + this.InitVars(); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public global::System.Data.DataColumn valueColumn { + get { + return this.columnvalue; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public global::System.Data.DataColumn labelColumn { + get { + return this.columnlabel; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public global::System.Data.DataColumn CodMagColumn { + get { + return this.columnCodMag; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public global::System.Data.DataColumn CodCSColumn { + get { + return this.columnCodCS; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Browsable(false)] + public int Count { + get { + return this.Rows.Count; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaRow this[int index] { + get { + return ((v_selTipoCellaRow)(this.Rows[index])); + } + } + + public event v_selTipoCellaRowChangeEventHandler v_selTipoCellaRowChanging; + + public event v_selTipoCellaRowChangeEventHandler v_selTipoCellaRowChanged; + + public event v_selTipoCellaRowChangeEventHandler v_selTipoCellaRowDeleting; + + public event v_selTipoCellaRowChangeEventHandler v_selTipoCellaRowDeleted; + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public void Addv_selTipoCellaRow(v_selTipoCellaRow row) { + this.Rows.Add(row); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaRow Addv_selTipoCellaRow(string label, string CodMag, string CodCS) { + v_selTipoCellaRow rowv_selTipoCellaRow = ((v_selTipoCellaRow)(this.NewRow())); + object[] columnValuesArray = new object[] { + null, + label, + CodMag, + CodCS}; + rowv_selTipoCellaRow.ItemArray = columnValuesArray; + this.Rows.Add(rowv_selTipoCellaRow); + return rowv_selTipoCellaRow; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaRow FindByvalue(int value) { + return ((v_selTipoCellaRow)(this.Rows.Find(new object[] { + value}))); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public override global::System.Data.DataTable Clone() { + v_selTipoCellaDataTable cln = ((v_selTipoCellaDataTable)(base.Clone())); + cln.InitVars(); + return cln; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override global::System.Data.DataTable CreateInstance() { + return new v_selTipoCellaDataTable(); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + internal void InitVars() { + this.columnvalue = base.Columns["value"]; + this.columnlabel = base.Columns["label"]; + this.columnCodMag = base.Columns["CodMag"]; + this.columnCodCS = base.Columns["CodCS"]; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + private void InitClass() { + this.columnvalue = new global::System.Data.DataColumn("value", typeof(int), null, global::System.Data.MappingType.Element); + base.Columns.Add(this.columnvalue); + this.columnlabel = new global::System.Data.DataColumn("label", typeof(string), null, global::System.Data.MappingType.Element); + base.Columns.Add(this.columnlabel); + this.columnCodMag = new global::System.Data.DataColumn("CodMag", typeof(string), null, global::System.Data.MappingType.Element); + base.Columns.Add(this.columnCodMag); + this.columnCodCS = new global::System.Data.DataColumn("CodCS", typeof(string), null, global::System.Data.MappingType.Element); + base.Columns.Add(this.columnCodCS); + this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] { + this.columnvalue}, true)); + this.columnvalue.AutoIncrement = true; + this.columnvalue.AutoIncrementSeed = -1; + this.columnvalue.AutoIncrementStep = -1; + this.columnvalue.AllowDBNull = false; + this.columnvalue.ReadOnly = true; + this.columnvalue.Unique = true; + this.columnlabel.ReadOnly = true; + this.columnlabel.MaxLength = 162; + this.columnCodMag.AllowDBNull = false; + this.columnCodMag.MaxLength = 50; + this.columnCodCS.AllowDBNull = false; + this.columnCodCS.MaxLength = 2; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaRow Newv_selTipoCellaRow() { + return ((v_selTipoCellaRow)(this.NewRow())); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) { + return new v_selTipoCellaRow(builder); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override global::System.Type GetRowType() { + return typeof(v_selTipoCellaRow); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) { + base.OnRowChanged(e); + if ((this.v_selTipoCellaRowChanged != null)) { + this.v_selTipoCellaRowChanged(this, new v_selTipoCellaRowChangeEvent(((v_selTipoCellaRow)(e.Row)), e.Action)); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) { + base.OnRowChanging(e); + if ((this.v_selTipoCellaRowChanging != null)) { + this.v_selTipoCellaRowChanging(this, new v_selTipoCellaRowChangeEvent(((v_selTipoCellaRow)(e.Row)), e.Action)); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) { + base.OnRowDeleted(e); + if ((this.v_selTipoCellaRowDeleted != null)) { + this.v_selTipoCellaRowDeleted(this, new v_selTipoCellaRowChangeEvent(((v_selTipoCellaRow)(e.Row)), e.Action)); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) { + base.OnRowDeleting(e); + if ((this.v_selTipoCellaRowDeleting != null)) { + this.v_selTipoCellaRowDeleting(this, new v_selTipoCellaRowChangeEvent(((v_selTipoCellaRow)(e.Row)), e.Action)); + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public void Removev_selTipoCellaRow(v_selTipoCellaRow row) { + this.Rows.Remove(row); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) { + global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType(); + global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence(); + DS_Utility ds = new DS_Utility(); + global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny(); + any1.Namespace = "http://www.w3.org/2001/XMLSchema"; + any1.MinOccurs = new decimal(0); + any1.MaxOccurs = decimal.MaxValue; + any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax; + sequence.Items.Add(any1); + global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny(); + any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1"; + any2.MinOccurs = new decimal(1); + any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax; + sequence.Items.Add(any2); + global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute(); + attribute1.Name = "namespace"; + attribute1.FixedValue = ds.Namespace; + type.Attributes.Add(attribute1); + global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute(); + attribute2.Name = "tableTypeName"; + attribute2.FixedValue = "v_selTipoCellaDataTable"; + type.Attributes.Add(attribute2); + type.Particle = sequence; + global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable(); + if (xs.Contains(dsSchema.TargetNamespace)) { + global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream(); + global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream(); + try { + global::System.Xml.Schema.XmlSchema schema = null; + dsSchema.Write(s1); + for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) { + schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current)); + s2.SetLength(0); + schema.Write(s2); + if ((s1.Length == s2.Length)) { + s1.Position = 0; + s2.Position = 0; + for (; ((s1.Position != s1.Length) + && (s1.ReadByte() == s2.ReadByte())); ) { + ; + } + if ((s1.Position == s1.Length)) { + return type; + } + } + } + } + finally { + if ((s1 != null)) { + s1.Close(); + } + if ((s2 != null)) { + s2.Close(); + } + } + } + xs.Add(dsSchema); + return type; + } + } + /// ///Represents strongly named DataRow class. /// @@ -990,6 +1304,76 @@ namespace GMW_data { } } + /// + ///Represents strongly named DataRow class. + /// + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")] + public partial class v_selTipoCellaRow : global::System.Data.DataRow { + + private v_selTipoCellaDataTable tablev_selTipoCella; + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + internal v_selTipoCellaRow(global::System.Data.DataRowBuilder rb) : + base(rb) { + this.tablev_selTipoCella = ((v_selTipoCellaDataTable)(this.Table)); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public int value { + get { + return ((int)(this[this.tablev_selTipoCella.valueColumn])); + } + set { + this[this.tablev_selTipoCella.valueColumn] = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public string label { + get { + try { + return ((string)(this[this.tablev_selTipoCella.labelColumn])); + } + catch (global::System.InvalidCastException e) { + throw new global::System.Data.StrongTypingException("The value for column \'label\' in table \'v_selTipoCella\' is DBNull.", e); + } + } + set { + this[this.tablev_selTipoCella.labelColumn] = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public string CodMag { + get { + return ((string)(this[this.tablev_selTipoCella.CodMagColumn])); + } + set { + this[this.tablev_selTipoCella.CodMagColumn] = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public string CodCS { + get { + return ((string)(this[this.tablev_selTipoCella.CodCSColumn])); + } + set { + this[this.tablev_selTipoCella.CodCSColumn] = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public bool IslabelNull() { + return this.IsNull(this.tablev_selTipoCella.labelColumn); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public void SetlabelNull() { + this[this.tablev_selTipoCella.labelColumn] = global::System.Convert.DBNull; + } + } + /// ///Row event argument class /// @@ -1051,6 +1435,37 @@ namespace GMW_data { } } } + + /// + ///Row event argument class + /// + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")] + public class v_selTipoCellaRowChangeEvent : global::System.EventArgs { + + private v_selTipoCellaRow eventRow; + + private global::System.Data.DataRowAction eventAction; + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaRowChangeEvent(v_selTipoCellaRow row, global::System.Data.DataRowAction action) { + this.eventRow = row; + this.eventAction = action; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaRow Row { + get { + return this.eventRow; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public global::System.Data.DataRowAction Action { + get { + return this.eventAction; + } + } + } } } namespace GMW_data.DS_UtilityTableAdapters { @@ -1426,6 +1841,212 @@ namespace GMW_data.DS_UtilityTableAdapters { } } + /// + ///Represents the connection and commands used to retrieve and save data. + /// + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "2.0.0.0")] + [global::System.ComponentModel.DesignerCategoryAttribute("code")] + [global::System.ComponentModel.ToolboxItem(true)] + [global::System.ComponentModel.DataObjectAttribute(true)] + [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" + + ", Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + public partial class v_selTipoCellaTableAdapter : global::System.ComponentModel.Component { + + private global::System.Data.SqlClient.SqlDataAdapter _adapter; + + private global::System.Data.SqlClient.SqlConnection _connection; + + private global::System.Data.SqlClient.SqlTransaction _transaction; + + private global::System.Data.SqlClient.SqlCommand[] _commandCollection; + + private bool _clearBeforeFill; + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public v_selTipoCellaTableAdapter() { + this.ClearBeforeFill = true; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected internal global::System.Data.SqlClient.SqlDataAdapter Adapter { + get { + if ((this._adapter == null)) { + this.InitAdapter(); + } + return this._adapter; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + internal global::System.Data.SqlClient.SqlConnection Connection { + get { + if ((this._connection == null)) { + this.InitConnection(); + } + return this._connection; + } + set { + this._connection = value; + if ((this.Adapter.InsertCommand != null)) { + this.Adapter.InsertCommand.Connection = value; + } + if ((this.Adapter.DeleteCommand != null)) { + this.Adapter.DeleteCommand.Connection = value; + } + if ((this.Adapter.UpdateCommand != null)) { + this.Adapter.UpdateCommand.Connection = value; + } + for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) { + if ((this.CommandCollection[i] != null)) { + ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[i])).Connection = value; + } + } + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + internal global::System.Data.SqlClient.SqlTransaction Transaction { + get { + return this._transaction; + } + set { + this._transaction = value; + for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) { + this.CommandCollection[i].Transaction = this._transaction; + } + if (((this.Adapter != null) + && (this.Adapter.DeleteCommand != null))) { + this.Adapter.DeleteCommand.Transaction = this._transaction; + } + if (((this.Adapter != null) + && (this.Adapter.InsertCommand != null))) { + this.Adapter.InsertCommand.Transaction = this._transaction; + } + if (((this.Adapter != null) + && (this.Adapter.UpdateCommand != null))) { + this.Adapter.UpdateCommand.Transaction = this._transaction; + } + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + protected global::System.Data.SqlClient.SqlCommand[] CommandCollection { + get { + if ((this._commandCollection == null)) { + this.InitCommandCollection(); + } + return this._commandCollection; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + public bool ClearBeforeFill { + get { + return this._clearBeforeFill; + } + set { + this._clearBeforeFill = value; + } + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + private void InitAdapter() { + this._adapter = new global::System.Data.SqlClient.SqlDataAdapter(); + global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping(); + tableMapping.SourceTable = "Table"; + tableMapping.DataSetTable = "v_selTipoCella"; + tableMapping.ColumnMappings.Add("value", "value"); + tableMapping.ColumnMappings.Add("label", "label"); + tableMapping.ColumnMappings.Add("CodMag", "CodMag"); + tableMapping.ColumnMappings.Add("CodCS", "CodCS"); + this._adapter.TableMappings.Add(tableMapping); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + private void InitConnection() { + this._connection = new global::System.Data.SqlClient.SqlConnection(); + this._connection.ConnectionString = global::GMW_data.Properties.Settings.Default.GMWConnectionString; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + private void InitCommandCollection() { + this._commandCollection = new global::System.Data.SqlClient.SqlCommand[3]; + this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand(); + this._commandCollection[0].Connection = this.Connection; + this._commandCollection[0].CommandText = "SELECT value, label, CodMag, CodCS FROM dbo.v_selTipoCella"; + this._commandCollection[0].CommandType = global::System.Data.CommandType.Text; + this._commandCollection[1] = new global::System.Data.SqlClient.SqlCommand(); + this._commandCollection[1].Connection = this.Connection; + this._commandCollection[1].CommandText = "SELECT value, label, CodMag, CodCS\r\nFROM v_selTipoCella\r\nWHERE " + + " (CodMag = @CodMag) AND (CodCS = @CodCS)"; + this._commandCollection[1].CommandType = global::System.Data.CommandType.Text; + this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "CodMag", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.NChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, "CodCS", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[2] = new global::System.Data.SqlClient.SqlCommand(); + this._commandCollection[2].Connection = this.Connection; + this._commandCollection[2].CommandText = "SELECT value, label, CodMag, CodCS\r\nFROM v_selTipoCella\r\nWHERE " + + " (value = @value)"; + this._commandCollection[2].CommandType = global::System.Data.CommandType.Text; + this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@value", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "value", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)] + public virtual int Fill(DS_Utility.v_selTipoCellaDataTable dataTable) { + this.Adapter.SelectCommand = this.CommandCollection[0]; + if ((this.ClearBeforeFill == true)) { + dataTable.Clear(); + } + int returnValue = this.Adapter.Fill(dataTable); + return returnValue; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)] + public virtual DS_Utility.v_selTipoCellaDataTable GetData() { + this.Adapter.SelectCommand = this.CommandCollection[0]; + DS_Utility.v_selTipoCellaDataTable dataTable = new DS_Utility.v_selTipoCellaDataTable(); + this.Adapter.Fill(dataTable); + return dataTable; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)] + public virtual DS_Utility.v_selTipoCellaDataTable getByConditio(string CodMag, string CodCS) { + this.Adapter.SelectCommand = this.CommandCollection[1]; + if ((CodMag == null)) { + throw new global::System.ArgumentNullException("CodMag"); + } + else { + this.Adapter.SelectCommand.Parameters[0].Value = ((string)(CodMag)); + } + if ((CodCS == null)) { + throw new global::System.ArgumentNullException("CodCS"); + } + else { + this.Adapter.SelectCommand.Parameters[1].Value = ((string)(CodCS)); + } + DS_Utility.v_selTipoCellaDataTable dataTable = new DS_Utility.v_selTipoCellaDataTable(); + this.Adapter.Fill(dataTable); + return dataTable; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)] + public virtual DS_Utility.v_selTipoCellaDataTable getByValue(int value) { + this.Adapter.SelectCommand = this.CommandCollection[2]; + this.Adapter.SelectCommand.Parameters[0].Value = ((int)(value)); + DS_Utility.v_selTipoCellaDataTable dataTable = new DS_Utility.v_selTipoCellaDataTable(); + this.Adapter.Fill(dataTable); + return dataTable; + } + } + /// ///Represents the connection and commands used to retrieve and save data. /// @@ -1478,29 +2099,30 @@ namespace GMW_data.DS_UtilityTableAdapters { ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[2])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@DeltaCelle", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.InputOutput, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[3] = new global::System.Data.SqlClient.SqlCommand(); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Connection = new global::System.Data.SqlClient.SqlConnection(global::GMW_data.Properties.Settings.Default.GMWConnectionString); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).CommandText = "dbo.stp_celleCreaMancantiBlocco"; + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).CommandText = "dbo.stp_ContaCelleBlocco"; ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).CommandType = global::System.Data.CommandType.StoredProcedure; ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.VarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IdxBlocco", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@FiltAttive", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@PosAssegnata", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[3])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@TotCelle", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.InputOutput, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[4] = new global::System.Data.SqlClient.SqlCommand(); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Connection = new global::System.Data.SqlClient.SqlConnection(global::GMW_data.Properties.Settings.Default.GMWConnectionString); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).CommandText = "dbo.stp_ContaCelleBlocco"; + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).CommandText = "dbo.stp_ContaCelleCreate"; ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).CommandType = global::System.Data.CommandType.StoredProcedure; ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.VarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@FiltAttive", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@PosAssegnata", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[4])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@TotCelle", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.InputOutput, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[5] = new global::System.Data.SqlClient.SqlCommand(); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).Connection = new global::System.Data.SqlClient.SqlConnection(global::GMW_data.Properties.Settings.Default.GMWConnectionString); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).CommandText = "dbo.stp_ContaCelleCreate"; + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).CommandText = "dbo.stp_celleCreaMancantiBlocco"; ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).CommandType = global::System.Data.CommandType.StoredProcedure; ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.VarChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@TotCelle", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.InputOutput, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + ((global::System.Data.SqlClient.SqlCommand)(this._commandCollection[5])).Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IdxBlocco", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -1635,43 +2257,10 @@ namespace GMW_data.DS_UtilityTableAdapters { return returnValue; } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - public virtual int stp_celleCreaMancantiBlocco(string CodCS, global::System.Nullable IdxBlocco) { - global::System.Data.SqlClient.SqlCommand command = ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[3])); - if ((CodCS == null)) { - command.Parameters[1].Value = global::System.DBNull.Value; - } - else { - command.Parameters[1].Value = ((string)(CodCS)); - } - if ((IdxBlocco.HasValue == true)) { - command.Parameters[2].Value = ((int)(IdxBlocco.Value)); - } - else { - command.Parameters[2].Value = global::System.DBNull.Value; - } - global::System.Data.ConnectionState previousConnectionState = command.Connection.State; - if (((command.Connection.State & global::System.Data.ConnectionState.Open) - != global::System.Data.ConnectionState.Open)) { - command.Connection.Open(); - } - int returnValue; - try { - returnValue = command.ExecuteNonQuery(); - } - finally { - if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { - command.Connection.Close(); - } - } - return returnValue; - } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] public virtual int stp_ContaCelleBlocco(string CodCS, string CodMag, global::System.Nullable FiltAttive, global::System.Nullable PosAssegnata, ref global::System.Nullable TotCelle) { - global::System.Data.SqlClient.SqlCommand command = ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[4])); + global::System.Data.SqlClient.SqlCommand command = ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[3])); if ((CodCS == null)) { command.Parameters[1].Value = global::System.DBNull.Value; } @@ -1729,7 +2318,7 @@ namespace GMW_data.DS_UtilityTableAdapters { [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] public virtual int stp_ContaCelleCreate(string CodCS, string CodMag, ref global::System.Nullable TotCelle) { - global::System.Data.SqlClient.SqlCommand command = ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[5])); + global::System.Data.SqlClient.SqlCommand command = ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[4])); if ((CodCS == null)) { command.Parameters[1].Value = global::System.DBNull.Value; } @@ -1771,6 +2360,45 @@ namespace GMW_data.DS_UtilityTableAdapters { } return returnValue; } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + public virtual int stp_celleCreaMancantiBlocco(string CodCS, string CodMag, global::System.Nullable IdxBlocco) { + global::System.Data.SqlClient.SqlCommand command = ((global::System.Data.SqlClient.SqlCommand)(this.CommandCollection[5])); + if ((CodCS == null)) { + command.Parameters[1].Value = global::System.DBNull.Value; + } + else { + command.Parameters[1].Value = ((string)(CodCS)); + } + if ((CodMag == null)) { + command.Parameters[2].Value = global::System.DBNull.Value; + } + else { + command.Parameters[2].Value = ((string)(CodMag)); + } + if ((IdxBlocco.HasValue == true)) { + command.Parameters[3].Value = ((int)(IdxBlocco.Value)); + } + else { + command.Parameters[3].Value = global::System.DBNull.Value; + } + global::System.Data.ConnectionState previousConnectionState = command.Connection.State; + if (((command.Connection.State & global::System.Data.ConnectionState.Open) + != global::System.Data.ConnectionState.Open)) { + command.Connection.Open(); + } + int returnValue; + try { + returnValue = command.ExecuteNonQuery(); + } + finally { + if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { + command.Connection.Close(); + } + } + return returnValue; + } } /// diff --git a/GMW/GMW_data/DS_Utility.xsd b/GMW/GMW_data/DS_Utility.xsd index 9e43853c..8fc7d20b 100644 --- a/GMW/GMW_data/DS_Utility.xsd +++ b/GMW/GMW_data/DS_Utility.xsd @@ -72,6 +72,51 @@ WHERE (CodCS = @CodCS) AND (CodMag = @CodMag) + + + + + + SELECT value, label, CodMag, CodCS FROM dbo.v_selTipoCella + + + + + + + + + + + + + + + + SELECT value, label, CodMag, CodCS +FROM v_selTipoCella +WHERE (CodMag = @CodMag) AND (CodCS = @CodCS) + + + + + + + + + + + SELECT value, label, CodMag, CodCS +FROM v_selTipoCella +WHERE (value = @value) + + + + + + + + @@ -112,18 +157,6 @@ WHERE (CodCS = @CodCS) AND (CodMag = @CodMag) - - - - dbo.stp_celleCreaMancantiBlocco - - - - - - - - @@ -152,6 +185,19 @@ WHERE (CodCS = @CodCS) AND (CodMag = @CodMag) + + + + dbo.stp_celleCreaMancantiBlocco + + + + + + + + + @@ -214,6 +260,34 @@ WHERE (CodCS = @CodCS) AND (CodMag = @CodMag) + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -225,5 +299,9 @@ WHERE (CodCS = @CodCS) AND (CodMag = @CodMag) + + + + \ No newline at end of file diff --git a/GMW/GMW_data/DS_Utility.xss b/GMW/GMW_data/DS_Utility.xss index 75595718..2eb8b41f 100644 --- a/GMW/GMW_data/DS_Utility.xss +++ b/GMW/GMW_data/DS_Utility.xss @@ -6,9 +6,10 @@ --> - - - + + + + \ No newline at end of file diff --git a/GMW/GMW_data/DS_magazzino.Designer.cs b/GMW/GMW_data/DS_magazzino.Designer.cs index 3046e0a9..90241669 100644 --- a/GMW/GMW_data/DS_magazzino.Designer.cs +++ b/GMW/GMW_data/DS_magazzino.Designer.cs @@ -9007,7 +9007,7 @@ SELECT IdxTipoCella, CodMag, CodCS, Quantita, Capienza, Max_X, Max_Y, Max_Z, Max [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] private void InitCommandCollection() { - this._commandCollection = new global::System.Data.SqlClient.SqlCommand[4]; + this._commandCollection = new global::System.Data.SqlClient.SqlCommand[5]; this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[0].Connection = this.Connection; this._commandCollection[0].CommandText = "SELECT IdxTipoCella, CodMag, CodCS, Quantita, Capienza, Max_X, Max_Y, Max_Z, Max_" + @@ -9027,19 +9027,25 @@ SELECT IdxTipoCella, CodMag, CodCS, Quantita, Capienza, Max_X, Max_Y, Max_Z, Max this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[3] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[3].Connection = this.Connection; - this._commandCollection[3].CommandText = "UPDATE [dbo].[TipoCella] SET [CodMag] = @CodMag, [CodCS] = @CodCS, [Quantita] = @" + + this._commandCollection[3].CommandText = "dbo.stp_TipoCellaGetByIdx"; + this._commandCollection[3].CommandType = global::System.Data.CommandType.StoredProcedure; + this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@RETURN_VALUE", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.ReturnValue, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IdxTipoCella", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4] = new global::System.Data.SqlClient.SqlCommand(); + this._commandCollection[4].Connection = this.Connection; + this._commandCollection[4].CommandText = "UPDATE [dbo].[TipoCella] SET [CodMag] = @CodMag, [CodCS] = @CodCS, [Quantita] = @" + "Quantita, [Capienza] = @Capienza, [Max_X] = @Max_X, [Max_Y] = @Max_Y, [Max_Z] = " + "@Max_Z, [Max_Kg] = @Max_Kg WHERE ([IdxTipoCella] = @Original_IdxTipoCella)"; - this._commandCollection[3].CommandType = global::System.Data.CommandType.Text; - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "CodMag", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.NChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, "CodCS", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Quantita", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "Quantita", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Capienza", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "Capienza", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_X", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_X", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_Y", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_Y", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_Z", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_Z", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_Kg", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_Kg", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_IdxTipoCella", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "IdxTipoCella", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); + this._commandCollection[4].CommandType = global::System.Data.CommandType.Text; + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodMag", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, "CodMag", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodCS", global::System.Data.SqlDbType.NChar, 2, global::System.Data.ParameterDirection.Input, 0, 0, "CodCS", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Quantita", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "Quantita", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Capienza", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "Capienza", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_X", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_X", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_Y", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_Y", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_Z", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_Z", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Max_Kg", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 0, 0, "Max_Kg", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_IdxTipoCella", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "IdxTipoCella", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -9086,6 +9092,22 @@ SELECT IdxTipoCella, CodMag, CodCS, Quantita, Capienza, Max_X, Max_Y, Max_Z, Max return dataTable; } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)] + public virtual DS_magazzino.TipoCellaDataTable getByIdx(global::System.Nullable IdxTipoCella) { + this.Adapter.SelectCommand = this.CommandCollection[3]; + if ((IdxTipoCella.HasValue == true)) { + this.Adapter.SelectCommand.Parameters[1].Value = ((int)(IdxTipoCella.Value)); + } + else { + this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value; + } + DS_magazzino.TipoCellaDataTable dataTable = new DS_magazzino.TipoCellaDataTable(); + this.Adapter.Fill(dataTable); + return dataTable; + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] public virtual int Update(DS_magazzino.TipoCellaDataTable dataTable) { @@ -9411,7 +9433,7 @@ SELECT IdxTipoCella, CodMag, CodCS, Quantita, Capienza, Max_X, Max_Y, Max_Z, Max [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, false)] public virtual int UpdateQuery(string CodMag, string CodCS, int Quantita, int Capienza, global::System.Nullable Max_X, global::System.Nullable Max_Y, global::System.Nullable Max_Z, global::System.Nullable Max_Kg, int Original_IdxTipoCella) { - global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[3]; + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[4]; if ((CodMag == null)) { throw new global::System.ArgumentNullException("CodMag"); } diff --git a/GMW/GMW_data/DS_magazzino.xsd b/GMW/GMW_data/DS_magazzino.xsd index 16090eb4..2eaf24f9 100644 --- a/GMW/GMW_data/DS_magazzino.xsd +++ b/GMW/GMW_data/DS_magazzino.xsd @@ -871,6 +871,17 @@ WHERE (IdxTipoCella = @Original_IdxTipoCella) + + + + dbo.stp_TipoCellaGetByIdx + + + + + + + diff --git a/GMW/GMW_data/DS_magazzino.xss b/GMW/GMW_data/DS_magazzino.xss index 93c9ccd6..bc7f633a 100644 --- a/GMW/GMW_data/DS_magazzino.xss +++ b/GMW/GMW_data/DS_magazzino.xss @@ -4,15 +4,15 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + - + - + @@ -83,7 +83,7 @@ 1107 - 303 + 322 diff --git a/GMW/GMW_data/bin/Debug/GMW_data.dll b/GMW/GMW_data/bin/Debug/GMW_data.dll index 6dce9d00..6ebe2d59 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/obj/Debug/GMW_data.dll b/GMW/GMW_data/obj/Debug/GMW_data.dll index 6dce9d00..6ebe2d59 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_Utility.Designer.cs.dll b/GMW/GMW_data/obj/Debug/TempPE/DS_Utility.Designer.cs.dll index cdd29b80..d694e506 100644 Binary files a/GMW/GMW_data/obj/Debug/TempPE/DS_Utility.Designer.cs.dll and b/GMW/GMW_data/obj/Debug/TempPE/DS_Utility.Designer.cs.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 e080dcc5..918cb607 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/utils.cs b/GMW/GMW_data/utils.cs index 8379870a..81dbc5c0 100644 --- a/GMW/GMW_data/utils.cs +++ b/GMW/GMW_data/utils.cs @@ -9,10 +9,11 @@ namespace GMW_data { public class utils { - #region area table adapters + #region area table adapters public DS_UtilityTableAdapters.STP taSTP; - + public DS_UtilityTableAdapters.v_selTipoCellaTableAdapter taSelTipoCella; + /// /// init dei table adapters @@ -20,6 +21,7 @@ namespace GMW_data protected void initTA() { taSTP = new GMW_data.DS_UtilityTableAdapters.STP(); + taSelTipoCella = new GMW_data.DS_UtilityTableAdapters.v_selTipoCellaTableAdapter(); } /// /// effettua setup dei connection strings da web.config delal singola applicazione @@ -28,6 +30,7 @@ namespace GMW_data { // connections del db //taSTP.Connection.ConnectionString = memLayer.ML.confReadString("GMWConnectionString"); + taSelTipoCella.Connection.ConnectionString = memLayer.ML.confReadString("GMWConnectionString"); } #endregion