actProcessRunningList.jsp
4.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
<title>运行中的流程</title>
<meta name="decorator" content="default"/>
<script type="text/javascript">
$(document).ready(function(){
top.$.jBox.tip.mess = null;
});
function page(n,s){
location = '${ctx}/act/process/running/?pageNo='+n+'&pageSize='+s;
}
function updateCategory(id, category){
$.jBox($("#categoryBox").html(), {title:"设置分类", buttons:{"关闭":true}, submit: function(){}});
$("#categoryBoxId").val(id);
$("#categoryBoxCategory").val(category);
}
//CheckBox 全选
function selectAll(){
var a = document.getElementsByTagName("input");
for(var i = 0;i<a.length;i++){
if(a[i].type == "checkbox"){
a[i].checked = true;
}
}
}
//全不选择
function unselectAll(){
var a = document.getElementsByTagName("input");
for(var i = 0;i<a.length;i++){
if(a[i].type == "checkbox"){
a[i].checked = false;
}
}
}
var procids_value =[];
function batDeleteProcIds(){
$('input[name="check_procid"]:checked').each(function(){
procids_value.push($(this).val());
});
if(procids_value.length == 0){
alert('请选择一条流程信息!');
return;
}
var selectedIDs = procids_value.join(';');
alert("本次批量删除的流程ID数量为:【"+procids_value.length+"】;ID分别为:"+selectedIDs);
var url = "${ctx}/act/process/deleteBatProcIns?procInsIds="+selectedIDs;
$("#batDeleteForm").attr("action",url);
}
</script>
<script type="text/template" id="categoryBox">
<form id="categoryForm" action="${ctx}/act/process/updateCategory" method="post" enctype="multipart/form-data"
style="text-align:center;" class="form-search" onsubmit="loading('正在设置,请稍等...');"><br/>
<input id="categoryBoxId" type="hidden" name="procDefId" value="" />
<select id="categoryBoxCategory" name="category">
<c:forEach items="${fns:getDictList('act_category')}" var="dict">
<option value="${dict.value}">${dict.label}</option>
</c:forEach>
</select>
<br/><br/>
<input id="categorySubmit" class="btn btn-primary" type="submit" value=" 保 存 "/>
</form>
</script>
</head>
<body>
<ul class="nav nav-tabs">
<li><a href="${ctx}/act/process/">流程管理</a></li>
<li><a href="${ctx}/act/process/deploy/">部署流程</a></li>
<li class="active"><a href="${ctx}/act/process/running/">运行中的流程</a></li>
</ul>
<form id="searchForm" action="${ctx}/act/process/running/" method="post" class="breadcrumb form-search">
<label>流程实例ID:</label><input type="text" id="procInsId" name="procInsId" value="${procInsId}" class="input-medium"/>
<label>流程定义Key:</label><input type="text" id="procDefKey" name="procDefKey" value="${procDefKey}" class="input-medium"/>
<input id="btnSubmit" class="btn btn-primary" type="submit" value="查询"/>
</form>
<form id="batDeleteForm" action="#" method="post" onsubmit="batDeleteProcIds();" class="breadcrumb form-search">
<label>批量删除原因:</label><input type="text" id="reason" name="reason" class="input-medium"/>
<input id="btnBatSubmit" class="btn btn-primary" type="submit" value="批量删除流程">
<input id="btnSelectAll" class="btn btn-primary" type="button" value="全 选" onclick="javascript:selectAll();"/>
<input id="btnunSelectAll" class="btn btn-primary" type="button" value="全不选" onclick="javascript:unselectAll();"/>
</form>
<sys:message content="${message}"/>
<table class="table table-striped table-bordered table-condensed">
<thead>
<tr>
<th>选择</th>
<th>执行ID</th>
<th>流程实例ID</th>
<th>流程定义ID</th>
<th>当前环节</th>
<th>是否挂起</th>
<th>操作</th>
</tr>
</thead>
<tbody>
<c:forEach items="${page.list}" var="procIns">
<tr>
<td><input type="checkbox" name="check_procid" id="${procIns.id}"
value="${procIns.id}"/></td>
<td>${procIns.id}</td>
<td>${procIns.processInstanceId}</td>
<td>${procIns.processDefinitionId}</td>
<td>${procIns.activityId}</td>
<td>${procIns.suspended}</td>
<td>
<shiro:hasPermission name="act:process:edit">
<a href="${ctx}/act/process/deleteProcIns?procInsId=${procIns.processInstanceId}&reason=" onclick="return promptx('删除流程','删除原因',this.href);">删除流程</a>
</shiro:hasPermission>
</td>
</tr>
</c:forEach>
</tbody>
</table>
<div class="pagination">${page}</div>
</body>
</html>