예제 #1
0
        public ActionResult DeleteConfirmed(int id)
        {
            var autor = _autorApp.GetById(id);

            _autorApp.Remove(autor);
            return(RedirectToAction("Index"));
        }
예제 #2
0
 public ActionResult Delete(int id, AutorViewModel autor)
 {
     if (ModelState.IsValid)
     {
         var _autorDomain = Mapper.Map <AutorViewModel, Autor>(autor);
         _autorAppService.Remove(_autorDomain);
         return(RedirectToAction("Index"));
     }
     return(View(autor));
 }