发布流程去掉连线校验\去重人数汇总计算修改
This commit is contained in:
parent
65069648a6
commit
44813f359f
Binary file not shown.
@ -325,9 +325,9 @@ public class PublishFormBeforeSaveEvent extends InterruptListener implements Int
|
||||
sbs.append(sb6);
|
||||
}
|
||||
|
||||
if (sbs.length()>0){
|
||||
/*if (sbs.length()>0){
|
||||
throw new BPMNError("0313", sbs.toString());
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -282,7 +282,7 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
new_uid = new_uid.join(",", sendList);
|
||||
long startTimes = System.currentTimeMillis();
|
||||
String[] users = new_uid.split(",");
|
||||
for (String uid:
|
||||
/*for (String uid:
|
||||
users) {
|
||||
BO bo = new BO();
|
||||
bo.set("USER_ID",uid);
|
||||
@ -292,7 +292,7 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
bo.set("PROCESS_TITLE",bo_act_coe_publish1.getString("PROCESS_TITLE"));
|
||||
bo.set("PUBLISH_DATE",sdf.format(endTime));
|
||||
SDK.getBOAPI().createDataBO("BO_EU__OA_MONITOR",bo,UserContext.fromUID(ta.getTarget()));
|
||||
}
|
||||
}*/
|
||||
System.out.println("new_uid>>>>>>>>>>>>>>"+users.length);
|
||||
|
||||
long startTime = System.currentTimeMillis();
|
||||
@ -318,7 +318,7 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
/**
|
||||
* 创建线程发送待阅数据
|
||||
*/
|
||||
course(list,startTime,jsonObject,processExecutionContext,sendList);
|
||||
//course(list,startTime,jsonObject,processExecutionContext,sendList);
|
||||
//System.out.println("发送人员数据>>>>>>>>>>>>>>"+list);
|
||||
}else {
|
||||
int size = users.length/length;
|
||||
@ -337,7 +337,7 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
/**
|
||||
* 创建线程发送待阅数据
|
||||
*/
|
||||
course(list,startTime,jsonObject,processExecutionContext,sendList);
|
||||
//course(list,startTime,jsonObject,processExecutionContext,sendList);
|
||||
//System.out.println("发送人员数据>>>>>>>>>>>>>>"+list);
|
||||
}
|
||||
|
||||
@ -548,6 +548,36 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 创建索引
|
||||
* @param processExecutionContext 流程实例
|
||||
* @param index 索引名称 (随便填写,aslp那边已经有固定的)
|
||||
* @param type 类型(随便填写,aslp中也是有固定的)
|
||||
* @param documentPath dc全路径
|
||||
* @param fileNames 文件名称
|
||||
*/
|
||||
public void createIndexByFile(ProcessExecutionContext processExecutionContext,String index,String type,String documentPath,JSONObject fileNames) {
|
||||
// 调用App
|
||||
String sourceAppId = processExecutionContext.getProcessInstance().getAppId();
|
||||
// aslp服务地址
|
||||
String aslp = "aslp://com.actionsoft.apps.addons.es/createIndexByFile";
|
||||
// 参数定义列表
|
||||
Map params = new HashMap<String, Object>();
|
||||
//索引名称(文档在哪存放),必填
|
||||
params.put("index", index);
|
||||
//类型(索引中对数据进行逻辑分区。不同 type的文档可能有不同的字段,但最好能够非常相似,比如:存储所有产品到索引products中,但是你有许多不同的产品类别,这些产品共享一种相同的(或非常相似)的模式:他们有一个标题、描述、产品代码和价格。他们只是正好属于“产品”下的一些子类。用type表示不同的类别),必填
|
||||
params.put("type", type);
|
||||
//要入库的文件全路径,必填
|
||||
params.put("documentPath", documentPath);
|
||||
//文件实际名称, jsonObject,非必填
|
||||
params.put("fileNames", fileNames);
|
||||
AppAPI appAPI = SDK.getAppAPI();
|
||||
//入库操作,从文件创建内容索引
|
||||
ResponseObject ro = appAPI.callASLP(appAPI.getAppContext(sourceAppId), aslp, params);
|
||||
System.out.println("ro===================="+ro);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据线程创建待阅日志
|
||||
* @param list
|
||||
@ -731,6 +761,7 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
//创建文件
|
||||
ResponseObject ro = appAPI.callASLP(appAPI.getAppContext(sourceAppId), aslp, params);
|
||||
System.out.println("流程手册的存入=================" + ro);
|
||||
createIndexByFile(processExecutionContext,"1","2",dcContext.getFilePath(),new JSONObject());
|
||||
}
|
||||
}
|
||||
|
||||
@ -769,6 +800,7 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
paramss.put("dc", dcContexts);
|
||||
AppAPI appAPIs = SDK.getAppAPI();
|
||||
ResponseObject ros = appAPIs.callASLP(appAPIs.getAppContext(sourceAppId), aslp, paramss);
|
||||
createIndexByFile(processExecutionContext,"1","2",dcContexts.getFilePath(),new JSONObject());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1687,8 +1719,8 @@ public class ProcessEndAfterEvent_new extends ExecuteListener implements Execute
|
||||
bo_Read_log.set("SENDNUMSJ", data);
|
||||
|
||||
//去重漏发人数
|
||||
String disnum = DBSql.getString("SELECT DISTINCT(user_id) AS NUMBERS from BO_ACT_DATAID where 1=1 AND PROCESSID='" + processInstId + "'");
|
||||
String disread_num = DBSql.getString("SELECT DISTINCT(user_id) AS NUMBERS from BO_ACT_ALREADY_DATAID where 1=1 AND PROCESSID='" + processInstId + "'");
|
||||
String disnum = DBSql.getString("SELECT COUNT(DISTINCT user_id ) AS NUMBERS from BO_ACT_DATAID where 1=1 AND PROCESSID='" + processInstId + "'");
|
||||
String disread_num = DBSql.getString("SELECT COUNT(DISTINCT user_id ) AS NUMBERS from BO_ACT_ALREADY_DATAID where 1=1 AND PROCESSID='" + processInstId + "'");
|
||||
Integer dis_data = Integer.parseInt(disnum)+Integer.parseInt(disread_num);
|
||||
bo_Read_log.set("DISTINCTSUM", dis_data);
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user