迁移代码提交
This commit is contained in:
parent
0576704a1d
commit
d82e3372c5
@ -0,0 +1,31 @@
|
||||
package com.actionsoft.apps.coe.pal.datamigration.at;
|
||||
|
||||
import com.actionsoft.bpms.bo.engine.BO;
|
||||
import com.actionsoft.bpms.commons.at.AbstExpression;
|
||||
import com.actionsoft.bpms.commons.at.ExpressionContext;
|
||||
import com.actionsoft.sdk.local.SDK;
|
||||
|
||||
public class getRoleAt extends AbstExpression {
|
||||
|
||||
|
||||
public getRoleAt(ExpressionContext atContext, String expressionValue) {
|
||||
super(atContext, expressionValue);
|
||||
}
|
||||
|
||||
public String execute(String expression) {
|
||||
String incentivecountersignature = null;
|
||||
// 获取部门内部校对人
|
||||
String departmentUser = getParameter(expression, 1);
|
||||
|
||||
// 获取流程经理
|
||||
String processManager = getParameter(expression, 2);
|
||||
|
||||
BO act_processmanager=SDK.getBOAPI().query("BO_ACT_PROCESSMANAGER").addQuery("DEAPRTMNUM=",departmentUser).addQuery("PROCESSMNUMBER=",processManager).detail();
|
||||
|
||||
if(act_processmanager!=null){
|
||||
incentivecountersignature=act_processmanager.getString("INCENTIVECOUNTERSIGNATURE");
|
||||
}
|
||||
return incentivecountersignature;
|
||||
}
|
||||
|
||||
}
|
||||
@ -13,6 +13,8 @@ import com.actionsoft.apps.coe.pal.pal.repository.model.impl.PALRepositoryModelI
|
||||
import com.actionsoft.apps.coe.pal.pal.repository.util.CoeProcessLevelUtil;
|
||||
import com.actionsoft.apps.resource.plugin.profile.DCPluginProfile;
|
||||
import com.actionsoft.bpms.commons.database.RowMap;
|
||||
import com.actionsoft.bpms.org.cache.UserCache;
|
||||
import com.actionsoft.bpms.org.model.UserModel;
|
||||
import com.actionsoft.bpms.schedule.IJob;
|
||||
import com.actionsoft.bpms.server.UserContext;
|
||||
import com.actionsoft.bpms.server.fs.DCContext;
|
||||
@ -223,6 +225,7 @@ public class CreateMaps implements IJob {
|
||||
}
|
||||
|
||||
List<RowMap> orgdepartmentList = DBSql.getMaps("select * from ORGUSER ");
|
||||
List<UserModel> activeList = UserCache.getActiveList();
|
||||
|
||||
int zindex = 1;
|
||||
elements = new WordUtilXWPF().rewritContent(null, elements, inputStream, "制度名称", null, "", 1);
|
||||
|
||||
@ -8,10 +8,7 @@ import java.io.InputStream;
|
||||
import java.math.BigInteger;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.*;
|
||||
|
||||
import org.apache.poi.hwpf.usermodel.Paragraph;
|
||||
import org.apache.poi.xwpf.usermodel.IBodyElement;
|
||||
@ -122,6 +119,18 @@ public class WordUtilXWPF {
|
||||
|
||||
// File file = null;
|
||||
int count = 0;
|
||||
String title="";
|
||||
JSONObject firstNode = new JSONObject();
|
||||
for (Map.Entry<String, Object> entry : elements.entrySet()) {
|
||||
String key = entry.getKey();
|
||||
JSONObject value = (JSONObject) entry.getValue();
|
||||
if(StringUtils.isNotEmpty(value.getString("title"))){
|
||||
if(value.getString("title").equals("制度")|| value.getString("title").equals("操作指导")){
|
||||
title=value.getString("title");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
List<String> failTitleList = new ArrayList<>();
|
||||
StringBuilder richSbuild = new StringBuilder();
|
||||
// String filePath =
|
||||
@ -161,9 +170,14 @@ public class WordUtilXWPF {
|
||||
|
||||
XWPFDocument doc = new XWPFDocument(docxfile);
|
||||
JSONArray onlinedata = new JSONArray();
|
||||
|
||||
JSONObject shapeze;
|
||||
// 创建起始节点
|
||||
JSONObject shapeze = ShapeUtil.getProcessShapeDefinitionByName("control.policy", "regulation");
|
||||
if(title.equals("制度")){
|
||||
shapeze = ShapeUtil.getProcessShapeDefinitionByName("control.policy", "regulation");
|
||||
}else{
|
||||
shapeze = ShapeUtil.getProcessShapeDefinitionByName("control.policy", "I/O_L4");
|
||||
}
|
||||
|
||||
String shapeIdz = UUIDGener.getObjectId();
|
||||
shapeze.put("text", name);// 不生效
|
||||
shapeze.put("level", 0);
|
||||
|
||||
@ -20,7 +20,7 @@ import java.nio.charset.Charset;
|
||||
public class UtilUrl {
|
||||
|
||||
//使用SOAP1.1发送消息
|
||||
public static String doPostSoap(String postUrl, String soapXml, String soapAction) {
|
||||
public String doPostSoap(String postUrl, String soapXml, String soapAction) {
|
||||
String retStr = "";
|
||||
// 创建HttpClientBuilder
|
||||
HttpClientBuilder httpClientBuilder = HttpClientBuilder.create();
|
||||
|
||||
Loading…
Reference in New Issue
Block a user