From 23c9d1577fd0c02ca6976c874855ad60268646b8 Mon Sep 17 00:00:00 2001 From: wjc <1243177876@qq.com> Date: 星期一, 25 七月 2022 10:31:16 +0800 Subject: [PATCH] 2022年07月25日10:31:11 --- HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs | 89 ++++++++++++++++++++++++++++++++------------ 1 files changed, 64 insertions(+), 25 deletions(-) diff --git a/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs b/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs index 8fff50b..24f5dc4 100644 --- a/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs +++ b/HDL_ON/UI/UI2/3-Intelligence/Automation/ConditionDeviceFunList.cs @@ -216,6 +216,40 @@ view1.frameLayout.Y = view.frameLayout.Bottom; view1.btnText.TextID = StringId.fangchaigongneng; fLayout.AddChidren(view1.FLayoutView()); + + + int intValue = 0; + if (edit) + { + Input inputs = Logic.currlogic.input[index]; + var dicList = inputs.condition; + foreach (var dic in dicList) + { + if (dic["key"] == "people_status") + { + //鏈変汉/鏃犱汉 + intValue = 1; + } + else + { + //闃叉媶鍔熻兘 + intValue = 2; + } + break; + + } + } + if (intValue == 1) + { + //鏈変汉/鏃犱汉 + view1.frameLayout.Visible = false; + + } + else if (intValue == 2) + { + //闃叉媶鍔熻兘 + view1.frameLayout.Y = Application.GetRealHeight(0); + } view1.btnClick.MouseUpEventHandler += (sender, e) => { DeviceView(device, view1.btnState, StringId.zaixian, StringId.buzaixian); @@ -230,25 +264,7 @@ //姣背娉紶鎰熷櫒(鑷爺鍖楅偖) case SPK.SenesorMegahealth: { - int intValue =0; - if (edit) - { - Input inputs = Logic.currlogic.input[index]; - var dicList = inputs.condition; - foreach (var dic in dicList) - { - if (dic["key"] == "target_status") - { - intValue = 1; - } - else - { - intValue = 2; - } - break; - - } - } + LogicView.FunTypeView view1= new LogicView.FunTypeView(); view1.btnText.TextID = StringId.diedaobaojing; view1.btnState.Name = Language.StringByID(StringId.diedaobaojing); @@ -263,13 +279,36 @@ view2.btnText.TextID = StringId.yourenbaojing; view2.btnState.Name = Language.StringByID(StringId.yourenbaojing); fLayout.AddChidren(view2.FLayoutView()); - - if (intValue==1) { - view2.frameLayout.Visible = false; - - } - if (intValue == 2) + int intValue = 0; + if (edit) { + Input inputs = Logic.currlogic.input[index]; + var dicList = inputs.condition; + foreach (var dic in dicList) + { + if (dic["key"] == "target_status") + { + //璺屽�掓姤璀� + intValue = 1; + } + else + { + //鏈変汉鎶ヨ + intValue = 2; + } + break; + + } + } + if (intValue == 1) + { + //璺屽�掓姤璀� + view2.frameLayout.Visible = false; + + } + else if (intValue == 2) + { + //鏈変汉鎶ヨ view2.frameLayout.Y = Application.GetRealHeight(0); } -- Gitblit v1.8.0