public ActionResult Details(Guid claimId) { var claimModel = _claimService.GetById(claimId); var viewModel = new UnderwriterClaimViewModel(claimModel); return(View(viewModel)); }
// GET: Claim/Details/5 public ActionResult Details(int id) { /* var userId = (int)Session["idu"]; * String Phone2 = userService.GetById(userId).login; * String mail = userService.GetById(userId).email; * ViewBag.home = mail; * ViewBag.phone = Phone2;*/ if (id == null) { return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } Claim c; c = ClaimsService.GetById((int)id); if (c == null) { return(HttpNotFound()); } ClaimModel cm = new ClaimModel() { ComplaintId = c.ComplaintId, Name = c.Name, Description = c.Description, ClaimDate = c.ClaimDate, ParentId = c.ParentId, ClaimType = c.ClaimType, status = c.status }; return(View(cm)); }
// GET: Claim/Details/5 public ActionResult Details(int id) { //debut code khawla IUserService service = new UserService(); user u = service.GetById(User.Identity.GetUserId()); string firstName = u.firstName; string lastName = u.lastName; string email = u.Email; ViewBag.userFirstName = firstName; ViewBag.userLastName = lastName; ViewBag.userMail = email; ViewBag.sexe = u.sexe.ToLower(); //fin code khawla claim comm = cls.GetById(id); return(View(comm)); }
public ActionResult Edit(Guid id) { var claim = _claimService.GetById(id); //if (claim == null) return new HttpNotFoundResult("Claim Does Not Exist"); var model = new EditClaimViewModel(claim); return(View(model)); }
public ActionResult Edit(Guid id) { try { var claimDomainModel = _claimService.GetById(id); var model = new ClaimViewModel(claimDomainModel); return(View(model)); } catch (ArgumentException) { return(View(new ClaimViewModel())); } }
public ActionResult ViewClaim(Guid id) { try { ClaimDomainModel claimModel = _claimService.GetById(id); ClaimViewModel viewModel = new ClaimViewModel(claimModel); return(View(viewModel)); } catch (ArgumentException e) { return(null); } }
// GET: api/ClaimApi/5 public Claim Get(int id) { Claim comp = MyService.GetById(id); return(comp); }
// GET: api/authorization/1 public IHttpActionResult Get(int id) { var group = _claimservice.GetById(id); return(Ok(group)); }