From 43ff05075703ae4aa3c8a86e72ae660688ff8c78 Mon Sep 17 00:00:00 2001 From: "Samuele E. Locatelli" Date: Fri, 18 May 2018 09:37:59 +0200 Subject: [PATCH] Aggiunta gestione MULTIAREA x fornitori --- Data/DS_app.Designer.cs | 204 ++++++++++++++++-- Data/DS_app.xsd | 64 +++++- Data/DS_app.xss | 12 +- Data/Data.csproj | 10 +- Data/DtProxy.cs | 49 +++++ Data/app.config | 8 +- PUB/Content/Site.css | 45 ---- PUB/PBO/AnagFornitori.aspx | 11 +- PUB/PBO/AnagFornitori.aspx.cs | 30 +++ PUB/PBO/AnagFornitori.aspx.designer.cs | 27 +++ PUB/PBO20180518.txt | 83 +++++++ PUB/PUB.csproj | 12 +- PUB/Web.config | 7 +- PUB/WebUserContols/mod_anagFornitori.ascx | 6 +- PUB/WebUserContols/mod_anagFornitori.ascx.cs | 37 ++++ PUB/WebUserContols/mod_forn2aree.ascx | 38 ++++ PUB/WebUserContols/mod_forn2aree.ascx.cs | 96 +++++++++ .../mod_forn2aree.ascx.designer.cs | 69 ++++++ 18 files changed, 712 insertions(+), 96 deletions(-) create mode 100644 Data/DtProxy.cs create mode 100644 PUB/PBO20180518.txt create mode 100644 PUB/WebUserContols/mod_forn2aree.ascx create mode 100644 PUB/WebUserContols/mod_forn2aree.ascx.cs create mode 100644 PUB/WebUserContols/mod_forn2aree.ascx.designer.cs diff --git a/Data/DS_app.Designer.cs b/Data/DS_app.Designer.cs index 0e4e517..1a240bd 100644 --- a/Data/DS_app.Designer.cs +++ b/Data/DS_app.Designer.cs @@ -2151,6 +2151,8 @@ namespace Data { private global::System.Data.DataColumn columnidxArea; + private global::System.Data.DataColumn columnAttivazione; + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] public RelFornitore2AreaDataTable() { @@ -2200,6 +2202,14 @@ namespace Data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + public global::System.Data.DataColumn AttivazioneColumn { + get { + return this.columnAttivazione; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] [global::System.ComponentModel.Browsable(false)] @@ -2237,11 +2247,12 @@ namespace Data { [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] - public RelFornitore2AreaRow AddRelFornitore2AreaRow(AnagAreeRow parentAnagAreeRowByAnagAree_RelFornitore2Area) { + public RelFornitore2AreaRow AddRelFornitore2AreaRow(AnagAreeRow parentAnagAreeRowByAnagAree_RelFornitore2Area, System.DateTime Attivazione) { RelFornitore2AreaRow rowRelFornitore2AreaRow = ((RelFornitore2AreaRow)(this.NewRow())); object[] columnValuesArray = new object[] { null, - null}; + null, + Attivazione}; if ((parentAnagAreeRowByAnagAree_RelFornitore2Area != null)) { columnValuesArray[1] = parentAnagAreeRowByAnagAree_RelFornitore2Area[0]; } @@ -2277,6 +2288,7 @@ namespace Data { internal void InitVars() { this.columnidxFornitore = base.Columns["idxFornitore"]; this.columnidxArea = base.Columns["idxArea"]; + this.columnAttivazione = base.Columns["Attivazione"]; } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -2286,6 +2298,8 @@ namespace Data { base.Columns.Add(this.columnidxFornitore); this.columnidxArea = new global::System.Data.DataColumn("idxArea", typeof(int), null, global::System.Data.MappingType.Element); base.Columns.Add(this.columnidxArea); + this.columnAttivazione = new global::System.Data.DataColumn("Attivazione", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element); + base.Columns.Add(this.columnAttivazione); this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] { this.columnidxFornitore, this.columnidxArea}, true)); @@ -3608,6 +3622,23 @@ namespace Data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + public System.DateTime Attivazione { + get { + try { + return ((global::System.DateTime)(this[this.tableRelFornitore2Area.AttivazioneColumn])); + } + catch (global::System.InvalidCastException e) { + throw new global::System.Data.StrongTypingException("Il valore della colonna \'Attivazione\' nella tabella \'RelFornitore2Area\' è DBNull." + + "", e); + } + } + set { + this[this.tableRelFornitore2Area.AttivazioneColumn] = value; + } + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] public AnagAreeRow AnagAreeRow { @@ -3619,6 +3650,18 @@ namespace Data { } } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + public bool IsAttivazioneNull() { + return this.IsNull(this.tableRelFornitore2Area.AttivazioneColumn); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + public void SetAttivazioneNull() { + this[this.tableRelFornitore2Area.AttivazioneColumn] = global::System.Convert.DBNull; + } + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] public AnagFornitoriRow[] GetAnagFornitoriRows() { @@ -5707,11 +5750,23 @@ SELECT idxCond, cod_cond, nome, indirizzo, cap, citta, cod_fisc, idxAmm, cod_Id, [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] private void InitCommandCollection() { - this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1]; + this._commandCollection = new global::System.Data.SqlClient.SqlCommand[3]; this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[0].Connection = this.Connection; this._commandCollection[0].CommandText = "SELECT idxArea, Area, Note, Qta FROM dbo.v_AnagAree"; 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_AAF_getByForn"; + 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("@idxFornitore", 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_AAF_getUnassigned"; + 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("@idxFornitore", 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()] @@ -5737,6 +5792,40 @@ SELECT idxCond, cod_cond, nome, indirizzo, cap, citta, cod_fisc, idxAmm, cod_Id, this.Adapter.Fill(dataTable); return dataTable; } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)] + public virtual DS_app.AnagAreeDataTable getByForn(global::System.Nullable idxFornitore) { + this.Adapter.SelectCommand = this.CommandCollection[1]; + if ((idxFornitore.HasValue == true)) { + this.Adapter.SelectCommand.Parameters[1].Value = ((int)(idxFornitore.Value)); + } + else { + this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value; + } + DS_app.AnagAreeDataTable dataTable = new DS_app.AnagAreeDataTable(); + this.Adapter.Fill(dataTable); + return dataTable; + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)] + public virtual DS_app.AnagAreeDataTable getUnassigned(global::System.Nullable idxFornitore) { + this.Adapter.SelectCommand = this.CommandCollection[2]; + if ((idxFornitore.HasValue == true)) { + this.Adapter.SelectCommand.Parameters[1].Value = ((int)(idxFornitore.Value)); + } + else { + this.Adapter.SelectCommand.Parameters[1].Value = global::System.DBNull.Value; + } + DS_app.AnagAreeDataTable dataTable = new DS_app.AnagAreeDataTable(); + this.Adapter.Fill(dataTable); + return dataTable; + } } /// @@ -6598,29 +6687,37 @@ SELECT idxFornitore, username, password, nome, indirizzo, p_iva, indirizzo_email tableMapping.DataSetTable = "RelFornitore2Area"; tableMapping.ColumnMappings.Add("idxFornitore", "idxFornitore"); tableMapping.ColumnMappings.Add("idxArea", "idxArea"); + tableMapping.ColumnMappings.Add("Attivazione", "Attivazione"); 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].[RelFornitore2Area] WHERE (([idxFornitore] = @Original_idxForni" + - "tore) AND ([idxArea] = @Original_idxArea))"; + "tore) AND ([idxArea] = @Original_idxArea) AND ((@IsNull_Attivazione = 1 AND [Att" + + "ivazione] IS NULL) OR ([Attivazione] = @Original_Attivazione)))"; this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text; this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idxFornitore", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idxFornitore", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idxArea", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idxArea", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); + this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_Attivazione", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Attivazione", global::System.Data.DataRowVersion.Original, true, null, "", "", "")); + this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Attivazione", global::System.Data.SqlDbType.DateTime, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Attivazione", 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].[RelFornitore2Area] ([idxArea]) VALUES (@idxArea);\r\nSELECT idxF" + - "ornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxForn" + - "itore = SCOPE_IDENTITY())"; + this._adapter.InsertCommand.CommandText = "INSERT INTO [dbo].[RelFornitore2Area] ([idxArea], [Attivazione]) VALUES (@idxArea" + + ", @Attivazione);\r\nSELECT idxFornitore, idxArea, Attivazione FROM RelFornitore2Ar" + + "ea WHERE (idxArea = @idxArea) AND (idxFornitore = SCOPE_IDENTITY())"; this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text; this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxArea", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idxArea", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._adapter.InsertCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Attivazione", global::System.Data.SqlDbType.DateTime, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Attivazione", 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].[RelFornitore2Area] SET [idxArea] = @idxArea WHERE (([idxFornitore] = @Original_idxFornitore) AND ([idxArea] = @Original_idxArea)); -SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxFornitore = @idxFornitore)"; + this._adapter.UpdateCommand.CommandText = @"UPDATE [dbo].[RelFornitore2Area] SET [idxArea] = @idxArea, [Attivazione] = @Attivazione WHERE (([idxFornitore] = @Original_idxFornitore) AND ([idxArea] = @Original_idxArea) AND ((@IsNull_Attivazione = 1 AND [Attivazione] IS NULL) OR ([Attivazione] = @Original_Attivazione))); +SELECT idxFornitore, idxArea, Attivazione FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxFornitore = @idxFornitore)"; this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text; this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxArea", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idxArea", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Attivazione", global::System.Data.SqlDbType.DateTime, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Attivazione", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idxFornitore", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idxFornitore", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_idxArea", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "idxArea", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); + this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@IsNull_Attivazione", global::System.Data.SqlDbType.Int, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Attivazione", global::System.Data.DataRowVersion.Original, true, null, "", "", "")); + this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@Original_Attivazione", global::System.Data.SqlDbType.DateTime, 0, global::System.Data.ParameterDirection.Input, 0, 0, "Attivazione", global::System.Data.DataRowVersion.Original, false, null, "", "", "")); this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxFornitore", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 0, 0, "idxFornitore", global::System.Data.DataRowVersion.Current, false, null, "", "", "")); } @@ -6634,11 +6731,18 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] private void InitCommandCollection() { - this._commandCollection = new global::System.Data.SqlClient.SqlCommand[1]; + this._commandCollection = new global::System.Data.SqlClient.SqlCommand[2]; this._commandCollection[0] = new global::System.Data.SqlClient.SqlCommand(); this._commandCollection[0].Connection = this.Connection; - this._commandCollection[0].CommandText = "SELECT idxFornitore, idxArea FROM dbo.RelFornitore2Area"; + this._commandCollection[0].CommandText = "SELECT * FROM dbo.RelFornitore2Area"; 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_RFA_insertQuery"; + 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("@idxFornitore", global::System.Data.SqlDbType.Int, 4, global::System.Data.ParameterDirection.Input, 10, 0, null, global::System.Data.DataRowVersion.Current, false, null, "", "", "")); + this._commandCollection[1].Parameters.Add(new global::System.Data.SqlClient.SqlParameter("@idxArea", 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()] @@ -6698,9 +6802,17 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.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(int Original_idxFornitore, int Original_idxArea) { + public virtual int Delete(int Original_idxFornitore, int Original_idxArea, global::System.Nullable Original_Attivazione) { this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_idxFornitore)); this.Adapter.DeleteCommand.Parameters[1].Value = ((int)(Original_idxArea)); + if ((Original_Attivazione.HasValue == true)) { + this.Adapter.DeleteCommand.Parameters[2].Value = ((object)(0)); + this.Adapter.DeleteCommand.Parameters[3].Value = ((System.DateTime)(Original_Attivazione.Value)); + } + else { + this.Adapter.DeleteCommand.Parameters[2].Value = ((object)(1)); + this.Adapter.DeleteCommand.Parameters[3].Value = global::System.DBNull.Value; + } 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)) { @@ -6721,8 +6833,14 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.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(int idxArea) { + public virtual int Insert(int idxArea, global::System.Nullable Attivazione) { this.Adapter.InsertCommand.Parameters[0].Value = ((int)(idxArea)); + if ((Attivazione.HasValue == true)) { + this.Adapter.InsertCommand.Parameters[1].Value = ((System.DateTime)(Attivazione.Value)); + } + else { + this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value; + } 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)) { @@ -6743,11 +6861,25 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.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(int idxArea, int Original_idxFornitore, int Original_idxArea, int idxFornitore) { + public virtual int Update(int idxArea, global::System.Nullable Attivazione, int Original_idxFornitore, int Original_idxArea, global::System.Nullable Original_Attivazione, int idxFornitore) { this.Adapter.UpdateCommand.Parameters[0].Value = ((int)(idxArea)); - this.Adapter.UpdateCommand.Parameters[1].Value = ((int)(Original_idxFornitore)); - this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(Original_idxArea)); - this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(idxFornitore)); + if ((Attivazione.HasValue == true)) { + this.Adapter.UpdateCommand.Parameters[1].Value = ((System.DateTime)(Attivazione.Value)); + } + else { + this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value; + } + this.Adapter.UpdateCommand.Parameters[2].Value = ((int)(Original_idxFornitore)); + this.Adapter.UpdateCommand.Parameters[3].Value = ((int)(Original_idxArea)); + if ((Original_Attivazione.HasValue == true)) { + this.Adapter.UpdateCommand.Parameters[4].Value = ((object)(0)); + this.Adapter.UpdateCommand.Parameters[5].Value = ((System.DateTime)(Original_Attivazione.Value)); + } + else { + this.Adapter.UpdateCommand.Parameters[4].Value = ((object)(1)); + this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value; + } + this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(idxFornitore)); 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)) { @@ -6768,8 +6900,42 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.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(int Original_idxFornitore, int Original_idxArea) { - return this.Update(Original_idxArea, Original_idxFornitore, Original_idxArea, Original_idxFornitore); + public virtual int Update(global::System.Nullable Attivazione, int Original_idxFornitore, int Original_idxArea, global::System.Nullable Original_Attivazione) { + return this.Update(Original_idxArea, Attivazione, Original_idxFornitore, Original_idxArea, Original_Attivazione, Original_idxFornitore); + } + + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "15.0.0.0")] + [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")] + public virtual int insertQuery(global::System.Nullable idxFornitore, global::System.Nullable idxArea) { + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[1]; + if ((idxFornitore.HasValue == true)) { + command.Parameters[1].Value = ((int)(idxFornitore.Value)); + } + else { + command.Parameters[1].Value = global::System.DBNull.Value; + } + if ((idxArea.HasValue == true)) { + command.Parameters[2].Value = ((int)(idxArea.Value)); + } + else { + command.Parameters[2].Value = global::System.DBNull.Value; + } + global::System.Data.ConnectionState previousConnectionState = command.Connection.State; + if (((command.Connection.State & global::System.Data.ConnectionState.Open) + != global::System.Data.ConnectionState.Open)) { + command.Connection.Open(); + } + int returnValue; + try { + returnValue = command.ExecuteNonQuery(); + } + finally { + if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) { + command.Connection.Close(); + } + } + return returnValue; } } diff --git a/Data/DS_app.xsd b/Data/DS_app.xsd index 7fe72f8..a1a8a1e 100644 --- a/Data/DS_app.xsd +++ b/Data/DS_app.xsd @@ -305,7 +305,30 @@ SELECT idxCond, cod_cond, nome, indirizzo, cap, citta, cod_fisc, idxAmm, cod_Id, - + + + + + dbo.stp_AAF_getByForn + + + + + + + + + + + dbo.stp_AAF_getUnassigned + + + + + + + + @@ -441,37 +464,43 @@ SELECT idxFornitore, username, password, nome, indirizzo, p_iva, indirizzo_email - DELETE FROM [dbo].[RelFornitore2Area] WHERE (([idxFornitore] = @Original_idxFornitore) AND ([idxArea] = @Original_idxArea)) + DELETE FROM [dbo].[RelFornitore2Area] WHERE (([idxFornitore] = @Original_idxFornitore) AND ([idxArea] = @Original_idxArea) AND ((@IsNull_Attivazione = 1 AND [Attivazione] IS NULL) OR ([Attivazione] = @Original_Attivazione))) + + - INSERT INTO [dbo].[RelFornitore2Area] ([idxArea]) VALUES (@idxArea); -SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxFornitore = SCOPE_IDENTITY()) + INSERT INTO [dbo].[RelFornitore2Area] ([idxArea], [Attivazione]) VALUES (@idxArea, @Attivazione); +SELECT idxFornitore, idxArea, Attivazione FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxFornitore = SCOPE_IDENTITY()) + - - SELECT idxFornitore, idxArea FROM dbo.RelFornitore2Area + + SELECT * FROM dbo.RelFornitore2Area - UPDATE [dbo].[RelFornitore2Area] SET [idxArea] = @idxArea WHERE (([idxFornitore] = @Original_idxFornitore) AND ([idxArea] = @Original_idxArea)); -SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxFornitore = @idxFornitore) + UPDATE [dbo].[RelFornitore2Area] SET [idxArea] = @idxArea, [Attivazione] = @Attivazione WHERE (([idxFornitore] = @Original_idxFornitore) AND ([idxArea] = @Original_idxArea) AND ((@IsNull_Attivazione = 1 AND [Attivazione] IS NULL) OR ([Attivazione] = @Original_Attivazione))); +SELECT idxFornitore, idxArea, Attivazione FROM RelFornitore2Area WHERE (idxArea = @idxArea) AND (idxFornitore = @idxFornitore) + - + + + @@ -480,8 +509,22 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A + - + + + + + dbo.stp_RFA_insertQuery + + + + + + + + + @@ -681,6 +724,7 @@ SELECT idxFornitore, idxArea FROM RelFornitore2Area WHERE (idxArea = @idxArea) A + diff --git a/Data/DS_app.xss b/Data/DS_app.xss index 22067c5..b118528 100644 --- a/Data/DS_app.xss +++ b/Data/DS_app.xss @@ -8,9 +8,9 @@ - - - + + + @@ -25,7 +25,7 @@ - + 894 @@ -37,7 +37,7 @@ - + 928 @@ -45,7 +45,7 @@ 928 - 979 + 1025 diff --git a/Data/Data.csproj b/Data/Data.csproj index d4ec7af..2f6d886 100644 --- a/Data/Data.csproj +++ b/Data/Data.csproj @@ -9,8 +9,9 @@ Properties Data Data - v4.6.1 + v4.6.2 512 + true @@ -45,6 +46,7 @@ True DS_app.xsd + True @@ -70,5 +72,11 @@ Settings.Designer.cs + + + {2872dcfe-8b46-43b2-baa0-842a816a2dd5} + SteamWare + + \ No newline at end of file diff --git a/Data/DtProxy.cs b/Data/DtProxy.cs new file mode 100644 index 0000000..8ac9c33 --- /dev/null +++ b/Data/DtProxy.cs @@ -0,0 +1,49 @@ +using SteamWare; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Data +{ + public class DtProxy + { + #region area protected + + protected DtProxy() + { + // inizializzo i table adapters + avvioTableAdapters(); + setupConnectionString(); + } + + /// + /// procedura di avvio dei tableAdapter + /// + protected virtual void avvioTableAdapters() + { + taRFA = new DS_appTableAdapters.RelFornitore2AreaTableAdapter(); + } + /// + /// effettua setup dei connection strings da web.config della singola applicazione + /// + protected virtual void setupConnectionString() + { + string connStr = memLayer.ML.confReadString("B2BCondConnectionString"); + //string connStrFiles = memLayer.ML.confReadString("B2BCondFilesConnectionString"); + // connections del db vocabolario + taRFA.Connection.ConnectionString = connStr; + } + + #endregion + + #region area public + + public DS_appTableAdapters.RelFornitore2AreaTableAdapter taRFA; + + public static DtProxy man = new DtProxy(); + + #endregion + } +} diff --git a/Data/app.config b/Data/app.config index c1c39be..4c76881 100644 --- a/Data/app.config +++ b/Data/app.config @@ -1,10 +1,8 @@ - + - + - \ No newline at end of file + diff --git a/PUB/Content/Site.css b/PUB/Content/Site.css index 89b658e..bb513f5 100644 --- a/PUB/Content/Site.css +++ b/PUB/Content/Site.css @@ -23,51 +23,6 @@ textarea { font-size: 1.2em; font-weight: bold; } -/* Paginazione table */ -/*bs4-aspnet-pager*/ -.bs4-aspnet-pager a, -.bs4-aspnet-pager span { - position: relative; - float: left; - padding: 6px 12px; - margin-left: -1px; - line-height: 1.42857143; - color: #337ab7; - text-decoration: none; - background-color: #fff; - border: 1px solid #ddd; -} -.bs4-aspnet-pager span { - z-index: 3; - color: #fff; - cursor: default; - background-color: #337ab7; - border-color: #337ab7; -} -.bs4-aspnet-pager tr > td:first-child > a, -.bs4-aspnet-pager tr > td:first-child > span { - margin-left: 0; - border-top-left-radius: 4px; - border-bottom-left-radius: 4px; -} -.bs4-aspnet-pager tr > td:last-child > a, -.bs4-aspnet-pager tr > td:last-child > span { - border-top-right-radius: 4px; - border-bottom-right-radius: 4px; -} -.bs4-aspnet-pager a:hover, -.bs4-aspnet-pager span:hover, -.bs4-aspnet-pager a:focus, -.bs4-aspnet-pager span:focus { - z-index: 2; - color: #23527c; - background-color: #eee; - border-color: #ddd; -} -.bs4-aspnet-pager td { - padding: 0; -} -/*end bs4-aspnet-pager */ /* Responsive: Portrait tablets and up */ @media screen and (min-width: 768px) { .jumbotron { diff --git a/PUB/PBO/AnagFornitori.aspx b/PUB/PBO/AnagFornitori.aspx index a38a926..8424637 100644 --- a/PUB/PBO/AnagFornitori.aspx +++ b/PUB/PBO/AnagFornitori.aspx @@ -1,10 +1,19 @@ <%@ Page Title="" Language="C#" MasterPageFile="~/SitePBO.master" AutoEventWireup="true" CodeBehind="AnagFornitori.aspx.cs" Inherits="PUB.PBO.AnagFornitori" %> <%@ Register Src="~/WebUserContols/mod_anagFornitori.ascx" TagPrefix="uc1" TagName="mod_anagFornitori" %> +<%@ Register Src="~/WebUserContols/mod_forn2aree.ascx" TagPrefix="uc1" TagName="mod_forn2aree" %> +
- +
+
+ +
+
+ +
+
diff --git a/PUB/PBO/AnagFornitori.aspx.cs b/PUB/PBO/AnagFornitori.aspx.cs index a55a3d6..004690d 100644 --- a/PUB/PBO/AnagFornitori.aspx.cs +++ b/PUB/PBO/AnagFornitori.aspx.cs @@ -11,7 +11,37 @@ namespace PUB.PBO { protected void Page_Load(object sender, EventArgs e) { + mod_anagFornitori.eh_selected += Mod_anagFornitori_eh_selected; + mod_anagFornitori.eh_reset += Mod_anagFornitori_eh_reset; + } + private void Mod_anagFornitori_eh_reset(object sender, EventArgs e) + { + togglDetail(false); + } + + private void Mod_anagFornitori_eh_selected(object sender, EventArgs e) + { + mod_forn2aree.idxForn = mod_anagFornitori.idxForn; + togglDetail(true); + } + + private void togglDetail(bool showDetail) + { + // cambio classe div + visibilità... + divSide.Visible = showDetail; + divMain.Attributes.Remove("class"); + divSide.Attributes.Remove("class"); + if (showDetail) + { + divMain.Attributes.Add("class", "col-9"); + divSide.Attributes.Add("class", "col-3"); + } + else + { + divMain.Attributes.Add("class", "col-12"); + divSide.Attributes.Add("class", "col-1"); + } } } } \ No newline at end of file diff --git a/PUB/PBO/AnagFornitori.aspx.designer.cs b/PUB/PBO/AnagFornitori.aspx.designer.cs index 18e08e0..7e758ab 100644 --- a/PUB/PBO/AnagFornitori.aspx.designer.cs +++ b/PUB/PBO/AnagFornitori.aspx.designer.cs @@ -12,6 +12,15 @@ namespace PUB.PBO { public partial class AnagFornitori { + /// + /// Controllo divMain. + /// + /// + /// Campo generato automaticamente. + /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind. + /// + protected global::System.Web.UI.HtmlControls.HtmlGenericControl divMain; + /// /// Controllo mod_anagFornitori. /// @@ -20,5 +29,23 @@ namespace PUB.PBO { /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind. /// protected global::PUB.WebUserContols.mod_anagFornitori mod_anagFornitori; + + /// + /// Controllo divSide. + /// + /// + /// Campo generato automaticamente. + /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind. + /// + protected global::System.Web.UI.HtmlControls.HtmlGenericControl divSide; + + /// + /// Controllo mod_forn2aree. + /// + /// + /// Campo generato automaticamente. + /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind. + /// + protected global::PUB.WebUserContols.mod_forn2aree mod_forn2aree; } } diff --git a/PUB/PBO20180518.txt b/PUB/PBO20180518.txt new file mode 100644 index 0000000..651e9d1 --- /dev/null +++ b/PUB/PBO20180518.txt @@ -0,0 +1,83 @@ +8:41:11 4779 Caricati 166 lemmi! +8:42:55 3974 Caricati 166 lemmi! +8:43:01 7275 Caricati 166 lemmi! +8:45:19 7101 Caricati 166 lemmi! +8:48:07 9338 Caricati 166 lemmi! +8:49:42 8913 Caricati 166 lemmi! +8:49:46 5278 Caricati 166 lemmi! +9:01:07 1670 Caricati 166 lemmi! +9:03:34 5098 Caricati 166 lemmi! +9:03:39 4903 Caricati 166 lemmi! +9:06:30 6894 Caricati 166 lemmi! +9:06:35 2954 Caricati 166 lemmi! +9:13:06 4411 Caricati 166 lemmi! +9:35:24 4048 Errore in startupAppConf: +System.Data.SqlClient.SqlException (0x80131904): Invalid object name 'dbo.Config'. + in System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + in System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + in System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) + in System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) + in System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() + in System.Data.SqlClient.SqlDataReader.get_MetaData() + in System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption) + in System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) + in System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) + in System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) + in System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) + in System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) + in System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) + in SteamWare.DS_UtilityTableAdapters.ConfigTableAdapter.GetData() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\DS_Utility.Designer.cs:riga 2669 + in SteamWare.memLayer.ricaricaAppConf() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\memLayer.cs:riga 192 + in SteamWare.memLayer.startupAppConf() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\memLayer.cs:riga 150 +ClientConnectionId:74c894c4-7506-41b5-84ac-6c463e4e5a5f +Error Number:208,State:1,Class:16 +9:35:24 4078 Errore in startupAppConf: +System.Data.SqlClient.SqlException (0x80131904): Invalid object name 'dbo.Config'. + in System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + in System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + in System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) + in System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) + in System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() + in System.Data.SqlClient.SqlDataReader.get_MetaData() + in System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption) + in System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) + in System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) + in System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) + in System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) + in System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) + in System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) + in SteamWare.DS_UtilityTableAdapters.ConfigTableAdapter.GetData() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\DS_Utility.Designer.cs:riga 2669 + in SteamWare.memLayer.ricaricaAppConf() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\memLayer.cs:riga 192 + in SteamWare.memLayer.startupAppConf() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\memLayer.cs:riga 150 +ClientConnectionId:74c894c4-7506-41b5-84ac-6c463e4e5a5f +Error Number:208,State:1,Class:16 +9:35:24 4108 Errore in startupAppConf: +System.Data.SqlClient.SqlException (0x80131904): Invalid object name 'dbo.Config'. + in System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + in System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction) + in System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) + in System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) + in System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() + in System.Data.SqlClient.SqlDataReader.get_MetaData() + in System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption) + in System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) + in System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) + in System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) + in System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) + in System.Data.SqlClient.SqlCommand.ExecuteDbDataReader(CommandBehavior behavior) + in System.Data.Common.DbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.Fill(DataTable[] dataTables, Int32 startRecord, Int32 maxRecords, IDbCommand command, CommandBehavior behavior) + in System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) + in SteamWare.DS_UtilityTableAdapters.ConfigTableAdapter.GetData() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\DS_Utility.Designer.cs:riga 2669 + in SteamWare.memLayer.ricaricaAppConf() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\memLayer.cs:riga 192 + in SteamWare.memLayer.startupAppConf() in C:\Users\samuele.steamw\Documents\VisualStudioProject\Steamware\SteamWareLib\memLayer.cs:riga 150 +ClientConnectionId:74c894c4-7506-41b5-84ac-6c463e4e5a5f +Error Number:208,State:1,Class:16 +9:35:24 4288 Caricati 166 lemmi! diff --git a/PUB/PUB.csproj b/PUB/PUB.csproj index c70166c..f2ad0ad 100644 --- a/PUB/PUB.csproj +++ b/PUB/PUB.csproj @@ -215,6 +215,7 @@ + @@ -270,7 +271,9 @@ - + + Designer + @@ -480,6 +483,13 @@ mod_contabilita.ascx + + mod_forn2aree.ascx + ASPXCodeBehind + + + mod_forn2aree.ascx + mod_graficiRow.ascx ASPXCodeBehind diff --git a/PUB/Web.config b/PUB/Web.config index f35fe1e..b19a9ee 100644 --- a/PUB/Web.config +++ b/PUB/Web.config @@ -6,11 +6,12 @@ - -
- + @@ -50,8 +50,6 @@ - - @@ -61,8 +59,6 @@ - - diff --git a/PUB/WebUserContols/mod_anagFornitori.ascx.cs b/PUB/WebUserContols/mod_anagFornitori.ascx.cs index a17735c..4060ed6 100644 --- a/PUB/WebUserContols/mod_anagFornitori.ascx.cs +++ b/PUB/WebUserContols/mod_anagFornitori.ascx.cs @@ -9,6 +9,19 @@ namespace PUB.WebUserContols { public partial class mod_anagFornitori : System.Web.UI.UserControl { + /// + /// indicato (nuovo) numero righe x pagina + /// + public event EventHandler eh_selected; + /// + /// indicato (nuovo) numero righe x pagina + /// + public event EventHandler eh_reset; + /// + /// Load pagina + /// + /// + /// protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) @@ -36,6 +49,11 @@ namespace PUB.WebUserContols { grView.SelectedIndex = -1; grView.DataBind(); + // sollevo evento nuovo valore... + if (eh_reset != null) + { + eh_reset(this, new EventArgs()); + } } public void doUpdate() { @@ -51,5 +69,24 @@ namespace PUB.WebUserContols { doUpdate(); } + + public int idxForn + { + get + { + int answ = 0; + int.TryParse(grView.SelectedValue.ToString(), out answ); + return answ; + } + } + + protected void grView_SelectedIndexChanged(object sender, EventArgs e) + { + // sollevo evento nuovo valore... + if (eh_selected != null) + { + eh_selected(this, new EventArgs()); + } + } } } \ No newline at end of file diff --git a/PUB/WebUserContols/mod_forn2aree.ascx b/PUB/WebUserContols/mod_forn2aree.ascx new file mode 100644 index 0000000..4301c42 --- /dev/null +++ b/PUB/WebUserContols/mod_forn2aree.ascx @@ -0,0 +1,38 @@ +<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_forn2aree.ascx.cs" Inherits="PUB.WebUserContols.mod_forn2aree" %> +<%@ Register Src="~/WebUserContols/cmp_numRow.ascx" TagPrefix="uc1" TagName="cmp_numRow" %> + +
+
+
+
+ Aggiungi +
+
+ + + + + + + +
+
+
+
+ + + + + + + + + + + + + + + <%--

su click mostro i dati di statistiche: es num condomini, num interventi periodo, fatturato last 12 mesi generato, ...

--%> +
+
diff --git a/PUB/WebUserContols/mod_forn2aree.ascx.cs b/PUB/WebUserContols/mod_forn2aree.ascx.cs new file mode 100644 index 0000000..92d91d0 --- /dev/null +++ b/PUB/WebUserContols/mod_forn2aree.ascx.cs @@ -0,0 +1,96 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; +using System.Web.UI; +using System.Web.UI.WebControls; +using Data; + +namespace PUB.WebUserContols +{ + public partial class mod_forn2aree : System.Web.UI.UserControl + { + /// + /// indicato (nuovo) numero righe x pagina + /// + public event EventHandler eh_selected; + /// + /// indicato (nuovo) numero righe x pagina + /// + public event EventHandler eh_reset; + /// + /// Load pagina + /// + /// + /// + protected void Page_Load(object sender, EventArgs e) + { + } + + + protected void lbtReset_Click(object sender, EventArgs e) + { + grView.SelectedIndex = -1; + grView.DataBind(); + // sollevo evento nuovo valore... + if (eh_reset != null) + { + eh_reset(this, new EventArgs()); + } + } + public void doUpdate() + { + grView.DataBind(); + } + + protected void grView_DataBound(object sender, EventArgs e) + { + } + + protected void grView_SelectedIndexChanged(object sender, EventArgs e) + { + // sollevo evento nuovo valore... + if (eh_selected != null) + { + eh_selected(this, new EventArgs()); + } + } + /// + /// Fornitore selezionato + /// + public int idxForn + { + get + { + int answ = 0; + int.TryParse(hfIdxForn.Value, out answ); + return answ; + } + set + { + hfIdxForn.Value = value.ToString(); + } + } + /// + /// NUOVA Area selezionata + /// + public int idxAreaNew + { + get + { + int answ = 0; + int.TryParse(ddlAree.SelectedValue, out answ); + return answ; + } + } + + protected void lbtAdd_Click(object sender, EventArgs e) + { + // aggiungo area selezionata... + DtProxy.man.taRFA.insertQuery(idxForn, idxAreaNew); + // aggiorno... + grView.DataBind(); + ddlAree.DataBind(); + } + } +} \ No newline at end of file diff --git a/PUB/WebUserContols/mod_forn2aree.ascx.designer.cs b/PUB/WebUserContols/mod_forn2aree.ascx.designer.cs new file mode 100644 index 0000000..691fc68 --- /dev/null +++ b/PUB/WebUserContols/mod_forn2aree.ascx.designer.cs @@ -0,0 +1,69 @@ +//------------------------------------------------------------------------------ +// +// Codice generato da uno strumento. +// +// Le modifiche a questo file possono causare un comportamento non corretto e verranno perse se +// il codice viene rigenerato. +// +//------------------------------------------------------------------------------ + +namespace PUB.WebUserContols { + + + public partial class mod_forn2aree { + + /// + /// Controllo lbtAdd. + /// + /// + /// 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 lbtAdd; + + /// + /// Controllo ddlAree. + /// + /// + /// 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.DropDownList ddlAree; + + /// + /// Controllo odsAree. + /// + /// + /// 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.ObjectDataSource odsAree; + + /// + /// Controllo grView. + /// + /// + /// 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.GridView grView; + + /// + /// Controllo ods. + /// + /// + /// 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.ObjectDataSource ods; + + /// + /// Controllo hfIdxForn. + /// + /// + /// 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.HiddenField hfIdxForn; + } +}