From edd6f453ff454268e44ceab8d2ebaf1c81a923d6 Mon Sep 17 00:00:00 2001 From: "Samuele E. Locatelli" Date: Thu, 7 Jun 2018 22:13:03 +0200 Subject: [PATCH] Altri avanzamenti x gestire sequencer con vis.js e redis --- MP-Site/MappaStatoSeq.aspx | 3 +++ MP-Site/MappaStatoSeq.aspx.cs | 9 ++++++- MP-Site/MappaStatoSeq.aspx.designer.cs | 9 +++++++ MP-Site/WS/MPData.asmx.cs | 2 +- MP-Site/Web.config | 2 +- MP-Site/WebMasterPages/MAPO_refresh30.master | 4 ++- .../WebUserControls/mod_sequencerStatiJS.ascx | 26 +++++++------------ .../mod_sequencerStatiJS.ascx.cs | 6 +++-- 8 files changed, 39 insertions(+), 22 deletions(-) diff --git a/MP-Site/MappaStatoSeq.aspx b/MP-Site/MappaStatoSeq.aspx index c050d95b..69ee8c80 100644 --- a/MP-Site/MappaStatoSeq.aspx +++ b/MP-Site/MappaStatoSeq.aspx @@ -3,6 +3,8 @@ <%@ Register Src="~/WebUserControls/mod_sequencerStati.ascx" TagPrefix="uc1" TagName="mod_sequencerStati" %> <%@ Register Src="~/WebUserControls/mod_sequencerStatiJS.ascx" TagPrefix="uc1" TagName="mod_sequencerStatiJS" %> <%@ Register Src="~/WebUserControls/mod_mainMap.ascx" TagPrefix="uc1" TagName="mod_mainMap" %> +<%@ Register Src="~/WebUserControls/mod_realtimeClock.ascx" TagPrefix="uc1" TagName="mod_realtimeClock" %> + + <%-- diff --git a/MP-Site/MappaStatoSeq.aspx.cs b/MP-Site/MappaStatoSeq.aspx.cs index cbe67789..e487c514 100644 --- a/MP-Site/MappaStatoSeq.aspx.cs +++ b/MP-Site/MappaStatoSeq.aspx.cs @@ -31,7 +31,10 @@ namespace MoonPro get { intervalloDate answ = new intervalloDate(); - answ.fine = DateTime.Now; + // arrotondo all'ultima ora x adesso.. + DateTime finePeriodo = DateTime.Now; + finePeriodo = finePeriodo.Date.AddHours(finePeriodo.Hour); + answ.fine = finePeriodo; answ.inizio = answ.fine.AddDays(-numGg); return answ; } @@ -45,6 +48,8 @@ namespace MoonPro { ddlNumgg.DataBind(); ddlNumgg.SelectedValue = memLayer.ML.confReadString("seq_gg"); + // imposto date di intervallo + mod_sequencerStatiJS2.periodo = intervalloAnalisi; } //if (memLayer.ML.BoolSessionObj("graphDataRefresh")) //{ @@ -80,6 +85,7 @@ namespace MoonPro protected void ddlNumgg_SelectedIndexChanged(object sender, EventArgs e) { + mod_sequencerStatiJS2.periodo = intervalloAnalisi; #if false repSeq.DataBind(); #endif @@ -121,6 +127,7 @@ namespace MoonPro protected void btnReload_Click(object sender, EventArgs e) { + mod_sequencerStatiJS2.periodo = intervalloAnalisi; #if false repSeq.DataBind(); #endif diff --git a/MP-Site/MappaStatoSeq.aspx.designer.cs b/MP-Site/MappaStatoSeq.aspx.designer.cs index 7f149b73..9be6cbc6 100644 --- a/MP-Site/MappaStatoSeq.aspx.designer.cs +++ b/MP-Site/MappaStatoSeq.aspx.designer.cs @@ -48,6 +48,15 @@ namespace MoonPro { /// protected global::MoonPro.WebUserControls.mod_mainMap mod_mainMap; + /// + /// Controllo mod_realtimeClock. + /// + /// + /// Campo generato automaticamente. + /// Per la modifica, spostare la dichiarazione di campo dal file di progettazione al file code-behind. + /// + protected global::MoonPro.WebUserControls.mod_realtimeClock mod_realtimeClock; + /// /// Controllo mod_sequencerStatiJS2. /// diff --git a/MP-Site/WS/MPData.asmx.cs b/MP-Site/WS/MPData.asmx.cs index 54f66a9a..8410e948 100644 --- a/MP-Site/WS/MPData.asmx.cs +++ b/MP-Site/WS/MPData.asmx.cs @@ -81,7 +81,7 @@ namespace MoonPro.WS inizio = Convert.ToDateTime(dataFrom), fine = Convert.ToDateTime(dataTo) }; - string rKey = string.Format("jsonSeq_MIF_{0}_{1}_{2}_{3}", idxMacch, numSplit, _intervallo.inizio.ToString("yyyyMMdd_hhmmss"), _intervallo.fine.ToString("yyyyMMdd_hhmmss")).Replace(" ", "_"); + string rKey = string.Format("jsonSeq_MIF_{0}_{1}_{2}_{3}", idxMacch, numSplit, _intervallo.inizio.ToString("yyyyMMdd_HHmmss"), _intervallo.fine.ToString("yyyyMMdd_HHmmss")).Replace(" ", "_"); //logger.lg.scriviLog("Nome key: " + rKey); // oggetti x proseguire... diff --git a/MP-Site/Web.config b/MP-Site/Web.config index fe747c80..fd172c16 100644 --- a/MP-Site/Web.config +++ b/MP-Site/Web.config @@ -19,7 +19,7 @@ - + diff --git a/MP-Site/WebMasterPages/MAPO_refresh30.master b/MP-Site/WebMasterPages/MAPO_refresh30.master index 8b0112ff..2acb0d14 100644 --- a/MP-Site/WebMasterPages/MAPO_refresh30.master +++ b/MP-Site/WebMasterPages/MAPO_refresh30.master @@ -9,7 +9,9 @@ MoonPro - MOnitor ONline della PROduzione - + + +
diff --git a/MP-Site/WebUserControls/mod_sequencerStatiJS.ascx b/MP-Site/WebUserControls/mod_sequencerStatiJS.ascx index 7f249912..6fe390c9 100644 --- a/MP-Site/WebUserControls/mod_sequencerStatiJS.ascx +++ b/MP-Site/WebUserControls/mod_sequencerStatiJS.ascx @@ -1,5 +1,5 @@ <%@ Control Language="C#" AutoEventWireup="true" CodeBehind="mod_sequencerStatiJS.ascx.cs" Inherits="MoonPro.WebUserControls.mod_sequencerStatiJS" %> - +
@@ -9,8 +9,11 @@