public ActionResult DeleteConfirmed(int id)
        {
            var editora = _editoraApp.GetById(id);

            _editoraApp.Remove(editora);
            return(RedirectToAction("Index"));
        }
Example #2
0
 public ActionResult Delete(int id, EditoraViewModel editora)
 {
     if (ModelState.IsValid)
     {
         var _editoraDomain = Mapper.Map <EditoraViewModel, Editora>(editora);
         _editoraAppService.Remove(_editoraDomain);
         return(RedirectToAction("Index"));
     }
     return(View(editora));
 }