Esempio n. 1
0
        //extracted from other methods to its own so can be used over and over
        private FutureReadingService CreateFutureReadingService()
        {
            var userID  = Guid.Parse(User.Identity.GetUserId());
            var service = new FutureReadingService(userID);

            return(service);
        }
Esempio n. 2
0
        // GET: BookInventory
        public ActionResult Index()
        {
            FutureReadingService service = CreateFutureReadingService();
            var model = service.GetBooks();

            return(View(model));
        }