You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
251 lines
6.1 KiB
251 lines
6.1 KiB
10 months ago
|
<#include "../../_include/_t.ftl"/>
|
||
|
<!DOCTYPE html>
|
||
|
<html>
|
||
|
<head>
|
||
|
<title></title>
|
||
|
<#include "../../_include/_h.ftl"/>
|
||
|
<#include "../../_include/_l.ftl"/>
|
||
|
<#include "../../_include/_j.ftl"/>
|
||
|
<#include "../../_include/_z.ftl"/>
|
||
|
<#include "../../_include/_e.ftl"/>
|
||
|
<#include "../../_include/bdata/_c.ftl"/>
|
||
|
<style type="text/css">
|
||
|
.aes-yellow{
|
||
|
color:#333333 !important;
|
||
|
background-color:#F4D26F !important;
|
||
|
}
|
||
|
.aes-red{
|
||
|
color:#ffffff !important;
|
||
|
background-color:red !important;
|
||
|
}
|
||
|
.td_class{
|
||
|
border:solid 1px #0060bf;
|
||
|
font-size:18px;
|
||
|
font-weight:bold;
|
||
|
text-align:center;
|
||
|
height:40px;
|
||
|
line-height:40px;
|
||
|
vertical-align:middle;
|
||
|
}
|
||
|
|
||
|
.tr_class{
|
||
|
border:solid 1px #0060bf;
|
||
|
font-size:18px;
|
||
|
text-align:center;
|
||
|
height:40px;
|
||
|
line-height:40px;
|
||
|
vertical-align:middle;
|
||
|
}
|
||
|
._tr_class{
|
||
|
border:solid 1px #0060bf;
|
||
|
font-size:18px;
|
||
|
text-align:center;
|
||
|
height:40px;
|
||
|
line-height:40px;
|
||
|
vertical-align:middle;
|
||
|
}
|
||
|
.clear{
|
||
|
clear: both;
|
||
|
}
|
||
|
</style>
|
||
|
</head>
|
||
|
<body class="layui-layout-body">
|
||
|
<div class="layui-layout layui-layout-admin">
|
||
|
<!-- 内容主体区域 -->
|
||
|
<div class="layui-body" style="top:0;">
|
||
|
<div class="page_content" style="margin-left: 0px;width: 100%;">
|
||
|
<div style="min-height: 80vh;padding:30px 50px;">
|
||
|
<h1 style="text-align:center;margin-bottom:20px;">单位隐患统计</h1>
|
||
|
<div class="page_tools">
|
||
|
<div class="layui-inline" style="width:90px;">
|
||
|
<input class="layui-input" type="text" id="data_1_01_beginDate" value="${.now?string('yyyy')}-01" placeholder="年份" autocomplete="off" style="font-size:16px;padding-top:4px;cursor:pointer;letter-spacing:1px;"/>
|
||
|
</div>
|
||
|
<div class="layui-inline">到</div>
|
||
|
<div class="layui-inline" style="width:90px;">
|
||
|
<input class="layui-input" type="text" id="data_1_01_endDate" value="${.now?string('yyyy-MM')}" placeholder="年份" autocomplete="off" style="font-size:16px;padding-top:4px;cursor:pointer;letter-spacing:1px;"/>
|
||
|
</div>
|
||
|
<button id="data_1_01_div_queryBtn" class="layui-btn layui-btn-normal"><i class="layui-icon"></i>查询</button>
|
||
|
</div>
|
||
|
<div id="data_1_01_div_echars" style="height:500px;width: 90%;margin:10px auto;margin-bottom: 66px;">
|
||
|
</div>
|
||
|
<table width="90%" style="border:solid 1px #0060bf;margin:10px auto;background-color:transparent;border-radius:5px;">
|
||
|
<thead>
|
||
|
<th class="td_class">时间</th>
|
||
|
<th class="td_class">隐患数</th>
|
||
|
<th class="td_class">时间</th>
|
||
|
<th class="td_class">隐患数</th>
|
||
|
<th class="td_class">时间</th>
|
||
|
<th class="td_class">隐患数</th>
|
||
|
</thead>
|
||
|
<tbody id="table_data">
|
||
|
<tr>
|
||
|
<td colspan="6" class="_tr_class">暂无数据</td>
|
||
|
</tr>
|
||
|
</tbody>
|
||
|
</table>
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
|
||
|
|
||
|
<script type="text/javascript">
|
||
|
layuiplus.on_w_1(function(){
|
||
|
layuiplus.init(1);
|
||
|
$.ajax({
|
||
|
type:"get",
|
||
|
url:"${ctx}/bdata/data1/load/1",
|
||
|
data:{
|
||
|
baseId:"${manager_user['baseId']}",
|
||
|
begin:$("#data_1_01_beginDate").val(),
|
||
|
end:$("#data_1_01_endDate").val()
|
||
|
},
|
||
|
dataType:"json",
|
||
|
success:function(data){
|
||
|
//解析data.lis
|
||
|
var tArr = new Array();
|
||
|
var dArr = new Array();
|
||
|
var _strHtml = "<tr>";
|
||
|
for(var i = 0;i < data.lis.length;i++){
|
||
|
if((i+1)%3 == 0){
|
||
|
_strHtml += '<td class="_tr_class">'+data.lis[i].ttym+'</td><td class="_tr_class">'+data.lis[i].cs+'</td></tr></tr>';
|
||
|
}else{
|
||
|
_strHtml += '<td class="_tr_class">'+data.lis[i].ttym+'</td><td class="_tr_class">'+data.lis[i].cs+'</td>';
|
||
|
}
|
||
|
tArr.push(data.lis[i].ttym);
|
||
|
dArr.push(data.lis[i].cs);
|
||
|
}
|
||
|
$("#table_data").html(_strHtml);
|
||
|
bdataEchars("1","data_1_01_div_echars",tArr,dArr);
|
||
|
}
|
||
|
});
|
||
|
//单位消防隐患统计的查询按钮
|
||
|
$("#data_1_01_div_queryBtn").click(function(){
|
||
|
$.ajax({
|
||
|
type:"get",
|
||
|
url:"${ctx}/bdata/data1/load/1",
|
||
|
data:{
|
||
|
baseId:"${manager_user['baseId']}",
|
||
|
begin:$("#data_1_01_beginDate").val(),
|
||
|
end:$("#data_1_01_endDate").val()
|
||
|
},
|
||
|
dataType:"json",
|
||
|
success:function(data){
|
||
|
//解析data.lis
|
||
|
var tArr = new Array();
|
||
|
var dArr = new Array();
|
||
|
var _strHtml = "<tr>";
|
||
|
for(var i = 0;i < data.lis.length;i++){
|
||
|
if((i+1)%3 == 0){
|
||
|
_strHtml += '<td class="_tr_class">'+data.lis[i].ttym+'</td><td class="_tr_class">'+data.lis[i].cs+'</td></tr></tr>';
|
||
|
}else{
|
||
|
_strHtml += '<td class="_tr_class">'+data.lis[i].ttym+'</td><td class="_tr_class">'+data.lis[i].cs+'</td>';
|
||
|
}
|
||
|
tArr.push(data.lis[i].ttym);
|
||
|
dArr.push(data.lis[i].cs);
|
||
|
}
|
||
|
$("#table_data").html(_strHtml);
|
||
|
bdataEchars("1","data_1_01_div_echars",tArr,dArr);
|
||
|
}
|
||
|
});
|
||
|
});
|
||
|
//日期input
|
||
|
ldate.render({
|
||
|
elem:"#data_1_01_beginDate",
|
||
|
type:"month",
|
||
|
max:"#data_1_01_endDate"
|
||
|
});
|
||
|
ldate.render({
|
||
|
elem:"#data_1_01_endDate",
|
||
|
type:"month",
|
||
|
max:"nowTime"
|
||
|
});
|
||
|
});
|
||
|
var bdataEchars = function(t,pdiv){
|
||
|
var option = {
|
||
|
tooltip: {
|
||
|
trigger: 'axis',
|
||
|
axisPointer: {
|
||
|
lineStyle: {
|
||
|
color: '#023c8d'
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
grid: {
|
||
|
left: '1%',
|
||
|
right: '4%',
|
||
|
bottom: '1%',
|
||
|
top: '6%',
|
||
|
containLabel: true
|
||
|
},
|
||
|
xAxis: [{
|
||
|
type: 'category',
|
||
|
boundaryGap: false,
|
||
|
axisLine: {
|
||
|
lineStyle: {
|
||
|
color: '#023c8d'
|
||
|
}
|
||
|
},
|
||
|
axisLabel: {
|
||
|
margin: 10,
|
||
|
textStyle: {
|
||
|
fontSize: 14,
|
||
|
color: '#b5e0ff'
|
||
|
}
|
||
|
},
|
||
|
data: arguments[2]
|
||
|
}],
|
||
|
yAxis: [{
|
||
|
type: 'value',
|
||
|
axisTick: {
|
||
|
show: false
|
||
|
},
|
||
|
axisLine: {
|
||
|
lineStyle: {
|
||
|
color: '#023c8d'
|
||
|
}
|
||
|
},
|
||
|
axisLabel: {
|
||
|
margin: 10,
|
||
|
textStyle: {
|
||
|
fontSize: 14,
|
||
|
color: '#b5e0ff'
|
||
|
}
|
||
|
},
|
||
|
splitLine: {
|
||
|
show: false
|
||
|
}
|
||
|
}],
|
||
|
series: [{
|
||
|
name:'已检查',
|
||
|
type:'line',
|
||
|
stack: '总数',
|
||
|
data:arguments[3],
|
||
|
symbolSize: 5,
|
||
|
areaStyle: {
|
||
|
normal: {
|
||
|
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
|
||
|
offset: 0,
|
||
|
color: 'rgba(61, 205, 249, 0.9)'
|
||
|
}, {
|
||
|
offset: 0.8,
|
||
|
color: 'rgba(61, 205, 249, 0.1)'
|
||
|
}], false),
|
||
|
shadowColor: 'rgba(0, 0, 0, 0.1)',
|
||
|
shadowBlur: 10
|
||
|
}
|
||
|
},
|
||
|
itemStyle: {
|
||
|
normal: {
|
||
|
color: 'rgb(61, 205, 249)',
|
||
|
borderWidth: 1
|
||
|
}
|
||
|
},
|
||
|
}]
|
||
|
};
|
||
|
echarts.init($("#"+pdiv).get(0)).setOption(option);
|
||
|
}
|
||
|
</script>
|
||
|
</body>
|
||
|
</html>
|