优化流程手册

This commit is contained in:
zhal 2022-07-22 14:01:31 +08:00
parent 0aaa9e6816
commit ed53d164ad
4 changed files with 42 additions and 14 deletions

View File

@ -72,8 +72,7 @@ public class SynchronousOrgJob implements IJob {
Connection open = DBSql.open(); Connection open = DBSql.open();
try { try {
orgdepartmentList = DBSql.getMaps(open, "select DEPARTMENTNAME,ID,LAYER,PARENTDEPARTMENTID,ORDERINDEX from ORGDEPARTMENT where Closed=0 ");
orgdepartmentList = DBSql.getMaps(open, "select DEPARTMENTNAME,ID,LAYER,PARENTDEPARTMENTID,ORDERINDEX from ORGDEPARTMENT");
PALRepositoryModelImpl model = CoeProcessLevelUtil.createPALRepositoryModel(id1, plRid1, wsId, "内蒙古伊利实业集团股份有限公司", PALRepositoryModelImpl model = CoeProcessLevelUtil.createPALRepositoryModel(id1, plRid1, wsId, "内蒙古伊利实业集团股份有限公司",
"", orderIndex, modeldefaultId, "org", true, 1, "", orderIndex, modeldefaultId, "org", true, 1,
@ -230,10 +229,6 @@ public class SynchronousOrgJob implements IJob {
//拿到基础结构 //拿到基础结构
JSONObject shape = ShapeUtil.getProcessShapeDefinitionByName("org.normal", "position"); JSONObject shape = ShapeUtil.getProcessShapeDefinitionByName("org.normal", "position");
if (StringUtils.isNotEmpty(definition.getString("commonShapeConfig"))) {
definition.remove("commonShapeConfig");
}
List<RowMap> orgdepartmentList = DBSql.getMaps(conn, "select DISTINCT(POSITION_NAME) from ORGUSER WHERE DEPARTMENTID=?", departmentId); List<RowMap> orgdepartmentList = DBSql.getMaps(conn, "select DISTINCT(POSITION_NAME) from ORGUSER WHERE DEPARTMENTID=?", departmentId);

View File

@ -2268,9 +2268,13 @@ public class CoeProcessLevelUtil {
String sessionId = new SSOUtil().registerClientSessionNoPassword(plModel.getCreateUser(), LoginConst.DEFAULT_LANG, "localhost", LoginConst.DEVICE_PC); String sessionId = new SSOUtil().registerClientSessionNoPassword(plModel.getCreateUser(), LoginConst.DEFAULT_LANG, "localhost", LoginConst.DEVICE_PC);
String relationFileId;
if(JSONObject.parseObject(property.getPropertyValue())!=null){ if(JSONObject.parseObject(property.getPropertyValue())!=null){
String relationFileId = JSONObject.parseObject(property.getPropertyValue()).get("relationFileId").toString(); 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+""; if(relationFileId.contains(",")){
String[] spiltRelationFileId=relationFileId.split(",");
relationFileId=spiltRelationFileId[0];
}
PALRepositoryModel model = PALRepositoryCache.getCache().get(uuid); PALRepositoryModel model = PALRepositoryCache.getCache().get(uuid);
@ -2280,6 +2284,8 @@ public class CoeProcessLevelUtil {
taskId=getLastPublishTaskIdByModelId(model.getId()); taskId=getLastPublishTaskIdByModelId(model.getId());
} }
} }
System.out.println("taskID==========="+taskId);
String url=SDK.getPortalAPI().getPortalUrl()+"/r/w?cmd=com.actionsoft.apps.coe.pal.publisher_publish_file_open&uuid="+relationFileId+""+"&sid="+sessionId+"&taskId="+taskId; String url=SDK.getPortalAPI().getPortalUrl()+"/r/w?cmd=com.actionsoft.apps.coe.pal.publisher_publish_file_open&uuid="+relationFileId+""+"&sid="+sessionId+"&taskId="+taskId;
//判断如果关联属性是岗位多个岗位显示为... //判断如果关联属性是岗位多个岗位显示为...
@ -2292,6 +2298,7 @@ public class CoeProcessLevelUtil {
} }
} }
appUrl="<a href='"+url+"' style='color:blue' target='_blank'>"+inputValue+"</a>"; appUrl="<a href='"+url+"' style='color:blue' target='_blank'>"+inputValue+"</a>";
System.out.println("appurl==============="+appUrl);
attribute.put("value", appUrl); attribute.put("value", appUrl);
} }
}else{ }else{

View File

@ -816,7 +816,7 @@
<span class="newadd_title"><#toolbarName></span> <span class="newadd_title"><#toolbarName></span>
</div> </div>
<div class="newadd_card"> <div class="newadd_card">
<div class="title"><span><#typeName></span></div> <div class="title"></div>
<div id="designer_layout" class="" > <div id="designer_layout" class="" >
<div id="canvas_container" style="padding:0px;background-color:white;"> <div id="canvas_container" style="padding:0px;background-color:white;">
<div id="designer_canvas" style="background-color: white !important;"> <div id="designer_canvas" style="background-color: white !important;">
@ -864,7 +864,7 @@
<div id="tab" style="display: none;font-size: 17px;"> <div id="tab" style="display: none;font-size: 17px;">
<div id="processDesc" class="headerTab" onclick="clickTab('processDesc');">流程属性</div> <div id="processDesc" class="headerTab" onclick="clickTab('processDesc');">流程属性</div>
<div id="processAttr" class="headerTab" onclick="clickTab('processAttr');">活动属性</div> <div id="processAttr" class="headerTab" onclick="clickTab('processAttr');">活动属性</div>
<div id="processFiledown" class="headerTab" onclick="clickTab('processFile');">文件下载</div> <div id="processFile" class="headerTab" onclick="clickTab('processFile');">文件下载</div>
</div> </div>
<!-- <div style="display: inline-block;float:right;"> <!-- <div style="display: inline-block;float:right;">
<span class="awsui-iconfont" id="closeTab" style="color:#A9A9A9;" awsui-qtip="隐藏属性" onclick="tabOperate('close');">&gt;&gt;</span> <span class="awsui-iconfont" id="closeTab" style="color:#A9A9A9;" awsui-qtip="隐藏属性" onclick="tabOperate('close');">&gt;&gt;</span>

View File

@ -1495,11 +1495,12 @@ function initProcessDesc() {
} }
function autoClickAttr() { function autoClickAttr() {
debugger;
// 属性自动切换 // 属性自动切换
if ($('#openTab').is(':hidden')) { if ($('#openTab').is(':hidden')) {
var name = ''; var name = '';
if (Utils.getSelected()[0] == null) { if (Utils.getSelected()[0] == null) {
debugger;
name = 'processDesc'; name = 'processDesc';
} else { } else {
name = 'processAttr'; name = 'processAttr';
@ -1535,7 +1536,6 @@ function dockShowView(name) {
// 点击页面时变更显示内容 // 点击页面时变更显示内容
function changeArributeByShape() { function changeArributeByShape() {
if(!isClickTab) { if(!isClickTab) {
autoClickAttr(); autoClickAttr();
} }
@ -1574,7 +1574,8 @@ function ProcessManual() {
t += '<table class="awsui-table">'; t += '<table class="awsui-table">';
t += '<tr><td>'; t += '<tr><td>';
t += '<div class="filetableHeader"><i class="awsui-iconfont" style="color: #999999;margin-top: 2px;">&#xe7cf;</i> 流程手册:</div>'; t += '<div class="filetableHeader"><i class="awsui-iconfont" style="color: #999999;margin-top: 2px;">&#xe7cf;</i> 流程手册:</div>';
t += '<div class="tableContent"><a href="javascript:void(0);" onclick="downloadProcessFile(\''+ taskId +'\')">'+ fileName +'</a></div>'; t += '<div class="tableContent"><a href="javascript:void(0);" onclick="openOutputFile(\''+ taskId +'\')">'+ fileName +'</a></div>';
t += '<i class="awsui-iconfont" style="color: #999999;margin-top: 2px;" onclick="downloadProcessFile(\''+taskId+'\')">&#xe653;</i>';
t += '</td></tr>'; t += '</td></tr>';
t += '</table>'; t += '</table>';
$('#processFileDock').append(t); $('#processFileDock').append(t);
@ -1582,6 +1583,32 @@ function ProcessManual() {
} }
function openOutputFile(taskId) {
// 打开流程手册
$.simpleAlert('正在打开', 'loading');
$.ajax({
type : "POST",
url : "./jd?sid=" + sid
+ "&cmd=com.actionsoft.apps.coe.pal_outputreport_output_process_preview",
data : {
taskId : taskId
},
success : function(msg) {
if (msg.result == "ok") {
$.simpleAlert("close");
if (msg['data']) {
var url = msg['data']['url'];
window.open(url);
}
} else {
$.simpleAlert("close");
$.simpleAlert(msg['msg'], 'info');
}
}
});
}
function downloadProcessFile(taskId) { function downloadProcessFile(taskId) {
$.ajax({ $.ajax({
type : "POST", type : "POST",
@ -1591,7 +1618,6 @@ function downloadProcessFile(taskId) {
taskId : taskId taskId : taskId
}, },
success : function(msg) { success : function(msg) {
debugger;
if (msg.result == "ok") { if (msg.result == "ok") {
window.location.href = msg.data.url; window.location.href = msg.data.url;
} }