流程阅览显示
This commit is contained in:
parent
89d4e0e600
commit
2b3a242987
@ -4,6 +4,7 @@ import java.io.FileOutputStream;
|
||||
import java.io.IOException;
|
||||
|
||||
import java.io.OutputStreamWriter;
|
||||
import java.sql.ResultSet;
|
||||
import java.sql.SQLException;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.*;
|
||||
@ -23,6 +24,7 @@ import com.actionsoft.apps.coe.pal.pal.ws.web.VersionUtil;
|
||||
import com.actionsoft.apps.resource.plugin.profile.DCPluginProfile;
|
||||
import com.actionsoft.bpms.bpmn.engine.cache.ProcessDefCache;
|
||||
import com.actionsoft.bpms.bpmn.engine.model.def.ProcessDefinition;
|
||||
import com.actionsoft.bpms.commons.database.RowMapper;
|
||||
import com.actionsoft.bpms.commons.login.constant.LoginConst;
|
||||
import com.actionsoft.bpms.commons.mvc.view.ResponseObject;
|
||||
import com.actionsoft.bpms.org.model.DepartmentModel;
|
||||
@ -2263,7 +2265,17 @@ public class CoeProcessLevelUtil {
|
||||
|
||||
if(JSONObject.parseObject(property.getPropertyValue())!=null){
|
||||
String relationFileId = JSONObject.parseObject(property.getPropertyValue()).get("relationFileId").toString();
|
||||
String url=SDK.getPortalAPI().getPortalUrl()+"/r/w?uuid="+relationFileId+"&teamId=&cmd=com.actionsoft.apps.coe.pal_pl_repository_designer&sid="+sessionId+"";
|
||||
//String url=SDK.getPortalAPI().getPortalUrl()+"/r/w?uuid="+relationFileId+"&teamId=&cmd=com.actionsoft.apps.coe.pal_pl_repository_designer&sid="+sessionId+"";
|
||||
|
||||
PALRepositoryModel model = PALRepositoryCache.getCache().get(uuid);
|
||||
|
||||
String taskId="";
|
||||
if (model != null) {
|
||||
if (model.isPublish() || model.isStop()) {// 停用或已发布状态查询最新流程手册
|
||||
taskId=getLastPublishTaskIdByModelId(model.getId());
|
||||
}
|
||||
}
|
||||
String url=SDK.getPortalAPI().getPortalUrl()+"/r/w?cmd=com.actionsoft.apps.coe.pal.publisher_publish_file_open&uuid="+relationFileId+""+"&sid="+sessionId+"&taskId="+taskId;
|
||||
|
||||
//判断如果关联属性是岗位,多个岗位显示为...
|
||||
if(attributeModel.getKey().equals("post")){
|
||||
@ -2290,6 +2302,24 @@ public class CoeProcessLevelUtil {
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取模型的最后发布时的taskId
|
||||
*
|
||||
* @param repositoryId
|
||||
* @return
|
||||
*/
|
||||
public static String getLastPublishTaskIdByModelId(String repositoryId) {
|
||||
String sql = "SELECT pl.TASKID FROM APP_ACT_COE_PAL_PUBLISH p, APP_ACT_COE_PAL_PUBLISH_LIST pl WHERE pl.pid = p.id AND pl.palrepositoryid = ? ORDER BY publishdate DESC";
|
||||
String taskId = DBSql.getObject(sql, new RowMapper<String>() {
|
||||
@Override
|
||||
public String mapRow(ResultSet rs, int arg1) throws SQLException {
|
||||
return rs.getString(1);
|
||||
}
|
||||
}, new Object[] { repositoryId });
|
||||
return taskId;
|
||||
}
|
||||
|
||||
/**
|
||||
* 统计个人权限下的模型文件的建模大类和建模方法分类
|
||||
* 不作为个人是否有某建模方法判断依据,仅根据已有数据进行统计
|
||||
|
||||
Loading…
Reference in New Issue
Block a user