diff --git a/ETS_Data/Ds_ProjEts.Designer.cs b/ETS_Data/Ds_ProjEts.Designer.cs index f70ae3d..8a5e84a 100644 --- a/ETS_Data/Ds_ProjEts.Designer.cs +++ b/ETS_Data/Ds_ProjEts.Designer.cs @@ -16565,6 +16565,7 @@ namespace ETS_Data.Ds_ProjEtsTableAdapters { this._commandCollection[0].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@showFasi", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[0].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@showCommArch", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[0].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@showCommZeroH", global::System.Data.SqlDbType.Bit, 1, global::System.Data.ParameterDirection.Input, 1, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[0].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLabel", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._commandCollection[1] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[1].Connection = this.Connection; this._commandCollection[1].CommandText = "dbo.stp_AF_deleteQuery"; @@ -16604,7 +16605,7 @@ namespace ETS_Data.Ds_ProjEtsTableAdapters { [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.Fill, true)] - public virtual int Fill(Ds_ProjEts.AnagCommFasiDataTable dataTable, string searchText, string capoComm, global::System.Nullable showFasi, global::System.Nullable showCommArch, global::System.Nullable showCommZeroH) { + public virtual int Fill(Ds_ProjEts.AnagCommFasiDataTable dataTable, string searchText, string capoComm, global::System.Nullable showFasi, global::System.Nullable showCommArch, global::System.Nullable showCommZeroH, string CodLabel) { this.Adapter.SelectCommand = this.CommandCollection[0]; if ((searchText == null)) { this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value; @@ -16636,6 +16637,12 @@ namespace ETS_Data.Ds_ProjEtsTableAdapters { else { this.Adapter.SelectCommand.Parameters[5].Value = global::System.DBNull.Value; } + if ((CodLabel == null)) { + this.Adapter.SelectCommand.Parameters[6].Value = global::System.DBNull.Value; + } + else { + this.Adapter.SelectCommand.Parameters[6].Value = ((string)(CodLabel)); + } if ((this.ClearBeforeFill == true)) { dataTable.Clear(); } @@ -16647,7 +16654,7 @@ namespace ETS_Data.Ds_ProjEtsTableAdapters { [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.Select, true)] - public virtual Ds_ProjEts.AnagCommFasiDataTable GetData(string searchText, string capoComm, global::System.Nullable showFasi, global::System.Nullable showCommArch, global::System.Nullable showCommZeroH) { + public virtual Ds_ProjEts.AnagCommFasiDataTable GetData(string searchText, string capoComm, global::System.Nullable showFasi, global::System.Nullable showCommArch, global::System.Nullable showCommZeroH, string CodLabel) { this.Adapter.SelectCommand = this.CommandCollection[0]; if ((searchText == null)) { this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value; @@ -16679,6 +16686,12 @@ namespace ETS_Data.Ds_ProjEtsTableAdapters { else { this.Adapter.SelectCommand.Parameters[5].Value = global::System.DBNull.Value; } + if ((CodLabel == null)) { + this.Adapter.SelectCommand.Parameters[6].Value = global::System.DBNull.Value; + } + else { + this.Adapter.SelectCommand.Parameters[6].Value = ((string)(CodLabel)); + } Ds_ProjEts.AnagCommFasiDataTable dataTable = new Ds_ProjEts.AnagCommFasiDataTable(); this.Adapter.Fill(dataTable); return dataTable; @@ -21165,7 +21178,7 @@ SELECT CodLabel, DescrLabel FROM AnagLabels WHERE (CodLabel = @CodLabel)"; [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.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 idxFase, CodLabel FROM dbo.LabelsComm"; @@ -21176,6 +21189,19 @@ SELECT CodLabel, DescrLabel FROM AnagLabels WHERE (CodLabel = @CodLabel)"; 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_idxFase", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 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_L2C_getByIdxFase"; + 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[2].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxFase", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 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_L2C_UpsertQuery"; + 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("@idxFase", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[3].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@CodLabel", global::System.Data.SqlDbType.NVarChar, 50, global::System.Data.ParameterDirection.Input, 0, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -21202,6 +21228,23 @@ SELECT CodLabel, DescrLabel FROM AnagLabels WHERE (CodLabel = @CodLabel)"; 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")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)] + public virtual Ds_ProjEts.LabelsCommDataTable getByIdxFase(global::System.Nullable idxFase) { + this.Adapter.SelectCommand = this.CommandCollection[2]; + if ((idxFase.HasValue == true)) { + this.Adapter.SelectCommand.Parameters[1].Value = ((int)(idxFase.Value)); + } + else { + this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value; + } + Ds_ProjEts.LabelsCommDataTable dataTable = new Ds_ProjEts.LabelsCommDataTable(); + this.Adapter.Fill(dataTable); + 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")] @@ -21358,6 +21401,41 @@ SELECT CodLabel, DescrLabel FROM AnagLabels WHERE (CodLabel = @CodLabel)"; } return returnValue; } + + [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, false)] + public virtual int UpsertQuery(global::System.Nullable idxFase, string CodLabel) { + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[3]; + if ((idxFase.HasValue == true)) { + command.Parameters[1].Value = ((int)(idxFase.Value)); + } + else { + command.Parameters[1].Value = global::System.DBNull.Value; + } + if ((CodLabel == null)) { + command.Parameters[2].Value = global::System.DBNull.Value; + } + else { + command.Parameters[2].Value = ((string)(CodLabel)); + } + 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/ETS_Data/Ds_ProjEts.xsd b/ETS_Data/Ds_ProjEts.xsd index 4c8ac38..ecdf584 100644 --- a/ETS_Data/Ds_ProjEts.xsd +++ b/ETS_Data/Ds_ProjEts.xsd @@ -613,6 +613,7 @@ + @@ -1613,6 +1614,29 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa + + + + dbo.stp_L2C_getByIdxFase + + + + + + + + + + + dbo.stp_L2C_UpsertQuery + + + + + + + + @@ -1623,7 +1647,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -1666,7 +1690,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -1716,7 +1740,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -1812,7 +1836,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -1863,7 +1887,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -1915,7 +1939,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2018,7 +2042,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2066,7 +2090,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2083,7 +2107,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2104,7 +2128,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2125,7 +2149,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2260,7 +2284,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2279,7 +2303,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2290,7 +2314,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2306,7 +2330,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2335,7 +2359,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2355,7 +2379,7 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - + @@ -2452,13 +2476,13 @@ SELECT idxFase, CodLabel FROM LabelsComm WHERE (CodLabel = @CodLabel) AND (idxFa - - - - - - - + + + + + + + \ No newline at end of file diff --git a/ETS_Data/Ds_ProjEts.xss b/ETS_Data/Ds_ProjEts.xss index 9cc4776..9c319c6 100644 --- a/ETS_Data/Ds_ProjEts.xss +++ b/ETS_Data/Ds_ProjEts.xss @@ -4,7 +4,7 @@ Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. --> - + @@ -17,12 +17,12 @@ - + - + @@ -116,12 +116,12 @@ - 1258 + 1259 773 - 1258 - 824 + 1259 + 813 diff --git a/ETS_Data/obj/Debug/TempPE/Ds_ProjEts.Designer.cs.dll b/ETS_Data/obj/Debug/TempPE/Ds_ProjEts.Designer.cs.dll index c1e88d0..17ed184 100644 Binary files a/ETS_Data/obj/Debug/TempPE/Ds_ProjEts.Designer.cs.dll and b/ETS_Data/obj/Debug/TempPE/Ds_ProjEts.Designer.cs.dll differ diff --git a/PROJ-ETS/PROJ-ETS/Commesse.aspx b/PROJ-ETS/PROJ-ETS/Commesse.aspx index f1e0151..7f088cd 100644 --- a/PROJ-ETS/PROJ-ETS/Commesse.aspx +++ b/PROJ-ETS/PROJ-ETS/Commesse.aspx @@ -29,8 +29,10 @@
- - + + + +
@@ -38,10 +40,10 @@
- ADD RES
+
diff --git a/PROJ-ETS/PROJ-ETS/Commesse.aspx.cs b/PROJ-ETS/PROJ-ETS/Commesse.aspx.cs index e3bb505..1418435 100644 --- a/PROJ-ETS/PROJ-ETS/Commesse.aspx.cs +++ b/PROJ-ETS/PROJ-ETS/Commesse.aspx.cs @@ -96,6 +96,20 @@ namespace PROJ_ETS } } /// + /// filtro CodLabel + /// + public string CodLabel + { + get + { + return utils.obj.StringSessionObj("CodLabel"); + } + set + { + utils.obj.setSessionVal("CodLabel", value); + } + } + /// /// determina se mostrare commesse archiviate /// /// @@ -124,7 +138,7 @@ namespace PROJ_ETS { showFasi = chkShowFasi.Checked; mod_commesseFull1.doUpdate(); - } + } /// /// mostra/nasconde filtro CC /// @@ -160,6 +174,25 @@ namespace PROJ_ETS fixFiltroCC(); } + /// + /// cambio valore filtro CC + /// + /// + /// + protected void ddlFiltLabel_SelectedIndexChanged(object sender, EventArgs e) + { + fixFiltroLabel(); + } + /// + /// salvo filtraggio capo commessa + update + /// + private void fixFiltroLabel() + { + CodLabel = ddlFiltLabel.SelectedValue; + mod_commesseFull1.doUpdate(); + } + + /// /// salvo ricerca /// @@ -186,7 +219,7 @@ namespace PROJ_ETS private void fixAddLabeld() { divModLabels.Visible = showAddLabels; - if(showAddLabels) + if (showAddLabels) { chkToggleAddLabels.Text = "Chiu[d]i"; } diff --git a/PROJ-ETS/PROJ-ETS/Commesse.aspx.designer.cs b/PROJ-ETS/PROJ-ETS/Commesse.aspx.designer.cs index 878bdcc..5c5a79e 100644 --- a/PROJ-ETS/PROJ-ETS/Commesse.aspx.designer.cs +++ b/PROJ-ETS/PROJ-ETS/Commesse.aspx.designer.cs @@ -103,13 +103,13 @@ namespace PROJ_ETS { protected global::System.Web.UI.WebControls.Label lblLabels; /// - /// txtLabels control. + /// ddlFiltLabel control. /// /// /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// - protected global::System.Web.UI.WebControls.TextBox txtLabels; + protected global::System.Web.UI.WebControls.DropDownList ddlFiltLabel; /// /// chkToggleAddLabels control. @@ -147,15 +147,6 @@ namespace PROJ_ETS { /// protected global::System.Web.UI.WebControls.DropDownList ddlSelLabel; - /// - /// odsLabel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.ObjectDataSource odsLabel; - /// /// lbtAddLabel control. /// @@ -174,6 +165,15 @@ namespace PROJ_ETS { /// protected global::System.Web.UI.WebControls.LinkButton lbtResetLabels; + /// + /// odsLabel control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.ObjectDataSource odsLabel; + /// /// mod_commesseFull1 control. /// diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx index 21ddb4f..579fba6 100644 --- a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx @@ -268,6 +268,7 @@ + diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx.cs b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx.cs index b95dc9c..85e9f84 100644 --- a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx.cs +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_commesseFull.ascx.cs @@ -835,7 +835,8 @@ namespace PROJ_ETS.WebUserControls { // devo salvare file con le info relative... value = Convert.ToInt32(((Label)riga.FindControl("lblValue")).Text); - DataProxy_ProjEts.DP.taL2C.Insert(value, codLabel); + // UPSERT... + DataProxy_ProjEts.DP.taL2C.UpsertQuery(value, codLabel); } } // aggiorno gridView... diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx index a6b2380..983d9c0 100644 --- a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx @@ -1,4 +1,14 @@ <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_labelsComm.ascx.cs" Inherits="PROJ_ETS.WebUserControls.mod_labelsComm" %> - -AAA BBB CCC \ No newline at end of file + + + <%# Eval("CodLabel") %> + + + + + + + + +<%--AAA BBB CCC--%> \ No newline at end of file diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx.designer.cs b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx.designer.cs index 0ad70e3..532618e 100644 --- a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx.designer.cs +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_labelsComm.ascx.designer.cs @@ -20,5 +20,23 @@ namespace PROJ_ETS.WebUserControls { /// To modify move field declaration from designer file to code-behind file. /// protected global::System.Web.UI.WebControls.HiddenField hfIdxFase; + + /// + /// repLabels control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Repeater repLabels; + + /// + /// ods control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.ObjectDataSource ods; } } diff --git a/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll b/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll index afc35d0..dbeeb10 100644 Binary files a/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll and b/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll differ diff --git a/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll b/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll index 12b5cbf..e2aef34 100644 Binary files a/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll and b/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll differ