private Process.MODEL GetSafeProcess(int step) { Process.MODEL prcs = Process.Caches.Find(delegate(Process.MODEL dele) { return(dele.FlowId.ToInt32() == this.FlowId.ToInt32() && dele.StepNo.ToInt32() == step); }); if (prcs == null) { throw new ApplicationException(String.Format("找不到步骤!")); } return(prcs); }
/// <summary> /// 生成当前工作N步中表单Html /// </summary> /// <param name="step"></param> /// <returns></returns> public String GenerateHtmls(int id) { WX.Flow.Model.Run.MODEL runmodel = WX.Flow.Model.Run.NewDataModel(id); FormFieldCollection datas = this.GetDatas_FormFieldCollection(); this.MyFlow.LoadProcessList(false); Process.MODEL process = this.MyFlow.ProcessList.Find(delegate(Process.MODEL prcs_dele) { return(prcs_dele.StepNo.ToInt32() == runmodel.StepNo.ToInt32()); }); if (process == null) { return(null); } return(this.MyForm.GenerateHtmls(datas, process.Editable_FormFieldCollection, process.Hidden_FormFieldCollection, runmodel.BeginUser.ToString())); }