public JsonResult FlagProcessTask(long uri, string stamp, string comments) { InforActionResult result = null; var flag = JsonConvert.DeserializeObject <InforProcessStamp>(stamp); if (AppUserState == null || AppUserState.Connected == false) { return(null); } result = ProcessService.FlagProcess(AppUserState.Wgs, AppUserState.Ds, AppUserState.UserName, uri, flag, comments); return(this.Jsonp(result)); }
public JsonResult ReasignNode(long processNode, long responsible, DateTime?dueDate, string notes, long addAboveUri = 0, long addBelowUri = 0) { var result = new InforActionResult(); try { if (AppUserState == null || AppUserState.Connected == false) { return(null); } if (addAboveUri > 0 || addBelowUri > 0) { if (addAboveUri > 0) { result = ProcessService.AddStepAbove(AppUserState.Wgs, AppUserState.Ds, AppUserState.UserName, addAboveUri, responsible, dueDate, notes); } if (addBelowUri > 0) { result = ProcessService.AddStepBelow(AppUserState.Wgs, AppUserState.Ds, AppUserState.UserName, addBelowUri, responsible, dueDate, notes); } } else { if (processNode > 0) { result = ProcessService.ReassignProcess(AppUserState.Wgs, AppUserState.Ds, AppUserState.UserName, processNode, notes, responsible, dueDate); } } } catch (Exception e) { result.Success = false; result.Faults.Add(new InforFault { Message = $"Error {e.Message}", IsWarningOnly = false }); } return(this.Jsonp(result)); }