test_report.html 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <meta charset="UTF-8">
  5. <title>检测报告查询</title>
  6. </head>
  7. <body>
  8. <div class="layui-card layadmin-header">
  9. <div class="layui-breadcrumb" lay-filter="breadcrumb">
  10. <a lay-href="">主页</a>
  11. <a><cite>车辆检测管理</cite></a>
  12. <a><cite>检测报告查询</cite></a>
  13. </div>
  14. </div>
  15. <div class="layui-fluid">
  16. <div class="layui-row layui-col-space15">
  17. <div class="layui-col-md12">
  18. <div class="layui-card">
  19. <!--<div class="layui-card-header">开启头部工具栏</div>-->
  20. <div class="layui-card-body">
  21. <div class="test-table-reload-btn" style="margin-bottom: 10px;">
  22. 搜索车牌:
  23. <div class="layui-inline">
  24. <input class="layui-input" name="车牌号" id="test-table-demoReload" style="text-transform:uppercase;">
  25. <!--autocomplete="off"-->
  26. </div>
  27. 检测日期:
  28. <div class="layui-input-inline">
  29. <input type="text" class="layui-input" id="test-laydate-range-date" placeholder=" - ">
  30. </div>
  31. <button class="layui-btn" data-type="reload">搜索</button>
  32. </div>
  33. <table class="layui-hide" id="test-table-toolbar" lay-filter="test-table-toolbar"></table>
  34. <!--<script type="text/html" id="test-table-toolbar-toolbarDemo">-->
  35. <!--<div class="layui-btn-container">-->
  36. <!--<button class="layui-btn layui-btn-sm" lay-event="getCheckData">获取选中行数据</button>-->
  37. <!--<button class="layui-btn layui-btn-sm" lay-event="getCheckLength">获取选中数目</button>-->
  38. <!--<button class="layui-btn layui-btn-sm" lay-event="isAll">验证是否全选</button>-->
  39. <!--</div>-->
  40. <!--</script>-->
  41. <!--<script type="text/html" id="test-table-toolbar-barDemo">-->
  42. <!--<a class="layui-btn layui-btn-xs" lay-event="edit">编辑</a>-->
  43. <!--<a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="del">删除</a>-->
  44. <!--</script>-->
  45. </div>
  46. </div>
  47. </div>
  48. </div>
  49. </div>
  50. </body>
  51. <script>
  52. layui.use(['admin', 'table','laydate'], function(){
  53. var admin = layui.admin
  54. ,$ = layui.$
  55. ,laydate = layui.laydate
  56. ,table = layui.table;
  57. table.render({
  58. elem: '#test-table-toolbar'
  59. ,url:'/detection/testReportSelect'
  60. ,method:'post'
  61. ,toolbar: '#test-table-toolbar-toolbarDemo'
  62. ,title: '用户数据表'
  63. ,cols: [[
  64. {type: 'checkbox', fixed: 'left'}
  65. // ,{field:'id', title:'ID', width:80, fixed: 'left', unresize: true, sort: true}
  66. ,{field:'检测顺序号', title:'检测顺序号', width:120, edit: 'text'}
  67. ,{field:'车牌号', title:'车牌', width:120, edit: 'text'}
  68. ,{field:'车牌颜色', title:'车牌颜色', width:120, edit: 'text'}
  69. ,{field:'车主姓名', title:'车主姓名', width:120, edit: 'text'}
  70. ,{field:'基准质量', title:'用户名', width:120, edit: 'text'}
  71. ,{field:'最大总质量', title:'使用性质', width:120, edit: 'text'}
  72. ,{field:'测试工况环境温度每秒数据', title:'环境温度', width:120, edit: 'text'}
  73. ,{field:'测试工况环境大气压力每秒数据', title:'大气压力', width:120, edit: 'text'}
  74. ,{field:'测试工况环境相对湿度每秒数据', title:'相对湿度', width:120, edit: 'text'}
  75. ,{field:'测试工况HC测试结果', title:'HC', width:120, edit: 'text'}
  76. ,{field:'测试工况CO测试结果', title:'CO', width:120, edit: 'text'}
  77. ,{field:'测试工况NO测试结果', title:'NO', width:120, edit: 'text'}
  78. ,{field:'测试工况CO2测试结果', title:'CO2', width:120, edit: 'text'}
  79. ,{field:'排放检合格不合格测判定结果', title:'判定结果', width:120, edit: 'text'}
  80. ,{field:'检测日期', title:'检测日期', width:120, edit: 'text'}
  81. ,{field:'工况检测的起止时间', title:'检测起止时间', width:120, edit: 'text'}
  82. ,{field:'车架号', title:'车架号', width:120, edit: 'text'}
  83. ,{field:'总犯规次数', title:'犯规次数', width:120, edit: 'text'}
  84. ,{field:'内部唯一性检测序列号', title:'检测序列号', width:120, edit: 'text'}
  85. ,{field:'登录员', title:'登录员', width:120, edit: 'text'}
  86. ,{field:'检测分类', title:'检测分类', width:120, edit: 'text'}
  87. ,{field:'CO限值', title:'CO限值', width:120, edit: 'text'}
  88. ,{field:'报告单编号', title:'报告单编号', width:120, edit: 'text'}
  89. // ,{fixed: 'right', title:'操作', toolbar: '#test-table-toolbar-barDemo', width:150}
  90. ]]
  91. ,page: true
  92. });
  93. var active = {
  94. reload: function(){
  95. var demoReload = $('#test-table-demoReload');
  96. var date = $('#test-laydate-range-date');
  97. //执行重载
  98. table.reload('test-table-toolbar', {
  99. where: {
  100. '车牌号': demoReload.val(),
  101. 'date': date.val()
  102. }
  103. });
  104. }
  105. };
  106. $('.test-table-reload-btn .layui-btn').on('click', function(){
  107. var type = $(this).data('type');
  108. active[type] ? active[type].call(this) : '';
  109. });
  110. laydate.render({
  111. elem: '#test-laydate-range-date'
  112. // ,range: true
  113. ,range: '~'
  114. });
  115. // //头工具栏事件
  116. // table.on('toolbar(test-table-toolbar)', function(obj){
  117. // var checkStatus = table.checkStatus(obj.config.id);
  118. // switch(obj.event){
  119. // case 'getCheckData':
  120. // var data = checkStatus.data;
  121. // layer.alert(JSON.stringify(data));
  122. // break;
  123. // case 'getCheckLength':
  124. // var data = checkStatus.data;
  125. // layer.msg('选中了:'+ data.length + ' 个');
  126. // break;
  127. // case 'isAll':
  128. // layer.msg(checkStatus.isAll ? '全选': '未全选');
  129. // break;
  130. // };
  131. // });
  132. // //监听行工具事件
  133. // table.on('tool(test-table-toolbar)', function(obj){
  134. // var data = obj.data;
  135. // if(obj.event === 'del'){
  136. // layer.confirm('真的删除行么', function(index){
  137. // obj.del();
  138. // layer.close(index);
  139. // });
  140. // } else if(obj.event === 'edit'){
  141. // layer.prompt({
  142. // formType: 2
  143. // ,value: data.email
  144. // }, function(value, index){
  145. // obj.update({
  146. // email: value
  147. // });
  148. // layer.close(index);
  149. // });
  150. // }
  151. // });
  152. });
  153. </script>
  154. </html>