Merge branch 'master' of https://e.coding.net/yilidev/yilipalkaifa/apps
This commit is contained in:
commit
275a2414ff
Binary file not shown.
@ -1,50 +0,0 @@
|
||||
package com.actionsoft.apps.coe.pal.pal.repository.util;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
|
||||
import java.util.Iterator;
|
||||
|
||||
public class DiagramUtil {
|
||||
|
||||
|
||||
/**
|
||||
* 设置画布大小
|
||||
* @param elements
|
||||
*/
|
||||
public static void setDiagramHeightWidth(JSONObject definition, JSONObject elements) {
|
||||
// 获取最大宽高,给100长度富余
|
||||
JSONObject maxHW = getMaxPositionXY(elements);
|
||||
int maxX = maxHW.getInteger("maxX") + 150;
|
||||
int maxH = maxHW.getInteger("maxY") + 150;
|
||||
JSONObject page = definition.getJSONObject("page");
|
||||
int pageW = page.getInteger("width");
|
||||
int pageH = page.getInteger("height");
|
||||
page.put("width", pageW > maxX ? pageW : maxX);
|
||||
page.put("height", pageH > maxH ? pageH : maxH);
|
||||
definition.put("page", page);
|
||||
}
|
||||
|
||||
|
||||
|
||||
public static JSONObject getMaxPositionXY(JSONObject elements) {
|
||||
int maxX = -99999;
|
||||
int maxY = -99999;
|
||||
Iterator<String> it = elements.keySet().iterator();
|
||||
while (it.hasNext()) {
|
||||
String key = it.next();
|
||||
JSONObject shape = elements.getJSONObject(key);
|
||||
String shapeName = shape.getString("name");
|
||||
if(!"linker".equals(shapeName)) {
|
||||
JSONObject props = shape.getJSONObject("props");
|
||||
int x = props.getInteger("x");
|
||||
int y = props.getInteger("y");
|
||||
maxX = maxX < x ? x : maxX;
|
||||
maxY = maxY < y ? y : maxY;
|
||||
}
|
||||
}
|
||||
JSONObject result = new JSONObject();
|
||||
result.put("maxX", maxX);
|
||||
result.put("maxY", maxY);
|
||||
return result;
|
||||
}
|
||||
}
|
||||
@ -1,15 +1,15 @@
|
||||
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=../apps/com.actionsoft.apps.coe.pal/main/favicon.ico><title>CoE PAL流程资产库</title><script src=../commons/awsui/js/icon.array.js></script><script>const settingParam =; <#settingParam>;
|
||||
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1"><link rel=icon href=../apps/com.actionsoft.apps.coe.pal/main/favicon.ico><title>CoE PAL流程资产库</title><script src=../commons/awsui/js/icon.array.js></script><script>const settingParam = <#settingParam>;
|
||||
const axiosBaseUrl = "./";
|
||||
const production = true;</script><script>var isNoticeActive =; <#isNoticeActive>; //是否启用通知中心
|
||||
const production = true;</script><script>var isNoticeActive = <#isNoticeActive>; //是否启用通知中心
|
||||
var notificationSoundTips = false; // 是否开启消息到达声音提醒
|
||||
var notificationMsgLoadFrequency = 60; // 通知消息检查频率
|
||||
var isSecurityPwdChange =; <#isSecurityPwdChange>; // 是否允许用户修改口令
|
||||
var forceChangePwd =; <#forceChangePwd>; // 默认口令验证,是否强制修改默认密码
|
||||
var isSecurityPwdComplexity =; <#isSecurityPwdComplexity>; // 密码强度
|
||||
var securityMinPwdLength =; <#securityMinPwdLength>; // 允许账户口令最小长度,0表示无限制
|
||||
var securityMaxPwdLength =; <#securityMaxPwdLength>; // 允许账户口令最大长度,最多32位长度
|
||||
var isSecAdminUser =; <#isSecAdminUser>;// 是否安全保密员,开启三员且该用户为安全保密员为true
|
||||
var isManage =; <#isManage>;// 是否资产库管理员
|
||||
var isSecurityPwdChange = <#isSecurityPwdChange>; // 是否允许用户修改口令
|
||||
var forceChangePwd = <#forceChangePwd>; // 默认口令验证,是否强制修改默认密码
|
||||
var isSecurityPwdComplexity = <#isSecurityPwdComplexity>; // 密码强度
|
||||
var securityMinPwdLength = <#securityMinPwdLength>; // 允许账户口令最小长度,0表示无限制
|
||||
var securityMaxPwdLength = <#securityMaxPwdLength>; // 允许账户口令最大长度,最多32位长度
|
||||
var isSecAdminUser = <#isSecAdminUser>;// 是否安全保密员,开启三员且该用户为安全保密员为true
|
||||
var isManage = <#isManage>;// 是否资产库管理员
|
||||
var mainType = "<#mainType>";
|
||||
var uid = "<#uid>";
|
||||
var wHref = "./w";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user