diff --git a/CMS-SC-Data/DS_Applicazione.xsd b/CMS-SC-Data/DS_Applicazione.xsd index d15efd5..c536abe 100644 --- a/CMS-SC-Data/DS_Applicazione.xsd +++ b/CMS-SC-Data/DS_Applicazione.xsd @@ -65,64 +65,13 @@ FROM v_ElencoFamMacc - - - - DELETE FROM [dbo].[ElencoMacchineCN] WHERE (([Matricola] = @Original_Matricola) AND ([Descrizione] = @Original_Descrizione) AND ([Cliente] = @Original_Cliente) AND ([CodFam] = @Original_CodFam) AND ([CorsaX] = @Original_CorsaX) AND ([CorsaY] = @Original_CorsaY) AND ([CorsaZ] = @Original_CorsaZ)) - - - - - - - - - - - - - - INSERT INTO [dbo].[ElencoMacchineCN] ([Matricola], [Descrizione], [Cliente], [CodFam], [CorsaX], [CorsaY], [CorsaZ]) VALUES (@Matricola, @Descrizione, @Cliente, @CodFam, @CorsaX, @CorsaY, @CorsaZ); -SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM ElencoMacchineCN WHERE (Matricola = @Matricola) - - - - - - - - - - - + - SELECT * FROM dbo.ElencoMacchineCN + SELECT * FROM v_ElencoMacchine - - - UPDATE [dbo].[ElencoMacchineCN] SET [Matricola] = @Matricola, [Descrizione] = @Descrizione, [Cliente] = @Cliente, [CodFam] = @CodFam, [CorsaX] = @CorsaX, [CorsaY] = @CorsaY, [CorsaZ] = @CorsaZ WHERE (([Matricola] = @Original_Matricola) AND ([Descrizione] = @Original_Descrizione) AND ([Cliente] = @Original_Cliente) AND ([CodFam] = @Original_CodFam) AND ([CorsaX] = @Original_CorsaX) AND ([CorsaY] = @Original_CorsaY) AND ([CorsaZ] = @Original_CorsaZ)); -SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM ElencoMacchineCN WHERE (Matricola = @Matricola) - - - - - - - - - - - - - - - - - - @@ -133,6 +82,7 @@ SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM Elen + @@ -1375,7 +1325,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1396,7 +1346,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1430,10 +1380,11 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) + - + @@ -1453,7 +1404,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1495,7 +1446,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1544,7 +1495,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1569,7 +1520,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1626,7 +1577,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1672,7 +1623,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1709,7 +1660,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1802,7 +1753,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1916,7 +1867,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -1936,7 +1887,7 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - + @@ -2026,18 +1977,18 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode) - - - - - - - - - - - - + + + + + + + + + + + + \ No newline at end of file diff --git a/CMS-SC-Data/DS_Applicazione.xss b/CMS-SC-Data/DS_Applicazione.xss index 377d501..62083ee 100644 --- a/CMS-SC-Data/DS_Applicazione.xss +++ b/CMS-SC-Data/DS_Applicazione.xss @@ -4,21 +4,21 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + - - - - - - - - - - - - + + + + + + + + + + + + @@ -81,19 +81,19 @@ - + - 1195 - 254 + 1226 + 273 - 1195 - 261 + 1226 + 325 - + 367 @@ -105,19 +105,19 @@ - + - 1061 - 379 + 1070 + 443 1018 - 379 + 443 - + 1096 @@ -129,7 +129,7 @@ - + 807 @@ -141,7 +141,7 @@ - + 1329 @@ -153,7 +153,7 @@ - + 1476 diff --git a/CMS-SC-Data/DS_Applicazione1.Designer.cs b/CMS-SC-Data/DS_Applicazione1.Designer.cs index 86064da..3ba1980 100644 --- a/CMS-SC-Data/DS_Applicazione1.Designer.cs +++ b/CMS-SC-Data/DS_Applicazione1.Designer.cs @@ -1102,6 +1102,8 @@ namespace CMS_SC_Data { private global::System.Data.DataColumn columnCorsaZ; + private global::System.Data.DataColumn columnIdxDossier; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] public ElencoMacchineCNDataTable() { @@ -1191,6 +1193,14 @@ namespace CMS_SC_Data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] + public global::System.Data.DataColumn IdxDossierColumn { + get { + return this.columnIdxDossier; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] [global::System.ComponentModel.Browsable(false)] @@ -1228,7 +1238,7 @@ namespace CMS_SC_Data { [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - public ElencoMacchineCNRow AddElencoMacchineCNRow(string Matricola, string Descrizione, string Cliente, ElencoFamMaccRow parentElencoFamMaccRowByFK_ElencoMacchineCN_ElencoFamMacc, int CorsaX, int CorsaY, int CorsaZ) { + public ElencoMacchineCNRow AddElencoMacchineCNRow(string Matricola, string Descrizione, string Cliente, ElencoFamMaccRow parentElencoFamMaccRowByFK_ElencoMacchineCN_ElencoFamMacc, int CorsaX, int CorsaY, int CorsaZ, int IdxDossier) { ElencoMacchineCNRow rowElencoMacchineCNRow = ((ElencoMacchineCNRow)(this.NewRow())); object[] columnValuesArray = new object[] { Matricola, @@ -1237,7 +1247,8 @@ namespace CMS_SC_Data { null, CorsaX, CorsaY, - CorsaZ}; + CorsaZ, + IdxDossier}; if ((parentElencoFamMaccRowByFK_ElencoMacchineCN_ElencoFamMacc != null)) { columnValuesArray[3] = parentElencoFamMaccRowByFK_ElencoMacchineCN_ElencoFamMacc[0]; } @@ -1277,6 +1288,7 @@ namespace CMS_SC_Data { this.columnCorsaX = base.Columns["CorsaX"]; this.columnCorsaY = base.Columns["CorsaY"]; this.columnCorsaZ = base.Columns["CorsaZ"]; + this.columnIdxDossier = base.Columns["IdxDossier"]; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -1296,6 +1308,8 @@ namespace CMS_SC_Data { base.Columns.Add(this.columnCorsaY); this.columnCorsaZ = new global::System.Data.DataColumn("CorsaZ", typeof(int), null, global::System.Data.MappingType.Element); base.Columns.Add(this.columnCorsaZ); + this.columnIdxDossier = new global::System.Data.DataColumn("IdxDossier", typeof(int), null, global::System.Data.MappingType.Element); + base.Columns.Add(this.columnIdxDossier); this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] { this.columnMatricola}, true)); this.columnMatricola.AllowDBNull = false; @@ -1310,6 +1324,7 @@ namespace CMS_SC_Data { this.columnCorsaX.AllowDBNull = false; this.columnCorsaY.AllowDBNull = false; this.columnCorsaZ.AllowDBNull = false; + this.columnIdxDossier.ReadOnly = true; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -5871,6 +5886,22 @@ namespace CMS_SC_Data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] + public int IdxDossier { + get { + try { + return ((int)(this[this.tableElencoMacchineCN.IdxDossierColumn])); + } + catch (global::System.InvalidCastException e) { + throw new global::System.Data.StrongTypingException("The value for column \'IdxDossier\' in table \'ElencoMacchineCN\' is DBNull.", e); + } + } + set { + this[this.tableElencoMacchineCN.IdxDossierColumn] = value; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] public ElencoFamMaccRow ElencoFamMaccRow { @@ -5882,6 +5913,18 @@ namespace CMS_SC_Data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] + public bool IsIdxDossierNull() { + return this.IsNull(this.tableElencoMacchineCN.IdxDossierColumn); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] + public void SetIdxDossierNull() { + this[this.tableElencoMacchineCN.IdxDossierColumn] = global::System.Convert.DBNull; + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] public ElencoDossierRow[] GetElencoDossierRows() { @@ -8606,49 +8649,8 @@ namespace CMS_SC_Data.DS_ApplicazioneTableAdapters { tableMapping.ColumnMappings.Add("CorsaX", "CorsaX"); tableMapping.ColumnMappings.Add("CorsaY", "CorsaY"); tableMapping.ColumnMappings.Add("CorsaZ", "CorsaZ"); + tableMapping.ColumnMappings.Add("IdxDossier", "IdxDossier"); this._adapter.TableMappings.Add(tableMapping); - this._adapter.DeleteCommand = new global::System.Data.SqlClient.SqlCommand(); - this._adapter.DeleteCommand.Connection = this.Connection; - this._adapter.DeleteCommand.CommandText = @"DELETE FROM [dbo].[ElencoMacchineCN] WHERE (([Matricola] = @Original_Matricola) AND ([Descrizione] = @Original_Descrizione) AND ([Cliente] = @Original_Cliente) AND ([CodFam] = @Original_CodFam) AND ([CorsaX] = @Original_CorsaX) AND ([CorsaY] = @Original_CorsaY) AND ([CorsaZ] = @Original_CorsaZ))"; - this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text; - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Matricola", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Matricola", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Descrizione", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Descrizione", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Cliente", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cliente", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CodFam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CodFam", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CorsaX", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaX", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CorsaY", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaY", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CorsaZ", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaZ", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.InsertCommand = new global::System.Data.SqlClient.SqlCommand(); - this._adapter.InsertCommand.Connection = this.Connection; - this._adapter.InsertCommand.CommandText = @"INSERT INTO [dbo].[ElencoMacchineCN] ([Matricola], [Descrizione], [Cliente], [CodFam], [CorsaX], [CorsaY], [CorsaZ]) VALUES (@Matricola, @Descrizione, @Cliente, @CodFam, @CorsaX, @CorsaY, @CorsaZ); -SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM ElencoMacchineCN WHERE (Matricola = @Matricola)"; - this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text; - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Matricola", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Matricola", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Descrizione", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Descrizione", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Cliente", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cliente", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodFam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CodFam", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CorsaX", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaX", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CorsaY", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaY", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CorsaZ", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaZ", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand = new global::System.Data.SqlClient.SqlCommand(); - this._adapter.UpdateCommand.Connection = this.Connection; - this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[ElencoMacchineCN] SET [Matricola] = @Matricola, [Descrizione] = @Descrizione, [Cliente] = @Cliente, [CodFam] = @CodFam, [CorsaX] = @CorsaX, [CorsaY] = @CorsaY, [CorsaZ] = @CorsaZ WHERE (([Matricola] = @Original_Matricola) AND ([Descrizione] = @Original_Descrizione) AND ([Cliente] = @Original_Cliente) AND ([CodFam] = @Original_CodFam) AND ([CorsaX] = @Original_CorsaX) AND ([CorsaY] = @Original_CorsaY) AND ([CorsaZ] = @Original_CorsaZ)); -SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM ElencoMacchineCN WHERE (Matricola = @Matricola)"; - this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text; - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Matricola", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Matricola", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Descrizione", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Descrizione", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Cliente", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cliente", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodFam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CodFam", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CorsaX", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaX", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CorsaY", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaY", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CorsaZ", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaZ", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Matricola", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Matricola", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Descrizione", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Descrizione", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Cliente", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Cliente", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CodFam", global::System.Data.SqlDbType.NVarChar, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CodFam", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CorsaX", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaX", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CorsaY", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaY", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); - this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_CorsaZ", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "CorsaZ", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -8664,7 +8666,7 @@ SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM Elen 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 * FROM dbo.ElencoMacchineCN"; + this._commandCollection[0].CommandText = "SELECT * FROM v_ElencoMacchine"; this._commandCollection[0].CommandType = global::System.Data.CommandType.Text; this._commandCollection[1] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[1].Connection = this.Connection; @@ -8747,214 +8749,6 @@ SELECT Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ FROM Elen return dataTable; } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - public virtual int Update(DS_Applicazione.ElencoMacchineCNDataTable dataTable) { - return this.Adapter.Update(dataTable); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - public virtual int Update(DS_Applicazione dataSet) { - return this.Adapter.Update(dataSet, "ElencoMacchineCN"); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - public virtual int Update(global::System.Data.DataRow dataRow) { - return this.Adapter.Update(new global::System.Data.DataRow[] { - dataRow}); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - public virtual int Update(global::System.Data.DataRow[] dataRows) { - return this.Adapter.Update(dataRows); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)] - public virtual int Delete(string Original_Matricola, string Original_Descrizione, string Original_Cliente, string Original_CodFam, int Original_CorsaX, int Original_CorsaY, int Original_CorsaZ) { - if ((Original_Matricola == null)) { - throw new global::System.ArgumentNullException("Original_Matricola"); - } - else { - this.Adapter.DeleteCommand.Parameters[0].Value = ((string)(Original_Matricola)); - } - if ((Original_Descrizione == null)) { - throw new global::System.ArgumentNullException("Original_Descrizione"); - } - else { - this.Adapter.DeleteCommand.Parameters[1].Value = ((string)(Original_Descrizione)); - } - if ((Original_Cliente == null)) { - throw new global::System.ArgumentNullException("Original_Cliente"); - } - else { - this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_Cliente)); - } - if ((Original_CodFam == null)) { - throw new global::System.ArgumentNullException("Original_CodFam"); - } - else { - this.Adapter.DeleteCommand.Parameters[3].Value = ((string)(Original_CodFam)); - } - this.Adapter.DeleteCommand.Parameters[4].Value = ((int)(Original_CorsaX)); - this.Adapter.DeleteCommand.Parameters[5].Value = ((int)(Original_CorsaY)); - this.Adapter.DeleteCommand.Parameters[6].Value = ((int)(Original_CorsaZ)); - global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State; - if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open) - != global::System.Data.ConnectionState.Open)) { - this.Adapter.DeleteCommand.Connection.Open(); - } - try { - int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery(); - return returnValue; - } - finally { - if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { - this.Adapter.DeleteCommand.Connection.Close(); - } - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)] - public virtual int Insert(string Matricola, string Descrizione, string Cliente, string CodFam, int CorsaX, int CorsaY, int CorsaZ) { - if ((Matricola == null)) { - throw new global::System.ArgumentNullException("Matricola"); - } - else { - this.Adapter.InsertCommand.Parameters[0].Value = ((string)(Matricola)); - } - if ((Descrizione == null)) { - throw new global::System.ArgumentNullException("Descrizione"); - } - else { - this.Adapter.InsertCommand.Parameters[1].Value = ((string)(Descrizione)); - } - if ((Cliente == null)) { - throw new global::System.ArgumentNullException("Cliente"); - } - else { - this.Adapter.InsertCommand.Parameters[2].Value = ((string)(Cliente)); - } - if ((CodFam == null)) { - throw new global::System.ArgumentNullException("CodFam"); - } - else { - this.Adapter.InsertCommand.Parameters[3].Value = ((string)(CodFam)); - } - this.Adapter.InsertCommand.Parameters[4].Value = ((int)(CorsaX)); - this.Adapter.InsertCommand.Parameters[5].Value = ((int)(CorsaY)); - this.Adapter.InsertCommand.Parameters[6].Value = ((int)(CorsaZ)); - global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State; - if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open) - != global::System.Data.ConnectionState.Open)) { - this.Adapter.InsertCommand.Connection.Open(); - } - try { - int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery(); - return returnValue; - } - finally { - if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { - this.Adapter.InsertCommand.Connection.Close(); - } - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)] - public virtual int Update(string Matricola, string Descrizione, string Cliente, string CodFam, int CorsaX, int CorsaY, int CorsaZ, string Original_Matricola, string Original_Descrizione, string Original_Cliente, string Original_CodFam, int Original_CorsaX, int Original_CorsaY, int Original_CorsaZ) { - if ((Matricola == null)) { - throw new global::System.ArgumentNullException("Matricola"); - } - else { - this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(Matricola)); - } - if ((Descrizione == null)) { - throw new global::System.ArgumentNullException("Descrizione"); - } - else { - this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(Descrizione)); - } - if ((Cliente == null)) { - throw new global::System.ArgumentNullException("Cliente"); - } - else { - this.Adapter.UpdateCommand.Parameters[2].Value = ((string)(Cliente)); - } - if ((CodFam == null)) { - throw new global::System.ArgumentNullException("CodFam"); - } - else { - this.Adapter.UpdateCommand.Parameters[3].Value = ((string)(CodFam)); - } - this.Adapter.UpdateCommand.Parameters[4].Value = ((int)(CorsaX)); - this.Adapter.UpdateCommand.Parameters[5].Value = ((int)(CorsaY)); - this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(CorsaZ)); - if ((Original_Matricola == null)) { - throw new global::System.ArgumentNullException("Original_Matricola"); - } - else { - this.Adapter.UpdateCommand.Parameters[7].Value = ((string)(Original_Matricola)); - } - if ((Original_Descrizione == null)) { - throw new global::System.ArgumentNullException("Original_Descrizione"); - } - else { - this.Adapter.UpdateCommand.Parameters[8].Value = ((string)(Original_Descrizione)); - } - if ((Original_Cliente == null)) { - throw new global::System.ArgumentNullException("Original_Cliente"); - } - else { - this.Adapter.UpdateCommand.Parameters[9].Value = ((string)(Original_Cliente)); - } - if ((Original_CodFam == null)) { - throw new global::System.ArgumentNullException("Original_CodFam"); - } - else { - this.Adapter.UpdateCommand.Parameters[10].Value = ((string)(Original_CodFam)); - } - this.Adapter.UpdateCommand.Parameters[11].Value = ((int)(Original_CorsaX)); - this.Adapter.UpdateCommand.Parameters[12].Value = ((int)(Original_CorsaY)); - this.Adapter.UpdateCommand.Parameters[13].Value = ((int)(Original_CorsaZ)); - global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State; - if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open) - != global::System.Data.ConnectionState.Open)) { - this.Adapter.UpdateCommand.Connection.Open(); - } - try { - int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery(); - return returnValue; - } - finally { - if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { - this.Adapter.UpdateCommand.Connection.Close(); - } - } - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)] - public virtual int Update(string Descrizione, string Cliente, string CodFam, int CorsaX, int CorsaY, int CorsaZ, string Original_Matricola, string Original_Descrizione, string Original_Cliente, string Original_CodFam, int Original_CorsaX, int Original_CorsaY, int Original_CorsaZ) { - return this.Update(Original_Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ, Original_Matricola, Original_Descrizione, Original_Cliente, Original_CodFam, Original_CorsaX, Original_CorsaY, Original_CorsaZ); - } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] @@ -14680,8 +14474,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; private UpdateOrderOption _updateOrder; - private ElencoMacchineCNTableAdapter _elencoMacchineCNTableAdapter; - private AnagFasiTableAdapter _anagFasiTableAdapter; private AnagSchedeTableAdapter _anagSchedeTableAdapter; @@ -14711,20 +14503,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; } } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" + - "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" + - "a", "System.Drawing.Design.UITypeEditor")] - public ElencoMacchineCNTableAdapter ElencoMacchineCNTableAdapter { - get { - return this._elencoMacchineCNTableAdapter; - } - set { - this._elencoMacchineCNTableAdapter = value; - } - } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" + @@ -14842,10 +14620,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; if ((this._connection != null)) { return this._connection; } - if (((this._elencoMacchineCNTableAdapter != null) - && (this._elencoMacchineCNTableAdapter.Connection != null))) { - return this._elencoMacchineCNTableAdapter.Connection; - } if (((this._anagFasiTableAdapter != null) && (this._anagFasiTableAdapter.Connection != null))) { return this._anagFasiTableAdapter.Connection; @@ -14887,9 +14661,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; public int TableAdapterInstanceCount { get { int count = 0; - if ((this._elencoMacchineCNTableAdapter != null)) { - count = (count + 1); - } if ((this._anagFasiTableAdapter != null)) { count = (count + 1); } @@ -14922,15 +14693,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] private int UpdateUpdatedRows(DS_Applicazione dataSet, global::System.Collections.Generic.List allChangedRows, global::System.Collections.Generic.List allAddedRows) { int result = 0; - if ((this._elencoMacchineCNTableAdapter != null)) { - global::System.Data.DataRow[] updatedRows = dataSet.ElencoMacchineCN.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent); - updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows); - if (((updatedRows != null) - && (0 < updatedRows.Length))) { - result = (result + this._elencoMacchineCNTableAdapter.Update(updatedRows)); - allChangedRows.AddRange(updatedRows); - } - } if ((this._anagSchedeTableAdapter != null)) { global::System.Data.DataRow[] updatedRows = dataSet.AnagSchede.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent); updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows); @@ -15004,14 +14766,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] private int UpdateInsertedRows(DS_Applicazione dataSet, global::System.Collections.Generic.List allAddedRows) { int result = 0; - if ((this._elencoMacchineCNTableAdapter != null)) { - global::System.Data.DataRow[] addedRows = dataSet.ElencoMacchineCN.Select(null, null, global::System.Data.DataViewRowState.Added); - if (((addedRows != null) - && (0 < addedRows.Length))) { - result = (result + this._elencoMacchineCNTableAdapter.Update(addedRows)); - allAddedRows.AddRange(addedRows); - } - } if ((this._anagSchedeTableAdapter != null)) { global::System.Data.DataRow[] addedRows = dataSet.AnagSchede.Select(null, null, global::System.Data.DataViewRowState.Added); if (((addedRows != null) @@ -15134,14 +14888,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; allChangedRows.AddRange(deletedRows); } } - if ((this._elencoMacchineCNTableAdapter != null)) { - global::System.Data.DataRow[] deletedRows = dataSet.ElencoMacchineCN.Select(null, null, global::System.Data.DataViewRowState.Deleted); - if (((deletedRows != null) - && (0 < deletedRows.Length))) { - result = (result + this._elencoMacchineCNTableAdapter.Update(deletedRows)); - allChangedRows.AddRange(deletedRows); - } - } return result; } @@ -15181,11 +14927,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; if ((dataSet.HasChanges() == false)) { return 0; } - if (((this._elencoMacchineCNTableAdapter != null) - && (this.MatchTableAdapterConnection(this._elencoMacchineCNTableAdapter.Connection) == false))) { - throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" + - "tring."); - } if (((this._anagFasiTableAdapter != null) && (this.MatchTableAdapterConnection(this._anagFasiTableAdapter.Connection) == false))) { throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" + @@ -15253,15 +14994,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; try { // ---- Prepare for update ----------- // - if ((this._elencoMacchineCNTableAdapter != null)) { - revertConnections.Add(this._elencoMacchineCNTableAdapter, this._elencoMacchineCNTableAdapter.Connection); - this._elencoMacchineCNTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection)); - this._elencoMacchineCNTableAdapter.Transaction = ((global::System.Data.SqlClient.SqlTransaction)(workTransaction)); - if (this._elencoMacchineCNTableAdapter.Adapter.AcceptChangesDuringUpdate) { - this._elencoMacchineCNTableAdapter.Adapter.AcceptChangesDuringUpdate = false; - adaptersWithAcceptChangesDuringUpdate.Add(this._elencoMacchineCNTableAdapter.Adapter); - } - } if ((this._anagFasiTableAdapter != null)) { revertConnections.Add(this._anagFasiTableAdapter, this._anagFasiTableAdapter.Connection); this._anagFasiTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(workConnection)); @@ -15383,10 +15115,6 @@ SELECT TagCode, DescrTag FROM AnagTags WHERE (TagCode = @TagCode)"; if (workConnOpened) { workConnection.Close(); } - if ((this._elencoMacchineCNTableAdapter != null)) { - this._elencoMacchineCNTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._elencoMacchineCNTableAdapter])); - this._elencoMacchineCNTableAdapter.Transaction = null; - } if ((this._anagFasiTableAdapter != null)) { this._anagFasiTableAdapter.Connection = ((global::System.Data.SqlClient.SqlConnection)(revertConnections[this._anagFasiTableAdapter])); this._anagFasiTableAdapter.Transaction = null; diff --git a/CMS-SC-Data/bin/Release/CMS-SC-Data.dll b/CMS-SC-Data/bin/Release/CMS-SC-Data.dll index 73b2397..86344cd 100644 Binary files a/CMS-SC-Data/bin/Release/CMS-SC-Data.dll and b/CMS-SC-Data/bin/Release/CMS-SC-Data.dll differ diff --git a/CMS-SC-Data/obj/Release/CMS-SC-Data.dll b/CMS-SC-Data/obj/Release/CMS-SC-Data.dll index 73b2397..86344cd 100644 Binary files a/CMS-SC-Data/obj/Release/CMS-SC-Data.dll and b/CMS-SC-Data/obj/Release/CMS-SC-Data.dll differ diff --git a/CMS_SC/WebUserControls/mod_anagMatricole.ascx b/CMS_SC/WebUserControls/mod_anagMatricole.ascx index 6624988..a6e17b2 100644 --- a/CMS_SC/WebUserControls/mod_anagMatricole.ascx +++ b/CMS_SC/WebUserControls/mod_anagMatricole.ascx @@ -5,7 +5,7 @@ <%: traduci("selCodFam") %>:  <%: traduci("insNewMatr") %>: - + <%: traduci("insNewMatr") %> @@ -52,7 +52,8 @@   - + + diff --git a/CMS_SC/bin/CMS-SC-Data.dll b/CMS_SC/bin/CMS-SC-Data.dll index 73b2397..86344cd 100644 Binary files a/CMS_SC/bin/CMS-SC-Data.dll and b/CMS_SC/bin/CMS-SC-Data.dll differ diff --git a/CMS_SC/bin/CMS_SC.dll b/CMS_SC/bin/CMS_SC.dll index 53b6233..99d2255 100644 Binary files a/CMS_SC/bin/CMS_SC.dll and b/CMS_SC/bin/CMS_SC.dll differ diff --git a/Release Clienti/CMS_SC.zip b/Release Clienti/CMS_SC.zip index 6cf33fb..8587227 100644 Binary files a/Release Clienti/CMS_SC.zip and b/Release Clienti/CMS_SC.zip differ diff --git a/Release Clienti/Update_CMS-SC.sql b/Release Clienti/Update_CMS-SC_1.8.097.sql similarity index 100% rename from Release Clienti/Update_CMS-SC.sql rename to Release Clienti/Update_CMS-SC_1.8.097.sql diff --git a/Release Clienti/Update_CMS-SC_1.9.100.sql b/Release Clienti/Update_CMS-SC_1.9.100.sql new file mode 100644 index 0000000..865a7bb --- /dev/null +++ b/Release Clienti/Update_CMS-SC_1.9.100.sql @@ -0,0 +1,484 @@ +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +create VIEW v_ElencoMacchine +AS +SELECT dbo.ElencoMacchineCN.Matricola, dbo.ElencoMacchineCN.Descrizione, dbo.ElencoMacchineCN.Cliente, dbo.ElencoMacchineCN.CodFam, dbo.ElencoMacchineCN.CorsaX, dbo.ElencoMacchineCN.CorsaY, + dbo.ElencoMacchineCN.CorsaZ, ISNULL(dbo.ElencoDossier.IdxDossier, 0) AS IdxDossier +FROM dbo.ElencoMacchineCN LEFT OUTER JOIN + dbo.ElencoDossier ON dbo.ElencoMacchineCN.Matricola = dbo.ElencoDossier.Matricola +go + +exec sp_addextendedproperty 'MS_DiagramPane1', '[0E232FF0-B466-11cf-A24F-00AA00A3EFFF, 1.00] +Begin DesignProperties = + Begin PaneConfigurations = + Begin PaneConfiguration = 0 + NumPanes = 4 + Configuration = "(H (1[40] 4[20] 2[20] 3) )" + End + Begin PaneConfiguration = 1 + NumPanes = 3 + Configuration = "(H (1 [50] 4 [25] 3))" + End + Begin PaneConfiguration = 2 + NumPanes = 3 + Configuration = "(H (1 [50] 2 [25] 3))" + End + Begin PaneConfiguration = 3 + NumPanes = 3 + Configuration = "(H (4 [30] 2 [40] 3))" + End + Begin PaneConfiguration = 4 + NumPanes = 2 + Configuration = "(H (1 [56] 3))" + End + Begin PaneConfiguration = 5 + NumPanes = 2 + Configuration = "(H (2 [66] 3))" + End + Begin PaneConfiguration = 6 + NumPanes = 2 + Configuration = "(H (4 [50] 3))" + End + Begin PaneConfiguration = 7 + NumPanes = 1 + Configuration = "(V (3))" + End + Begin PaneConfiguration = 8 + NumPanes = 3 + Configuration = "(H (1[56] 4[18] 2) )" + End + Begin PaneConfiguration = 9 + NumPanes = 2 + Configuration = "(H (1 [75] 4))" + End + Begin PaneConfiguration = 10 + NumPanes = 2 + Configuration = "(H (1[66] 2) )" + End + Begin PaneConfiguration = 11 + NumPanes = 2 + Configuration = "(H (4 [60] 2))" + End + Begin PaneConfiguration = 12 + NumPanes = 1 + Configuration = "(H (1) )" + End + Begin PaneConfiguration = 13 + NumPanes = 1 + Configuration = "(V (4))" + End + Begin PaneConfiguration = 14 + NumPanes = 1 + Configuration = "(V (2))" + End + ActivePaneConfig = 0 + End + Begin DiagramPane = + Begin Origin = + Top = 0 + Left = 0 + End + Begin Tables = + Begin Table = "ElencoMacchineCN" + Begin Extent = + Top = 6 + Left = 38 + Bottom = 265 + Right = 208 + End + DisplayFlags = 280 + TopColumn = 0 + End + Begin Table = "ElencoDossier" + Begin Extent = + Top = 12 + Left = 410 + Bottom = 142 + Right = 580 + End + DisplayFlags = 280 + TopColumn = 0 + End + End + End + Begin SQLPane = + End + Begin DataPane = + Begin ParameterDefaults = "" + End + Begin ColumnWidths = 9 + Width = 284 + Width = 1500 + Width = 1500 + Width = 1500 + Width = 1500 + Width = 1500 + Width = 1500 + Width = 1500 + Width = 1500 + End + End + Begin CriteriaPane = + Begin ColumnWidths = 11 + Column = 1440 + Alias = 900 + Table = 1170 + Output = 720 + Append = 1400 + NewValue = 1170 + SortType = 1350 + SortOrder = 1410 + GroupBy = 1350 + Filter = 1350 + Or = 1350 + Or = 1350 + Or = 1350 + End + End +End +', 'SCHEMA', 'dbo', 'VIEW', 'v_ElencoMacchine' +go + +exec sp_addextendedproperty 'MS_DiagramPaneCount', 1, 'SCHEMA', 'dbo', 'VIEW', 'v_ElencoMacchine' +go + +commit +go + + +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +-- ============================================= +-- Author: S.E. Locatelli +-- Create date: 2015.10.19 +-- Description: recupero record da matricola +-- ============================================= +alter PROCEDURE stp_AM_getByMatr +( + @Matricola NVARCHAR(50) +) +AS +SET NOCOUNT OFF; + +SELECT * +FROM v_ElencoMacchine +WHERE Matricola = @Matricola +go + +commit +go + + +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +-- ============================================= +-- Author: S.E. Locatelli +-- Create date: 2015.06.09 +-- Description: insert record +-- ============================================= +alter PROCEDURE stp_AM_insertQuery +( + @Matricola NVARCHAR(50), + @User NVARCHAR(50), + @Descrizione NVARCHAR(50), + @Cliente NVARCHAR(50), + @CodFam NVARCHAR(50), + @CorsaX INT, + @CorsaY INT, + @CorsaZ INT +) +AS + +BEGIN tran + + SET NOCOUNT OFF; + + DECLARE @IdxDossier INT = 0 + + -- inserisco macchina + INSERT INTO ElencoMacchineCN (Matricola, Descrizione, Cliente, CodFam, CorsaX, CorsaY, CorsaZ) + VALUES (@Matricola, @Descrizione, @Cliente, @CodFam, @CorsaX, @CorsaY, @CorsaZ); + + -- creo DOSSIER x matricola... + EXEC stp_ED_InsertQuery @Matricola, @User + -- leggo numero dossier! + SELECT @IdxDossier = IdxDossier + FROM ElencoDossier + WHERE Matricola = @Matricola + + -- inserisco schema collaudi da famiglia macchina nel dossier... + EXEC stp_SCM_insByFamMac @IdxDossier, @CodFam + + + -- inserisco istanza prove standard x varie fasi... + EXEC stp_SCM_insMisFasiMissing @IdxDossier + + SELECT * + FROM ElencoMacchineCN + WHERE Matricola = @Matricola + +COMMIT tran +go + +commit +go + +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +-- ============================================= +-- Author: S.E. Locatelli +-- Create date: 2015.06.18 +-- Description: update misura (ede eventualmente parametro) con VERIFICA OK +-- ============================================= +alter PROCEDURE stp_Mis_updateMis +( + @Original_IdxDossier INT + ,@Original_CodScheda NVARCHAR(50) + ,@Original_Vers INT + ,@Original_NumScheda INT + ,@Original_CodMisura NVARCHAR(50) + ,@Original_Fase NVARCHAR(50) + ,@Operatore NVARCHAR(50) + ,@ValorePar FLOAT + ,@ValoreMis NVARCHAR(4000) + ,@CodVisib NVARCHAR(50) +) +AS + + +UPDATE Misure +SET Operatore = CASE WHEN @ValoreMis <> '' THEN @Operatore ELSE '' END + ,DataOra = GETDATE() + ,ValorePar = ISNULL(@ValorePar, 0) + ,ValoreMis = @ValoreMis + ,OkValMis = dbo.f_checkVal(CodScheda, Vers, CodMisura, @ValorePar, @ValoreMis) + ,CodVisib = ISNULL(@CodVisib, ISNULL(CodVisib,'')) +WHERE IdxDossier = @Original_IdxDossier + AND CodScheda = @Original_CodScheda + AND Vers = @Original_Vers + AND NumScheda = @Original_NumScheda + AND CodMisura = @Original_CodMisura + AND Fase = @Original_Fase + +RETURN +go + +commit +go + + +set xact_abort on +go + +begin transaction +go + +set ANSI_NULLS on +go + +-- ============================================= +-- Author: S.E. Locatelli +-- Create date: 2015.10.20 +-- Description: update misura (ede eventualmente parametro) con VERIFICA OK +-- ============================================= +alter FUNCTION f_checkVal +( + @CodScheda NVARCHAR(50) + ,@Vers INT + ,@CodMisura NVARCHAR(50) + ,@ValorePar FLOAT + ,@ValoreMis NVARCHAR(4000) +) +RETURNS BIT +AS + BEGIN + DECLARE @answ BIT = 0 + ,@ValFlt FLOAT = 0 + ,@TipoValMisura NVARCHAR(50) = '' + ,@NumVal INT = 0 + + DECLARE @delim AS VARCHAR(2) + DECLARE @chrind INT = 1 + + -- recupero num righe x validazione parametro + SELECT @NumVal = COUNT(*) + FROM ValidVal + WHERE CodScheda = @CodScheda + AND Vers = @Vers + AND CodMisura = @CodMisura + + -- check 1: DEVE ESSERCI ALMENO un valore di validazione da controllare + IF(@NumVal > 0) + BEGIN + -- recupero tipo val misura + SELECT @TipoValMisura = ISNULL(TipoValMisura,'') + FROM DettScheda + WHERE CodScheda = @CodScheda + AND Vers = @Vers + AND CodMisura = @CodMisura + + -- check 2: tipo di valore, se float/int faccio cast e test... + IF (@TipoValMisura = 'INT' OR @TipoValMisura = 'FLT') + BEGIN + + IF LTRIM(RTRIM(ISNULL(@ValoreMis,''))) <> '' + BEGIN + -- recupero valore misura come FLOAT + SELECT @ValFlt = ISNULL(CAST(REPLACE(@ValoreMis,',','.') AS FLOAT), -999999) + + IF @ValFlt > -999999 + BEGIN + SELECT @answ = CASE WHEN @ValFlt BETWEEN LIVal AND LSVal THEN 1 ELSE 0 END + FROM ValidVal + WHERE CodScheda = @CodScheda + AND Vers = @Vers + AND CodMisura = @CodMisura + AND MinPar <= @ValorePar + AND MaxPar > @ValorePar + END + END + END + + -- check 2: se è boolean è test DIRETTO + ELSE IF (@TipoValMisura = 'BOL') + BEGIN + SELECT @answ = ISNULL(CAST(@ValoreMis AS BIT), 0) + END + + -- check 3: se è AFLT è test per tutti i valori passati + ELSE IF (@TipoValMisura = 'AFLT') + BEGIN + SET @answ = 0 + -- verifico il formato del delimitatore passato se / o spazio + IF CHARINDEX('/', @ValoreMis) > 0 + BEGIN + SET @ValoreMis = REPLACE(@ValoreMis,' ','') + SET @delim = '/' + END + ELSE + IF CHARINDEX(' ', @ValoreMis) > 0 + BEGIN + SET @ValoreMis = REPLACE(@ValoreMis,' ',' ') -- se ci sono spazi doppi li riduco cmq a 1 + SET @delim = ' ' + END + ELSE + SET @delim = '' -- solo un valore + + SET @ValoreMis = RTRIM(LTRIM(REPLACE(@ValoreMis,',','.'))) + + WHILE @chrind > 0 AND ISNULL(@ValoreMis,'') <> '' + BEGIN + + SELECT @chrind = CHARINDEX(@delim, @ValoreMis) + + IF @chrind > 0 + SET @ValFlt = CAST(LEFT(@ValoreMis, @chrind - 1) AS FLOAT) + ELSE + SELECT @ValFlt = CAST(@ValoreMis AS FLOAT) + + SELECT @answ = CASE WHEN @ValFlt BETWEEN LIVal AND LSVal THEN 1 ELSE 0 END + FROM ValidVal + WHERE CodScheda = @CodScheda + AND Vers = @Vers + AND CodMisura = @CodMisura + AND MinPar <= @ValorePar + AND MaxPar > @ValorePar + + SELECT @ValoreMis = RIGHT(@ValoreMis, LEN(@ValoreMis) - @chrind) + + IF LEN(@ValoreMis) = 0 OR @answ = 0 -- se anche solo un valore KO esco con @answ = 0 + BREAK + END + END + END + ELSE + BEGIN + -- ...(altrimenti è OK per "partito preso" SE HO un valore e KO se non ce l'ho...) + SELECT @answ = CASE WHEN @ValoreMis <> '' THEN 1 ELSE 0 END + END + + RETURN @answ + END +go + +commit +go + + +set xact_abort on +go + +begin transaction +go + +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'btnClonaConfFamMacch', N'Clona Famiglia Esistente') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'insIsEnabled', N'Inserimento Abilitato') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'insNewMatr', N'Crea Macchina e schede') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'numMatrExisting', N'Matricola già presente') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'numMatrIsEmpty', N'Manca Numero Matricola') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'plsInsNewMatr', N'Nuova Matricola Macchina') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'selCodFam', N'Selezionare Famiglia') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'SelectFM_CSV_2ins', N'Selezionare Fam.Macc e Scheda per inserire') +INSERT INTO dbo.Vocabolario + VALUES (N'EN', N'warnHasChildRecord', N'Attenzione: record child collegati') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'btnClonaConfFamMacch', N'Clona Famiglia Esistente') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'insIsEnabled', N'Inserimento Abilitato') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'insNewMatr', N'Crea Macchina e schede') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'numMatrExisting', N'Matricola già presente') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'numMatrIsEmpty', N'Manca Numero Matricola') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'plsInsNewMatr', N'Nuova Matricola Macchina') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'selCodFam', N'Selezionare Famiglia') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'SelectFM_CSV_2ins', N'Selezionare Fam.Macc e Scheda per inserire') +INSERT INTO dbo.Vocabolario + VALUES (N'IT', N'warnHasChildRecord', N'Attenzione: record child collegati') +go + +commit transaction +go + + + diff --git a/VersGen/CMS_SC.cs b/VersGen/CMS_SC.cs index 8ab8fe0..fd6d039 100644 --- a/VersGen/CMS_SC.cs +++ b/VersGen/CMS_SC.cs @@ -5,7 +5,7 @@ using System.Reflection; -[assembly: AssemblyVersion("1.8.099.354")] -[assembly: AssemblyFileVersion("1.8.099.354")] +[assembly: AssemblyVersion("1.9.100.354")] +[assembly: AssemblyFileVersion("1.9.100.354")] [assembly: AssemblyCopyright("Steamware © 2009-2015")] [assembly: AssemblyCompany("Steamware")] diff --git a/VersGen/CMS_SC.tt b/VersGen/CMS_SC.tt index ea9c079..834ed32 100644 --- a/VersGen/CMS_SC.tt +++ b/VersGen/CMS_SC.tt @@ -6,8 +6,8 @@ using System.Reflection; -[assembly: AssemblyVersion("1.8.099.<#= this.RevisionNumber #>")] -[assembly: AssemblyFileVersion("1.8.099.<#= this.RevisionNumber #>")] +[assembly: AssemblyVersion("1.9.100.<#= this.RevisionNumber #>")] +[assembly: AssemblyFileVersion("1.9.100.<#= this.RevisionNumber #>")] [assembly: AssemblyCopyright("Steamware © 2009-<#= DateTime.Now.Year #>")] [assembly: AssemblyCompany("Steamware")] <#+