pal参数提交,阅览代码提交

This commit is contained in:
zhal 2023-07-29 13:37:10 +08:00
parent 353c634c10
commit 745b072171

View File

@ -142,6 +142,7 @@ Designer.op.shapeSelectable = function(a) {
}
});
};
//根据isLaneAttrConfig来判断数组的数据
function getTmpArray(isLaneAttrConfig) {
var tmpArray1 = ['verticalPool', 'verticalLane', 'horizontalPool', 'horizontalLane'];
@ -152,6 +153,7 @@ function getTmpArray(isLaneAttrConfig) {
return tmpArray1;
}
}
// 重写
Designer.linkClickable = function (a, c) {/*
* var b = $("#link_spot"); if
@ -170,6 +172,7 @@ Designer.linkClickable = function(a, c) {/*
var myshapeLink = "";
var linkIndex = 0;
var selectShape = Utils.getSelected()[0];
/**
* 功能去除字符串中所有空格 传参需要处理的字符串 返回值去除空格后的字符串
*/
@ -199,8 +202,16 @@ UI.showInsertLink = function() {
$("#link_dialog").dialog({
title: "插入链接",
buttons: [
{text:'确定',cls:"blue",handler:function(){UI.setLink();}},
{text:'关闭',handler:function(){$('#link_dialog').dialog('close');}}
{
text: '确定', cls: "blue", handler: function () {
UI.setLink();
}
},
{
text: '关闭', handler: function () {
$('#link_dialog').dialog('close');
}
}
]
});
$(".awsui-simple-tab").find("a[tit=file]").trigger('click');
@ -326,13 +337,20 @@ UI.showImportDlg = function() {
width: 400,
height: 200,
buttons: [
{text:'导入',cls:"blue",handler:function(){
{
text: '导入', cls: "blue", handler: function () {
importVisio();
}},
{text:'取消',handler:function(){$("#visio_import_dlg").dialog("close");}}
}
},
{
text: '取消', handler: function () {
$("#visio_import_dlg").dialog("close");
}
}
]
});
}
//初始化visio导入的fileupload组件
function initVisioImportFileUpload() {
$("#visio_import_upfile").upfile({
@ -834,6 +852,7 @@ function setLinkTargetType(obj) {
$(obj).parent().hide().siblings().show().text($(obj)
.find("option:selected").text());
}
// 判断给定的对象是不是数组
function isArray(o) {
@ -956,11 +975,13 @@ function checkLink(str) {
}
return flag;
}
// 隐藏链接重复提示
function removerWarning() {
$("#warningContent").text("");
}
// 删除所选 链接
function deleteTheLinkNode(str, index) {
@ -1062,12 +1083,14 @@ function removeLinkHistoryByLink(obj) {
window.top.$.confirm(options);
}
// 显示链接历史的删除
function showRemoveTrLinkHistory(obj) {
$(obj).children("td").children("span::contains('删除')").show();
$(obj).children("td").children("span").children("select").show();
}
// 隐藏链接历史的删除按钮
function hideRemoveTrLinkHistory(obj) {
@ -1298,6 +1321,7 @@ function showRelevanceShapesContent() {
});
}
function noPermissionMsg() {
$.simpleAlert("暂无该模型权限", "warning", 1500);
}
@ -1379,6 +1403,7 @@ function attributeShowTabContent(currentShape) {
// var dialogTableList = []
var tableObj = {}
var curTableId = ''
function getPrivateAttributeHtml(attributesJsonArray, tbodyId, shape) {
// 属性排序
var defaultMoreAttr = $('#defaultMoreAttrSort').val();
@ -1462,10 +1487,12 @@ function getPrivateAttributeHtml(attributesJsonArray, tbodyId, shape) {
+ '</td></tr>';
} else if (!objReadonly && objType == "boolean") {
booleanFlag = true;
var booleanValue = { "objId" : obj.id,
var booleanValue = {
"objId": obj.id,
"objValue": obj.value,
"objOptions": obj.ref,
"objType": objType};
"objType": objType
};
booleanValues.push(booleanValue);
constr = '<tr ' + mouseout + mouseover + ' objid="' + obj.id + '" class="tagContentTableTr">'
+ ' <td>' + objName + '</td>'
@ -1500,9 +1527,11 @@ function getPrivateAttributeHtml(attributesJsonArray, tbodyId, shape) {
} else if (objType == "select" || objType == "select_m") {
selectFlag = true;
var selectValue = { "objId" : obj.id,
var selectValue = {
"objId": obj.id,
"objValue": obj.value,
"objType": objType};
"objType": objType
};
selectValues.push(selectValue);
constr = '<tr ' + mouseout + mouseover + ' objid="' + obj.id + '" class="tagContentTableTr">'
@ -1540,7 +1569,11 @@ function getPrivateAttributeHtml(attributesJsonArray, tbodyId, shape) {
} else if (!objReadonly && objType == "table") {
let objRef = JSON.parse(obj.ref)
let objTableInput = obj.value.table !== undefined && obj.value.table.length > 1 ? '请查看' : '请输入'
tableObj[obj.id] = obj.value.table == undefined ? [ { id: Utils.newId() ,name: objRef.firstColumn, desc: objRef.secondColumn} ] : obj.value.table;
tableObj[obj.id] = obj.value.table == undefined ? [{
id: Utils.newId(),
name: objRef.firstColumn,
desc: objRef.secondColumn
}] : obj.value.table;
// dialogTableList = obj.value.table == undefined ? [ { id: Utils.newId() ,name: objRef.firstColumn, desc: objRef.secondColumn} ] : obj.value.table;
constr = '<tr ' + mouseout + mouseover + ' class="tagContentTableTr">'
+ ' <td>' + objName + requiredSpan + '</td>'
@ -1652,6 +1685,7 @@ function getAttributeByAttrId(shape, objId, relationShapes) {
return shape;
}
Array.prototype.notDistinct = function () {
var newArr = [], obj = {};
for (var i = 0, len = this.length; i < len; i++) {
@ -1876,6 +1910,7 @@ function removeShepeAttributeAndReturnDifferent(exitObj, newObj1) {
}
return exitObj;
}
// 删除没有选中的元素
function removeNotCheckedAttribute(shape, obj1) {
@ -1909,6 +1944,7 @@ function removeNotCheckedAttribute(shape, obj1) {
// Model.update(shape);
$("#tagContentTable0 tr[objid='" + obj1.id + "']").remove();
}
// 过滤掉重复的属性生成新的数组
function filterRepeatAttribute(arr1, arr2, shape) {
@ -1944,6 +1980,7 @@ function showEditButton(obj) {
}
var inputUpdate = false;
function saveInputContent(obj, value) {
// 按钮
// $(obj).siblings("span::contains('...')").hide();
@ -2272,6 +2309,7 @@ function removeTrAttribute(obj) {
};
window.top.$.confirm(options);
}
// 显示删除按钮
function showRemoveTrAttribute(obj) {
@ -2286,6 +2324,7 @@ function showRemoveTrAttribute(obj) {
$(obj).children("td").children("span").hide();
}
}
// 隐藏删除按钮
function hideRemoveTrAttribute(obj) {
@ -2300,6 +2339,7 @@ function hideRemoveTrAttribute(obj) {
$(obj).children("td").children("span").show();
}
}
// 经常用的是通过遍历,重构数组.
Array.prototype.remove = function (dx) {
if (isNaN(dx) || dx > this.length) {
@ -2312,6 +2352,7 @@ Array.prototype.remove = function(dx) {
}
this.length -= 1;
};
function removeElementFromArr(dx, obj) {
if (isNaN(dx) || dx > obj.length) {
return false;
@ -2588,6 +2629,7 @@ function deleteLinkerSelected(linker) {
Model.remove(d)
}
}
// 显示图形关系特性
function showShapeRelationTab(currentShape) {
@ -2697,6 +2739,7 @@ function showShapeRelationTab(currentShape) {
}
}
}
// 给关系类型增加内容
function addtagContentTableContent(shape1, str, obj) {
@ -2711,6 +2754,7 @@ function addtagContentTableContent(shape1, str, obj) {
+ '</div> </td></tr>';
$("#tagContentTable1").append(constr);
}
// 判断是不是支持对象的关系类型
function isObjectRelationshipModel(linker, isAlert) {
@ -2895,6 +2939,7 @@ function changeArributeByShape() {
$("#attr_no_more_attribute_id").hide();
}
}
function initUserAddressForShape(objIds, shapeId, shapeName) {
$.each(objIds, function (key, value) {
var objId = value;
@ -3459,7 +3504,6 @@ function getRelevanceAwsOrgNameByShapeId(objIds, shapeId) {
}
// 形状关联弹窗
function openRelationDig(obj, value) {
var shapeRelationValue = $("input[objid_shapeId='" + $(obj).attr("objid") + "']").val();
@ -3908,6 +3952,7 @@ function saveRelevanceShapesTODB(shapesObj, shapeId, shapeName, fileName,
// 获取boolean类型属性的option
var booleanComboboxs = [];
function getBooleanSelectOptions(booleanValues, shapeId) {
for (var i = 0; i < booleanValues.length; i++) {
var objId = booleanValues[i].objId;
@ -3975,6 +4020,7 @@ function getBooleanSelectOptions(booleanValues, shapeId) {
//获取select类型属性的option
var comboboxs = [];
function getSelectOptions(category, selectValues, shapeId) {
$.ajax({
type: "POST",
@ -4118,6 +4164,7 @@ function getScreenResolution() {
}
}
/**
* 图形创建后事件
*/
@ -4173,7 +4220,37 @@ function outputReport() {
fileId: ruuid
},
success: function (r) {
debugger;
if (r.result == "ok") {
if (methodId == "data.form") {
$.ajax({
type: "POST",
url: "./jd?sid="
+ CLB.sid
+ "&cmd=com.actionsoft.apps.coe.pal.publisher_output_pr_estimateFile",
data: {
fileId: ruuid
},
success: function (rep) {
if (rep.data.result == "existExcel") {
$.ajax({
type: "POST",
url: "./jd?sid="
+ CLB.sid
+ "&cmd=com.actionsoft.apps.coe.pal.publisher_output_pr_downloadExcelFile",
data: {
taskIds: r.data.taskId
},
success: function (msg) {
if (msg.result == "ok") {
window.open(msg.data.url);
$.simpleAlert("close");
} else {
$.simpleAlert("close");
}
}
});
} else {
$.simpleAlert('正在打开', 'loading');
setTimeout(function () {
$.ajax({
@ -4198,6 +4275,98 @@ function outputReport() {
}
});
}, 2000);
}
}
});
} else if (methodId == 'control.policy') {
$.ajax({
type: "POST",
url: "./jd?sid="
+ CLB.sid
+ "&cmd=com.actionsoft.apps.coe.pal.publisher_output_pr_estimatePPTFile",
data: {
fileId: ruuid
},
success: function (rep) {
debugger;
if (rep.data.result == "existPPT") {
setTimeout(function () {
$.ajax({
type: "POST",
url: "./jd?sid="
+ CLB.sid
+ "&cmd=com.actionsoft.apps.coe.pal_outputreport_output_process_ppt_preview",
data: {
taskId: r.data.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');
}
}
});
}, 2000);
} else {
$.simpleAlert('正在打开', 'loading');
setTimeout(function () {
$.ajax({
type: "POST",
url: "./jd?sid="
+ CLB.sid
+ "&cmd=com.actionsoft.apps.coe.pal_outputreport_output_process_preview",
data: {
taskId: r.data.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');
}
}
});
}, 2000);
}
}
});
} else {
$.simpleAlert('正在打开', 'loading');
setTimeout(function () {
$.ajax({
type: "POST",
url: "./jd?sid="
+ CLB.sid
+ "&cmd=com.actionsoft.apps.coe.pal_outputreport_output_process_preview",
data: {
taskId: r.data.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');
}
}
});
}, 2000);
}
} else {
if (methodId == 'data.form') {
$.simpleAlert('表单手册创建失败', 'error');
@ -4222,10 +4391,16 @@ UI.showImportShapeDlg = function() {
width: 570,
height: 380,
buttons: [
{text:'确定',cls:"blue",handler:function(){
{
text: '确定', cls: "blue", handler: function () {
importShapeFile();
}},
{text:'取消',handler:function(){$("#shape_import_dlg").dialog("close");}}
}
},
{
text: '取消', handler: function () {
$("#shape_import_dlg").dialog("close");
}
}
],
onClose: delShapeFiles
});
@ -4414,10 +4589,16 @@ UI.showImportPolicyFileDlg = function() {
width: 570,
height: 380,
buttons: [
{text:'确定',cls:"blue",handler:function(){
{
text: '确定', cls: "blue", handler: function () {
importPolicyFile();
}},
{text:'取消',handler:function(){$("#policyfile_import_dlg").dialog("close");}}
}
},
{
text: '取消', handler: function () {
$("#policyfile_import_dlg").dialog("close");
}
}
],
onClose: delPolicyFiles
});
@ -4878,6 +5059,7 @@ function getInterfaceShapeLink(obj, elements) {
}
var checkObj = undefined;
// 画布鼠标右键-添加至前置流程、后置流程功能
function showLeadAndRearProcessDlg(type) {
checkObj = undefined;