Exemplo n.º 1
0
        public ActionResult Index()
        {
            var vm = new IndexViewModel();

            if(State.RegisteredForEvent()) {
                vm.SubmittedSessions = Bus.Query(new SubmittedSessions());
            }

            return View(vm.WithUser(CurrentUser));
        }
Exemplo n.º 2
0
        public ActionResult Index(IndexViewModel input)
        {
            return Execute(input)
                .OnSuccess(x => RedirectToAction("Index"))
                .OnFailure(x => {
                    if(State.RegisteredForEvent()) {
                        input.SubmittedSessions = Bus.Query(new SubmittedSessions());
                    }

                    return View(input);
                });
        }