listReportPush.jsp 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. <%@ page language="java" contentType="text/html;charset=GBK" pageEncoding="GBK"%>
  2. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  3. <html>
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html;charset=GBK">
  6. <title>报表推送设置列表</title>
  7. <link href="${pageContext.request.contextPath}/main.css" rel="stylesheet" type="text/css" />
  8. <link href="${pageContext.request.contextPath }/liger/lib/ligerUI/skins/${sessionScope.css}/css/ligerui-all.css" rel="stylesheet" type="text/css" />
  9. <script src="${pageContext.request.contextPath }/liger/lib/jquery/jquery-1.3.2.min.js" type="text/javascript"></script>
  10. <script src="${pageContext.request.contextPath }/liger/lib/ligerUI/js/core/base.js" type="text/javascript"></script>
  11. <script src="${pageContext.request.contextPath}/liger/lib/ligerUI/js/ligerui.all.js" type="text/javascript"></script>
  12. <script type="text/javascript" src="/shares/js/constant.js"></script>
  13. <script type="text/javascript" src="/shares/js/common.js"></script>
  14. <script type="text/javascript">
  15. var grid = null;
  16. var dialog = null;
  17. $(function() {
  18. loadReportPushList();
  19. });
  20. function loadReportPushList(params) {
  21. var columns = [ {
  22. display : '报表类型',
  23. name : 'type_name',
  24. width: '15%'
  25. }, {
  26. display : '报表名称',
  27. name : 'report_name',
  28. width: '30%'
  29. }, {
  30. display : '状态',
  31. name : 'execute_state_name',
  32. width: '15%'
  33. }, {
  34. display : '操作',
  35. name : 'remark',
  36. width: '20%',
  37. render : function(row){
  38. var html = "";
  39. html = "<a href=\"#\" onclick=\"toEditReportPush("+row.universalid+")\">编辑</a>";
  40. html += "&nbsp;&nbsp;<a href=\"#\" onclick=\"delReportPush("+row.universalid+")\">删除</a>";
  41. html += "&nbsp;&nbsp;<a href=\"#\" onclick=\"toReportSubscribeList("+row.universalid+")\">订阅列表</a>";
  42. html += "&nbsp;&nbsp;<a href=\"#\" onclick=\"toReportPushHistoryList("+row.universalid+")\">推送历史</a>";
  43. return html;
  44. }
  45. } ];
  46. grid = $("#maingrid4")
  47. .ligerGrid(
  48. {
  49. columns : columns,
  50. pageSize : 20,
  51. url : 'reportPushAction.do?method=queryReportPushData&time='
  52. + new Date().getTime() + params,
  53. pageParmName : 'p', //页索引参数名,(提交给服务器)
  54. pagesizeParmName : 'pSize', //页记录数参数名,(提交给服务器)
  55. width : '99.9%',
  56. height : '99%'
  57. });
  58. $("#pageloading").hide();
  59. }
  60. //查询
  61. function searchByKword() {
  62. var s = "";
  63. var att_date_start = $("#att_date_start").val();//规则名称
  64. if (att_date_start != "" && typeof (att_date_start) != "undefined") {
  65. s += "&att_date_start=" + att_date_start;
  66. }
  67. var att_date_end = $("#att_date_end").val();//规则名称
  68. if (att_date_end != "" && typeof (att_date_end) != "undefined") {
  69. s += "&att_date_end=" + att_date_end;
  70. }
  71. grid.set("newPage", "1");
  72. loadReportPushList(s);
  73. }
  74. function toAddReportPush(){
  75. addTab('addReportPush','新增推送','reportPushAction.do?method=toAddReportPush'+'&tabid=' + getCurrentTabId(),true,true);
  76. }
  77. function toEditReportPush(universalid){
  78. addTab('eidtReportPush','编辑推送','reportPushAction.do?method=toEditReportPush&universalid='+universalid+'&tabid=' + getCurrentTabId(),true,true);
  79. }
  80. function toReportSubscribeList(universalid){
  81. addTab('reportSubscribeList','订阅列表','reportPushAction.do?method=toReportSubscribeList&push_id='+universalid+'&tabid=' + getCurrentTabId(),true,true);
  82. }
  83. function toReportPushHistoryList(universalid){
  84. addTab('toReportPushHistoryList','推送历史','reportPushAction.do?method=toReportPushHistoryList&push_id='+universalid+'&tabid=' + getCurrentTabId(),true,true);
  85. }
  86. function delReportPush(universalid){
  87. $.ligerDialog.confirm('是否确认删除?', function (yes)
  88. {
  89. if(yes){
  90. $.ajax({
  91. type:"POST",
  92. url:"reportPushAction.do?method=delReportPush",
  93. data : {"universalid":universalid},
  94. timeout:10000,
  95. cache:false,
  96. dataType:"json",
  97. success:function(data){
  98. var success = data.success;
  99. if(success){
  100. $.ligerDialog.success(success);
  101. loadReportPushList();
  102. }else{
  103. showAjaxError(null, data.error);
  104. }
  105. },
  106. error:showAjaxError
  107. });
  108. }
  109. });
  110. }
  111. </script>
  112. </head>
  113. <body>
  114. <div class="container">
  115. <div id="title" class="form-button">
  116. <input type="button" class="l-button" value="新增" onclick="toAddReportPush();" style="width: 70px"/>
  117. </div>
  118. <div class="default_search" style="margin: 0; height:30px;"></div>
  119. <div style="clear: both;"></div>
  120. <div id="searchbar">
  121. <div style="overflow: hidden; clear: both;">
  122. <div id="maingrid4" style="margin: 0; padding: 0"></div>
  123. </div>
  124. </div>
  125. </div>
  126. </body>
  127. </html>