在审批流程中,加入处理前和处理后的数据处理,可以将审批流程外的业务处理或是流程额外程序出来分离出来。放在代码前,代码后处理。
public WfActivity assignComplete(WfTranstion wfTrans,String procId, String activityId,
String touserId,String memo,HttpServletRequest request)throws WfException {
WfActivity wfAct = null;
try {
CodeFormula.parseBeforeCode(wfTrans.getConnection(),procId,activityId,CodeFormula.apply_code,request);
CheckAgree.execute(wfTrans,procId, activityId, new WfUser(uname, pwd),流程自己处理的方法
touserId,memo);
CodeFormula.parseAfterCode(wfTrans.getConnection(),procId,activityId,CodeFormula.apply_code,request);
} catch (WfException e) {
wfAct = null;
throw e;
}
return wfAct;
}