public ActionResult CancelApp(int flowCaseId) { Applicant manager = new Applicant(WFEntities, this.Username); var result = manager.Cancel(flowCaseId); manager.NotificationSender.Send(); ViewBag.CancelResult = result; ViewBag.PendingCount = manager.CountPending();//#TODO return(PartialView("_CancelResult", manager.GetFlowAndCase(flowCaseId))); }
public object cancel_flowcase(int flowCaseId) { Singleton <ILogWritter> .Instance?.WriteLog("WorkFlow-cancel_flowcase", JsonConvert.SerializeObject(flowCaseId)); Applicant manager = new Applicant(Entities, User.Identity.Name); var result = manager.Cancel(flowCaseId); if (result == CancelFlowResult.Canceled) { manager.NotificationSender.Send(); return(new { ret_code = RetCode.Success, ret_msg = string.Empty }); } return(new { ret_code = RetCode.Failure, ret_msg = result.ToString() }); }