exportstatistic.html 2.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8" />
  5. <title>main_entiity</title>
  6. <script>
  7. $(document).ready(function() {
  8. $('#post').click(function() {
  9. debugger;
  10. var url = "http://dev.xplatform.tech:20020/x_okr_assemble_control/servlet/export/statisticreportcontent/stream";
  11. var form = $("<form>"); //定义一个form表单
  12. var ipt_centerId = $("<input type='text' name='centerId' value='"+ $("#centerId").val() +"'/>"); //定义一个form表单
  13. var ipt_reportCycle = $("<input type='text' name='reportCycle' value='"+ $("#reportCycle").val() +"'/>"); //定义一个form表单
  14. var ipt_statisticTime = $("<input type='text' name='statisticTime' value='2016-12-23'/>"); //定义一个form表单
  15. form.attr('style', 'display:none'); //在form表单中添加查询参数
  16. form.attr('method', 'post');
  17. form.attr('action', url );
  18. form.append( ipt_centerId ); //将表单放置在web中
  19. form.append( ipt_reportCycle ); //将表单放置在web中
  20. form.append( ipt_statisticTime ); //将表单放置在web中
  21. $('body').append(form); //将表单放置在web中
  22. form.submit();
  23. });
  24. });
  25. </script>
  26. </head>
  27. <body>
  28. <div style="float: left; width: 720px;">
  29. <div style="width: 100%;">
  30. <table border="1" style="width:100%">
  31. <tr>
  32. <td>centerId:</td>
  33. <td><input type="text" id="centerId" style="width:95%"/></td>
  34. </tr>
  35. <tr>
  36. <td>reportCycle:</td>
  37. <td><input type="text" id="reportCycle" style="width:95%"/></td>
  38. </tr>
  39. <tr>
  40. <td>statisticTime:</td>
  41. <td><input type="text" id="statisticTime" style="width:95%"/></td>
  42. </tr>
  43. <tr>
  44. <td colspan="2">
  45. <button id="post">POST</button>
  46. </td>
  47. </tr>
  48. <tr>
  49. <td colspan="2">
  50. <textarea id="content" style="width:97%;height:300px">{}</textarea>
  51. </td>
  52. </tr>
  53. <tr>
  54. <td colspan="2">
  55. <textarea id="result" style="width:97%;height:400px"></textarea>
  56. </td>
  57. </tr>
  58. </table>
  59. </div>
  60. </div>
  61. </body>
  62. </html>