/// <summary> /// редактирование данных GET /// </summary> /// <param name="id"></param> /// <returns></returns> public ActionResult Edit(int id) { var role = _roleInfoService.GetById(id); if (role != null) { var roleModel = Mapper.Map <RoleInfo, EditRoleModel>(role); return(View(roleModel)); } return(RedirectToAction("Index")); }