管理办法,文件详情页,按钮切换以及文件属性打开逻辑更新
This commit is contained in:
parent
2a7721a150
commit
de84ceb995
@ -73,6 +73,28 @@
|
|||||||
height: 36px !important;
|
height: 36px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.floating-buttons {
|
||||||
|
position: absolute;
|
||||||
|
top: 10px;
|
||||||
|
left: 10px;
|
||||||
|
z-index: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.floating-button {
|
||||||
|
margin-right: 5px;
|
||||||
|
padding: 5px 10px;
|
||||||
|
border: none;
|
||||||
|
border-radius: 4px;
|
||||||
|
background-color: #4e7ff9;
|
||||||
|
color: white;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.floating-button:hover {
|
||||||
|
background-color: #3a68e0;
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
<script src="../apps/com.actionsoft.apps.coe.pal/lib/designer/scripts/jquery.js"></script>
|
<script src="../apps/com.actionsoft.apps.coe.pal/lib/designer/scripts/jquery.js"></script>
|
||||||
<script type='text/javascript' charset='UTF-8' src='../apps/com.actionsoft.apps.coe.pal/lib/designer/scripts/util.js'></script>
|
<script type='text/javascript' charset='UTF-8' src='../apps/com.actionsoft.apps.coe.pal/lib/designer/scripts/util.js'></script>
|
||||||
@ -695,6 +717,13 @@
|
|||||||
//$(".headerTab").css("margin-right" , "5%");
|
//$(".headerTab").css("margin-right" , "5%");
|
||||||
changeUrl();
|
changeUrl();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(methodId=="process.epc" || methodId=="process.flowchart"){//流程类图
|
||||||
|
$("#floating-buttons").show();
|
||||||
|
}else{
|
||||||
|
$("#floating-buttons").hide();
|
||||||
|
}
|
||||||
|
|
||||||
// else {
|
// else {
|
||||||
// $(".headerTab").css("margin-right" , "4%");
|
// $(".headerTab").css("margin-right" , "4%");
|
||||||
// }
|
// }
|
||||||
@ -744,6 +773,48 @@
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function openInfo(type){
|
||||||
|
if(type==="word"){
|
||||||
|
$("#designer_layout").height( $("#designer_layout").height() + 93);
|
||||||
|
$(".suofang").hide();
|
||||||
|
$(".newadd_card .title").hide();
|
||||||
|
$.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']) {
|
||||||
|
$("#canvas_container").hide();
|
||||||
|
$("#canvas_container_epcWord").empty();
|
||||||
|
$("#canvas_container_epcWord").show();
|
||||||
|
$("#canvas_container_epcWord").css({"width":"100%","height":"100%"});
|
||||||
|
let url = msg['data']['url'];
|
||||||
|
$("#canvas_container_epcWord").append("<iframe id='ifr' src=" + url + "></iframe>");
|
||||||
|
$("#on_doc").width("1050px");
|
||||||
|
$('#online_mainDiv').css("left","0px");
|
||||||
|
$("#ifr").height("100%");
|
||||||
|
$("#ifr").width("100%");
|
||||||
|
$("#designer_layout").css("overflow-x","hidden");
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
$.simpleAlert("close");
|
||||||
|
$.simpleAlert(msg['msg'], 'info');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}else{
|
||||||
|
$(".suofang").show();
|
||||||
|
$(".newadd_card .title").show();
|
||||||
|
$("#canvas_container").show();
|
||||||
|
$("#canvas_container_epcWord").hide();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//将文件预览页面嵌入流程模型页面
|
//将文件预览页面嵌入流程模型页面
|
||||||
function changeUrl() {
|
function changeUrl() {
|
||||||
$.ajax({
|
$.ajax({
|
||||||
@ -758,6 +829,7 @@
|
|||||||
//$.simpleAlert("close");
|
//$.simpleAlert("close");
|
||||||
if (msg['data']) {
|
if (msg['data']) {
|
||||||
$("#canvas_container").empty();
|
$("#canvas_container").empty();
|
||||||
|
$("#canvas_container").removeAttr('style');
|
||||||
$("#canvas_container").css({"width":"100%","height":"100%"});
|
$("#canvas_container").css({"width":"100%","height":"100%"});
|
||||||
let url = msg['data']['url'];
|
let url = msg['data']['url'];
|
||||||
$("#canvas_container").append("<iframe id='ifr' src=" + url + "></iframe>");
|
$("#canvas_container").append("<iframe id='ifr' src=" + url + "></iframe>");
|
||||||
@ -883,6 +955,7 @@
|
|||||||
-ms-user-select: text;
|
-ms-user-select: text;
|
||||||
user-select: text; }
|
user-select: text; }
|
||||||
.newadd_card {
|
.newadd_card {
|
||||||
|
position: relative; /* 添加相对定位,作为浮动按钮的参考容器 */
|
||||||
float: left;
|
float: left;
|
||||||
width:70%;
|
width:70%;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
@ -1064,6 +1137,12 @@
|
|||||||
<span class="newadd_title" id="toolbarname"><#toolbarName></span>
|
<span class="newadd_title" id="toolbarname"><#toolbarName></span>
|
||||||
</div>
|
</div>
|
||||||
<div class="newadd_card">
|
<div class="newadd_card">
|
||||||
|
<!-- 新增按钮容器 -->
|
||||||
|
<div id="floating-buttons" class="floating-buttons" style="display: none">
|
||||||
|
<button class="floating-button" onclick="openInfo('epc')" >流程图</button>
|
||||||
|
<button class="floating-button" onclick="openInfo('word')" >手册图</button>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="title"><span></span></div>
|
<div class="title"><span></span></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;">
|
||||||
@ -1071,6 +1150,9 @@
|
|||||||
<canvas id="designer_grids" style="background-color:white;">您的浏览器不支持HTML5,请使用IE9及以上版本,或Chrome、Firefox等浏览器</canvas>
|
<canvas id="designer_grids" style="background-color:white;">您的浏览器不支持HTML5,请使用IE9及以上版本,或Chrome、Firefox等浏览器</canvas>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<div id="canvas_container_epcWord">
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div id="shape_img_container"></div>
|
<div id="shape_img_container"></div>
|
||||||
<div id="layout_block"></div>
|
<div id="layout_block"></div>
|
||||||
|
|||||||
@ -494,6 +494,35 @@ function openDialog(obj) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 打开管理要求wps预览页面
|
||||||
|
* @param uuid
|
||||||
|
*/
|
||||||
|
function openMRWps(uuid){
|
||||||
|
$.ajax({
|
||||||
|
type : "POST",
|
||||||
|
url : "./jd?sid="
|
||||||
|
+ CLB.sid
|
||||||
|
+ "&cmd=com.awspaas.user.apps.yiliwps.previewUrl_mr_read",
|
||||||
|
data : {
|
||||||
|
palId : uuid,
|
||||||
|
},
|
||||||
|
success : function(data) {
|
||||||
|
if(data.result=="ok"){
|
||||||
|
if (data.data.content.code === 200) {
|
||||||
|
//换一种打开方式
|
||||||
|
window.open(data.data.content.data.link);
|
||||||
|
}else{
|
||||||
|
$.simpleAlert(data.data.msg, "info", 2000);
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
$.simpleAlert(data.msg, "info", 2000);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Array.prototype.unique = function(){
|
Array.prototype.unique = function(){
|
||||||
var res = [];
|
var res = [];
|
||||||
@ -1556,6 +1585,9 @@ function initProcessDesc() {
|
|||||||
t += '<td class="tableContent tableright" onclick="openDialog(' + JSON.stringify(tableValue).replace(/\"/g,"'") +')">' +'<span style="color:blue">'+tableFlag+'</span>'+'</td>';
|
t += '<td class="tableContent tableright" onclick="openDialog(' + JSON.stringify(tableValue).replace(/\"/g,"'") +')">' +'<span style="color:blue">'+tableFlag+'</span>'+'</td>';
|
||||||
t += '</tr>';
|
t += '</tr>';
|
||||||
}
|
}
|
||||||
|
} else if(obj.name=="管理要求位置"){
|
||||||
|
//增加点击事件,打开管理要求的在线文档
|
||||||
|
t += '<td class="tableContent tableright" onclick="openMRWps(\''+ruuid+'\')">' + value + '</td>';
|
||||||
} else {
|
} else {
|
||||||
value = value.replace(/\n/g,'<br>')
|
value = value.replace(/\n/g,'<br>')
|
||||||
if(obj.name == "作废人" && value.indexOf("注销")>0){
|
if(obj.name == "作废人" && value.indexOf("注销")>0){
|
||||||
@ -1567,6 +1599,7 @@ function initProcessDesc() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// t += '<td colspan="2" class="tableContent">' + value + '</td>';
|
// t += '<td colspan="2" class="tableContent">' + value + '</td>';
|
||||||
// t += '</tr>';
|
// t += '</tr>';
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user