Beispiel #1
0
 public void Delete()
 {
     LeveranciersLijst.Remove(LeveranciersSelectedItem);
     _eventAggregator.PublishOnUIThread(message: new LeveranciersChange(new Leverancier()
     {
         Name = ""
     }));
 }
Beispiel #2
0
        public void Handle(AddLeverancier message)
        {
            if (!message.Edit)
            {
                Leverancier leverancier = new Leverancier();
                leverancier = message.Leverancier;
                LeveranciersLijst.Add(leverancier);
            }

            // OrderBy does NOT change the original Collection !! Original Collection must be recreated !!!
            LeveranciersLijst = new BindableCollection <Leverancier>(LeveranciersLijst.OrderBy(i => i.Name));
            Save();
            LeveranciersLijstUI = LeveranciersLijst;
        }