private void ResetLHSX() { var dialog = MsgBox.QuestionShow("确认重置老化顺序?"); if (dialog == MsgBoxResult.OK) { LHSXCollection.Clear(); } }
private void DeleteLHSX() { var dialog = MsgBox.QuestionShow("确认删除?"); if (dialog == MsgBoxResult.OK) { if (LHSXSelectedItem != null) { LHSXCollection.Remove(LHSXSelectedItem); } } LHSXSelectedItem = null; }
private void AddLHSX() { LHSXInfo item = new LHSXInfo(); item.srdy = SRDYSelectedItem.Value; item.fzcy = FZCSSelectedItem.Name; item.pdfw = getCSSXXName(); item.cjkt = Iscj; item.dzzzTimeUnit = (RepeatUnitEnum)DZZXUnitSelectedIndex; item.dzzx = DZZX + "-" + FunExt.GetRepeatUnitName(DZZXUnitSelectedIndex); item.gscTimeUnit = (TimeUnitEnum)GSCUnitSelectedIndex; item.gsc = GSC + "-" + FunExt.GetTimeUnitName(GSCUnitSelectedIndex); item.kscTimeUnit = (TimeUnitEnum)KSCUnitSelectedIndex; item.ksc = KSC + "-" + FunExt.GetTimeUnitName(KSCUnitSelectedIndex); LHSXCollection.Add(item); }
private void ModifyLHSX() { var item = LHSXCollection.FirstOrDefault(s => s.guid == LHSXSelectedItem.guid); if (item == null) { return; } item.srdy = SRDYSelectedItem.Value; item.fzcy = FZCSSelectedItem.Name; item.pdfw = getCSSXXName(); item.cjkt = Iscj; item.dzzzTimeUnit = (RepeatUnitEnum)DZZXUnitSelectedIndex; item.dzzx = DZZX + "-" + FunExt.GetRepeatUnitName(DZZXUnitSelectedIndex); item.gscTimeUnit = (TimeUnitEnum)GSCUnitSelectedIndex; item.gsc = GSC + "-" + FunExt.GetTimeUnitName(GSCUnitSelectedIndex); item.kscTimeUnit = (TimeUnitEnum)KSCUnitSelectedIndex; item.ksc = KSC + "-" + FunExt.GetTimeUnitName(KSCUnitSelectedIndex); }