From 7be49626566913e384b2f2c6f67155b73f669367 Mon Sep 17 00:00:00 2001 From: "Samuele E. Locatelli" Date: Fri, 3 Jan 2020 09:39:19 +0100 Subject: [PATCH] Ok delete MachineParams --- ES3/WebUserControls/cmp_machParams.ascx | 49 ++++++---- .../cmp_machParams.ascx.designer.cs | 9 -- MapoDb/DS_Plan.Designer.cs | 95 ++++++++++++++++++- MapoDb/DS_Plan.xsd | 25 +++++ MapoDb/DS_Plan.xss | 6 +- 5 files changed, 152 insertions(+), 32 deletions(-) diff --git a/ES3/WebUserControls/cmp_machParams.ascx b/ES3/WebUserControls/cmp_machParams.ascx index 4286d77c..edf2406e 100644 --- a/ES3/WebUserControls/cmp_machParams.ascx +++ b/ES3/WebUserControls/cmp_machParams.ascx @@ -1,14 +1,8 @@ <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="cmp_machParams.ascx.cs" Inherits="ES3.WebUserControls.cmp_machParams" %>
-
- aggiungere select + edit -
-
- Mancanti -
- + @@ -26,23 +20,44 @@ - + + - - - - + + + - - - - + + + + + + + + + + + + + + + - + + + + + + + + + + +
diff --git a/ES3/WebUserControls/cmp_machParams.ascx.designer.cs b/ES3/WebUserControls/cmp_machParams.ascx.designer.cs index 70e8b31c..46a5e74b 100644 --- a/ES3/WebUserControls/cmp_machParams.ascx.designer.cs +++ b/ES3/WebUserControls/cmp_machParams.ascx.designer.cs @@ -14,15 +14,6 @@ namespace ES3.WebUserControls public partial class cmp_machParams { - /// - /// Controllo lbtAddNew. - /// - /// - /// Campo generato automaticamente. - /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind. - /// - protected global::System.Web.UI.WebControls.LinkButton lbtAddNew; - /// /// Controllo grView. /// diff --git a/MapoDb/DS_Plan.Designer.cs b/MapoDb/DS_Plan.Designer.cs index 70d75b7a..d074b26e 100644 --- a/MapoDb/DS_Plan.Designer.cs +++ b/MapoDb/DS_Plan.Designer.cs @@ -11085,16 +11085,31 @@ SELECT idxPromessa, KeyRichiesta, KeyBCode, Attivabile, IdxODL, CodArticolo, Cod [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")] private void InitCommandCollection() { - this._commandCollection = new global::System.Data.SqlClient.SqlCommand[2]; + this._commandCollection = new global::System.Data.SqlClient.SqlCommand[4]; this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[0].Connection = this.Connection; this._commandCollection[0].CommandText = "SELECT *\r\nFROM MachineParams"; 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 = "dbo.stp_MacPar_insMissing"; + this._commandCollection[1].CommandText = "dbo.stp_MacPar_DeleteQuery"; this._commandCollection[1].CommandType = global::System.Data.CommandType.StoredProcedure; this._commandCollection[1].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[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_IdxMacchina", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, 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 = "dbo.stp_MacPar_insMissing"; + this._commandCollection[2].CommandType = global::System.Data.CommandType.StoredProcedure; + this._commandCollection[2].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] = new global::System.Data.SqlClient.SqlCommand(); + this._commandCollection[3].Connection = this.Connection; + this._commandCollection[3].CommandText = "dbo.stp_MacPar_UpdateQuery"; + 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("@Original_IdxMacchina", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodConfAper", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@OEE", global::System.Data.SqlDbType.Float, 8, global::System.Data.ParameterDirection.Input, 53, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@SetupTime", 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()] @@ -11124,8 +11139,82 @@ SELECT idxPromessa, KeyRichiesta, KeyBCode, Attivabile, IdxODL, CodArticolo, Cod [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")] [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] - public virtual int insMissing() { + public virtual int DeleteQuery(string Original_IdxMacchina) { global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[1]; + if ((Original_IdxMacchina == null)) { + command.Parameters[1].Value = global::System.DBNull.Value; + } + else { + command.Parameters[1].Value = ((string)(Original_IdxMacchina)); + } + 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.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + public virtual int insMissing() { + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[2]; + 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.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "16.0.0.0")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + public virtual int UpdateQuery(string Original_IdxMacchina, string CodConfAper, global::System.Nullable OEE, global::System.Nullable SetupTime) { + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[3]; + if ((Original_IdxMacchina == null)) { + command.Parameters[1].Value = global::System.DBNull.Value; + } + else { + command.Parameters[1].Value = ((string)(Original_IdxMacchina)); + } + if ((CodConfAper == null)) { + command.Parameters[2].Value = global::System.DBNull.Value; + } + else { + command.Parameters[2].Value = ((string)(CodConfAper)); + } + if ((OEE.HasValue == true)) { + command.Parameters[3].Value = ((double)(OEE.Value)); + } + else { + command.Parameters[3].Value = global::System.DBNull.Value; + } + if ((SetupTime.HasValue == true)) { + command.Parameters[4].Value = ((int)(SetupTime.Value)); + } + else { + command.Parameters[4].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)) { diff --git a/MapoDb/DS_Plan.xsd b/MapoDb/DS_Plan.xsd index 4d2ce893..0c15fc1f 100644 --- a/MapoDb/DS_Plan.xsd +++ b/MapoDb/DS_Plan.xsd @@ -678,6 +678,17 @@ FROM MachineParams + + + + dbo.stp_MacPar_DeleteQuery + + + + + + + @@ -688,6 +699,20 @@ FROM MachineParams + + + + dbo.stp_MacPar_UpdateQuery + + + + + + + + + + diff --git a/MapoDb/DS_Plan.xss b/MapoDb/DS_Plan.xss index 74415940..8251e19b 100644 --- a/MapoDb/DS_Plan.xss +++ b/MapoDb/DS_Plan.xss @@ -4,7 +4,7 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + @@ -17,7 +17,7 @@ - + @@ -47,7 +47,7 @@ 482 - 1135 + 1120 482