private void OnLayoutSelectionChanged(object sender, SelectionChangedEventArgs e) { if (CtrlGroup == null || SelectedLayout == null) { return; } CtrlGroup.SetXamlLayout(SelectedLayout); }
private void OnTabSelectionChanged(object sender, SelectionChangedEventArgs e) { if (tcLayout.SelectedIndex == 1) { NewLayout.ValidateXaml(); CtrlGroup.SetXamlLayout(NewLayout); } }
public OneConnPara(Wlst.client.SluCtrlParaRead.SluCtrlParaReadItem info, int sluId) { //lvf 2018年4月2日11:28:29 额定功率 对应关系 只呈现上限数字 var dir = new Dictionary <int, string>(); dir.Add(0, "未设置"); dir.Add(1, "20"); dir.Add(2, "100"); dir.Add(3, "120"); dir.Add(4, "150"); dir.Add(5, "200"); dir.Add(6, "250"); dir.Add(7, "300"); dir.Add(8, "400"); dir.Add(9, "600"); dir.Add(10, "800"); dir.Add(11, "1000"); dir.Add(12, "1500"); dir.Add(13, "2000"); dir.Add(14, "50"); dir.Add(15, "75"); this.RtuId = sluId + ""; this.PhyId = info.PhyId + ""; CtrlBarcode = info.CtrlBarcode + ""; CtrlOrder = info.CtrlOrder + ""; UppperPowerLimit = info.UppperPowerLimit + ""; LowerPowerLimit = info.LowerPowerLimit + ""; CtrlStatus = info.CtrlStatus ? "投运" : "停运"; CtrlEnableAlarm = info.CtrlEnableAlarm ? "允许主报" : "禁止主报"; LampCode = "---"; //lvf 2018年4月2日10:53:27 添加灯杆编码 var t = EquipmentDataInfoHold.InfoItems[sluId] as Wlst.Sr.EquipmentInfoHolding.Model.Wj2090Slu; if (t == null || t.WjSluCtrls == null) { return; } foreach (var g in t.WjSluCtrls) { if (g.Value.CtrlPhyId == info.PhyId) { LampCode = g.Value.LampCode; break; } } CtrlGroup = ""; foreach (var g in info.CtrlGroup) { CtrlGroup += g + "-"; } if (CtrlGroup.Length > 1) { CtrlGroup = CtrlGroup.Substring(0, CtrlGroup.Length - 1); } CtrlRoute = ""; foreach (var g in info.CtrlRoute) { CtrlRoute += g + "-"; } if (CtrlRoute.Length > 1) { CtrlRoute = CtrlRoute.Substring(0, CtrlRoute.Length - 1); } CtrlPowerTurnon = ""; foreach (var g in info.CtrlPowerTurnon) { CtrlPowerTurnon += g ? "是" + "-" : "否" + "-"; } if (CtrlPowerTurnon.Length > 1) { CtrlPowerTurnon = CtrlPowerTurnon.Substring(0, CtrlPowerTurnon.Length - 1); } CtrlVector = ""; foreach (var g in info.CtrlVector) { CtrlVector += g + "-"; } if (CtrlVector.Length > 1) { CtrlVector = CtrlVector.Substring(0, CtrlVector.Length - 1); } // lvf 2018年4月2日11:05:32 改成上限数字 RatedPower = ""; foreach (var g in info.RatedPower) { RatedPower += dir[g] + "-"; } if (RatedPower.Length > 1) { RatedPower = RatedPower.Substring(0, RatedPower.Length - 1); } }