Exemplo n.º 1
0
        public ActionResult Proposals(MovieProposalSortOrder?Order, string Term)
        {
            Order = Order ?? MovieProposalSortOrder.TopRated;
            var model = MovieProposalRepo.Search(Term, Order.Value);

            ViewBag.SortOrder  = Order;
            ViewBag.SearchTerm = Term;

            return(View(model));
        }
Exemplo n.º 2
0
        public ActionResult Index()
        {
            var db = new Movie();

            var fromDate = DateTime.Now;
            var model    = db.ListMoviesBySession(fromDate, fromDate.AddDays(1));

            ViewBag.News         = NewsRepo.GetTop(3);
            ViewBag.TopProposals = MovieProposalRepo.Search(SortOrder: MovieProposalSortOrder.TopRated, TakeQuantity: 10);
            ViewBag.NewProposals = MovieProposalRepo.Search(SortOrder: MovieProposalSortOrder.Newest, TakeQuantity: 10);

            return(View(model));
        }
Exemplo n.º 3
0
        public ActionResult LoadProposals(MovieProposalSortOrder?Order, string Term, int Skip)
        {
            var model = MovieProposalRepo.Search(Term, Order ?? MovieProposalSortOrder.TopRated, Skip);

            return(PartialView("ProposalList", model));
        }