From da5999ee08de8f6267a4ed491b79b36649c52186 Mon Sep 17 00:00:00 2001 From: wxr <464027401@qq.com> Date: 星期一, 27 十二月 2021 11:52:22 +0800 Subject: [PATCH] 备份 --- HDL_ON/UI/UI2/FuntionControlView/Electrical/SocketPage_CumulativePowerConsumption.cs | 47 +++++++++++++++++++++++++++++++++++++---------- 1 files changed, 37 insertions(+), 10 deletions(-) diff --git a/HDL_ON/UI/UI2/FuntionControlView/Electrical/SocketPage_CumulativePowerConsumption.cs b/HDL_ON/UI/UI2/FuntionControlView/Electrical/SocketPage_CumulativePowerConsumption.cs index 1c5dc5c..e4a7974 100644 --- a/HDL_ON/UI/UI2/FuntionControlView/Electrical/SocketPage_CumulativePowerConsumption.cs +++ b/HDL_ON/UI/UI2/FuntionControlView/Electrical/SocketPage_CumulativePowerConsumption.cs @@ -174,11 +174,11 @@ #region 閫夋嫨鏁版嵁鏃ユ湡鑼冨洿 var showDataTypeView = new FrameLayout() { - X = Application.GetRealWidth(183), + X = Application.GetRealWidth(136), Y = Application.GetRealHeight(12), - Width = Application.GetRealWidth(144), + Width = Application.GetRealWidth(144+47), Height = Application.GetRealHeight(24), - BackgroundImagePath = "FunctionIcon/EnvironmentalScience/SensorHistoryBg1.png", + BackgroundImagePath = "FunctionIcon/EnvironmentalScience/HistoryOpionBg1.png", }; diagramView.AddChidren(showDataTypeView); @@ -214,41 +214,68 @@ TextColor = CSS_Color.PromptingColor2, SelectedTextColor = CSS_Color.MainColor, TextSize = CSS_FontSize.PromptFontSize_FirstLevel, - Text = Language.StringByID(StringId.month),//DateTime.Now.Month.ToString() + + Text = Language.StringByID(StringId.month) }; showDataTypeView.AddChidren(btnShowHistroyData_Month); + + var btnShowHistroyData_Year = new Button() + { + X = Application.GetRealWidth(48 * 3), + Width = Application.GetRealWidth(48), + TextAlignment = TextAlignment.Center, + TextColor = CSS_Color.PromptingColor2, + SelectedTextColor = CSS_Color.MainColor, + TextSize = CSS_FontSize.PromptFontSize_FirstLevel, + Text = Language.StringByID(StringId.Years), + }; + showDataTypeView.AddChidren(btnShowHistroyData_Year); btnShowHistroyData_Day.MouseUpEventHandler = (sender, e) => { - showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/SensorHistoryBg1.png"; + showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/HistoryOpionBg1.png"; btnShowHistroyData_Day.IsSelected = true; btnShowHistroyData_Month.IsSelected = false; btnShowHistroyData_Week.IsSelected = false; + btnShowHistroyData_Year.IsSelected = false; curQueryType = "hour"; brokenLine.YvalueText = ""; - LoadMothed_GetHistoryData(); + LoadMothed_GetHistoryData(); }; btnShowHistroyData_Week.MouseUpEventHandler = (sender, e) => { - showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/SensorHistoryBg2.png"; + showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/HistoryOpionBg2.png"; btnShowHistroyData_Day.IsSelected = false; btnShowHistroyData_Month.IsSelected = false; btnShowHistroyData_Week.IsSelected = true; + btnShowHistroyData_Year.IsSelected = false; curQueryType = "week"; brokenLine.YvalueText = ""; - LoadMothed_GetHistoryData(); + LoadMothed_GetHistoryData(); }; btnShowHistroyData_Month.MouseUpEventHandler = (sender, e) => { - showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/SensorHistoryBg3.png"; + showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/HistoryOpionBg3.png"; btnShowHistroyData_Day.IsSelected = false; btnShowHistroyData_Month.IsSelected = true; btnShowHistroyData_Week.IsSelected = false; + btnShowHistroyData_Year.IsSelected = false; curQueryType = "month"; brokenLine.YvalueText = ""; - LoadMothed_GetHistoryData(); + LoadMothed_GetHistoryData(); + }; + + btnShowHistroyData_Year.MouseUpEventHandler = (sender, e) => + { + showDataTypeView.BackgroundImagePath = "FunctionIcon/EnvironmentalScience/HistoryOpionBg4.png"; + btnShowHistroyData_Day.IsSelected = false; + btnShowHistroyData_Month.IsSelected = false; + btnShowHistroyData_Year.IsSelected = true; + btnShowHistroyData_Week.IsSelected = false; + curQueryType = "year_month"; + brokenLine.YvalueText = ""; + LoadMothed_GetHistoryData(); }; #endregion -- Gitblit v1.8.0