private void updateInfo(object sender)
 {
     ListBDE     = new ObservableCollection <BDE>(persistance.GetBDEList().Where(b => b.Account.ID == Singleton <User> .GetInstance().Account.ID).ToList());
     listTickets = persistance.GetTicketsDB();
     selectedBDE = null;
     OnPropertyChanged("ListTickets");
     OnPropertyChanged("SaleTotal");
     OnPropertyChanged("ProfitTotal");
     OnPropertyChanged("MargeTotal");
 }
Exemplo n.º 2
0
        public ChoiceBDEViewModel(IDialogCoordinator instance, Collection <BasketItem> items, IDialog dialog, MainWindow main, float reduc)
        {
            persistance = Singleton <IPersistance> .GetInstance();

            this.dialog       = dialog;
            ListBDE           = new Collection <BDE>(persistance.GetBDEList().Where(b => b.Account.ID == Singleton <User> .GetInstance().Account.ID).ToList <BDE>());
            PickBDE           = new RelayCommand <BDE>(addBasketToDB);
            dialogCoordinator = instance;
            CancelChoice      = new RelayCommand(cancelChoice);
            baskets           = items;
            this.main         = main;
            this.reduction    = reduc;
        }