public ActionResult EditInit(string id) { if (string.IsNullOrWhiteSpace(id)) { return(Json(null)); } try { var jobId = int.Parse(id); var checkResult = UserLogic.IsJobMaster(GetOperation().UserId, jobId); if (checkResult.IsSuccess == false) { return(Json(checkResult)); } var result = JobLogic.GetDetail(jobId); return(Json(result)); } catch { var result = new IsSuccessResult(ErrorCode.JobNotFound.ToString()); return(Json(result)); } }
public ActionResult DetailInit(string id) { try { var jobId = int.Parse(id); var result = JobLogic.GetDetail(jobId); return(Json(result)); } catch { var result = new IsSuccessResult(ErrorCode.JobNotFound.ToString()); return(Json(result)); } }