public string GetFlowIdentification(string userNo, long workId) { UserLogin(userNo); BP.WF.GenerWorkFlow gwf = new BP.WF.GenerWorkFlow(workId); return(gwf.Paras_GroupMark); }
protected void Btn_Send_Click(object sender, EventArgs e) { string msg = ""; try { BP.WF.Node nd = new BP.WF.Node(this.FK_Node); string[] strs = this.WorkIDs.Split(','); foreach (string str in strs) { if (string.IsNullOrEmpty(str)) { continue; } Int64 wkid = Int64.Parse(str); BP.WF.GenerWorkFlow gwf = new BP.WF.GenerWorkFlow(wkid); BP.WF.SendReturnObjs objs = BP.WF.Dev2Interface.Node_SendWork(nd.FK_Flow, wkid, null); msg += "<fieldset>"; msg += "<legend>对工作(" + gwf.Title + ")处理情况如下。</legend>"; msg += objs.ToMsgOfHtml(); msg += "</fieldset>"; } msg = msg.Replace("@", "<br>@"); this.Response.Write(msg + "<script type='text/javascript'> window.onload = function(){var ifreamTable = document.getElementById('ifreamTable'); ifreamTable.style.display='none';} </script><br/>[<a href='/WF/Batch.aspx' style='color:blue;'>返回批处理</a>]"); } catch (Exception ex) { //if (ex.Message.Contains("节点没有岗位") || ex.Message.Contains("@没有找到可接受的工作人员") || ex.Message.Contains("没有找到人员") || ex.Message.Contains("流程设计错误") || ex.Message.Contains("@您设置的当前节点")) //{ ErrorMessage.InnerHtml = ex.Message + "<br/>"; // return; //} //msg = ex.ToString().Replace("@", "<BR>@"); //System.Web.HttpContext.Current.Session["info"] = msg; //System.Web.HttpContext.Current.Application["info" + WebUser.No] = msg; //System.Web.HttpContext.Current.Application["url"] = Request.RawUrl; //string url ="/WF/ErrorPage.aspx"; //this.Response.Redirect(url, true); } }
/// <summary> /// 发送前检查是否已退件、是否已办理 /// </summary> /// <param name="fk_flow">流程标识</param> /// <param name="workId">工作标识</param> /// <param name="currentNodeID">当前节点标识</param> public static void BeforeSendCheck(string fk_flow, int workId, int currentNodeID) { BP.WF.GenerWorkFlow gwf = null; try { gwf = new BP.WF.GenerWorkFlow(workId); } catch { } if (gwf != null) { if (gwf.WFState == BP.WF.WFState.Delete) { throw new Exception("该案件已经退件,请刷新页面"); } var _currentNodeID = BP.WF.Dev2Interface.Node_GetCurrentNodeID(fk_flow, workId); if (currentNodeID != _currentNodeID) { throw new Exception("当前环节已经完成,请刷新页面!!"); } } }