| | |
| | | } |
| | | } |
| | | break; |
| | | case SPK.AirFreshStandard: |
| | | { |
| | | //做了一个特殊处理; |
| | | bool _bool = false; |
| | | for (int i = 0; i < dicSateteList.Count; i++) |
| | | { |
| | | var dic = dicSateteList[i]; |
| | | if (dic.ContainsValue("on_off")) |
| | | { |
| | | if (dic["value"] == "on") |
| | | { |
| | | //判断是否存在且是开状态 |
| | | _bool = true; |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | |
| | | if (!_bool) |
| | | { |
| | | //如果新风为含有开关属性且是关=状态; |
| | | //清空列表所有数据,重新单独配置一个开关属性且是关=状态; |
| | | //(新风属性是单独控制的,如果配置关,再配置一个风速,风速一样执行) |
| | | dicSateteList.Clear(); |
| | | //没有开关就默认添加-开-属性 |
| | | Dictionary<string, string> diction = new Dictionary<string, string>(); |
| | | diction.Add("key", "on_off"); |
| | | diction.Add("value", "off"); |
| | | dicSateteList.Add(diction); |
| | | } |
| | | } |
| | | break; |
| | | } |
| | | outputDevice.status = dicSateteList; |
| | | |