public void EditLocker(int id, Locker locker) { Lockers[id] = locker; if (id == 0) { LeftLocker = locker; } if (id == Lockers.Count - 1) { RightLocker = locker; } }
public void InsertLocker(int id, Locker locker) { Lockers.Insert(id, locker); if (id == 0) { LeftLocker = locker; } if (id == Lockers.Count - 1) { RightLocker = locker; } }
private void FillLockerInfos(Locker locker) { // type LockTypeBox.SelectedIndex = int.Parse(locker.Type[1] + "") - 1; // entraxe EntraxeUpDown.Value = locker.Entraxe; // kit patere pieds PatereCheck.IsChecked = (locker.KitPiedPat) >= 2; PiedCheck.IsChecked = (locker.KitPiedPat % 2) != 0; // barre penderie PenderieBox.SelectedIndex = locker.IsPend; // type plaque PlaqueBox.SelectedIndex = locker.TypePlaq; // type serrure TypeSerrBox.SelectedIndex = TypeSerrBox.Items.IndexOf(locker.TypeSerr.Split(',')[0]); DisableIncompatibleOptions(); }
public void SetLocker(int idx, Locker locker) { Lockers[idx] = locker; }
private string ToFileFormat(Locker locker) { return($"{locker.Type};{locker.Entraxe};{locker.KitPiedPat};{locker.IsPend};{locker.TypeSerr};{locker.TypePlaq}"); }