Commit 96b95f26 authored by shiyubin's avatar shiyubin

完整版

parent c5b7e788
No preview for this file type
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect
driverClassName=org.postgresql.Driver driverClassName=org.postgresql.Driver
validationQuery=SELECT 1 validationQuery=SELECT 1
jdbc_url=jdbc:postgresql://192.168.100.220:5432/MineSIX_test1 jdbc_url=jdbc:postgresql://192.168.3.220:5432/MineSIX_test1
jdbc_username=postgres jdbc_username=postgres
jdbc_password=red___ jdbc_password=red___
......
...@@ -180,7 +180,7 @@ ...@@ -180,7 +180,7 @@
var layer = '50'; var layer = '50';
var kqid = 1; var kqid = 1;
$.getJSON('http://192.168.1.11:8080/MineJSON/vzigbee.action?type=8&param=' $.getJSON('http://localhost:8080/MineJSON/vzigbee.action?type=8&param='
+ rowData.personcode+ '-' + rowData.personcode+ '-'
+ (Date.parse(new Date(starttime)) / 1000)+ '-' + (Date.parse(new Date(starttime)) / 1000)+ '-'
+ (Date.parse(new Date(endtime)) / 1000) + (Date.parse(new Date(endtime)) / 1000)
......
...@@ -84,7 +84,11 @@ ...@@ -84,7 +84,11 @@
} }
function exportd() { function exportd() {
Export('历史记录', $('#datagrid')) Export('历史记录', $('#datagrid'))
}
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
} }
</script> </script>
</head> </head>
......
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/co2jiance.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/co2jiance.jsp"
</script> </script>
...@@ -90,6 +90,12 @@ ...@@ -90,6 +90,12 @@
Export('一氧化碳历史记录', $('#datagrid')) Export('一氧化碳历史记录', $('#datagrid'))
} }
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
}
</script> </script>
</head> </head>
<body class="easyui-layout" data-options="fit:true"> <body class="easyui-layout" data-options="fit:true">
......
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/cojiance.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/cojiance.jsp"
</script> </script>
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/fengsu.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/fengsu.jsp"
//window.location.href="http://localhost:8080/MineTRS/tubiao/fengsu.jsp" //window.location.href="http://localhost:8080/MineTRS/tubiao/fengsu.jsp"
</script> </script>
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/fengya.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/fengya.jsp"
//window.location.href="http://localhost:8080/MineTRS/tubiao/fengya.jsp" //window.location.href="http://localhost:8080/MineTRS/tubiao/fengya.jsp"
</script> </script>
...@@ -84,7 +84,11 @@ ...@@ -84,7 +84,11 @@
} }
function exportd() { function exportd() {
Export('风速历史记录', $('#datagrid')) Export('风速历史记录', $('#datagrid'))
}
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
} }
</script> </script>
</head> </head>
......
...@@ -93,6 +93,11 @@ ...@@ -93,6 +93,11 @@
Export('设备开停历史记录', $('#datagrid')) Export('设备开停历史记录', $('#datagrid'))
} }
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
}
</script> </script>
</head> </head>
<body class="easyui-layout" data-options="fit:true"> <body class="easyui-layout" data-options="fit:true">
......
...@@ -86,6 +86,11 @@ ...@@ -86,6 +86,11 @@
Export('氧气历史记录', $('#datagrid')) Export('氧气历史记录', $('#datagrid'))
} }
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
}
</script> </script>
</head> </head>
<body class="easyui-layout" data-options="fit:true"> <body class="easyui-layout" data-options="fit:true">
......
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/o2jiance.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/o2jiance.jsp"
</script> </script>
...@@ -216,16 +216,24 @@ ...@@ -216,16 +216,24 @@
parent.dj.messagerAlert('提示', '请勾选要删除的记录!', 'error'); parent.dj.messagerAlert('提示', '请勾选要删除的记录!', 'error');
} }
} }
function _search() { function _search() {
datagrid.datagrid('load', dj.serializeObject($('#searchForm'))); datagrid.datagrid('load', dj.serializeObject($('#searchForm')));
} }
function cleanSearch() { function cleanSearch() {
datagrid.datagrid('load', {}); datagrid.datagrid('load', {});
$('#searchForm input').val(''); $('#searchForm input').val('');
} }
function exportd() { function exportd() {
Export('人员定位历史记录', $('#datagrid')) Export('人员定位历史记录', $('#datagrid'))
}
setInterval('Reflash()', 5000)
function Reflash() {
$("#datagrid").datagrid("reload")
} }
</script> </script>
</head> </head>
......
...@@ -84,7 +84,11 @@ ...@@ -84,7 +84,11 @@
} }
function exportd() { function exportd() {
Export('湿度历史记录', $('#datagrid')) Export('湿度历史记录', $('#datagrid'))
}
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
} }
</script> </script>
</head> </head>
......
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/shidu.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/shidu.jsp"
//window.location.href="http://localhost:8080/MineTRS/tubiao/fengya.jsp" //window.location.href="http://localhost:8080/MineTRS/tubiao/fengya.jsp"
</script> </script>
...@@ -84,7 +84,11 @@ ...@@ -84,7 +84,11 @@
} }
function exportd() { function exportd() {
Export('温度历史记录', $('#datagrid')) Export('温度历史记录', $('#datagrid'))
}
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
} }
</script> </script>
</head> </head>
......
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
window.location.href="http://192.168.1.11:8081/MineEM/tubiao/wendu.jsp" window.location.href="http://localhost:8081/MineEM/tubiao/wendu.jsp"
//window.location.href="http://localhost:8080/MineTRS/tubiao/fengya.jsp" //window.location.href="http://localhost:8080/MineTRS/tubiao/fengya.jsp"
</script> </script>
...@@ -86,6 +86,11 @@ ...@@ -86,6 +86,11 @@
Export('压力历史记录', $('#datagrid')) Export('压力历史记录', $('#datagrid'))
} }
setInterval('Reflash()', 10000)
function Reflash() {
$("#datagrid").datagrid("reload")
}
</script> </script>
</head> </head>
<body class="easyui-layout" data-options="fit:true"> <body class="easyui-layout" data-options="fit:true">
......
...@@ -2,12 +2,12 @@ ...@@ -2,12 +2,12 @@
<html> <html>
<title>环境监测大屏</title> <title>环境监测大屏</title>
<head> <head>
<%--<script>window.location.href='http://192.168.1.11:8080/MineTT/jinda/index.html';</script>--%> <%--<script>window.location.href='http://localhost:8080/MineTT/jinda/index.html';</script>--%>
<script type="text/javascript" src="${pageContext.request.contextPath}/jslib/jquery-1.8.2.min.js" charset="utf-8"></script> <script type="text/javascript" src="${pageContext.request.contextPath}/jslib/jquery-1.8.2.min.js" charset="utf-8"></script>
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
$(function() { $(function() {
window.open("http://192.168.1.11:8080/MineTT/jinda/disscreen.jsp",'top'); window.open("http://localhost:8080/MineTT/jinda/disscreen.jsp",'top');
}) })
</script> </script>
......
...@@ -2,12 +2,12 @@ ...@@ -2,12 +2,12 @@
<html> <html>
<title>三维动画</title> <title>三维动画</title>
<head> <head>
<%--<script>window.location.href='http://192.168.1.11:8080/MineTT/jinda/index.html';</script>--%> <%--<script>window.location.href='http://localhost:8080/MineTT/jinda/index.html';</script>--%>
<script type="text/javascript" src="${pageContext.request.contextPath}/jslib/jquery-1.8.2.min.js" charset="utf-8"></script> <script type="text/javascript" src="${pageContext.request.contextPath}/jslib/jquery-1.8.2.min.js" charset="utf-8"></script>
<script type="text/javascript" charset="utf-8"> <script type="text/javascript" charset="utf-8">
$(function() { $(function() {
window.open("http://192.168.1.11:8080/MineTT/jinda/index.html",'top'); window.open("http://localhost:8080/MineTT/jinda/index.html",'top');
}) })
</script> </script>
......
<xml> <xml>
<InterLink ip="192.168.1.11:8080"> <InterLink ip="localhost:8080">
</InterLink> </InterLink>
<MachineList> <MachineList>
<machine id="572283213433474205D4FF37" zkname="定位" name="人员定位基站0-1" position="1.22,123.27,13.63" rotation="90,180,0" scale="10,10,10" type="Zigbee" layer="0"/> <machine id="572283213433474205D4FF37" zkname="定位" name="人员定位基站0-1" position="1.22,123.27,13.63" rotation="90,180,0" scale="10,10,10" type="Zigbee" layer="0"/>
......
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
}], }],
pane: 0, pane: 0,
title: { title: {
text: '<span style="font-size:8px">' + name + ":" + value1.toFixed(2)+'</span><br/>℃', text: '<span style="font-size:8px">' + name + ":" + value1.toFixed(2)+'</span><br/>',
y: -40 y: -40
} }
}], }],
...@@ -159,6 +159,7 @@ ...@@ -159,6 +159,7 @@
measureMax = 15; measureMax = 15;
} }
$("#"+deviceType).empty() $("#"+deviceType).empty()
const arrAll = JSON.parse(data); const arrAll = JSON.parse(data);
$.each(arrAll, function(key, val) { $.each(arrAll, function(key, val) {
if (sensorname === key) { if (sensorname === key) {
...@@ -181,6 +182,7 @@ ...@@ -181,6 +182,7 @@
"<p style='font-size: 15px; margin-left: 10px; margin-top: -10px'>时间: " + val.jctime +"</p></br>" + "<p style='font-size: 15px; margin-left: 10px; margin-top: -10px'>时间: " + val.jctime +"</p></br>" +
"<p style='font-size: 15px; margin-left: 10px; margin-top: -10px';color: " + color + "'>报警: " + ifbj + "</p></br>" + "<p style='font-size: 15px; margin-left: 10px; margin-top: -10px';color: " + color + "'>报警: " + ifbj + "</p></br>" +
"</div>") "</div>")
setInterval("ReflashChart(" + deviceType+index + ")", 10000)
initpolygon1(deviceType+index, sensorname, val.value2, sensorname, measureMin, measureMax) initpolygon1(deviceType+index, sensorname, val.value2, sensorname, measureMin, measureMax)
}) })
...@@ -188,6 +190,11 @@ ...@@ -188,6 +190,11 @@
}) })
} }
function ReflashChart(name) {
console.log(">>>>>>>>>>>>>>>>>" + name)
$("#" + name).datagrid("reload")
}
</script> </script>
</head> </head>
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect hibernate.dialect=org.hibernate.dialect.PostgreSQLDialect
driverClassName=org.postgresql.Driver driverClassName=org.postgresql.Driver
validationQuery=SELECT 1 validationQuery=SELECT 1
jdbc_url=jdbc:postgresql://192.168.100.220:5432/MineSIX_test1 jdbc_url=jdbc:postgresql://192.168.3.220:5432/MineSIX_test1
jdbc_username=postgres jdbc_username=postgres
jdbc_password=red___ jdbc_password=red___
......
File added
...@@ -131,7 +131,7 @@ public class CohistoryServiceImpl extends BaseServiceImpl implements CohistorySe ...@@ -131,7 +131,7 @@ public class CohistoryServiceImpl extends BaseServiceImpl implements CohistorySe
@Override @Override
public List realTimeCo() { public List realTimeCo() {
String hql = "select a.id, a.zkname, a.sensorname, a.ifbj, a.jctime, a.value2, b.zduan from" + String hql = "select a.id, a.zkname, a.sensorname, a.ifbj, a.jctime, a.value2, b.zduan from" +
" (select id, zkname, sensorname, ifbj , jctime, value2, rank() over (partition by zkname order by jctime )"+ " (select id, zkname, sensorname, ifbj , jctime, value2, rank() over (partition by zkname order by jctime desc)"+
" from tab_yiyanghuatan where jctime > (now() - interval '1 hour')) a" + " from tab_yiyanghuatan where jctime > (now() - interval '1 hour')) a" +
" inner join tab_station b on a.sensorname = b.station where a.rank = 1"; " inner join tab_station b on a.sensorname = b.station where a.rank = 1";
List list =getCurrentSession().createSQLQuery(hql).setResultTransformer(Transformers.aliasToBean(EnvRealModel.class)).list(); List list =getCurrentSession().createSQLQuery(hql).setResultTransformer(Transformers.aliasToBean(EnvRealModel.class)).list();
......
...@@ -13,7 +13,7 @@ public class DButil { ...@@ -13,7 +13,7 @@ public class DButil {
Connection conn = null; Connection conn = null;
try { try {
Class.forName("org.postgresql.Driver"); Class.forName("org.postgresql.Driver");
String url = "jdbc:postgresql://192.168.100.220:5432/MineSIX_test1"; String url = "jdbc:postgresql://192.168.3.220:5432/MineSIX_test1";
String username = "postgres"; String username = "postgres";
String password = "red___"; String password = "red___";
conn =DriverManager.getConnection(url,username,password); conn =DriverManager.getConnection(url,username,password);
......
...@@ -6,7 +6,7 @@ import javax.xml.bind.annotation.XmlRootElement; ...@@ -6,7 +6,7 @@ import javax.xml.bind.annotation.XmlRootElement;
public class Props { public class Props {
public int runtime = 0; public int runtime = 0;
public String ip = "192.168.1.221";//服务器端监听地址 public String ip = "localhost";//服务器端监听地址
public int port = 4321;//服务器监听端口 public int port = 4321;//服务器监听端口
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment