Пример #1
0
        public ActionResult DoEdit(Guid id, HttpPostedFileBase file, ActorInput newView)
        {
            var data = ActorsDao.GetActorWithFilms(id);

            newView.CopyToData(data, file, CountriesDao, FilmsDao);
            ActorsDao.Update(data);

            return(RedirectToAction("Index"));
        }
Пример #2
0
        public ActionResult Edit(Guid id)
        {
            var actor = ActorsDao.GetActorWithFilms(id);

            return(View(new ActorInfoContainer()
            {
                Actor = new ActorView(actor),
                AvailableFilms = FilmsDao.GetFilmsWithoutActor(actor.ID),
                Countries = CountriesDao.FindAll().OrderBy(c => c.Name)
            }));
        }
Пример #3
0
        public ActionResult Delete(Guid id)
        {
            var actor = ActorsDao.GetActorWithFilms(id);

            return(View(new ActorView(actor)));
        }