public virtual ActionResult Update(EditDocTypeViewModel model) { if (!ModelState.IsValid) { return(RedirectToAction("Index", "DocType")); } return(UpdateDocType(model)); }
private ActionResult UpdateDocType(EditDocTypeViewModel model) { _docTypeService.Update(model.DocTypeId, model.Code, model.Description); return(RedirectToRoute(new { controller = "DocType", action = "Index" })); }