public ActionResult EditRate(int?id) { if (id == null) { new SelectListItem { }; return(new HttpStatusCodeResult(HttpStatusCode.BadRequest)); } physician_rate rateService = _rateService.GetDetails(Convert.ToInt32(id)); // get physician name ViewBag.name = _rateService.GetPhysicianName(rateService.rat_phy_key); if (rateService == null) { return(HttpNotFound()); } var types = new List <int>() { UclTypes.ServiceType.ToInt(), UclTypes.CoverageType.ToInt(), UclTypes.CaseType.ToInt(), UclTypes.IdentificationType.ToInt(), UclTypes.TpaDelay.ToInt(), UclTypes.NonTPACandidate.ToInt(), UclTypes.LoginDelay.ToInt(), UclTypes.BillingCode.ToInt(), UclTypes.CallerSource.ToInt() }; var uclDataList = _lookUpService.GetUclData(types) .Where(m => m.ucd_is_active) .OrderBy(c => c.ucd_sort_order) .Select(m => new { m.ucd_key, m.ucd_title, m.ucd_description, m.ucd_ucl_key }) .ToList(); ViewBag.UclData = uclDataList.OrderBy(o => o.ucd_description); ViewBag.Status = true; return(GetViewResult(rateService)); }