示例#1
0
        public KitchenViewModel(ISaleRepo saleRepo, ICategoryRepo categoryRepo)
        {
            _saleRepo     = saleRepo;
            _categoryRepo = categoryRepo;

            CookedCommand           = new RelayCommand <Data.Sale>(Cooked, (_) => SelectedSale != null);
            ToProductAddViewCommand = new RelayCommand(ToReservationAddView);
        }
示例#2
0
        //private Data.Occupancy _selectedOccupancy;
        //public Data.Occupancy SelectedOccupancy
        //{
        //    get { return _selectedOccupancy; }
        //    set { SetValue(ref _selectedOccupancy, value); }
        //}

        #endregion

        #region Constructor
        public WaiterViewModel(ISaleRepo saleRepo, IOccupanciesRepo occupanciesRepo, ICategoryRepo categoryRepo)
        {
            _saleRepo        = saleRepo;
            _occupanciesRepo = occupanciesRepo;
            _categoryRepo    = categoryRepo;

            // .Where(sale => sale.Cooked.Equals("0"))         (ObservableCollection < Data.Sale > )
            //EditReservationCommand = new RelayCommand<CurrentCellEndEditEventArgs>(EditReservation);
            DeliverdCommand = new RelayCommand <WaiterSale>(Delivered, (_) => SelectedSale != null);
        }
示例#3
0
 public SaleService(IRepo <Sale> repo, IInvoiceService inService, ICartService cService, IRepo <Payment> pRepo, IPaymentRepo payRepo, IRepo <Customer> custRepo, ISaleRepo sRepo)
 {
     _repo      = repo;
     _cService  = cService;
     _inService = inService;
     _pRepo     = pRepo;
     _payRepo   = payRepo;
     _custRepo  = custRepo;
     _sRepo     = sRepo;
 }
示例#4
0
        /// <summary>
        /// Creates the DashboardViewModel instance.
        /// Sets the commands equal to a method to call.
        /// </summary>
        public DashboardViewModel(IReservationRepo reservationRepo, ISaleRepo saleRepo)
        {
            LocationHandler.Start();
            LocationHandler.statusChanged += LocationHandler_statusChanged;
            weatherHandler = new Weather.WeatherHandler();

            Time = DateTime.Now;
            DispatcherTimer timer = new DispatcherTimer();

            timer.Interval = TimeSpan.FromSeconds(0.3);
            timer.Tick    += Timer_Tick;
            timer.Start();

            _reservationRepo = reservationRepo;
            _saleRepo        = saleRepo;

            ChannelsMusic = MusicPlayer.channels;

            if (!MusicPlayer.channels.ContainsKey(Properties.Settings.Default.FavorityMusic)) // if the saved key of your favorite (last played) channel doens't exist, play Studio Brussel.
            {
                SelectedChannelMusic = getMusicChannelKeyValuePair("Studio Brussel");
            }
            else
            {
                SelectedChannelMusic = getMusicChannelKeyValuePair(Properties.Settings.Default.FavorityMusic);
            }
            LastSelectedChannelMusic = SelectedChannelMusic;

            MusicPlayer.statusChanged += MusicPlayer_statusChanged;

            PlayOrPauseMusicCommand = new RelayCommand(PlayOrPauseMusic);
            VolumeDownMusicCommand  = new RelayCommand(VolumeDownMusic);
            VolumeUpMusicCommand    = new RelayCommand(VolumeUpMusic);
            VolumeMuteMusicCommand  = new RelayCommand(MuteMusic);

            SelectedChannelMusicSelectionChangedCommand = new RelayCommand(SelectedChannelMusicSelectionChanged);
        }
示例#5
0
 public SaleService(ISaleRepo saleRepo, ICarRepo carRepo)
 {
     _saleRepo = saleRepo;
     _carRepo  = carRepo;
 }
示例#6
0
 public SaleService(ISaleRepo saleRepo, ICarService carService)
 {
     _saleRepo   = saleRepo;
     _carService = carService;
 }
 public SaleReturnController(ISaleRepo repo)
 {
     _repo = repo;
 }
 public SaleController(ISaleRepo saleRepo, IPurchaseRepo purchaseRepo)
 {
     _saleRepo     = saleRepo;
     _purchaseRepo = purchaseRepo;
 }
示例#9
0
 public StatsController(IUserRepo userRepo, ISaleRepo saleRepo, IProductRepo productRepo)
 {
     _userRepo    = userRepo;
     _saleRepo    = saleRepo;
     _productRepo = productRepo;
 }
示例#10
0
 public SaleController(ISaleRepo saleRepo)
 {
     _saleRepo = saleRepo;
 }