1
Vote

Reusable wf - can't start old version.

description

对可复用工作流, 调用此方法 var asso = GetAssoByName(); 获取的工作流关联,启动的流程始终是老版本。
必须访问下工作流管理页面才能刷新。
可能需要调用GetAssoByTemplateId ...

comments

jianyi wrote Jul 21, 2014 at 8:29 AM

private SPWorkflowAssociation GetAssociationForRequest(SPWorkflowAssociationCollection associations)
{
associations.UpdateAssociationsToLatestVersion();
SPWorkflowAssociation associationByName = associations.GetAssociationByName(this.m_AssociationName, base.Web.Locale);
if (associationByName == null)
{
    associationByName = associations[this.m_TemplateId];
}
return associationByName;
}