weblog.html 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146
  1. <!DOCTYPE HTML>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="renderer" content="webkit|ie-comp|ie-stand">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  7. <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
  8. <meta http-equiv="Cache-Control" content="no-siteapp" />
  9. <!--[if lt IE 9]>
  10. <script type="text/javascript" src="${ctx}/assets/lib/html5.js"></script>
  11. <script type="text/javascript" src="${ctx}/assets/lib/respond.min.js"></script>
  12. <script type="text/javascript" src="${ctx}/assets/lib/PIE_IE678.js"></script>
  13. <![endif]-->
  14. <link rel="stylesheet" type="text/css" href="${ctx}/assets/static/h-ui/css/H-ui.min.css" />
  15. <link rel="stylesheet" type="text/css" href="${ctx}/assets/static/h-ui.admin/css/H-ui.admin.css" />
  16. <link rel="stylesheet" type="text/css" href="${ctx}/assets/lib/Hui-iconfont/1.0.7/iconfont.css" />
  17. <link rel="stylesheet" type="text/css" href="${ctx}/assets/lib/icheck/icheck.css" />
  18. <link rel="stylesheet" type="text/css" href="${ctx}/assets/static/h-ui.admin/skin/default/skin.css" id="skin" />
  19. <link rel="stylesheet" type="text/css" href="${ctx}/assets/static/h-ui.admin/css/style.css" />
  20. <script type="text/ecmascript" src="${ctx}/assets/lib/jquery/1.9.1/jquery.js"></script>
  21. <script type="text/javascript" src="${ctx}/assets/static/h-ui/js/H-ui.js"></script>
  22. <link rel="stylesheet" type="text/css" media="screen" href="${ctx}/assets/lib/jqueryui/jquery-ui.css" />
  23. <link rel="stylesheet" type="text/css" media="screen" href="${ctx}/assets/lib/jqgrid/css/ui.jqgrid.css" />
  24. <script type="text/ecmascript" src="${ctx}/assets/lib/jqueryui/jquery-ui.js"></script>
  25. <script type="text/ecmascript" src="${ctx}/assets/lib/jqgrid/js/i18n/grid.locale-cn.js"></script>
  26. <script type="text/ecmascript" src="${ctx}/assets/lib/jqgrid/js/jquery.jqGrid.min.js"></script>
  27. <script type="text/javascript" src="${ctx}/assets/js/base.js"></script>
  28. <!--[if IE 6]>
  29. <script type="text/javascript" src="${ctx}/assets/lib/DD_belatedPNG_0.0.8a-min.js" ></script>
  30. <script>DD_belatedPNG.fix('*');</script>
  31. <![endif]-->
  32. <script type="text/javascript">
  33. $(function() {
  34. $(window).resize(function(){
  35. $("#tree").setGridWidth($(window).width()-40); 
  36. });
  37. $("#tree").jqGrid({
  38. caption:'日志管理',
  39. url : '${ctx}/myconsole/weblog/getByPage',
  40. editurl:"${ctx}/myconsole/weblog/saveOrUpdate",
  41. mtype : "POST",
  42. datatype : "json",
  43. sidx : "opttime",
  44. sord : "desc",
  45. prmNames : {
  46. id: "keyid", 
  47. oper:"oper",    
  48. addoper:"add",
  49. editoper:"edit",
  50. deloper:"del" 
  51. },
  52. colModel : [ {
  53. label : '操作用户ID',
  54. name : 'optuserid',
  55. width : 80,
  56. editable: true,
  57. },{
  58. label : '操作IP',
  59. name : 'optip',
  60. hidden :true,
  61. viewable :true,
  62. }, {
  63. label : '操作时间',
  64. name : 'opttime',
  65. editable: true,
  66. width : 80,
  67. formoptions:{
  68. elmsuffix:"*"
  69. },
  70. editrules:{required:true}
  71. },{
  72. label : '操作类型',
  73. name : 'opttype',
  74. width : 40,
  75. editable: true,
  76. },{
  77. label : '操作模块',
  78. name : 'optmode',
  79. width : 60,
  80. editable: true,
  81. edittype:"text"
  82. },{
  83. label : '操作内容',
  84. name : 'optinfo',
  85. width : 200,
  86. editable: true,
  87. edittype:"text"
  88. }],
  89. rownumbers : true,//添加左侧行号
  90. viewrecords : true,//是否在浏览导航栏显示记录总数
  91. rowNum : 10,//每页显示记录数
  92. rowList : [10,15,20,30,40,50 ],//用于改变显示行数的下拉列表框的元素数组。
  93. autowidth : true,
  94. height : 'auto',
  95. pager : "#pager",
  96. });
  97. jQuery('#tree').navGrid('#pager',
  98. // the buttons to appear on the toolbar of the grid
  99. {
  100. edit : false,
  101. add : false,
  102. del : false,
  103. search : true,
  104. refresh : true,
  105. view : true,
  106. position : "left",
  107. cloneToTop : true
  108. },
  109. // options for the Delete Dailog
  110. {
  111. errorTextFormat : function(data) {
  112. return 'Error: ' + data.responseText
  113. }
  114. },{},{},{
  115. // search options 这里支持多条件查询
  116. multipleSearch: true,
  117. sopt:['eq','ne','cn','nc','lt','le','gt','ge'],
  118. afterSubmit: function(r, data) {
  119. var messageString = r.responseText;
  120. var mesObj = eval('(' + messageString + ')');
  121. return [mesObj.state, mesObj.message];
  122. }
  123. }
  124. );
  125. /* jQuery('#tree').jqGrid('bindKeys'); */
  126. })
  127. </script>
  128. <title>我的桌面</title>
  129. </head>
  130. <body>
  131. <div class="page-container">
  132. <table id="tree"></table>
  133. <div id="pager"></div>
  134. </div>
  135. <footer class="footer mt-20">
  136. <div class="container">
  137. <p></p>
  138. </div>
  139. </footer>
  140. </body>
  141. </html>