//public string VirtualRootPath { get; set; } protected void btnAdd_Click(object sender, EventArgs e) { if (string.IsNullOrEmpty(_BPMContext.ProcID)) { return; } string currentInstId = _BPMContext.ProcID; string[] procIds = hidRelatedFlowProcIdList.Value.Split(','); //当前流程已有的关联流程 List <string> ListProcId = new List <string>(); foreach (string procid in procIds) { Pkurg.BPM.Entities.FlowRelated info = Pkurg.PWorldBPM.Business.Controls.WF_Relation.GetRelatedFlowInfo(currentInstId.ToString(), procid); if (info == null) { Pkurg.BPM.Entities.WorkFlowInstance inst = new Pkurg.BPM.Services.WorkFlowInstanceService().GetByInstanceId(procid); if (inst == null) { continue; } info = new Pkurg.BPM.Entities.FlowRelated() { FlowId = currentInstId, RelatedFlowId = procid, CreateTime = DateTime.Now, // CreatorId=_BPMContext.CurrentUser.Id, CreatorName = _BPMContext.CurrentUser.Name, RelatedFlowName = inst.FormTitle, RelatedFlowCreator = inst.CreateByUserName, RelatedFlowEndTime = inst.FinishedTime }; Pkurg.PWorldBPM.Business.Controls.WF_Relation.AddRelatedFlowInfo(info); } } Refresh(); }
public static Pkurg.BPM.Entities.FlowRelated AddRelatedFlowInfo(Pkurg.BPM.Entities.FlowRelated info) { return(new Pkurg.BPM.Services.FlowRelatedService().Save(info)); }