diff --git a/Projects/WebGIM/GIM_data/DS_applicazione.Designer.cs b/Projects/WebGIM/GIM_data/DS_applicazione.Designer.cs index 4e6cc85..c3c8263 100644 --- a/Projects/WebGIM/GIM_data/DS_applicazione.Designer.cs +++ b/Projects/WebGIM/GIM_data/DS_applicazione.Designer.cs @@ -3837,9 +3837,10 @@ namespace GIM_data { this.columnidxImpianto.AllowDBNull = false; this.columnidxMacchina.AllowDBNull = false; this.columndescrizione.AllowDBNull = false; - this.columndescrizione.MaxLength = 500; + this.columndescrizione.MaxLength = 2500; this.columnidxStato.AllowDBNull = false; - this.columndescrizioneIntervento.MaxLength = 500; + this.columndescrizioneIntervento.MaxLength = 2500; + this.columnisPreventivabile.AllowDBNull = false; this.columndescrAmbitoGuasto.MaxLength = 50; this.columndescrPriorita.MaxLength = 50; this.columndescrTipo.MaxLength = 50; @@ -9224,12 +9225,7 @@ namespace GIM_data { [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] public bool isPreventivabile { get { - try { - return ((bool)(this[this.tablev_intervExp.isPreventivabileColumn])); - } - catch (global::System.InvalidCastException e) { - throw new global::System.Data.StrongTypingException("The value for column \'isPreventivabile\' in table \'v_intervExp\' is DBNull.", e); - } + return ((bool)(this[this.tablev_intervExp.isPreventivabileColumn])); } set { this[this.tablev_intervExp.isPreventivabileColumn] = value; @@ -9488,18 +9484,6 @@ namespace GIM_data { this[this.tablev_intervExp.descrizioneInterventoColumn] = global::System.Convert.DBNull; } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - public bool IsisPreventivabileNull() { - return this.IsNull(this.tablev_intervExp.isPreventivabileColumn); - } - - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] - public void SetisPreventivabileNull() { - this[this.tablev_intervExp.isPreventivabileColumn] = global::System.Convert.DBNull; - } - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")] public bool IsidxCausaleNull() { @@ -14659,47 +14643,27 @@ ORDER BY numIntMtz DESC"; 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 numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -WHERE (numIntMtz = @numIntMtz)"; + this._commandCollection[1].CommandText = @"SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (numIntMtz = @numIntMtz)"; this._commandCollection[1].CommandType = global::System.Data.CommandType.Text; this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numIntMtz", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "numIntMtz", 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 *\r\nFROM v_intervExp\r\nWHERE (idxCausale = @idxCausale)"; + this._commandCollection[2].CommandText = @"SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (idxCausale = @idxCausale)"; this._commandCollection[2].CommandType = global::System.Data.CommandType.Text; this._commandCollection[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxCausale", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idxCausale", 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 = @"SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -where idxImpianto=@idxImpianto -ORDER BY numIntMtz DESC -"; + this._commandCollection[3].CommandText = @"SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (idxImpianto = @idxImpianto) ORDER BY numIntMtz DESC"; this._commandCollection[3].CommandType = global::System.Data.CommandType.Text; this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxImpianto", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idxImpianto", 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 = @"SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -WHERE idxMacchina=@idxMacchina -ORDER BY numIntMtz DESC"; + this._commandCollection[4].CommandText = @"SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (idxMacchina = @idxMacchina) ORDER BY numIntMtz DESC"; this._commandCollection[4].CommandType = global::System.Data.CommandType.Text; this._commandCollection[4].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxMacchina", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idxMacchina", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[5] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[5].Connection = this.Connection; - this._commandCollection[5].CommandText = @"SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -where richiesta between @inizio and @fine -ORDER BY numIntMtz DESC"; + this._commandCollection[5].CommandText = @"SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (richiesta BETWEEN @inizio AND @fine) ORDER BY numIntMtz DESC"; this._commandCollection[5].CommandType = global::System.Data.CommandType.Text; this._commandCollection[5].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@inizio", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 0, 0, "richiesta", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[5].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fine", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 0, 0, "richiesta", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); @@ -14719,7 +14683,7 @@ ORDER BY numIntMtz DESC"; this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxTipo", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxImpianto", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxMacchina", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizione", global::System.Data.SqlDbType.VarChar, 500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizione", global::System.Data.SqlDbType.VarChar, 2500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxCausale", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@scheduled", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[6].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@numIntMtz", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.InputOutput, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); @@ -14740,7 +14704,7 @@ ORDER BY numIntMtz DESC"; this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@inizioIntervento", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 23, 3, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fineIntervento", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 23, 3, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@isPreventivabile", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizioneIntervento", global::System.Data.SqlDbType.VarChar, 500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[8].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizioneIntervento", global::System.Data.SqlDbType.NVarChar, 2500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[9].Connection = this.Connection; this._commandCollection[9].CommandText = "dbo.sp_updateInterventoFull"; @@ -14751,15 +14715,15 @@ ORDER BY numIntMtz DESC"; this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@inizioIntervento", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 23, 3, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@fineIntervento", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 23, 3, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@isPreventivabile", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizioneIntervento", global::System.Data.SqlDbType.VarChar, 500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@matr", global::System.Data.SqlDbType.VarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizioneIntervento", global::System.Data.SqlDbType.NVarChar, 2500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@matr", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@guasto", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 23, 3, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@isFermo", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxImpianto", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxMacchina", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxAmbito", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxPriorita", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); - this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizione", global::System.Data.SqlDbType.VarChar, 500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@descrizione", global::System.Data.SqlDbType.NVarChar, 2500, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxTipo", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxCausale", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[9].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@presaInCarico", global::System.Data.SqlDbType.DateTime, 8, global::System.Data.ParameterDirection.Input, 23, 3, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); diff --git a/Projects/WebGIM/GIM_data/DS_applicazione.xsd b/Projects/WebGIM/GIM_data/DS_applicazione.xsd index 742eba5..58d56d3 100644 --- a/Projects/WebGIM/GIM_data/DS_applicazione.xsd +++ b/Projects/WebGIM/GIM_data/DS_applicazione.xsd @@ -589,11 +589,7 @@ ORDER BY numIntMtz DESC - SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -WHERE (numIntMtz = @numIntMtz) + SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (numIntMtz = @numIntMtz) @@ -603,9 +599,7 @@ WHERE (numIntMtz = @numIntMtz) - SELECT * -FROM v_intervExp -WHERE (idxCausale = @idxCausale) + SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (idxCausale = @idxCausale) @@ -615,13 +609,7 @@ WHERE (idxCausale = @idxCausale) - SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -where idxImpianto=@idxImpianto -ORDER BY numIntMtz DESC - + SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (idxImpianto = @idxImpianto) ORDER BY numIntMtz DESC @@ -631,12 +619,7 @@ ORDER BY numIntMtz DESC - SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -WHERE idxMacchina=@idxMacchina -ORDER BY numIntMtz DESC + SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (idxMacchina = @idxMacchina) ORDER BY numIntMtz DESC @@ -646,12 +629,7 @@ ORDER BY numIntMtz DESC - SELECT numIntMtz, richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, descrAmbitoGuasto, idxPriorita, descrPriorita, isFermo, idxTipo, descrTipo, idxImpianto, - codImpianto, nomeImpianto, idxMacchina, codMacchina, nomeMacchina, descrizione, idxStato, DescrStato, presaInCarico, inizioIntervento, fineIntervento, - descrizioneIntervento, isPreventivabile, idxCausale, descrCausale -FROM v_intervExp -where richiesta between @inizio and @fine -ORDER BY numIntMtz DESC + SELECT DescrStato, codImpianto, codMacchina, dataLav, descrAmbitoGuasto, descrCausale, descrPriorita, descrTipo, descrizione, descrizioneIntervento, fineIntervento, guasto, idxAmbito, idxCausale, idxImpianto, idxMacchina, idxPriorita, idxStato, idxTipo, inizioIntervento, isFermo, isPreventivabile, matr, nomeImpianto, nomeMacchina, numIntMtz, presaInCarico, richiesta, turnoLav FROM v_intervExp WHERE (richiesta BETWEEN @inizio AND @fine) ORDER BY numIntMtz DESC @@ -676,7 +654,7 @@ ORDER BY numIntMtz DESC - + @@ -707,7 +685,7 @@ ORDER BY numIntMtz DESC - + @@ -723,15 +701,15 @@ ORDER BY numIntMtz DESC - - + + - + @@ -1763,7 +1741,7 @@ WHERE (idxCausale = @Original_idxCausale) - + @@ -1774,11 +1752,11 @@ WHERE (idxCausale = @Original_idxCausale) - + - + @@ -2213,20 +2191,20 @@ WHERE (idxCausale = @Original_idxCausale) - - - - - - - - - - - - - - + + + + + + + + + + + + + + \ No newline at end of file diff --git a/Projects/WebGIM/GIM_data/DS_applicazione.xss b/Projects/WebGIM/GIM_data/DS_applicazione.xss index 2b3f2be..538112c 100644 --- a/Projects/WebGIM/GIM_data/DS_applicazione.xss +++ b/Projects/WebGIM/GIM_data/DS_applicazione.xss @@ -4,7 +4,7 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + @@ -13,13 +13,13 @@ - + - + - + @@ -84,7 +84,7 @@ 429 - 732 + 745 429 @@ -117,7 +117,7 @@ 631 - 629 + 598 631 diff --git a/Projects/WebGIM/GIM_data/bin/GIM_data.dll b/Projects/WebGIM/GIM_data/bin/GIM_data.dll index 4bf4bd3..dff85a0 100644 Binary files a/Projects/WebGIM/GIM_data/bin/GIM_data.dll and b/Projects/WebGIM/GIM_data/bin/GIM_data.dll differ diff --git a/Projects/WebGIM/GIM_site/GIM_site.csproj b/Projects/WebGIM/GIM_site/GIM_site.csproj index cca322e..b400d6b 100644 --- a/Projects/WebGIM/GIM_site/GIM_site.csproj +++ b/Projects/WebGIM/GIM_site/GIM_site.csproj @@ -175,6 +175,7 @@ + diff --git a/Projects/WebGIM/GIM_site/WebUserControls/mod_elencoMtzProg.ascx.cs b/Projects/WebGIM/GIM_site/WebUserControls/mod_elencoMtzProg.ascx.cs index e3abb10..8b83d8f 100644 --- a/Projects/WebGIM/GIM_site/WebUserControls/mod_elencoMtzProg.ascx.cs +++ b/Projects/WebGIM/GIM_site/WebUserControls/mod_elencoMtzProg.ascx.cs @@ -419,6 +419,8 @@ public partial class mod_elencoMtzProg : ApplicationUserControl mtzProgr.obj.processaCodaMtzPro(); grView.DataBind(); UpdatePanel2.Update(); + // aggiorno + doUpdate(); // chiamo evento if (eh_updateDone != null) { diff --git a/Projects/WebGIM/GIM_site/bin/GIM_data.dll b/Projects/WebGIM/GIM_site/bin/GIM_data.dll index 4bf4bd3..dff85a0 100644 Binary files a/Projects/WebGIM/GIM_site/bin/GIM_data.dll and b/Projects/WebGIM/GIM_site/bin/GIM_data.dll differ diff --git a/Projects/WebGIM/GIM_site/bin/GIM_site.dll b/Projects/WebGIM/GIM_site/bin/GIM_site.dll index 4ac147a..3f8efe6 100644 Binary files a/Projects/WebGIM/GIM_site/bin/GIM_site.dll and b/Projects/WebGIM/GIM_site/bin/GIM_site.dll differ diff --git a/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.csprojResolveAssemblyReference.cache b/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.csprojResolveAssemblyReference.cache index b625da2..ed40750 100644 Binary files a/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.csprojResolveAssemblyReference.cache and b/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.csprojResolveAssemblyReference.cache differ diff --git a/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.dll b/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.dll index 4ac147a..3f8efe6 100644 Binary files a/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.dll and b/Projects/WebGIM/GIM_site/obj/Somaschini/GIM_site.dll differ diff --git a/Projects/WebGIM/GIM_site/obj/Somaschini/Package/WebGIM.zip b/Projects/WebGIM/GIM_site/obj/Somaschini/Package/WebGIM.zip index f38bfe8..f7abc5e 100644 Binary files a/Projects/WebGIM/GIM_site/obj/Somaschini/Package/WebGIM.zip and b/Projects/WebGIM/GIM_site/obj/Somaschini/Package/WebGIM.zip differ diff --git a/Projects/WebGIM/GIM_site/sql/Applicazione/GIM_0210.sql b/Projects/WebGIM/GIM_site/sql/Applicazione/GIM_0210.sql index 4f3ced4..59f46fa 100644 --- a/Projects/WebGIM/GIM_site/sql/Applicazione/GIM_0210.sql +++ b/Projects/WebGIM/GIM_site/sql/Applicazione/GIM_0210.sql @@ -141,6 +141,131 @@ commit; go +set xact_abort on; +go + +begin transaction; +go + +alter table InterventiMtz alter column + descrizione nvarchar(2500) not null; +go + +alter table InterventiMtz alter column + descrizioneIntervento nvarchar(2500); +go + +set ANSI_NULLS on; +go + +/************************************* +* STORED PROCEDURE sp_updateInterventoFull +* aggiorna TUTTI i dati dell'intervento +* +* modif.: S.E.L. - 2009.02.20 +**************************************/ +alter PROCEDURE sp_updateInterventoFull +( + @Original_numIntMtz INT, + @idxStato INT, + @inizioIntervento DATETIME, + @fineIntervento DATETIME, + @isPreventivabile BIT, + @descrizioneIntervento NVARCHAR(2500), + @matr NVARCHAR(50), + @guasto DATETIME, + @isFermo BIT, + @idxImpianto INT, + @idxMacchina INT, + @idxAmbito INT, + @idxPriorita INT, + @descrizione NVARCHAR(2500), + @idxTipo INT, + @idxCausale int, + @presaInCarico DATETIME +) +AS + +UPDATE InterventiMtz +SET inizioIntervento = @inizioIntervento, fineIntervento = @fineIntervento, descrizioneIntervento = @descrizioneIntervento, isPreventivabile = @isPreventivabile, + idxStato = @idxStato, matr = @matr, guasto = @guasto, idxAmbito = @idxAmbito, idxPriorita = @idxPriorita, isFermo = @isFermo, idxTipo = @idxTipo, + idxImpianto = @idxImpianto, idxMacchina = @idxMacchina, descrizione = @descrizione, presaInCarico = @presaInCarico, idxCausale = @idxCausale +WHERE (numIntMtz = @Original_numIntMtz) + +RETURN +go + +/************************************* +* STORED PROCEDURE sp_updateIntervento +* aggiorna i dati dell'intervento compilati dalla manutenzione +* +* modif.: S.E.L. - 2009.01.28 +**************************************/ +alter PROCEDURE sp_updateIntervento +( + @Original_numIntMtz INT, + @idxStato INT, + @inizioIntervento DATETIME, + @fineIntervento DATETIME, + @isPreventivabile BIT, + @descrizioneIntervento NVARCHAR(2500) +) +AS + +UPDATE InterventiMtz +SET inizioIntervento = @inizioIntervento, fineIntervento = @fineIntervento, descrizioneIntervento = @descrizioneIntervento, isPreventivabile = @isPreventivabile, idxStato = @idxStato +WHERE (numIntMtz = @Original_numIntMtz) + +RETURN +go + +/************************************* +* STORED PROCEDURE sp_insRichiesta +* Inserisce nuova richiesta di intervento +* +* modif.: S.E.L. - 2009.02.20 +**************************************/ +alter PROCEDURE sp_insRichiesta +( + @richiesta datetime, + @dataLav datetime, + @turnoLav int, + @matr varchar(10), + @guasto datetime, + @idxAmbito int, + @idxPriorita int, + @isFermo bit, + @idxTipo int, + @idxImpianto int, + @idxMacchina int, + @descrizione varchar(2500), + @idxCausale int, + @scheduled bit, + @numIntMtz int output +) +AS + +BEGIN tran + + INSERT INTO InterventiMtz + (richiesta, dataLav, turnoLav, matr, guasto, idxAmbito, idxPriorita, isFermo, idxTipo, idxImpianto, idxMacchina, descrizione, idxStato, idxCausale, scheduled) + VALUES (@richiesta,@dataLav,@turnoLav,@matr,@guasto,@idxAmbito,@idxPriorita,@isFermo,@idxTipo,@idxImpianto,@idxMacchina,@descrizione, + 1,@idxCausale,@scheduled) + + /************************************* + * salvo idx del nuovo record + **************************************/ + SET @numIntMtz = SCOPE_IDENTITY() + +COMMIT tran + +RETURN (@numIntMtz) +go + +commit; +go + + diff --git a/Projects/WebGIM/WebGIM.suo b/Projects/WebGIM/WebGIM.suo index 2bdefcb..b131838 100644 Binary files a/Projects/WebGIM/WebGIM.suo and b/Projects/WebGIM/WebGIM.suo differ