Esempio n. 1
0
        public IActionResult AfisareAutori()
        {
            var authors = new AuthorViewModel
            {
                AUTORs = repository.GetAllAuthorsAsync().Result.ToList()
            };

            return(View(authors));
        }
Esempio n. 2
0
        public IActionResult AfisareCarti()
        {
            var books = new BookViewModel
            {
                CARTEs = repository.GetAllBooksAsync().Result.ToList(),
                AUTORs = repository.GetAllAuthorsAsync().Result.ToList(),
                GENs   = repository.GetAllGenresAsync().Result.ToList()
            };

            return(View(books));
        }