wei
2020-12-22 bac00b1bc932d3a85f90986466757b24d9407d61
Merge remote-tracking branch 'origin/WJC' into NewFilePath
2个文件已修改
64 ■■■■■ 已修改文件
HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs 30 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs 34 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
HDL_ON/UI/UI2/3-Intelligence/Automation/InpOrOutLogicMethod.cs
@@ -173,7 +173,7 @@
        /// <param name="viewLayout">上下滑动控件</param>
        public static void OutputTarget(FrameLayout thisView, VerticalScrolViewLayout viewLayout)
        {
            for (int i = 0; i < Logic.currlogic.output.Count; i++)
            {
                Output outputTarget = Logic.currlogic.output[i];
@@ -230,33 +230,23 @@
                                    {
                                        string on_off = GetKeyValue("on_off", dicList);
                                        string brightness = GetKeyValue("brightness", dicList);
                                        if (on_off != "")
                                        if (on_off == "on" && brightness != "")
                                        {
                                            if (on_off == "on")
                                            {
                                                stateStr = Language.StringByID(StringId.onLogic);
                                            }
                                            else
                                            {
                                                stateStr = Language.StringByID(StringId.offLogic);
                                            }
                                            stateStr = Language.StringByID(StringId.onLogic) + brightness + "%";
                                        }
                                        if (brightness != "")
                                        else if (on_off == "on")
                                        {
                                            stateStr += brightness + "%";
                                            stateStr = Language.StringByID(StringId.onLogic);
                                        }
                                        if (on_off != "" && on_off == "off")
                                        else if (on_off == "off")
                                        {
                                            targetView.btnState.Text = Language.StringByID(StringId.offLogic);
                                            stateStr = Language.StringByID(StringId.offLogic);
                                        }
                                        else
                                        else if (brightness != "")
                                        {
                                            targetView.btnState.Text = stateStr;
                                            stateStr = brightness + "%";
                                        }
                                        targetView.btnState.Text = stateStr;
                                    }
                                    break;
                                case FunctionType.Curtain:
HDL_ON/UI/UI2/3-Intelligence/Automation/TargetDeviceFunList.cs
@@ -482,7 +482,7 @@
                                            {
                                                //移除列表所有数据
                                                dicSateteList.Clear();
                                                //重新添加开光属性数据
                                                //重新添加-关-属性数据
                                                Dictionary<string, string> diction = new Dictionary<string, string>();
                                                diction.Add("key", "on_off");
                                                diction.Add("value", "off");
@@ -494,6 +494,34 @@
                                }
                                break;
                            }
                        case FunctionType.AC:
                        case FunctionType.FloorHeating:
                            {
                                //(空调/地热)做了一个特殊处理;
                                bool _bool = false;
                                for (int i = 0; i < dicSateteList.Count; i++)
                                {
                                    var dic = dicSateteList[i];
                                    if (dic.ContainsValue("on_off"))
                                    {
                                        //判断是否存在
                                        _bool = true;
                                        break;
                                    }
                                }
                                if (!_bool)
                                {
                                    //没有开关就默认添加-开-属性
                                    Dictionary<string, string> diction = new Dictionary<string, string>();
                                    diction.Add("key", "on_off");
                                    diction.Add("value", "on");
                                    dicSateteList.Add(diction);
                                }
                            }
                            break;
                    }
                    outputDevice.status = dicSateteList;
@@ -740,7 +768,7 @@
            LogicView.BrightnessView brightness = new LogicView.BrightnessView();
            brightness.FLayoutView(frame, titleName, button.Text, (brightnesValue) =>
            {
                button.Text = brightnesValue;
                button.Text = brightnesValue+"%";
                Dictionary<string, string> dic = new Dictionary<string, string>();
                string keyVlaue = "";
                switch (device.functionType)
@@ -842,7 +870,7 @@
                                case "brightness":
                                    {
                                        button2.Text = value;
                                        button2.Text = value+"%";
                                    }
                                    break;
                            }