diff --git a/Jenkinsfile b/Jenkinsfile index ae40c40f..695c26ad 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -13,7 +13,7 @@ pipeline { steps { /* calcolo numero versione... diverso x branch MASTER/DEVELOP */ script { - withEnv(['NEXT_BUILD_NUMBER=1379']) { + withEnv(['NEXT_BUILD_NUMBER=1380']) { // env.versionNumber = VersionNumber(versionNumberString : '6.12.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true) env.versionNumber = VersionNumber(versionNumberString : '6.12.${BUILD_DATE_FORMATTED, "yyMM"}.${BUILDS_ALL_TIME}', projectStartDate : '2006-01-01', skipFailedBuilds: true, overrideBuildsAllTime: '${NEXT_BUILD_NUMBER}') env.APP_NAME = 'MAPO' diff --git a/MP-ADM/Planner.aspx.cs b/MP-ADM/Planner.aspx.cs index 03065cf8..4b70f22e 100644 --- a/MP-ADM/Planner.aspx.cs +++ b/MP-ADM/Planner.aspx.cs @@ -9,13 +9,15 @@ namespace MP_ADM private void checkEnabled() { - bool optPar = memLayer.ML.CRB("OptAdmKitEnabled"); + // FIXME TODO + // !!! FARE!!! vera verifica licenza ES3 in AnagKeyValue... + bool optPar = memLayer.ML.CRB("OptAdmPlanEnabled"); divContent.Visible = optPar; lblDataImportOut.Visible = !optPar; string messaggio = ""; if (!optPar) { - messaggio = "Attenzione: Gestione KIT disabilitata"; + messaggio = "Attenzione: Gestione PLANNER disabilitata"; lblDataImportOut.Text = messaggio; } } @@ -87,6 +89,7 @@ namespace MP_ADM { if (!Page.IsPostBack) { + checkFixPromIn(); toggleVisibility(); } checkEnabled(); @@ -99,6 +102,12 @@ namespace MP_ADM cmp_PODL_OUT.eh_nuovoValore += Cmp_PODL_OUT_eh_nuovoValore; } + private void checkFixPromIn() + { + // chiama stored x riallineamento prom IN che fossero pending (-10) x chiudere SE processate tutte le prom a valle (promOut con idxODL > 0) + DataLayerObj.taPromIn.updProc(); + } + #endregion Protected Methods } } \ No newline at end of file diff --git a/MapoDb/DS_Plan.Designer.cs b/MapoDb/DS_Plan.Designer.cs index a34fa5d4..3a488eeb 100644 --- a/MapoDb/DS_Plan.Designer.cs +++ b/MapoDb/DS_Plan.Designer.cs @@ -11023,13 +11023,18 @@ 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[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 idxPromessa, KeyRichiesta, KeyBCode, Attivabile, IdxODL, CodArticolo, CodG" + "ruppo, IdxMacchina, NumPezzi, TCAssegnato, DueDate, Priorita, PzPallet, Note FRO" + "M dbo.PromesseIN"; 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_PODL_IN_updProc"; + 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, "", "", "")); } [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] @@ -11385,6 +11390,28 @@ SELECT idxPromessa, KeyRichiesta, KeyBCode, Attivabile, IdxODL, CodArticolo, Cod string Original_Note) { return this.Update(KeyRichiesta, KeyBCode, Attivabile, IdxODL, CodArticolo, CodGruppo, IdxMacchina, NumPezzi, TCAssegnato, DueDate, Priorita, PzPallet, Note, Original_idxPromessa, Original_KeyRichiesta, Original_KeyBCode, Original_Attivabile, Original_IdxODL, Original_CodArticolo, Original_CodGruppo, Original_IdxMacchina, Original_NumPezzi, Original_TCAssegnato, Original_DueDate, Original_Priorita, Original_PzPallet, Original_Note, Original_idxPromessa); } + + [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 updProc() { + global::System.Data.SqlClient.SqlCommand command = this.CommandCollection[1]; + 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/MapoDb/DS_Plan.xsd b/MapoDb/DS_Plan.xsd index d61753c9..adfcb492 100644 --- a/MapoDb/DS_Plan.xsd +++ b/MapoDb/DS_Plan.xsd @@ -346,7 +346,18 @@ SELECT idxPromessa, KeyRichiesta, KeyBCode, Attivabile, IdxODL, CodArticolo, Cod - + + + + + dbo.stp_PODL_IN_updProc + + + + + + + @@ -757,7 +768,7 @@ ORDER BY TotOreRich DESC - + @@ -770,7 +781,7 @@ ORDER BY TotOreRich DESC - + @@ -800,7 +811,7 @@ ORDER BY TotOreRich DESC - + @@ -823,7 +834,7 @@ ORDER BY TotOreRich DESC - + @@ -846,7 +857,7 @@ ORDER BY TotOreRich DESC - + @@ -965,7 +976,7 @@ ORDER BY TotOreRich DESC - + @@ -1021,7 +1032,7 @@ ORDER BY TotOreRich DESC - + @@ -1147,7 +1158,7 @@ ORDER BY TotOreRich DESC - + @@ -1169,7 +1180,7 @@ ORDER BY TotOreRich DESC - + @@ -1183,7 +1194,7 @@ ORDER BY TotOreRich DESC - + @@ -1199,7 +1210,7 @@ ORDER BY TotOreRich DESC - + @@ -1221,7 +1232,7 @@ ORDER BY TotOreRich DESC - + @@ -1243,7 +1254,7 @@ ORDER BY TotOreRich DESC - + @@ -1263,7 +1274,7 @@ ORDER BY TotOreRich DESC - + @@ -1282,7 +1293,7 @@ ORDER BY TotOreRich DESC - + @@ -1348,8 +1359,8 @@ ORDER BY TotOreRich DESC - - + + \ No newline at end of file diff --git a/MapoDb/DataLayer.cs b/MapoDb/DataLayer.cs index 994d5a5c..3d6e9cac 100644 --- a/MapoDb/DataLayer.cs +++ b/MapoDb/DataLayer.cs @@ -66,6 +66,7 @@ namespace MapoDb public DS_PlanTableAdapters.RichiesteTableAdapter taPlanRichieste; public DS_ProdTempiTableAdapters.PromesseODLTableAdapter taPODL; public DS_ProdTempiTableAdapters.PostazioniMapoTableAdapter taPostazioni; + public DS_PlanTableAdapters.PromesseINTableAdapter taPromIn; public DS_PlanTableAdapters.PromesseOUTTableAdapter taPromOut; public DS_ProdTempiTableAdapters.stp_PzProd_getByMacchinaTableAdapter taPzProd2conf; public DS_ProdTempiTableAdapters.RegistroControlliTableAdapter taRC; @@ -519,6 +520,7 @@ namespace MapoDb taPlanRichieste = new DS_PlanTableAdapters.RichiesteTableAdapter(); taPODL = new DS_ProdTempiTableAdapters.PromesseODLTableAdapter(); taPostazioni = new DS_ProdTempiTableAdapters.PostazioniMapoTableAdapter(); + taPromIn = new DS_PlanTableAdapters.PromesseINTableAdapter(); taPromOut = new DS_PlanTableAdapters.PromesseOUTTableAdapter(); taPzProd2conf = new DS_ProdTempiTableAdapters.stp_PzProd_getByMacchinaTableAdapter(); taRC = new DS_ProdTempiTableAdapters.RegistroControlliTableAdapter(); @@ -585,6 +587,7 @@ namespace MapoDb taPlanRichieste.Connection.ConnectionString = connectionStringES3; taPODL.Connection.ConnectionString = connectionString; taPostazioni.Connection.ConnectionString = connectionString; + taPromIn.Connection.ConnectionString = connectionStringES3; taPromOut.Connection.ConnectionString = connectionStringES3; taPzProd2conf.Connection.ConnectionString = connectionString; taRC.Connection.ConnectionString = connectionString;