// GET: Recepcioneri
        public async Task <IActionResult> Index()
        {
            SobeController sobeController = new SobeController(_context);

            ViewData["sobe"] = sobeController.getAllSobe();
            return(View(await _context.Recepcioner.ToListAsync()));
        }
コード例 #2
0
        // GET: Sefs
        public async Task <IActionResult> Index()
        {
            SobeController         sobeController         = new SobeController(_context);
            RecepcioneriController recepcioneriController = new RecepcioneriController(_context, _userManager);

            ViewData["uposlenici"] = recepcioneriController.getAll();
            ViewData["sobe"]       = sobeController.getAllSobe();
            return(View(await _context.Sef.ToListAsync()));
        }
コード例 #3
0
        public async Task <IActionResult> Step3(int?id)
        {
            var rezervacije = await _context.Rezervacija.ToListAsync();

            if (id == null)
            {
                return(NotFound());
            }

            var korisnik = await _userManager.FindByNameAsync(User.Identity.Name);

            SobeController sobeController = new SobeController(_context);
            var            sobe           = sobeController.getAllSobe();
            var            soba           = sobe.Find(s => s.ID == id);

            ViewData["soba"]     = soba;
            ViewData["Korisnik"] = korisnik;
            return(View());
        }