duration.html 3.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. {extend name="common/common2" /}
  2. {block name="main"}
  3. <div class="row">
  4. <div class="col-sm-12">
  5. <div class="ibox float-e-margins">
  6. <div class="ibox-title">
  7. <h5>{$meta_title}</h5>
  8. </div>
  9. <div class="ibox-content">
  10. <div class="alert alert-info">
  11. <form action="{:url('duration')}" method="GET" id='search_form' class="form-inline">
  12. <div class="input-group" style="width: 200px">
  13. <span class="input-group-addon">月份</span>
  14. <input class="form-control dialog-datetime1" id="dialog-datetime1" name="month" type="text" data-date-format="yyyy-mm" value="{$month}" placeholder="" readonly/>
  15. </div>
  16. <div class="input-group">
  17. <span class="input-group-btn">
  18. <button class="btn btn-primary btn-sm" type="submit"><i class="glyphicon glyphicon-search">搜索</i></button>
  19. </span>
  20. <span class="input-group-btn">
  21. <button class="btn btn-default btn-sm" type="reset" onclick="empty_search()"><i class="glyphicon glyphicon-remove">重置</i></button>
  22. </span>
  23. </div>
  24. </form>
  25. </div>
  26. <div class="panel-group">
  27. <div class="panel panel-default">
  28. <div class="panel-heading clearfix">
  29. <div class="btn-group pull-left">
  30. 工单完成时长统计
  31. </div>
  32. <div style="display: none" class="btn-group pull-right">
  33. <a href="javascript:;" onclick="printer()" class="btn btn-sm btn btn-primary"><i class="glyphicon glyphicon-print"></i>打印</a>
  34. </div>
  35. </div>
  36. <div class="panel-body" id="printer">
  37. <table class="table table-bordered">
  38. <thead>
  39. <tr>
  40. <th>工单类型</th>
  41. <th>完成工单时长</th>
  42. <th>完成工单量</th>
  43. <th>平均时长</th>
  44. </tr>
  45. </thead>
  46. <tbody>
  47. {foreach $data as $k=>$v}
  48. <tr>
  49. <td>{$v.title}</td>
  50. <td>{$v.duration}min</td>
  51. <td>{$v.count}</td>
  52. <td>{$v.avgDuration}min</td>
  53. </tr>
  54. {/foreach}
  55. </tbody>
  56. </table>
  57. </div>
  58. </div>
  59. </div>
  60. </div>
  61. </div>
  62. </div>
  63. </div>
  64. {/block}
  65. {block name="script"}
  66. <script src="/static/echarts.js"></script>
  67. <script src="/static/browser.js"></script>
  68. <script src="/static/layDate-v5.0.9/laydate.js"></script>
  69. <script type="text/javascript">
  70. function empty_search(){
  71. window.location.href = 'duration';
  72. }
  73. $(function () {
  74. laydate.render({
  75. elem: '#dialog-datetime1'
  76. ,type: 'month'
  77. });
  78. })
  79. </script>
  80. {/block}