Exemple #1
0
        public IActionResult Index()
        {
            var phone = _phoneRepository.GetAllPhones().OrderBy(p => p.Name);

            var homeViewModel = new HomeViewModels()
            {
                Phones = phone.ToList()
            };

            return(View(homeViewModel));
        }
Exemple #2
0
        public ViewResult Index()
        {
            var phones = new PhoneListViewModel()
            {
                Phones = _phoneRepository.GetAllPhones()
            };

            _reservationService.ReservationChecker();

            return(View(phones));
        }
Exemple #3
0
        public ActionResult ComparePhones()
        {
            var phones = phonesRepository.GetAllPhones();

            return(View(phones));
        }
Exemple #4
0
        public IEnumerable <Phone> GetAllPhones()
        {
            IEnumerable <Phone> phones = repository.GetAllPhones();

            return(phones);
        }
Exemple #5
0
        public async Task <List <Phone> > GetAllPhones()
        {
            var phones = await _repository.GetAllPhones();

            return(phones);
        }