subscribeList.jsp 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285
  1. <%@ page language="java" contentType="text/html;charset=GBK" pageEncoding="GBK"%>
  2. <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
  3. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  4. <html>
  5. <head>
  6. <meta http-equiv="Content-Type" content="text/html;charset=GBK">
  7. <title>申购记录列表</title>
  8. <%-- <link href="${pageContext.request.contextPath}/main.css" rel="stylesheet" type="text/css" /> --%>
  9. <link href="${pageContext.request.contextPath }/liger/lib/ligerUI/skins/${sessionScope.css}/css/ligerui-all.css" rel="stylesheet" type="text/css" />
  10. <script src="${pageContext.request.contextPath }/liger/lib/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
  11. <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/ligerui.all.js" type="text/javascript"></script>
  12. <link href="${pageContext.request.contextPath}/main.css" rel="stylesheet" type="text/css" />
  13. <script type="text/javascript" src="/shares/js/constant.js"></script>
  14. <script type="text/javascript" src="/shares/js/common.js"></script>
  15. <script type="text/javascript" src="/shares/js/yw/bpm/oa.js"></script>
  16. <script type="text/javascript" src="/shares/js/yw/bpm/promptDefine.js"></script>
  17. <script type="text/javascript" src="${pageContext.request.contextPath }/yw/bpm/datacenter/js/flowInsDataCommon.js"></script>
  18. <script type="text/javascript">
  19. var grid = null;
  20. $(function() {
  21. grid = $("#maingrid4")
  22. .ligerGrid(
  23. {
  24. columns : [
  25. {
  26. display : '标题',
  27. name : 'flow_ins_name',
  28. width : 200
  29. },
  30. // {
  31. // display : '申请人',
  32. // name : 'create_name',
  33. // width : 100
  34. // },
  35. {
  36. display : '申请日期',
  37. name : 'apply_date',
  38. width : 100
  39. },
  40. {
  41. display : '申购总额',
  42. name : 'total_amount',
  43. width : 100
  44. },
  45. {
  46. display : '已付款',
  47. name : 'paid_amount',
  48. width : 100,
  49. render : function (row){
  50. if(row.paid_amount){
  51. return row.paid_amount;
  52. }else{
  53. return "0";
  54. }
  55. }
  56. },
  57. {
  58. display : '未付款',
  59. name : 'remain_amount',
  60. width : 100,
  61. render : function (row){
  62. if(row.remain_amount){
  63. return row.remain_amount;
  64. }else{
  65. return "0";
  66. }
  67. }
  68. },
  69. {
  70. display : '状态',
  71. name : 'state',
  72. width : 100,
  73. render : function(row) {
  74. var html = "";
  75. if (row.state == ""
  76. || row.state == "0") {
  77. html = "<font color=red>未报销</font>";
  78. } else if (row.state == "1" && row.paid_amount >= row.total_amount ) {
  79. html = "<font color=green>已全部报销</font>";
  80. }else if(row.state == "1" && row.paid_amount < row.total_amount){
  81. html = "<font color=green>已部分报销</font>";
  82. }
  83. return html;
  84. }
  85. },
  86. {
  87. display : '创建时间',
  88. name : 'create_date',
  89. width : 130
  90. },
  91. {
  92. display : '操作',
  93. isAllowHide : false,
  94. render : function(row) {
  95. var dialogId = row.flow_ins_id
  96. + new Date().getTime();
  97. var html = '<a href=\"#\" onclick=\"openODialog(\'${pageContext.request.contextPath }/FlowAction.do?task=toInfo&state=all&insId='
  98. + row.flow_ins_id
  99. + '&tabid='
  100. + getCurrentTabId()
  101. + '&dialogId='
  102. + dialogId
  103. + '\', \'查看流程信息\', \''
  104. + dialogId
  105. + '\');\">查看</a>&nbsp;';
  106. if (row.flow_model_id
  107. && (row.state == "" || row.state == "0" || row.paid_amount < row.total_amount)) {
  108. html += '<a href=\"#\" onclick=\"startFlow('
  109. + row.flow_model_id
  110. + ','
  111. + row.flow_ins_id
  112. + ',\''
  113. + row.model_name
  114. + '\',\'${session.name}\')\" >发起流程</a>';
  115. }
  116. return html;
  117. }
  118. } ],
  119. usePager : true,
  120. pageSize : 20,
  121. parms : [ {
  122. name : "flow_ins_name",
  123. value : ""
  124. }, {
  125. name : "starttime",
  126. value : ""
  127. }, {
  128. name : "endtime",
  129. value : ""
  130. } ],
  131. url : 'bpmDataCenterAction.do?task=getSubscribeData&time='
  132. + new Date().getTime(),
  133. pageParmName : 'p', //页索引参数名,(提交给服务器)
  134. pagesizeParmName : 'pSize', //页记录数参数名,(提交给服务器)
  135. pageSize: 20,
  136. width : '99.9%',
  137. enabledSort : true,
  138. height : '99%',//getParentHeight()-67,
  139. detail : {
  140. onShowDetail : showPayment
  141. },
  142. onError : function() {
  143. alert("数据加载失败,请刷新页面!");
  144. }
  145. });
  146. $("#pageloading").hide();
  147. $("#starttime").ligerDateEditor({
  148. showTime : false,
  149. width : 120,
  150. labelAlign : 'left',
  151. format : "yyyy-MM-dd"
  152. });
  153. $("#endtime").ligerDateEditor({
  154. showTime : false,
  155. width : 120,
  156. labelAlign : 'left',
  157. format : "yyyy-MM-dd"
  158. });
  159. //$("#modelId").ligerComboBox();
  160. });
  161. function showPayment(row, detailPanel, callback) {
  162. var gProcess = document.createElement('div');
  163. $(detailPanel).append(gProcess);
  164. $(gProcess).css('margin', 10).ligerGrid(
  165. {
  166. columns : [ {
  167. display : '标题',
  168. name : 'flow_ins_name',
  169. width : 180
  170. }, {
  171. display : '申请日期',
  172. name : 'apply_date',
  173. width : 100
  174. }, {
  175. display : '付款总额',
  176. name : 'total_amount',
  177. width : 100
  178. }, {
  179. display : '流转状态',
  180. name : 'state_name',
  181. width : 90
  182. }, {
  183. display : '创建时间',
  184. name : 'create_date',
  185. width : 130
  186. } , {
  187. display : '操作',
  188. width : 100,
  189. isAllowHide : false,
  190. render : function(row) {
  191. var dialogId = row.flow_ins_id
  192. + new Date().getTime();
  193. var html = '<a href=\"#\" onclick=\"openODialog(\'${pageContext.request.contextPath }/FlowAction.do?task=toInfo&state=all&insId='
  194. + row.flow_ins_id
  195. + '&tabid='
  196. + getCurrentTabId()
  197. + '&dialogId='
  198. + dialogId
  199. + '\', \'查看流程信息\', \''
  200. + dialogId
  201. + '\');\">查看</a>&nbsp;';
  202. // if (row.flow_model_id
  203. // && (row.state == "" || row.state == "0")) {
  204. // html += '<a href=\"#\" onclick=\"startFlow('
  205. // + row.flow_model_id
  206. // + ','
  207. // + row.flow_ins_id
  208. // + ',\''
  209. // + row.model_name
  210. // + '\',\'${session.name}\')\" >发起流程</a>';
  211. // }
  212. return html;
  213. }
  214. }],
  215. usePager : false,
  216. width : '90%',
  217. frozen:false,
  218. url : 'bpmDataCenterAction.do?task=getPaymentData&linFlowInsId='
  219. + row.link_flow_ins_id + '&time='
  220. + new Date().getTime()
  221. });
  222. }
  223. function searchByKword() {
  224. grid.set("parms", [ {
  225. name : "flow_ins_name",
  226. value : encodeURI($("#flow_ins_name").val())
  227. }, {
  228. name : "starttime",
  229. value : $("#starttime").val()
  230. }, {
  231. name : "endtime",
  232. value : $("#endtime").val()
  233. } ]);
  234. grid.set("newPage", "1");
  235. grid.loadData(true);
  236. }
  237. function searchAll() {
  238. $("#flow_ins_name").val("");
  239. $("#starttime").val("");
  240. $("#endtime").val("");
  241. searchByKword();
  242. }
  243. </script>
  244. </head>
  245. <body>
  246. <div class="container-layout">
  247. <div id="title" class="form-button" style="width: 100%;">
  248. <input onclick="closeTabUseInOA();" type="button" value="关闭" class="l-button">
  249. </div>
  250. <div class="default_search" style="margin: 0; width: 100%;">
  251. <ul class="list_search">
  252. <li class="title">标题:</li>
  253. <li class="text"><input type="text" id="flow_ins_name" name="flow_ins_name" style="width: 130px;"></li>
  254. </ul>
  255. <ul class="list_search">
  256. <li class="title">创建时间:</li>
  257. <li class="text"><input type="text" id="starttime" name="starttime" style="width: 130px;"></li>
  258. <li class="title" style="width: 10px; text-align: center; padding-left: 0px; padding-right: 3px;">至</li>
  259. <li class="text"><input type="text" id="endtime" name="endtime" style="width: 130px;"></li>
  260. </ul>
  261. <!-- </div> -->
  262. <!-- <div class="default_search" style="margin: 0; width: 100%;"> -->
  263. <ul>
  264. <li class="search-button"><input type="button" class='l-button' name="search" onclick="searchByKword()" value="查询" />
  265. <input type="button" class='l-button' name="search" onclick="searchAll()" value="查询全部" />
  266. </li>
  267. </ul>
  268. </div>
  269. <div id="maingrid4" style="margin: 0; padding: 0; clear: both;"></div>
  270. <div style="display: none;"></div>
  271. </div>
  272. <%@ include file="/include/message.jsp"%>
  273. </body>
  274. </html>