<%--
|
Created by IntelliJ IDEA.
|
User: Dell
|
Date: 2023/11/13
|
Time: 15:15
|
To change this template use File | Settings | File Templates.
|
--%>
|
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
|
|
<html>
|
<head>
|
<title></title>
|
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
<link rel="stylesheet" href="../Home/HomeCss/Home.css"/>
|
<link rel="stylesheet" href="../CSS/layui1.css"/>
|
<link rel="stylesheet" href="../Home/HomeCss/Time.css/">
|
<link rel="stylesheet" href="Search/css/style.css"/>
|
<link rel="stylesheet" href="Search/css/style-search.css"/>
|
<style>
|
/*.layui-table-click {*/
|
/* background-color: #10DB3E !important;*/
|
/* color: black; !*设置文字颜色为白色*!*/
|
/*}*/
|
.BMap_noprint{
|
z-index: 9999;
|
}
|
. BMap_noprint anchorTR{
|
z-index: 1000;
|
}
|
.anchorTR{
|
z-index: 1000;
|
}
|
.BMapGL_naviControl {
|
z-index: 1000; /* 设置控件的层级为1000 */
|
}
|
element.style {
|
width: 0px;
|
height: 0px;
|
}
|
.layui-laypage-skip{
|
display: none;
|
}
|
.layui-table-header{
|
background: linear-gradient(to right,#0059D9,transparent 120%)!important;
|
border: none !important;
|
}
|
/*layui表格样式*/
|
.layui-table-cell{
|
background-color: rgba(5, 73, 146,0) !important;
|
border: none !important;
|
}
|
|
.table-container {
|
background-color: rgba(255, 255, 255, 0) !important;
|
}
|
.layui-table td{
|
background-color: rgba(5, 73, 146,0) !important;
|
color: white;
|
}
|
.layui-laypage{
|
position: relative;
|
}
|
|
.layui-table th{
|
color: white;
|
border: none !important;
|
|
}
|
tr{
|
border: none;
|
}
|
.layui-table tr:first-child{
|
background-color: rgba(28, 52, 89, 0) !important;
|
border: none !important;
|
}
|
.layui-table tr:hover td{
|
color: #57E1E0;
|
}
|
.layui-laypage {
|
background-color: rgba(5, 73, 146, 0) !important;
|
width: 1000px;
|
}
|
.layui-laypage a {
|
background-color: rgba(5, 73, 146, 0) !important; /* 设置分页按钮背景颜色 */
|
color: white; /* 设置分页按钮文字颜色 */
|
}
|
/* 分页当前页样式 */
|
.layui-laypage .layui-laypage-curr a {
|
background-color: rgba(5, 73, 146, 0) !important; /* 设置分页按钮选中的背景颜色 */
|
}
|
/* 表格边框样式 */
|
#container {
|
height: 100%;
|
}
|
. layui-unselect{
|
background-color: rgba(5, 73, 146, 0) !important;
|
}
|
.table-container {
|
background-color: rgba(255, 255, 255, 0) !important; /* 设置容器元素的背景色为半透明,可以根据需要调整透明度 */
|
}
|
.layui-table {
|
background-color: rgba(255, 255, 255, 0) !important; /* 设置表格的背景色为透明,加上 !important 是为了覆盖 layui 默认样式 */
|
border: none !important;
|
}
|
.layui-table-box{
|
border: none !important;
|
}
|
.layui-unselect{
|
background-color:#1C3459 ;
|
height: 30px;
|
color: white;
|
}
|
.layui-select-title{
|
background-color:#1C3459 ;
|
height: 30px;
|
color: white;
|
}
|
.layui-anim:hover{
|
color: black;
|
}
|
dd{
|
background-color:#1C3459 ;
|
}
|
|
dd:hover{
|
background-color:#1C3459 ;
|
}
|
.layui-select-title:hover {
|
background-color:#1C3459 ; /* 设置悬浮时的背景颜色为蓝色 */
|
}
|
#titles{
|
background: url("/hxzkuwb/Home/HomeImg/title.png")no-repeat;
|
background-position: center;
|
}
|
.loading {
|
width: 200px;
|
height: 200px;
|
box-sizing: border-box;
|
border-radius: 50%;
|
border-top: 10px solid #63a69f;
|
/* 相对定位 */
|
position: relative;
|
/* 执行动画(动画a1 时长 线性的 无限次播放) */
|
animation: a1 2s linear infinite;
|
}
|
|
.loading::before,
|
.loading::after {
|
content: "";
|
}
|
|
.loading::before {
|
border-top: 10px solid #f2e1ac;
|
/* 旋转120度 */
|
transform: rotate(120deg);
|
}
|
|
.loading::after {
|
border-top: 10px solid #f2836b;
|
/* 旋转240度 */
|
transform: rotate(240deg);
|
}
|
</style>
|
</head>
|
<body>
|
<div class="layui-container" style="width: 100%;margin: 0px;padding: 0px;display: none">
|
<div class="layui-row" style="z-index: 9999999">
|
<div class="layui-col-xs12 layui-col-md12">
|
<ul class="list">
|
|
</ul>
|
|
</div>
|
</div>
|
<%-- 头部标题--%>
|
<div class="layui-row" style="width: 100%;position: fixed;z-index: 9;">
|
<div class="layui-col-xs12 layui-col-md12" style="width: 100%;height: 100px">
|
<h1 style="text-align: center;height: 70px;line-height: 65px;color: white;font-size: 25px;width: 100%;position: relative;top: -8px" id="titles"></h1>
|
</div>
|
</div>
|
<div class="layui-row" id="wealcome" style="position: fixed;top: 30px;right: 15px;z-index: 999999999">
|
<div class="layui-col-xs12 layui-col-md12" style="width: 100%">
|
<ul class="htxx" style="width: 100%;">
|
<li style="display: inline-block"><img src="HomeImg/date.png" style="position: relative;top: 0px"/></li>
|
<li id="current-time" style="display: inline-block;font-size: 12px;margin-left: 10px;">日期:2024-00-00 00:00:00</li>
|
<li style="font-size: 12px">欢迎:</li>
|
<li id="yhm" style="font-size: 12px;margin-left: 15px"></li>
|
<li style="margin-left: 15px;"><a id="Ht" href="javascript:;" onclick="joinHouTai()" style="font-size: 12px;position: relative;top: -2px">后台</a></li>
|
<li style="margin-left: 15px;"><a href="javascript:;" onclick="out()" title="点击退出登录系统"><img src="HomeImg/logout.png" style="width: 20px;position: relative;top: -3px"> </a> </li>
|
</ul>
|
</div>
|
</div>
|
<%-- 告警信息 跑马灯--%>
|
<div class="layui-row" id="warningTong" style="width: 19.5%;height:39%;margin-left: 12px;z-index: 999;position: fixed;margin-top:117px;display: none">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="width: 100%;">
|
<span id="warningTongtitle" style="display: inline-block;width: 100%;height: 10%;line-height: 35px;text-align: center;color: white;font-size: 16px">告警统计</span>
|
<span id="warningBorder" style="width: 100%;height: 1px;display: inline-block"></span>
|
</div>
|
<div id="warningTongbody" style="width: 100%;height: 90%">
|
<marquee direction="up" scrollamount="2" id="myMarquee" class="gjxx" style="height: 300px;width: 18%;z-index: 99999999;display: none">
|
</marquee>
|
<div id="gjimg" style="height: 100%;text-align: center;width: 100%">
|
<img src="../Icon/雷达.gif" width="200" style="margin-top: 10%"/>
|
</div>
|
</div>
|
</div>
|
</div>
|
<%-- 通讯--%>
|
<div id="txin" class="layui-row" style="display: none;width: 19.5%;height: 39%;margin-left: 12px;;margin-top: 3.5%;position: fixed;z-index: 999;">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="width: 100%;">
|
<span id="TongXuntitle" style="display: inline-block;width: 100%;height: 10%;line-height: 35px;text-align: center;color: white;font-size: 16px">即时通讯</span>
|
<span id="warningBorder" style="width: 100%;height: 1px;display: inline-block"></span>
|
</div>
|
<div id="TongXunbody" style="width: 100%;height: 90%;padding-top: 10px;text-align: center;overflow:hidden;">
|
<p style=""><img src="HomeImg/bs2.png" width="360" style="height: 15%"/><br><input type="text" id="username" style="position: relative;height: 40px;top: -46px;left: 0px;width: 300px;background-color: transparent;;left: -20px;border: none" placeholder="请输入设备ID" /></p>
|
<p style=""><img src="HomeImg/bs3.png" width="360" style="height: 30%;margin-top: 0px"/><input type="text" id="context" style="height: 60px;position: relative;top: -80px;left: 0px;width: 300px;background-color: transparent;left: -20px;border: none;color: red" placeholder="请输入内容" /></p>
|
<p style="width: 90%;text-align: left;margin-left: 5%;height: 10%;position: relative;top: -30px"><img src="HomeImg/bs6.png"/><span id="gouxuan" style=""> 勾选发给所有人</span></p>
|
<p style="width: 90%;position: relative;top: -20px"><a href="javascript:;" onclick="send()" ><img src="HomeImg/bs4.png" width="100"/></a> <a href="javascript:;"><img src="HomeImg/bs5.png" width="100"/></a></p>
|
</div>
|
</div>
|
</div>
|
<%-- 统计--%>
|
<div class="layui-row" id="tong1" style="display:none;width: 19.5%;height: 39%">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="width: 100%;">
|
<span id="JinRiTongJititle" style="display: inline-block;width: 100%;height: 10%;line-height: 35px;text-align: center;color: white;font-size: 16px">今日统计</span>
|
<span id="warningBorder" style="width: 100%;height: 1px;display: inline-block"></span>
|
|
</div>
|
<div id="JinRiTongJibody" style="width: 100%;height: 90%;text-align: center;overflow:hidden;">
|
<div class="weichuli" ><img src="HomeImg/WeiChuLi.png" style="width: 120px;position: relative;top: 90px;left: 50px"></div>
|
<div class="wcl" style="text-shadow: 0px 0px 3px #00FFFF,0px 0px 3px #00FFFF,0px 0px 3px #00FFFF;position: relative;left: 70px;top: 50px">未处理:0</div>
|
<div id="tong" style="width: 350px;height: 280px;position: relative;top: 40px;"></div>
|
</div>
|
</div>
|
</div>
|
<%-- 人员统计--%>
|
<div class="layui-row" id="personTong" style="width: 19.5%;height: 39%;z-index: 999999;display: none">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="width: 100%;">
|
<span id="personTongtitle" style="display: inline-block;width: 100%;height: 10%;line-height: 35px;padding-left: 78px;color: white;font-size: 16px">人员统计</span>
|
</div>
|
<div style="width: 100%;height: 90%;" id="personTongbody">
|
<table>
|
<tr>
|
<td>姓名</td>
|
<td>部门</td>
|
<td>区域</td>
|
<td>进入时间</td>
|
</tr>
|
</table>
|
</div>
|
</div>
|
</div>
|
<%-- 区域统计--%>
|
<a href="javascript:;" id="PowerShuaXin" onclick="ChongDianPowerShuaXin()" style="width: 60px;height: 40px;text-align: center;font-size: 12px;line-height: 40px;background-color: #00bff4;display: inline-block;position:fixed;right: 7%;bottom: 40%;z-index: 99999999999999;color: white;display: none">刷新</a>
|
<a href="javascript:;" onclick="ChongDianPower()" style="width: 60px;height: 40px;text-align: center;font-size: 12px;line-height: 40px;background-color: #00bff4;display: inline-block;position:fixed;right: 2%;bottom: 40%;z-index: 99999999999999;color: white">充电人员</a>
|
<a style="width: 20%;height: 8%;text-align: center;font-size: 12px;display: inline-block;position:fixed;right: 2%;bottom: 30%;z-index: 99999999999999;color: white"><img src="/hxzkuwb/Home/HomeImg/border1.png"></a>
|
|
<div class="layui-row" id="tong2" style="width: 19.5%;height: 39%;z-index: 999999;display: none;">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="width: 100%;">
|
<span id="QuYutitle" style="display: inline-block;width: 100%;height: 10%;line-height: 35px;text-align: center;color: white;font-size: 16px">区域统计</span><span style="position: absolute;top: 10px;left: 310px"><a href="javascript:;" title="上一页" onclick="nextpageQuYu('上一页')"><img src="HomeImg/jt1.png" style="width: 20px"/></a> <a href="javascript:;" title="下一页" onclick="nextpageQuYu('下一页')"><img src="HomeImg/jt2.png" style="width: 20px"/></a></span>
|
<span id="warningBorder" style="width: 100%;height: 1px;display: inline-block"></span>
|
|
</div>
|
<div id="QuYubody" style="width: 100%;height: 90%;padding-top: 10px;text-align: left;overflow:hidden;">
|
<div style="z-index: 9999;color: white;width: 360px;">
|
<ul class="qytj" style="position: relative;">
|
<li style="font-size: 12px">区域名称</li>
|
<li style="font-size: 12px">人数</li>
|
<li style="font-size: 12px;margin-left: 40px">统计时间</li>
|
</ul>
|
<div id="qytj" style="z-index: 9999;color: white;width: 100%;left: 20px">
|
|
</div>
|
</div>
|
</div>
|
</div>
|
</div>
|
<div class="layui-row" id="tong3" style="width: 19.5%;height: 39%;z-index: 999999;display: none;">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="width: 100%;">
|
<span id="Powertitle" style="display: inline-block;width: 100%;height: 10%;line-height: 35px;padding-left: 78px;color: white;font-size: 16px">充电提示</span><span style="position: absolute;top: 10px;left: 310px"><a href="javascript:;" title="上一页" onclick="nextpagepower('上一页')"><img src="HomeImg/jt1.png" style="width: 20px"/></a> <a href="javascript:;" title="下一页" onclick="nextpagepower('下一页')"><img src="HomeImg/jt2.png" style="width: 20px"/></a></span>
|
</div>
|
<div id="Powerbody" style="width: 100%;height: 90%;padding-top: 10px;text-align: center;overflow:hidden;">
|
<ul class="qytj" style="width: 100%">
|
<li style="font-size: 12px;color: white">名称</li>
|
<li style="font-size: 12px;color: white">电量</li>
|
<li style="font-size: 12px;color: white">编号</li>
|
<li style="font-size: 12px;color: white">状态</li>
|
</ul>
|
<div id="cdts" style="z-index: 9999;color: white;width: 100%;">
|
</div>
|
</div>
|
</div>
|
</div>
|
<%-- <div id="cxgjs" style="width: 55%;height: 50%;z-index: 99999999999;position: fixed;top: 10%;left: 20%;background-color: white;padding: 2%;padding-bottom: 5%;border-radius: 10px">--%>
|
<%-- <span onclick="Cxgj()" style="cursor: pointer;display: inline-block;float: right"><img src="HomeImg/clos.png" width="25"/></span><br>--%>
|
<%-- <iframe src="../HouTai/ChaXunGuiJi/ChaXunGuiJi1.jsp" style="width: 100%;height: 50%;z-index: 99999999999;border: 0px;position: fixed"></iframe>--%>
|
<%-- </div>--%>
|
<div class="layui-row" style="height: 100%;width: 100%;position: fixed;top: 0px;opacity: 0" id="ditu1">
|
<div class="layui-col-xs12 layui-col-md12">
|
<iframe src="Home1.jsp" style="width: 100%;height: 100%;border: none;"></iframe>
|
</div>
|
</div>
|
<div class="layui-row" style="height: 100%;width: 100%;position: fixed;top: 0px;z-index: 6" id="ditu2">
|
<div class="layui-col-xs12 layui-col-md12" style="width: 100%;height: 100%;" id="container">
|
</div>
|
</div>
|
<%-- 设备信息--%>
|
<div class="layui-row" id="ac" style="background-color: rgb(30, 42, 71,0.9)">
|
<div class="layui-col-xs12 layui-col-md12" style="">
|
<div class="boxalls tabs" style="padding-top: 30px;padding-left: 20px;padding-right: 20px">
|
<form class="layui-form">
|
<input type="text" class="sear" name="anchorid">
|
<a href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-search1">搜索</span></a>
|
<a href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-table-search4" style="margin-left: 80px">刷新</span></a>
|
<a onclick="SheBeiGuan()" href="javascript:;"><span class="sear1" style="float: right;margin-right: 0px">关闭</span></a>
|
</form>
|
<table id="anchor" lay-filter="anc" style=""></table>
|
</div>
|
<div class="boxfoot6"></div>
|
</div>
|
</div>
|
<%-- 围栏信息--%>
|
<div class="layui-row" id="fen" style="background-color: rgb(30, 42, 71,0.8)">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div class="boxalls tabs" style="padding-top: 30px;padding-left: 20px;padding-right: 20px">
|
<form class="layui-form">
|
<input type="text" class="sear" name="name">
|
<a href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-search2">搜索</span></a>
|
<a href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-table-search3" style="margin-left: 80px">刷新</span></a>
|
<a onclick="WeiLanGuan()" href="javascript:;"><span class="sear1" style="float: right;margin-right: 0px">关闭</span></a>
|
</form>
|
<table id="fence" lay-filter="fence"></table>
|
</div>
|
<div class="boxfoot6"></div>
|
</div>
|
</div>
|
<%-- 充电信息--%>
|
<div class="layui-row" id="fen1" style="background-color: rgb(255, 255, 255,0)">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div style="padding-top: 30px;padding-left: 20px;padding-right: 20px">
|
<table id="PowerPerson" lay-filter="PowerPerson" style="background-color: rgb(255, 255, 255,1)" ></table>
|
</div>
|
<div></div>
|
</div>
|
</div>
|
<%-- 警告信息--%>
|
<div class="layui-row" id="war" style="background-color: rgb(30, 42, 71,0.9)">
|
<div class="layui-col-xs12 layui-col-md12" >
|
<div class="boxalls tabs" style="padding-top: 30px;padding-left: 20px;padding-right: 20px">
|
<form class="layui-form">
|
<input style="display: inline-block" type="text" class="sear" name="objectid" >
|
<a style="display: inline-block" href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-search3">搜索</span></a>
|
<a style="display: inline-block" href="javascript:;"><span class="sear1" style="margin-left: 80px"lay-submit lay-filter="demo-table-search2">刷新</span></a>
|
<div style="width: 12%;display: inline-block;margin-left: 50px;background-color: #1C3459">
|
<select id="filterSelect" name="type" lay-filter="filterSelect">
|
<option value="请选择">请选择</option>
|
<option value="低电量">低电量</option>
|
<option value="SOS">SOS</option>
|
<option value="跌落告警">跌落告警</option>
|
<option value="测距异常">测距异常</option>
|
<option value="静止告警">静止告警</option>
|
<option value="缺员告警">缺员告警</option>
|
<option value="超员告警">超员告警</option>
|
<option value="聚集告警">聚集告警</option>
|
<option value="进入告警">进入告警</option>
|
</select>
|
</div>
|
<a style="display: inline-block" href="javascript:;" onclick="wardis()"><span class="searcount" id="searnum" style="margin-left: 40px">全部告警</span></a>
|
<a onclick="JingGaoGuan()" href="javascript:;"><span class="sear1" style="float: right;margin-right: 0px">关闭</span></a>
|
</form>
|
<table id="warning" lay-filter="warning"></table>
|
</div>
|
<div class="boxfoot6"></div>
|
</div>
|
</div>
|
<%-- 人员信息--%>
|
<div class="layui-row" id="tags" style="background-color: rgb(30, 42, 71,0.9)">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div class="boxalls tabs" style="padding-top: 30px;padding-left: 20px;padding-right: 20px;">
|
<form class="layui-form">
|
<input type="text" class="sear" name="pTagid" >
|
<a href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-search4">搜索</span></a>
|
<a href="javascript:;"><span class="sear1" style="margin-left: 80px" lay-submit lay-filter="demo-table-search1">刷新</span></a>
|
<a href="javascript:;"><span class="sear1" style="margin-left: 20px" lay-submit lay-filter="demo-table-update">修改</span></a>
|
<a onclick="RenYuanGuan()" href="javascript:;"><span class="sear1" style="float: right;margin-right: 0px">关闭</span></a>
|
</form>
|
<form class="layui-form" id="perup" lay-filter="myForm" action="javascript:;" method="post" onsubmit="return personuup()" style="display: none;position: absolute;top:70px;left: 350px;z-index: 99999999;background-color: rgb(44, 56, 80,0.9);padding: 10px 50px;width: 40%;box-shadow: 5px 5px 5px black;color: white">
|
<div class="layui-form-item">
|
<label class="layui-form-label">设备编号:</label>
|
<div class="layui-input-block">
|
<input type="text" lay-verify="title" readonly name="tagId" id="uperson1" required autocomplete="off" class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item">
|
<label class="layui-form-label">人员名称:</label>
|
<div class="layui-input-block">
|
<input type="text" lay-verify="title" name="pname" placeholder="请输入设备编号" id="uperson2" required autocomplete="off" class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item">
|
<label class="layui-form-label">人员性别:</label>
|
<div class="layui-input-block">
|
<input type="radio" name="pSex" value="男" title="男" checked>
|
<input type="radio" name="pSex" value="女" title="女"> </div>
|
</div>
|
<div class="layui-form-item">
|
<label class="layui-form-label">人员电话:</label>
|
<div class="layui-input-block">
|
<input type="text" lay-verify="title" id="uperson3" placeholder="请输入人员电话" name="pPhone" required autocomplete="off" class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item">
|
<label class="layui-form-label">身份证号:</label>
|
<div class="layui-input-block">
|
<input type="text" lay-verify="title" id="uperson4" placeholder="请输入身份证号" name="pIdcardnum" required autocomplete="off" class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item">
|
<label class="layui-form-label">选择部门:</label>
|
<div class="layui-input-block">
|
<select name="pDepartment" id="bumen">
|
<option></option>
|
</select> </div>
|
</div>
|
<div class="layui-form-item">
|
<label class="layui-form-label">岗位:</label>
|
<div class="layui-input-block">
|
<input type="text" lay-verify="title" id="uperson5" name="pZu" required autocomplete="off" class="layui-input">
|
</div>
|
</div>
|
<div class="layui-form-item">
|
<div class="layui-input-block">
|
<button type="submit" class="layui-btn" lay-submit lay-filter="submitBtn">立即提交</button>
|
<button type="button" class="layui-btn layui-btn-normal" lay-filter="" onclick="quxiaos()" style="margin-left: 20px">取消</button>
|
</div>
|
</div>
|
</form>
|
<table id="tag" lay-filter="tag"></table>
|
</div>
|
<div class="boxfoot6"></div>
|
</div>
|
</div>
|
<%-- 聚集信息--%>
|
<div class="layui-row" id="gather" style="background-color: rgb(30, 42, 71,0.9)">
|
<div class="layui-col-xs12 layui-col-md12">
|
<div class="boxalls tabs" style="padding-top: 30px;padding-left: 20px;padding-right: 20px;">
|
<form class="layui-form">
|
<input type="text" class="sear" name="pTagid">
|
<a href="javascript:;"><span class="sear1" lay-submit lay-filter="demo-search4">搜索</span></a>
|
<a href="javascript:;"><span class="sear1" style="margin-left: 80px" lay-submit lay-filter="demo-table-search1">刷新</span></a>
|
<a onclick="JuJiGuan()" href="javascript:;"><span class="sear1" style="float: right;margin-right: 0px">关闭</span></a>
|
</form>
|
<table id="gathers" lay-filter="gathers"></table>
|
</div>
|
<div class="boxfoot6"></div>
|
</div>
|
</div>
|
<div id="ChaXuns" style="">
|
<div>
|
<span>
|
<input id="sousuotags" type="text" placeholder="" style="background-color: rgb(255, 255, 255,0.5);padding-left: 5px;border: none;width: 100px;color: black;height: 30px;border-top-left-radius: 4px;border-bottom-left-radius: 4px"/>
|
</span>
|
<a href="javascript:;" id="SouSuoTag"><span style="position: relative;top: -7px;left: -4px;width: 40px;height: 30px;border-bottom-right-radius: 4px;border-top-right-radius: 4px;background-color: rgb(116, 143, 252,0.5);display: inline-block">
|
<img src="HomeImg/search.png" width="20" height="20" style="position: relative;top: 3px"/>
|
</span>
|
</a>
|
</div>
|
</div>
|
<%-- 地图切换--%>
|
<div class="layui-row" id="Ditu">
|
<div class="layui-col-xs12 layui-col-md12" style="text-align: center">
|
<div style="text-align: center;z-index: 99999">
|
<ul style="margin: auto;text-align: center;width: 100%;padding: 5px;z-index: 999999;" class="MapShow">
|
<li id="topbottom" style="display: none;margin-left: 12.8%"><img src="HomeImg/tobottom.png" style="width:1%"></li>
|
<li style="font-size: 12px;color: #07F4F6;width: 10%;display: inline-block;text-align: right"><img src="/hxzkuwb/Icon/隐藏看板.png" alt="隐藏看板" title="隐藏看板" onClick="yckb()"
|
style="width: 22%;cursor:pointer;margin-right:2%"><br><span id ="yckbtext">隐藏看板</span></li>
|
<li style="font-size: 12px;color: #07F4F6;width: 10%;display: inline-block" id="maps"><input type="checkbox" id="sanweis" onClick="Qh1()" style="display: none;position: relative;top:
|
2px"/><img src="/hxzkuwb/Icon/3D地图.png" title="切换地图" alt="切换地图" onClick="Qh1()" style="width: 22%;cursor:pointer;"><br>三维地图</li>
|
<li style="font-size: 12px;color:#07F4F6;width: 10%;display: inline-block;text-align: left" ><img src="/hxzkuwb/Icon/查看更多.png" onclick="ello()" title="更多操作" style="margin-
|
left:1%;width: 22%;cursor:pointer;" alt="更多操作"><br><span style="margin-right: 1%">更多操作</span></li>
|
</ul>
|
</div>
|
</div>
|
</div>
|
<%-- 告警信息处理窗口--%>
|
<div class="layui-row" id="wind" style="display: none">
|
<div class="layui-col-xs12 layui-col-md12" style="">
|
<img src="HomeImg/zuosj.png" style="width: 25px;position: relative;left: -19px;top: 140px">
|
<div style="width: 200%;color: black;overflow-y: hidden;background-color: white;border: 3px solid #7CCEFF;" id="XiangXi">
|
</div>
|
</div>
|
</div>
|
<%-- 底部复选款--%>
|
<%-- <div class="layui-row" id="switc">--%>
|
<%-- <div class="layui-col-xs12 layui-col-md12" style="">--%>
|
<%-- <div class="layui-form-item" style="float: right;">--%>
|
<%-- <label class="layui-form-label" style="color: white;font-size: 12px;">告警消息</label>--%>
|
<%-- <div class="layui-input-block">--%>
|
<%-- <input type="checkbox" checked style="display: none;position: relative;top: 12px;left: -3px;" id="myCheckbox">--%>
|
<%-- <img src="HomeImg/gouxuan.png" id="ck1" onclick="check1()" style="position:relative;top: 10px;left: -10px"/>--%>
|
<%-- <img src="HomeImg/weigouxuan.png" id="ck2" onclick="check2()" style="display: none;position:relative;top: 10px;left: -10px"/>--%>
|
<%-- </div>--%>
|
<%-- </div>--%>
|
|
<%-- </div>--%>
|
<%-- </div>--%>
|
<%-- <div class="layui-row" id="switc1">--%>
|
<%-- <div class="layui-col-xs12 layui-col-md12" style="">--%>
|
<%-- <div class="layui-form-item" style="float: right;">--%>
|
<%-- <label class="layui-form-label" style="color: white;font-size: 12px;">区域统计</label>--%>
|
<%-- <div class="layui-input-block">--%>
|
<%-- <input type="checkbox" checked style="display: none;position: relative;top: 12px;left: -3px;" id="myCheckbox1">--%>
|
<%-- <img src="HomeImg/gouxuan.png" id="ck3" onclick="check3()" style="position:relative;top: 10px;left: -10px"/>--%>
|
<%-- <img src="HomeImg/weigouxuan.png" id="ck4" onclick="check4()" style="display: none;position:relative;top: 10px;left: -10px"/>--%>
|
<%-- </div>--%>
|
<%-- </div>--%>
|
|
<%-- </div>--%>
|
<%-- </div>--%>
|
<%-- <div class="layui-row" id="switc2">--%>
|
<%-- <div class="layui-col-xs12 layui-col-md12" style="">--%>
|
<%-- <div class="layui-form-item" style="float: right;">--%>
|
<%-- <label class="layui-form-label" style="color: white;font-size: 12px;">充电提示</label>--%>
|
<%-- <div class="layui-input-block">--%>
|
<%-- <input type="checkbox" style="display: none;position: relative;top: 12px;left: -3px;" id="myCheckbox2">--%>
|
<%-- <img src="HomeImg/gouxuan.png" id="ck5" onclick="check5()" style="position:relative;top: 10px;left: -10px"/>--%>
|
<%-- <img src="HomeImg/weigouxuan.png" id="ck6" onclick="check6()" style="display: none;position:relative;top: 10px;left: -10px"/>--%>
|
<%-- </div>--%>
|
<%-- </div>--%>
|
|
<%-- </div>--%>
|
<%-- </div>--%>
|
<div class="layui-row" id="feng">
|
<div class="layui-col-xs12 layui-col-md12" style="">
|
<div class="layui-form-item" style="float: right;">
|
|
</div>
|
</div>
|
</div>
|
|
<%-- 人员详细数据--%>
|
<div class="layui-row" id="personMsg" style="z-index: 9999999;">
|
<div class="layui-col-xs4 layui-col-md4" style="">
|
<div id="boxses" class="boxallsMSG" style="color: black;width: 80%;height: 70%;padding: 15px;margin-left: 110%">
|
<div style="">
|
<a href="javascript:;" onclick="ShuaXinShuJu()"><span style="width: 100px;display: inline-block;background-color: #0357D1;text-align: center;color: white;height: 25px;line-height: 25px;">刷新数据</span><span id="personDate" style="color: black;margin-left: 30px"></span></a>
|
<a href="javascript:;" onclick="GuanMsg()"><span style="width: 60px;display: inline-block;background-color: #0357D1;text-align: center;color: white;height: 25px;line-height: 25px;float: right">关闭</span></a>
|
</div>
|
<div style="margin-top: 10px;float: left">
|
<a href="javascript:;"><span style="display: inline-block;width: 100px;height: 200px;" id="personImage">
|
|
</span></a>
|
</div>
|
<div style="margin-top: 10px;float: left;width: 75%;padding-left: 10px">
|
<span style="font-size: 12px;width: 31%;display:inline-block;">姓名:<span class="xingming"></span></span>
|
<span style="font-size: 12px;width: 28%;display: inline-block;">性别:<span class="xingbie"></span></span>
|
<span style="font-size: 12px;width: 34%;display: inline-block;">部门:<span class="bumen"></span></span>
|
</div>
|
<div style="margin-top: 10px;float: left;;width: 75%;padding-left: 10px">
|
<span style="font-size: 12px;width: 31%;display:inline-block;">版本:<span class="banben"></span></span>
|
<span style="font-size: 12px;width: 28%;display:inline-block;">类型:<span class="leixing"></span></span>
|
<span style="font-size: 12px;width: 34%;display:inline-block;">电话:<span class="dianhua"></span></span>
|
</div>
|
<div style="margin-top: 10px;float: left;width: 75%;padding-left:10px">
|
<span style="font-size: 12px;width: 31%;display:inline-block;">卡号:<span class="kahao"></span></span>
|
<span style="font-size: 12px;width: 28%;display:inline-block;">岗位:<span class="shijian"></span></span>
|
<span style="font-size: 12px;width: 34%;display:inline-block;">电量:<span class="powers"></span></span>
|
</div>
|
<div style="margin-top: 10px;float: left;width: 75%;padding-left:10px">
|
<span style="font-size: 12px;width: 31%;display:inline-block;">泊位:<span class="bowei"></span></span>
|
</div>
|
<div style="margin-top: 30px;float: left;margin-left: 10px;width: 500px;">
|
<span style="margin: 20px;position: relative;left: -5px;top: -120px;">用户照片</span>
|
</div>
|
<div style="margin-top: 10px;float: left;position: relative;top: -110px;width: 100%;">
|
<span style="font-size: 12px;width: 26%;display: inline-block;">经度:<span class="jingdu"></span></span>
|
<span style="font-size: 12px;width: 26%;display: inline-block;">纬度:<span class="weidu"></span></span>
|
<span style="font-size: 12px;width: 20%;display: inline-block;">高程:<span class="gaocheng"></span></span>
|
<span style="font-size: 12px;width: 20%;display: inline-block;">状态:<span class="zhuangtai1"></span></span>
|
</div>
|
<div style="margin-top: 10px;float: left;position: relative;top: -110px;width: 100%;">
|
<span style="font-size: 12px;width: 26%;display: inline-block;">X坐标:<span class="xzuobiao"></span></span>
|
<span style="font-size: 12px;width: 26%;display: inline-block;">Y坐标:<span class="yzuobiao"></span></span>
|
<span style="font-size: 12px;width: 20%;display: inline-block;">楼层:<span class="louceng"></span></span>
|
<span style="font-size: 12px;width: 20%;display: inline-block;">状态:<span class="zhuangtai2"></span></span>
|
</div>
|
<div style="margin-top: 30px;float: left;position: relative;top: -110px;width: 100%;">
|
<span>文字:</span>
|
<span><input type="text" id="context1" style="width: 70%;height: 25px;border: 1px solid #BFE4F2"></span>
|
<a href="javascript:;" onclick="sendMsg()"><span style="border: 1px solid #BFE4F2;height: 23px;line-height: 24px;width: 40px;background-color:#BFE4F2;display: inline-block;text-align: center;position: relative;left: -5px;top: 0px">发送</span></a>
|
</div>
|
</div>
|
<div class="boxfootMSG" style="width: 100%"></div>
|
</div>
|
</div>
|
<%-- 告警详细处理--%>
|
<div class="layui-row" id="warningMsg" style="z-index: 9999999">
|
<div class="layui-col-xs12 layui-col-md12" style="z-index: 9999999">
|
<ul style="height: 100%;padding: 20px">
|
<li style="margin: 15px 0px">序号:<input type="text" id="warningid" name="ids" readonly style="background-color: whitesmoke;width: 200px;border: none;padding: 5px"></li>
|
<span style="display:none" id="warningidtype"></span>
|
<li style="margin: 15px 0px">快速处理:
|
<input type="radio" name="baoliu5" onclick="gjxzt('无需处理')" value="无需处理" title="无需处理" checked>无需处理
|
<input type="radio" name="baoliu5" onclick="gjxzt('误报')" value="误报" title="误报">误报
|
<input type="radio" name="baoliu5" onclick="gjxzt('已联系')" value="已联系" title="已联系">已联系
|
</li>
|
<li style="margin: 15px 0px">详细处理记录:</li>
|
<li style="margin: 15px 0px">
|
<textarea placeholder="请输入内容" id="warningwb" name="baoliu6" style="background-color: whitesmoke;width: 250px;height: 60px;border: none;padding: 5px"></textarea>
|
</li>
|
<li style="margin: 15px 0px">
|
<button type="submit" class="layui-btn" lay-submit="" lay-filter="" onclick="warningbc()">保存</button>
|
<button type="button" class="layui-btn layui-btn-normal" lay-filter="" onclick="warningqx()" style="margin-left: 50px">取消</button>
|
</li>
|
<input type="hidden" value="" id="idwar">
|
</ul>
|
</div>
|
</div>
|
<div class="layui-row" id="warningMsg1">
|
<div class="layui-col-xs12 layui-col-md12" style="">
|
<ul style="height: 100%;padding: 20px">
|
<li style="margin: 15px 0px">序号:<input type="text" id="warningid1" name="ids" readonly style="background-color: whitesmoke;width: 200px;border: none;padding: 5px"></li>
|
<li style="margin: 15px 0px">快速处理:
|
<input type="radio" name="baoliu5" value="无需处理" title="无需处理" checked>无需处理
|
<input type="radio" name="baoliu5" value="误报" title="误报">误报
|
<input type="radio" name="baoliu5" value="已联系" title="已联系">已联系
|
</li>
|
<li style="margin: 15px 0px">详细处理记录:</li>
|
<li style="margin: 15px 0px">
|
<textarea placeholder="请输入内容" id="warningwb1" name="baoliu6" style="background-color: whitesmoke;width: 250px;height: 60px;border: none;padding: 5px"></textarea>
|
</li>
|
<li style="margin: 15px 0px">
|
<button type="submit" class="layui-btn" lay-submit="" lay-filter="" onclick="warningbc()">保存</button>
|
<button type="button" class="layui-btn layui-btn-normal" lay-filter="" onclick="warningqx()" style="margin-left: 50px">取消</button>
|
</li>
|
</ul>
|
</div>
|
</div>
|
<div class="layui-row" id="" style="position: fixed;bottom: 0px;">
|
<div class="layui-col-xs12 layui-col-md12" style="">
|
<img src="HomeImg/db1.png" style="width: 400px"/>
|
</div>
|
</div>
|
<div class="layui-row" id="" style="position: fixed;bottom: 0px;right: 0px">
|
<div class="layui-col-xs12 layui-col-md12" style="">
|
<img src="HomeImg/db2.png" style="width: 400px"/>
|
</div>
|
</div>
|
</div>
|
<%--更多--%>
|
<div style="width: 100%">
|
<div id="ello" style="display: none;z-index: 999999999;width: 14%;height: 10%;position: fixed;bottom: 11.6%;right: 36%;background-color: rgba(50,101,159,0.6);border-radius: 5px">
|
<ul style="padding-top: 5%;">
|
<li style="color: white;display: inline-block;width: 45%;text-align: center"><span>显示基站</span> <input onclick="showJiZhan()" style="" id="showJiZhan" type="checkbox"/></li>
|
<li style="color: white;display: inline-block;width: 45%;text-align: center"><span>显示网关</span> <input onclick="showWangGuan()" style="" id="ShowWangGuan" type="checkbox"/></li>
|
<li style="color: white;display: inline-block;width: 45%;text-align: center"><span>显示离线</span> <input onclick="showLiXian()" style="" id="ShowLiXianes" type="checkbox"/></li>
|
<li style="color: white;display: inline-block;width: 45%;text-align: center"><span>区域框选</span> <input onclick="QuYuKuangXuan()" style="" id="QuYuKuangXuan" type="checkbox"/></li>
|
<li style="color: white;display: inline-block;width: 45%;text-align: center"><span>聚集显示</span> <input onclick="JuJiXianShi()" style="" id="JuJiXianShi" type="checkbox"/></li>
|
<%-- <li style="width: 40%;border: 1px solid red;color: white;height: 15%;line-height: 15%"><span>显示基站</span><input onclick="showJiZhan()" style="margin-left: 10%;margin-top: 5%" id="showJiZhan" type="checkbox"/></li>--%>
|
<%-- <li style="width: 40%;color: white;height: 15%;line-height: 15%"><span>显示网关</span><input onclick="showWangGuan()" style="margin-left: 10%;margin-top: 5%" id="ShowWangGuan" type="checkbox"/></li>--%>
|
<%-- <li style="color: white;height: 15%;line-height: 15%"><span>显示离线</span><input onclick="showLiXian()" style="margin-left: 10%;margin-top: 5%" id="ShowLiXianes" type="checkbox"/></li>--%>
|
<%-- <li style="color: white;height: 15%;line-height: 15%"><span>区域框选</span><input onclick="QuYuKuangXuan()" style="margin-left: 10%;margin-top: 5%" id="QuYuKuangXuan" type="checkbox"/></li>--%>
|
<%-- <li style="color: white;height: 15%;line-height: 15%"><span>聚集显示</span><input onclick="JuJiXianShi()" style="margin-left: 10%;margin-top: 8%" id="JuJiXianShi" type="checkbox"/></li>--%>
|
</ul>
|
</div>
|
</div>
|
<span class="JingWeiDu" style="position: fixed;bottom: 0px;display: inline-block;height: 20px;z-index: 9999;right: 0px">
|
</span>
|
<div class="heimu" style="display: none;width: 100%;height: 100%;position: fixed;top: 0px;left: 0px;z-index: 9999;background-color: black;opacity: 0.8"></div>
|
<span class="heimu1" style="display: none;z-index: 99999999;position: fixed;top: 0px;width: 100%;text-align: center;margin-top: 20%">
|
<span style="display: inline-block;width: 200px;height: 40px;line-height: 40px;background-color: rgba(0,0,0,0.6);color: white"> 正在加载中.....</span>
|
</span>
|
<div style="height: 100%;width: 24%;position: fixed;top: 0px;left: 0px;z-index: 9;" id="border2s"></div>
|
<div style="height: 100%;width: 24%;position: fixed;top: 0px;right: 0px;z-index: 9;" id="border3s"></div>
|
<%--三维建筑内人员数量信息--%>
|
<div id="JianZhuMsg" style="background: url(../Home/HomeImg/FloorBg1.png) no-repeat; background-size: 100% 200%;position: fixed;top: -2%;right: -25%;width: 25%;height: 105%;z-index: 999999999999">
|
<div id="Kuanges">
|
|
</div>
|
</div>
|
<%--<div style="height: 5%;width: 100%;position: fixed;bottom: 0px;left: 0px;z-index: 9;background: linear-gradient(to top, rgba(0, 0, 0, 1) 1%, rgba(0, 0, 0, 0));"></div>--%>
|
</body>·
|
<script type="text/html" id="titleTpl">
|
{{# if(d.anchormode === '0' || d.anchormode === '-1' ) { }}
|
<span class="" style="color: white;display: inline-block;width: 35px;height: 20px;line-height: 20px;text-align:center;background-color: #666666;border-radius: 5px;font-size: 12px;position: relative;left: -3px">离线</span>
|
{{# } else if(d.anchormode === '1') { }}
|
<span class="" style="color: white;display: inline-block;width: 35px;height: 20px;line-height: 20px;text-align:center;background-color: limegreen;border-radius: 5px;font-size: 12px;position: relative;left: -3px">在线</span>
|
{{# } }}
|
</script>
|
<script type="text/html" id="titleTplPower">
|
<span>{{d.power}}%</span>
|
</script>
|
<script type="text/html" id="titleTpl1">
|
{{# if(d.ponline === '0' || d.ponline === '-1' ) { }}
|
<span class="" style="color: white;display: inline-block;width: 35px;height: 20px;line-height: 20px;text-align:center;background-color: #666666;border-radius: 5px;font-size: 12px;position: relative;left: 0px">离线</span>
|
{{# } else if(d.ponline === '1') { }}
|
<span class="" style="color: white;display: inline-block;width: 35px;height: 20px;line-height: 20px;text-align:center;background-color: limegreen;border-radius: 5px;font-size: 12px;position: relative;left: 0px">在线</span>
|
{{# } }}
|
</script>
|
<script type="text/html" id="barDemotag">
|
<a href="javascript:;" onclick="personMsg('{{d.id}}')"><img src="HomeImg/gengduo.png" style="width: 22px"></a>
|
</script>
|
<script type="text/html" id="titleTplFence">
|
{{# if(d.baoliu7 === '0' || d.baoliu7 === '-1' ) { }}
|
<a href="javascript:;" lay-event="开启"><span class="" style="color: white;background-color: red;padding: 5px">未启用</span></a>
|
{{# } else if(d.baoliu7 === '1') { }}
|
<a href="javascript:;" lay-event="关闭"><span class="" style="color: white;background-color: limegreen;padding: 5px">已启用</span></a>
|
{{# } }}
|
</script>
|
<script type="text/html" id="titleWarning">
|
{{# if(d.status === '未处理' ) { }}
|
<a href="javascript:;" lay-event="处理">
|
<span class="" style="color: white;background-color: rgb(116, 47, 80,0.8);display: inline-block;padding: 0px 10px">未处理</span>
|
</a>
|
{{# } else if(d.status === '已处理') { }}
|
<a href="javascript:;"><span class="" style="color: white;background-color: rgb(28, 145, 87,0.8);display: inline-block;padding: 0px 10px">已处理</span></a>
|
{{# } }}
|
</script>
|
<script type="text/html" id="phoneTpl">
|
{{# var phone = d.pphone; }}
|
{{# var formattedPhone = phone.slice(0, 3) + '****' + phone.slice(-3); }}
|
{{ formattedPhone }}
|
</script>
|
<script src="../JS/layui.js"></script>
|
<script src="../JS/layer.js"></script>
|
<script src="../Home/HomeJs/echarts.min.js"></script>
|
<script src="../Home/HomeJs/Home.js"></script>
|
<script src="../JS/fengmap/fengmap.map.min.js"></script>
|
<script src="../JS/fengmap/fengmap.plugin.min.js"></script>
|
<script src="../HouTai/Js/jquery-3.5.1.js"></script>
|
<script src="HomeJs/Time.js"></script>
|
<script src="../Home/HomeJs/TuBiao.js"></script>
|
<script src="HomeJs/checkdJs.js"></script>
|
|
<script>
|
var login = sessionStorage.getItem('username')
|
$("#warningusername").val(login)
|
if(login == null){
|
window.location='../index.jsp'
|
}else{
|
$(".layui-container").show();
|
$("#yhm").text(login)
|
}
|
function out(){
|
sessionStorage.removeItem("username")
|
localStorage.removeItem("username")
|
if(sessionStorage.getItem('username') == null || localStorage.getItem("username")){
|
window.location='../index.jsp'
|
}else{
|
$(".layui-container").show();
|
$("#yhm").text(login)
|
}
|
}
|
function joinHouTai(){
|
var user = $("#yhm").text();
|
var data = "username="+user
|
$.get("/hxzkuwb/findUserRole",data,function (data){
|
if(data.ujoin == "No"){
|
layer.msg('当前没有权限进入后台,请联系管理员')
|
}else{
|
window.open("../HouTai/HouTai.jsp")
|
}
|
})
|
}
|
//设置默认执行百度地图
|
localStorage.setItem("百度地图","执行")
|
//三维地图
|
localStorage.setItem("三维地图","不执行")
|
//二维地图默认为否
|
localStorage.setItem("二维地图","不执行")
|
//从部门查询图标背景颜色:并显示到 三维/二维/百度
|
var mapess;
|
function findBuMenColor(dename){
|
var data = "departmentname="+dename
|
var color = "";
|
$.ajax({
|
url: "/hxzkuwb/findBuMenColor",
|
type: "GET",
|
data: data,
|
async: false,
|
success: function(data) {
|
color = data.baoliu5
|
}
|
});
|
return color;
|
}
|
function SanWei(){
|
//三维地图
|
var map;
|
var options = {
|
container: document.getElementById("fengmap"),
|
appName: 'map1',
|
key: '09facc4ee52d1844bc1e561dad5abf59',
|
mapID: '1732234539564851202',
|
themeID: '1717913720470753281',
|
mapURL: '../fengmap/data/',
|
themeURL: '../fengmap/data/theme/',
|
minTiltAngle: 0,
|
mapZoom: 21,
|
backgroundColor:'#001133',
|
}
|
map = new fengmap.FMMap(options);
|
map.on('loaded', function () {
|
});
|
}
|
|
//loadJScript();
|
|
function loadJScript() {
|
var script = document.createElement('script');
|
script.type = 'text/javascript';
|
script.src = '//api.map.baidu.com/api?type=webgl&v=1.0&ak=zoVtgLNWuaZBjMAa32RZRFIagXxST0fm&callback=init';
|
document.body.appendChild(script);
|
}
|
// GL版命名空间为BMapGL
|
|
//百度
|
function Qh(){
|
mapess++;
|
$(".qhWeiLan").css("display","inline-block");
|
$("#ditu2").css("opacity","1")
|
$("#ditu2").css("z-index","7")
|
$("#ditu2").show();
|
$("#ChaXuns").show();
|
$(".ctrls").show();
|
$(".MapType").show();
|
localStorage.setItem("百度地图","执行")
|
localStorage.setItem("三维地图","不执行")
|
var sanweis = document.getElementById("sanweis")
|
var baidus = document.getElementById("baidus")
|
sanweis.checked = false;
|
baidus.checked = true;
|
layer.msg('操作成功')
|
}
|
//三维
|
Qh1()
|
function Qh1(){
|
mapess++;
|
$("#maps").empty();
|
$("#maps").append('<li class="MapType" onclick="inits()" style="cursor: pointer;font-size: 12px;width: 100px;display: inline-block;color: '+data[0].color+'"><a href="javascript:;" style="font-size: 12px;cursor:pointer;color: '+data[0].color+'" title=""><img src="/hxzkuwb/Icon/GIS地图.png" style="width: 40%"><br><span style="color: #07F4F6">百度地图</span></a></li>')
|
$(".qhWeiLan").css("display","none");
|
$("#ditu2").hide();
|
$("#ChaXuns").hide();
|
$("#ditu1").css("opacity","1");
|
$("#ditu1").css("z-index","6")
|
$("#ditu3").css("opacity","0")
|
$("#ditu3").css("z-index","5")
|
localStorage.setItem("三维地图","执行")
|
localStorage.setItem("百度地图","不执行")
|
var sanweis = document.getElementById("sanweis")
|
layer.msg('操作成功')
|
$(".MapType").hide();
|
$("#weilanxs").hide();
|
}
|
|
var qhWeiLanNum = 0;
|
var qhOnline = 0
|
var qhJiZhan = 0;
|
</script>
|
|
<script>
|
function getfence() {
|
var fences = [];
|
$.ajax({
|
async: false, //同步的
|
type: "GET",
|
url: "/hxzkuwb/baidufence.do",
|
dataType: "json",
|
success: function (data) {
|
fences.push(data.fences);
|
},
|
});
|
return fences;
|
}
|
function getGPS() {
|
var gpslist = [];
|
$.ajax({
|
async: false,
|
type: 'POST',
|
traditional: true,
|
url: "/hxzkuwb/getGPS",
|
dataType: 'json',
|
data: {},
|
success: function (data) {
|
//经纬度从度分秒转成度
|
gpslist = data
|
},
|
});
|
return gpslist;
|
};
|
|
function getGPSOffOnlie() {
|
var gpslist = [];
|
$.ajax({
|
async: false,
|
type: 'POST',
|
traditional: true,
|
url: "/hxzkuwb/getGPSOffOnLine",
|
dataType: 'json',
|
data: {},
|
success: function (data) {
|
//经纬度从度分秒转成度
|
gpslist = data
|
},
|
});
|
return gpslist;
|
};
|
</script>
|
|
|
|
|
<!-- 百度地图功能 -->
|
<script type="text/javascript">
|
|
var sousuopd = false;
|
var sousuoid = "";
|
var sousuo;
|
var quxiao;
|
|
function Convertor(ak) {
|
this.stepCount = 100;
|
this.pointCount = [];
|
this.Result = [];
|
this.NoisIndex = [];
|
this.Time = new Date();
|
this.AK = ak;
|
this.M_PI = 3.14159265358979324;
|
this.A = 6378245.0;
|
this.EE = 0.00669342162296594323;
|
this.X_PI = this.M_PI * 3000.0 / 180.0;
|
}
|
Convertor.prototype.outofChine = function (p) {
|
if (p.lng < 72.004 || p.lng > 137.8347) {
|
return true;
|
}
|
if (p.lat < 0.8293 || p.lat > 55.8271) {
|
return true;
|
}
|
return false;
|
}
|
;
|
Convertor.prototype.WGS2GCJ_lat = function (x, y) {
|
var ret1 = -100.0 + 2.0 * x + 3.0 * y + 0.2 * y * y + 0.1 * x * y + 0.2 * Math.sqrt(Math.abs(x));
|
ret1 += (20.0 * Math.sin(6.0 * x * this.M_PI) + 20.0 * Math.sin(2.0 * x * this.M_PI)) * 2.0 / 3.0;
|
ret1 += (20.0 * Math.sin(y * this.M_PI) + 40.0 * Math.sin(y / 3.0 * this.M_PI)) * 2.0 / 3.0;
|
ret1 += (160.0 * Math.sin(y / 12.0 * this.M_PI) + 320 * Math.sin(y * this.M_PI / 30.0)) * 2.0 / 3.0;
|
return ret1;
|
}
|
;
|
Convertor.prototype.WGS2GCJ_lng = function (x, y) {
|
var ret2 = 300.0 + x + 2.0 * y + 0.1 * x * x + 0.1 * x * y + 0.1 * Math.sqrt(Math.abs(x));
|
ret2 += (20.0 * Math.sin(6.0 * x * this.M_PI) + 20.0 * Math.sin(2.0 * x * this.M_PI)) * 2.0 / 3.0;
|
ret2 += (20.0 * Math.sin(x * this.M_PI) + 40.0 * Math.sin(x / 3.0 * this.M_PI)) * 2.0 / 3.0;
|
ret2 += (150.0 * Math.sin(x / 12.0 * this.M_PI) + 300.0 * Math.sin(x / 30.0 * this.M_PI)) * 2.0 / 3.0;
|
return ret2;
|
}
|
;
|
Convertor.prototype.WGS2GCJ = function (poi) {
|
if (this.outofChine(poi)) {
|
return;
|
}
|
var poi2 = {};
|
var dLat = this.WGS2GCJ_lat(poi.lng - 105.0, poi.lat - 35.0);
|
var dLon = this.WGS2GCJ_lng(poi.lng - 105.0, poi.lat - 35.0);
|
var radLat = poi.lat / 180.0 * this.M_PI;
|
var magic = Math.sin(radLat);
|
magic = 1 - this.EE * magic * magic;
|
var sqrtMagic = Math.sqrt(magic);
|
dLat = (dLat * 180.0) / ((this.A * (1 - this.EE)) / (magic * sqrtMagic) * this.M_PI);
|
dLon = (dLon * 180.0) / (this.A / sqrtMagic * Math.cos(radLat) * this.M_PI);
|
poi2.lat = poi.lat + dLat;
|
poi2.lng = poi.lng + dLon;
|
return poi2;
|
}
|
;
|
Convertor.prototype.GCJ2BD09 = function (poi) {
|
var poi2 = {};
|
var x = poi.lng
|
, y = poi.lat;
|
var z = Math.sqrt(x * x + y * y) + 0.00002 * Math.sin(y * this.X_PI);
|
var theta = Math.atan2(y, x) + 0.000003 * Math.cos(x * this.X_PI);
|
poi2.lng = z * Math.cos(theta) + 0.0065;
|
poi2.lat = z * Math.sin(theta) + 0.006;
|
return poi2;
|
}
|
;
|
/**
|
* WGS->百度坐标系
|
*/
|
Convertor.prototype.WGS2BD09 = function (poi) {
|
//WGS->GCJ
|
var poi2 = this.WGS2GCJ(poi);
|
if (typeof poi2 === "undefined") {
|
return;
|
}
|
//GCJ->百度坐标系
|
return this.GCJ2BD09(poi2);
|
}
|
|
function zhuanhuan(aaa) {
|
var c = new Convertor();
|
var bbb = [];
|
for (var i = 0; i < aaa.length; i++) {
|
var rr = c.WGS2BD09({ lng: aaa[i].lng, lat: aaa[i].lat });
|
bbb.push(rr);
|
}
|
return bbb;
|
c = null;
|
bbb = null;
|
}
|
|
jQuery.Hashtable = function () {
|
this.items = new Array();
|
this.itemsCount = 0;
|
this.add = function (key, value) {
|
if (!this.containsKey(key)) {
|
this.items[key] = value;
|
this.itemsCount++;
|
}
|
else
|
throw "key '" + key + "' allready exists."
|
}
|
this.get = function (key) {
|
if (this.containsKey(key))
|
return this.items[key];
|
else
|
return null;
|
}
|
|
this.remove = function (key) {
|
if (this.containsKey(key)) {
|
delete this.items[key];
|
this.itemsCount--;
|
}
|
else
|
throw "key '" + key + "' does not exists."
|
}
|
this.containsKey = function (key) {
|
return typeof (this.items[key]) != "undefined";
|
}
|
this.containsValue = function containsValue(value) {
|
for (var item in this.items) {
|
if (this.items[item] == value)
|
return true;
|
}
|
return false;
|
}
|
this.contains = function (keyOrValue) {
|
return this.containsKey(keyOrValue) || this.containsValue(keyOrValue);
|
}
|
this.clear = function () {
|
this.items = new Array();
|
itemsCount = 0;
|
}
|
this.size = function () {
|
return this.itemsCount;
|
}
|
this.isEmpty = function () {
|
return this.size() == 0;
|
}
|
};
|
|
if (localStorage.getItem("maptypesnum") == null || localStorage.getItem("maptypesnum") == ""){
|
localStorage.setItem("maptypesnum",0)
|
}else{
|
localStorage.setItem("maptypesnum",localStorage.getItem("maptypesnum"))
|
}
|
|
var onLine = 0;
|
var onFence = 0;
|
var onJiZhan = 0;
|
function inits(){
|
localStorage.setItem("maptypesnum",parseInt(localStorage.getItem("maptypesnum"))+parseInt(1));
|
if(localStorage.getItem("maptypesnum")%2==0){
|
localStorage.setItem("mapType","地球模式")
|
}else{
|
localStorage.setItem("mapType","路网模式")
|
}
|
location.reload();
|
}
|
function init() {
|
var shijiao;
|
var zhongxindian;
|
var gao;
|
var level;
|
$.ajax({
|
url: "/hxzkuwb/findbaidumapList",
|
data: data,
|
async: false,
|
success: function(data) {
|
shijiao = data[0].shijiao;
|
gao = data[0].heig;
|
zhongxindian = data[0].center
|
level = data[0].level;
|
},
|
error: function() {
|
// 在这里处理失败的回调函数
|
}
|
});
|
//读取系统设置
|
var fences = getfence();
|
var showRect = true;
|
var nameFormat = "{x}_{y}";
|
var ext = ".png";
|
var bm_tagZb = 0;//是否显示标签坐标
|
var bm_viewPower = 0;//是否显示电量
|
var bm_viewTagid = 1;//是否显示标签ID
|
var bm_offView = 1;//是否离线不显示图标
|
// 百度地图API功能//默认卫星地图 {mapType:BMAP_SATELLITE_MAP}
|
var bm = new BMapGL.Map("container"); // 创建Map实例
|
var zhong =zhongxindian.split(';') ;
|
bm.centerAndZoom(new BMapGL.Point(zhong[0],zhong[1]), level); // 初始化地图,设置中心点坐标和地图级别
|
bm.enableScrollWheelZoom(true); //开启鼠标滚轮缩放
|
console.log()
|
if(localStorage.getItem("mapType") == "地球模式"){
|
bm.setMapType(BMAP_EARTH_MAP);
|
}else{
|
|
}
|
//添加地图类型控件
|
bm.setHeading(shijiao); //设置地图旋转角度
|
bm.setTilt(gao);
|
|
|
|
var zuobiaoxi = "";
|
//从数据库查询当前选择的什么系坐标
|
$.ajax({
|
url: "/hxzkuwb/findbaidumapList",
|
type: "GET",
|
async: false,
|
success: function(data) {
|
zuobiaoxi = data[0].zhuanhuan
|
}
|
});
|
|
var tileLayer = new BMapGL.TileLayer();
|
tileLayer.getTilesUrl = function(tileCoord, zoom) {
|
var name = nameFormat
|
.replace("{x}", tileCoord.x)
|
.replace("{y}", tileCoord.y)
|
.replace("{z}", zoom)
|
;
|
return 'tiles/' + zoom + '/' + name + ext;
|
}
|
bm.addTileLayer(tileLayer);
|
|
var navi3DCtrl = new BMapGL.NavigationControl3D({
|
anchor: BMAP_ANCHOR_BOTTOM_RIGHT, // 将控件锚点设置为地图底部
|
offset: new BMapGL.Size(0, 0) // 设置控件相对于锚点的偏移量,这里将偏移量设为(0, 0)
|
});
|
bm.addControl(navi3DCtrl);
|
var offset = new BMapGL.Size(525, 20); // 水平和垂直偏移量
|
navi3DCtrl.setOffset(offset);
|
bm.addEventListener('click', function (e) {
|
$(".JingWeiDu").text('当前位置经纬度:' + e.latlng.lng + ',' + e.latlng.lat)
|
});
|
|
|
|
var myIcon = new BMapGL.Icon("../Home/HomeImg/default.png", new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
}
|
);
|
var timer2;
|
var mar1;
|
$("#SouSuoTag").click(function (){
|
var pTagid = $("#sousuotags").val();
|
var data = "pTagid="+pTagid
|
if(pTagid == ""){
|
localStorage.setItem("百度地图","执行")
|
clearInterval(timer2);
|
bm.removeOverlay(markers1[localStorage.getItem("markers1")]);
|
delete markers1[localStorage.getItem("markers1")]
|
markers = {}
|
markers1 = {}
|
layer.msg('操作成功')
|
}else{
|
localStorage.setItem("百度地图","不执行")
|
mar1 = localStorage.getItem("markers1");
|
$.ajax({
|
url: "/hxzkuwb/findOnePerson",
|
type: "POST",
|
data: data,
|
async: false,
|
success: function(data) {
|
if (data == "") {
|
layer.msg("该人员不存在!")
|
} else {
|
if (zuobiaoxi == "百度"){
|
var c = new Convertor();
|
var rr1 = c.WGS2BD09({
|
lng: parseFloat(data.baoliu2),
|
lat: parseFloat(data.baoliu3)
|
});
|
}else{
|
var rr1 = ({lng: parseFloat(data.baoliu2), lat: parseFloat(data.baoliu3)});
|
}
|
var c = new Convertor();
|
|
var targetPoint = new BMapGL.Point(rr1.lng, rr1.lat);
|
bm.panTo(targetPoint);
|
bm.removeOverlay(markers[pTagid]);
|
delete markers[pTagid]
|
bm.removeOverlay(markers1[mar1]);
|
delete markers1[mar1]
|
localStorage.setItem("markers1",pTagid);
|
//再根据搜索的人员,添加显示到地图上,并且一秒一刷新
|
timer2 = setInterval(function (){
|
var gpsInfo = hqSearch(pTagid);
|
var c = new Convertor();
|
if (gpsInfo.baoliu2 != "-1") {
|
var rr = c.WGS2BD09({
|
lng: parseFloat(gpsInfo.baoliu2),
|
lat: parseFloat(gpsInfo.baoliu3)
|
});
|
if (zuobiaoxi == "百度"){
|
var lng = parseFloat(rr.lng);
|
var lat = parseFloat(rr.lat);
|
}else{
|
var lng = parseFloat(gpsInfo.baoliu2);
|
var lat = parseFloat(gpsInfo.baoliu3);
|
}
|
var userId = gpsInfo.ptagid;
|
// 判断在线状态
|
if (gpsInfo.ponline == "1" || gpsInfo.ponline == "0") {
|
// 如果标记已存在,则更新坐标
|
if (markers[userId]) {
|
markers[userId].setPosition(new BMapGL.Point(lng, lat));
|
markers1[userId].setPoint(new BMapGL.Point(lng, lat));
|
|
} else {
|
const customOverlay = new BMapGL.CustomOverlay(createDOM, {
|
point: new BMapGL.Point(lng, lat),
|
opacity: 0.7,
|
map: bm,
|
offsetY: 26,
|
zIndex: -99
|
})
|
bm.addOverlay(customOverlay);
|
markers1[userId] = customOverlay;
|
// 创建坐标点
|
var point = new BMapGL.Point(lng, lat);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/" + gpsInfo.pimage, new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40),
|
zIndex:10
|
});
|
|
var marker = new BMapGL.Marker(point, {icon: myIcon});
|
// 将标记添加到地图上
|
bm.addOverlay(marker);
|
var label = new BMapGL.Label(gpsInfo.pname + " " + userId, {offset: new BMapGL.Size(0, -70)});
|
label.setStyle({
|
color: "#fff",
|
fontSize: "14px",
|
borderRadius: "5px",
|
padding: "5px 5px",
|
border: "0",
|
backgroundColor: gpsInfo.bumencolor,
|
transform: 'translateX(-50%)',
|
});
|
|
marker.setLabel(label);
|
// 存储标记到 markers 对象中
|
markers[userId] = marker;
|
marker.setTitle(gpsInfo.ptagid);
|
marker.addEventListener("click", function () {
|
var data = "id=" + this.getTitle();
|
$.ajax({
|
url: "/hxzkuwb/findtagIdPerson",
|
data: data,
|
async: false,
|
success: function (data) {
|
if (data.ponline == "1") {
|
data.ponline = "在线";
|
} else {
|
data.ponline = "离线";
|
}
|
$("#personImage").empty()
|
$("#personImage").append('<img style="width: 100px;height: 100px" src=/hxzkuwb/Icon/' + data.baoliu38 + '/>')
|
$(".xingming").text(data.pname);
|
$(".xingbie").text(data.psex);
|
$(".bumen").text(data.pdepartment);
|
$(".banben").text("未知");
|
$(".bowei").text(data.baoliu39);
|
$(".leixing").text(data.baoliu19);
|
$(".dianhua").text(data.pphone);
|
$(".kahao").text(data.ptagid);
|
$(".shijian").text(data.pzu);
|
$(".powers").text(data.ppower+"%")
|
$(".jingdu").text(data.baoliu2);
|
$(".weidu").text(data.baoliu3);
|
$(".gaocheng").text(data.baoliu4);
|
$(".zhuangtai1").text(data.baoliu13);
|
$(".xzuobiao").text(data.px);
|
$(".yzuobiao").text(data.py);
|
$(".louceng").text(data.pfloor);
|
$(".zhuangtai2").text(data.ponline);
|
}
|
});
|
$("#personMsg").show();
|
});
|
}
|
} else {
|
// 如果标记存在,则移除标记
|
if (markers[userId]) {
|
bm.removeOverlay(markers[userId]);
|
delete markers[userId];
|
}
|
if (markers1[userId]) {
|
bm.removeOverlay(markers1[userId]);
|
delete markers1[userId];
|
}
|
}
|
}
|
},2000)
|
|
}
|
}
|
});
|
}
|
})
|
|
|
function hqSearch(id){
|
var data = "pTagid="+id
|
var person;
|
$.ajax({
|
url: "/hxzkuwb/findOnePerson",
|
type: "POST",
|
data: data,
|
async: false,
|
success: function(data) {
|
person = data
|
}
|
});
|
return person;
|
}
|
function quxiao2() {
|
sousuopd = false;
|
sousuoid = "";
|
|
}
|
|
$("#sousuo2").click(function (){
|
sousuoid = $("#sousuotagidx").val();
|
//判断ID是否存在
|
$.ajax({
|
url: "idCunZai.do",
|
type: "POST",
|
dataType: "JSON",
|
data: {
|
id: sousuoid,
|
},
|
success:function (data){
|
if(data.length == 0){
|
alert("当前标签不在线")
|
}else{
|
var gpslist = getGPS();
|
for (const key in gpslist) {
|
if (gpslist[key][0] == sousuoid) {
|
bm.panTo(new BMapGL.Point(gpslist[key][1], gpslist[key][2]));
|
}
|
}
|
}
|
}
|
})
|
})
|
|
$("#sousuo2sx").click(function (){
|
window.location.reload();
|
})
|
quxiao = quxiao2;
|
|
// 增加矩形图层
|
for (var i = 0; i < fences.length; i++) {
|
fences[i] = fences[i].split(";");
|
for (var j = 0; j < fences[i].length; j++) {
|
fences[i][j] = fences[i][j].split(",");
|
}
|
}
|
var points = [];
|
for(var i = 0 ; i < fences.length;i++){
|
for (var j = i ; j< fences[i].length;j++){
|
var point = new BMapGL.Point(fences[i][j][0], fences[i][j][1]);
|
points.push(point);
|
|
}
|
}
|
var tt = 0;
|
var tt2 = true;
|
var tt3 = 0;
|
|
|
//获取基站数据。
|
var jizhanes = FindShowJiZhan();
|
var wangguanes = FindShowWangGuan();
|
//获取网关数据
|
//var t = 300; 每600ms从后台请求一次最新的数据
|
var markers = {};
|
var markers1 = {};
|
var timer = setInterval(function() {
|
|
|
if (localStorage.getItem("百度地图") == "不执行"){
|
return
|
}
|
markers = {};
|
bm.clearOverlays();
|
if(onFence == 0){
|
//显示围栏
|
var polygon = new BMapGL.Polygon(points, { strokeColor: "red", strokeOpacity: 0.5, fillColor: "red", fillOpacity: 0.3 });
|
bm.addOverlay(polygon);
|
}
|
if (localStorage.getItem("jizhanshow") == "1"){
|
//显示基站
|
if (zuobiaoxi == "百度"){
|
for (var i = 0 ; i <jizhanes.length; i ++){
|
var c = new Convertor();
|
var rr = c.WGS2BD09({ lng: parseFloat(jizhanes[i].baoliu6), lat: parseFloat(jizhanes[i].baoliu7)});
|
var point = new BMapGL.Point(rr.lng,rr.lat);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/jizhan.png", new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
});
|
var jizhan = new BMapGL.Marker(point, { icon: myIcon });
|
var label = new BMapGL.Label(jizhanes[i].anchorid, {offset: new BMapGL.Size(0, -70)});
|
label.setStyle({
|
color: "black",
|
fontSize: "14px",
|
borderRadius: "5px",
|
padding: "5px 5px",
|
border: "0",
|
transform: 'translateX(-50%)',
|
});
|
jizhan.setLabel(label);
|
bm.addOverlay(jizhan);
|
console.log("添加成功")
|
}
|
}else{
|
for (var i = 0 ; i <jizhanes.length; i ++){
|
var point = new BMapGL.Point(jizhanes[i].baoliu6,jizhanes[i].baoliu7);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/jizhan.png", new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
});
|
var jizhan = new BMapGL.Marker(point, { icon: myIcon });
|
bm.addOverlay(jizhan);
|
|
}
|
}
|
|
}
|
if (localStorage.getItem("wangguanshow") == "1"){
|
if (zuobiaoxi == "百度"){
|
for (var i = 0 ; i <wangguanes.length; i ++){
|
//显示网关
|
var c = new Convertor();
|
var rr = c.WGS2BD09({ lng: parseFloat(wangguanes[i].lon), lat: parseFloat(wangguanes[i].lat)});
|
var point = new BMapGL.Point(rr.lng,rr.lat);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/wangguan.png", new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
});
|
var wangguan = new BMapGL.Marker(point, { icon: myIcon });
|
var label = new BMapGL.Label(wangguanes[i].loragwid, {offset: new BMapGL.Size(0, -70)});
|
label.setStyle({
|
color: "black",
|
fontSize: "14px",
|
borderRadius: "5px",
|
padding: "5px 5px",
|
border: "0",
|
transform: 'translateX(-50%)',
|
});
|
wangguan.setLabel(label);
|
bm.addOverlay(wangguan);
|
console.log("添加网关成功")
|
}
|
}else{
|
for (var i = 0 ; i <wangguanes.length; i ++){
|
//显示网关
|
var point = new BMapGL.Point(wangguanes[i].lon,wangguanes[i].lat);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/wangguan.png", new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
});
|
var wangguan = new BMapGL.Marker(point, { icon: myIcon });
|
bm.addOverlay(wangguan);
|
}
|
}
|
}
|
if(onLine == 0){
|
//只显示在线
|
var gps_node_list1 = getGPS();
|
for (var i = 0; i < gps_node_list1.length; i++) {
|
var gpsInfo = gps_node_list1[i];
|
var c = new Convertor();
|
if(gpsInfo.baoliu2!= "-1" && gpsInfo.baoliu2 !=""){
|
var rr = c.WGS2BD09({ lng: parseFloat(gpsInfo.baoliu2), lat: parseFloat(gpsInfo.baoliu3)});
|
if (zuobiaoxi == "百度"){
|
var lng = parseFloat(rr.lng);
|
var lat = parseFloat(rr.lat);
|
}else{
|
var lng = parseFloat(gpsInfo.baoliu2);
|
var lat = parseFloat(gpsInfo.baoliu3);
|
}
|
var userId = gpsInfo.ptagid;
|
// 判断在线状态
|
localStorage.setItem("username","超级管理员")
|
if(gpsInfo.psos == "1") {
|
if (markers1.hasOwnProperty(userId)) {
|
// 如果已经存在该标记,则移除原来的标记
|
bm.removeOverlay(markers1[userId]);
|
// 更新标记位置
|
const customOverlay = new BMapGL.CustomOverlay(createDOM, {
|
point: new BMapGL.Point(lng, lat),
|
opacity: 1,
|
bm: bm,
|
offsetY: 26,
|
zIndex: -1
|
});
|
bm.addOverlay(customOverlay);
|
markers1[userId] = customOverlay;
|
} else {
|
// 如果不存在该标记,则添加新标记
|
const customOverlay = new BMapGL.CustomOverlay(createDOM, {
|
point: new BMapGL.Point(lng, lat),
|
opacity: 1,
|
bm: bm,
|
offsetY: 26,
|
zIndex: -1
|
});
|
bm.addOverlay(customOverlay);
|
markers1[userId] = customOverlay;
|
}
|
}else{
|
if (markers1.hasOwnProperty(userId)) {
|
// 如果已经存在该标记,则移除原来的标记
|
bm.removeOverlay(markers1[userId]);
|
}
|
}
|
// 创建坐标点
|
var point = new BMapGL.Point(lng, lat);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/"+gpsInfo.pimage, new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
});
|
var marker = new BMapGL.Marker(point, { icon: myIcon });
|
|
// 将标记添加到地图上
|
bm.addOverlay(marker);
|
var label = new BMapGL.Label(gpsInfo.pname+" "+userId, {offset: new BMapGL.Size(0, -70)});
|
label.setStyle({
|
color: "#fff",
|
fontSize: "14px",
|
borderRadius: "5px",
|
padding: "5px 5px",
|
border: "0",
|
backgroundColor: gpsInfo.bumencolor,
|
transform: 'translateX(-50%)',
|
});
|
marker.setLabel(label);
|
// 存储标记到 markers 对象中
|
markers[userId] = marker;
|
marker.setTitle(gpsInfo.ptagid);
|
marker.addEventListener("click", function () {
|
var data = "id="+this.getTitle();
|
$.ajax({
|
url: "/hxzkuwb/findtagIdPerson",
|
data: data,
|
async: false,
|
success: function(data) {
|
if (data.ponline == "1") {
|
data.ponline = "在线";
|
} else {
|
data.ponline = "离线";
|
}
|
$("#personImage").empty()
|
$("#personImage").append('<img style="width: 100px;height: 100px" src=/hxzkuwb/Icon/'+data.baoliu38+'/>')
|
$(".xingming").text(data.pname);
|
$(".xingbie").text(data.psex);
|
$(".bumen").text(data.pdepartment);
|
$(".banben").text("未知");
|
$(".bowei").text(data.baoliu39);
|
$(".leixing").text(data.baoliu19);
|
$(".dianhua").text(data.pphone);
|
$(".kahao").text(data.ptagid);
|
$(".shijian").text(data.pzu);
|
$(".powers").text(data.ppower+"%")
|
$(".jingdu").text(data.baoliu2);
|
$(".weidu").text(data.baoliu3);
|
$(".gaocheng").text(data.baoliu4);
|
$(".zhuangtai1").text(data.baoliu13);
|
$(".xzuobiao").text(data.px);
|
$(".yzuobiao").text(data.py);
|
$(".louceng").text(data.pfloor);
|
$(".zhuangtai2").text(data.ponline);
|
}
|
});
|
$("#personMsg").show();
|
});
|
}
|
}
|
}else{
|
var gps_node_list1 = getGPSOffOnlie();
|
for (var i = 0; i < gps_node_list1.length; i++) {
|
var gpsInfo = gps_node_list1[i];
|
var c = new Convertor();
|
if(gpsInfo.baoliu2!= "-1" && gpsInfo.baoliu2 !=""){
|
var rr = c.WGS2BD09({ lng: parseFloat(gpsInfo.baoliu2), lat: parseFloat(gpsInfo.baoliu3)});
|
var lng = parseFloat(rr.lng);
|
var lat = parseFloat(rr.lat);
|
var userId = gpsInfo.ptagid;
|
// 判断在线状态
|
if(gpsInfo.psos == "1") {
|
if (markers1.hasOwnProperty(userId)) {
|
// 如果已经存在该标记,则移除原来的标记
|
bm.removeOverlay(markers1[userId]);
|
// 更新标记位置
|
const customOverlay = new BMapGL.CustomOverlay(createDOM, {
|
point: new BMapGL.Point(lng, lat),
|
opacity: 1,
|
bm: bm,
|
offsetY: 26,
|
zIndex: -1
|
});
|
bm.addOverlay(customOverlay);
|
markers1[userId] = customOverlay;
|
} else {
|
// 如果不存在该标记,则添加新标记
|
const customOverlay = new BMapGL.CustomOverlay(createDOM, {
|
point: new BMapGL.Point(lng, lat),
|
opacity: 1,
|
bm: bm,
|
offsetY: 26,
|
zIndex: -1
|
});
|
bm.addOverlay(customOverlay);
|
markers1[userId] = customOverlay;
|
}
|
}else{
|
|
if (markers1.hasOwnProperty(userId)) {
|
// 如果已经存在该标记,则移除原来的标记
|
bm.removeOverlay(markers1[userId]);
|
}
|
}
|
// 创建坐标点
|
var point = new BMapGL.Point(lng, lat);
|
// 创建标记
|
var myIcon = new BMapGL.Icon("../Icon/"+gpsInfo.pimage, new BMapGL.Size(40, 40), {
|
anchor: new BMapGL.Size(20, 40)
|
});
|
var marker = new BMapGL.Marker(point, { icon: myIcon });
|
// 将标记添加到地图上
|
bm.addOverlay(marker);
|
var label = new BMapGL.Label(gpsInfo.pname+" "+userId, {offset: new BMapGL.Size(0, -70)});
|
|
if (gpsInfo.ponline == "0"){
|
label.setStyle({
|
color: "#fff",
|
fontSize: "14px",
|
borderRadius: "5px",
|
padding: "5px 5px",
|
border: "0",
|
backgroundColor: '#666666',
|
transform: 'translateX(-50%)',
|
});
|
}else{
|
label.setStyle({
|
color: "#fff",
|
fontSize: "14px",
|
borderRadius: "5px",
|
padding: "5px 5px",
|
border: "0",
|
backgroundColor: gpsInfo.bumencolor,
|
transform: 'translateX(-50%)',
|
});
|
}
|
marker.setLabel(label);
|
// 存储标记到 markers 对象中
|
markers[userId] = marker;
|
marker.setTitle(gpsInfo.ptagid);
|
marker.addEventListener("click", function () {
|
console.log("123456")
|
var data = "id="+this.getTitle();
|
$.ajax({
|
url: "/hxzkuwb/findtagIdPerson",
|
data: data,
|
async: false,
|
success: function(data) {
|
if (data.ponline == "1") {
|
data.ponline = "在线";
|
} else {
|
data.ponline = "离线";
|
}
|
$("#personImage").empty()
|
$("#personImage").append('<img style="width: 100px;height: 100px" src=/hxzkuwb/Icon/'+data.baoliu38+'/>')
|
$(".xingming").text(data.pname);
|
$(".xingbie").text(data.psex);
|
$(".bumen").text(data.pdepartment);
|
$(".banben").text("未知");
|
$(".bowei").text(data.baoliu39);
|
$(".leixing").text(data.baoliu19);
|
$(".dianhua").text(data.pphone);
|
$(".kahao").text(data.ptagid);
|
$(".shijian").text(data.pzu);
|
$(".powers").text(data.ppower+"%")
|
$(".jingdu").text(data.baoliu2);
|
$(".weidu").text(data.baoliu3);
|
$(".gaocheng").text(data.baoliu4);
|
$(".zhuangtai1").text(data.baoliu13);
|
$(".xzuobiao").text(data.px);
|
$(".yzuobiao").text(data.py);
|
$(".louceng").text(data.pfloor);
|
$(".zhuangtai2").text(data.ponline);
|
}
|
});
|
$("#personMsg").show();
|
});
|
}
|
}
|
}
|
}, 3000); // 为每一个icon 添加点击事件
|
|
// bm.addEventListener("dragstart", function() {
|
// clearInterval(timer); // 拖动开始时停止定时器
|
// });
|
};
|
$(document).bind('click', function (e) {
|
var e = e || window.event; //浏览器兼容性
|
var elem = e.target || e.srcElement;
|
while (elem) { //循环判断至跟节点,防止点击的是div子元素
|
if (elem.id && elem.id == 'test') {
|
return;
|
}
|
elem = elem.parentNode;
|
}
|
$('.content-absolute').css('display', 'none'); //点击的不是div或其子元素
|
});
|
|
//显示围栏
|
function qhweil(){
|
qhWeiLanNum = qhWeiLanNum+1;
|
if (qhWeiLanNum%2==0){
|
onFence = 0
|
$("#weilanxs").text("隐藏围栏")
|
|
}else{
|
$("#weilanxs").text("显示围栏")
|
onFence = 1
|
}
|
layer.msg('操作成功')
|
}
|
//显示离线
|
function xianshilixians() {
|
qhOnline = qhOnline+1
|
if (qhOnline%2==0){
|
var lixian = document.getElementById("xianshilixian")
|
lixian.checked = false;
|
onLine = "0"
|
localStorage.setItem("oNLine","No")
|
|
}else{
|
var lixian = document.getElementById("xianshilixian")
|
lixian.checked = true;
|
onLine = "1"
|
localStorage.setItem("oNLine","Yes")
|
}
|
layer.msg('操作成功')
|
}
|
|
function getdateTime() {
|
var date = new Date();
|
|
var year = date.getFullYear();
|
var month = date.getMonth() + 1; // 因为月份是从0开始计数,所以需要加1
|
var day = date.getDate();
|
var hours = date.getHours();
|
var minutes = date.getMinutes();
|
var seconds = date.getSeconds();
|
|
// 格式化时间,保证小时、分钟、秒始终有两位数
|
month = formatTime(month);
|
day = formatTime(day);
|
hours = formatTime(hours);
|
minutes = formatTime(minutes);
|
seconds = formatTime(seconds);
|
|
// 更新页面显示时间的元素的内容
|
document.getElementById("personDate").innerHTML ="更新时间:"+ year + "-" + month + "-" + day + " " + hours + ":" + minutes + ":" + seconds;
|
}
|
|
function updateTime() {
|
var date = new Date();
|
|
var year = date.getFullYear();
|
var month = date.getMonth() + 1; // 因为月份是从0开始计数,所以需要加1
|
var day = date.getDate();
|
var hours = date.getHours();
|
var minutes = date.getMinutes();
|
var seconds = date.getSeconds();
|
|
// 格式化时间,保证小时、分钟、秒始终有两位数
|
month = formatTime(month);
|
day = formatTime(day);
|
hours = formatTime(hours);
|
minutes = formatTime(minutes);
|
seconds = formatTime(seconds);
|
|
// 更新页面显示时间的元素的内容
|
document.getElementById("current-time").innerHTML ="日期:"+ year + "-" + month + "-" + day + " " + hours + ":" + minutes + ":" + seconds;
|
}
|
|
function createDOM() {
|
const img = document.createElement('img');
|
img.style.height = '120px';
|
img.style.width = '120px';
|
img.src = '/hxzkuwb/Home/HomeImg/警示.gif';
|
img.draggable = false;
|
return img;
|
}
|
|
function formatTime(time) {
|
if (time < 10) {
|
time = "0" + time;
|
}
|
return time;
|
}
|
|
function ShuaXinShuJu(){
|
var tagid = $(".kahao").text();
|
personMsgtid(tagid)
|
getdateTime()
|
layer.msg('刷新成功')
|
}
|
// 每秒钟更新一次时间
|
setInterval(updateTime, 1000);
|
$("#fenglogo").fadeIn(2000);
|
$("#switc").fadeIn(4000);
|
$("#switc1").fadeIn(4000);
|
$("#switc2").fadeIn(4000);
|
|
|
|
|
mercatorTolonlat()
|
function mercatorTolonlat(){
|
let lonlat={lon:0,lat:0};
|
|
|
let x = 13521642.21136821/20037508.34*180;
|
let y = 3584507.2560229967/20037508.34*180;
|
|
y= 180/Math.PI*(2*Math.atan(Math.exp(y*Math.PI/180))-Math.PI/2);
|
|
lonlat.lon = x;
|
lonlat.lat = y;
|
return lonlat;
|
};
|
|
</script>
|
<%--<script>--%>
|
<%-- var result;--%>
|
<%-- var department = [];--%>
|
<%-- window.onload = function () {--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: "POST",--%>
|
<%-- url: "/hxzkuwb/jiedepartment.do",--%>
|
<%-- data: {},--%>
|
<%-- dataType: "json",--%>
|
<%-- success: function (data) {--%>
|
<%-- for (var i = 0; i < data.dataList.length; i++) {--%>
|
<%-- department.push([data.dataList[i].departmentname, data.dataList[i].iconadress]);--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].label == 0) {--%>
|
<%-- $("#labela").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].achor == 0) {--%>
|
<%-- $("#anchora").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].gps == 0) {--%>
|
<%-- $("#gpsa").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].fence == 0) {--%>
|
<%-- $("#fencea").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].warning == 0) {--%>
|
<%-- $("#warninga").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].history == 0) {--%>
|
<%-- $("#historya").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].attendance == 0) {--%>
|
<%-- $("#attendancea").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].basiclnfo == 0) {--%>
|
<%-- $("#basiclnfoa").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].video == 0) {--%>
|
<%-- $("#videoa").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- if (data.dataList2[0].gas == 0) {--%>
|
<%-- $("#gasa").css({ 'display': 'none' });--%>
|
<%-- };--%>
|
<%-- },--%>
|
<%-- });--%>
|
<%-- };--%>
|
|
<%--</script>--%>
|
<!-- 常用函数 -->
|
<%--<script>--%>
|
<%-- function BezierEllipse2(ctx, x, y, a, b) {--%>
|
<%-- var k = .5522848,--%>
|
<%-- ox = a * k, // 水平控制点偏移量--%>
|
<%-- oy = b * k; // 垂直控制点偏移量</p> <p> ctx.beginPath();--%>
|
|
<%-- //从椭圆的左端点开始顺时针绘制四条三次贝塞尔曲线--%>
|
<%-- ctx.moveTo(x - a, y);--%>
|
<%-- ctx.bezierCurveTo(x - a, y - oy, x - ox, y - b, x, y - b);--%>
|
<%-- ctx.bezierCurveTo(x + ox, y - b, x + a, y - oy, x + a, y);--%>
|
<%-- ctx.bezierCurveTo(x + a, y + oy, x + ox, y + b, x, y + b);--%>
|
<%-- ctx.bezierCurveTo(x - ox, y + b, x - a, y + oy, x - a, y);--%>
|
<%-- ctx.closePath();--%>
|
<%-- ctx.stroke();--%>
|
<%-- };--%>
|
|
<%-- function getTruemap_all() {--%>
|
<%-- var map_wl = {};--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: "POST",--%>
|
<%-- url: "/hxzkuwb/qiehuanditu_option.do",--%>
|
<%-- dataType: 'json',--%>
|
<%-- data: {},--%>
|
<%-- success: function (data) {--%>
|
<%-- let tmp = new Set();--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- tmp.add(data[i].floor);--%>
|
<%-- };--%>
|
<%-- let tmpl = Array.from(tmp);--%>
|
<%-- for (i in tmpl) {--%>
|
<%-- map_wl[tmpl[i]] = [];--%>
|
<%-- }--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- map_wl[data[i].floor].push([data[i].xtruelength, data[i].ytruewidth]);--%>
|
<%-- }--%>
|
<%-- },--%>
|
<%-- });--%>
|
<%-- return map_wl;--%>
|
<%-- };--%>
|
|
<%-- function getYuandian_all() {--%>
|
<%-- var yuandian = {};--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: "POST",--%>
|
<%-- url: "/hxzkuwb/qiehuanditu_option.do",--%>
|
<%-- dataType: 'json',--%>
|
<%-- data: {},--%>
|
<%-- success: function (data) {--%>
|
|
<%-- let tmp = new Set();--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- tmp.add(data[i].floor);--%>
|
<%-- };--%>
|
<%-- let tmpl = Array.from(tmp);--%>
|
<%-- for (i in tmpl) {--%>
|
<%-- yuandian[tmpl[i]] = [];--%>
|
<%-- }--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- yuandian[data[i].floor].push([data[i].x0Length, data[i].y0Width]);--%>
|
<%-- }--%>
|
<%-- }--%>
|
<%-- });--%>
|
<%-- return yuandian;--%>
|
<%-- };--%>
|
|
<%-- function getSystemSetting() {--%>
|
<%-- var sysset = [];--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: 'GET',--%>
|
<%-- url: "/hxzkuwb/findsystem",--%>
|
<%-- dataType: 'json',--%>
|
<%-- success: function (data) {--%>
|
|
<%-- sysset = data;--%>
|
<%-- },--%>
|
<%-- });--%>
|
<%-- return sysset;--%>
|
<%-- };--%>
|
|
<%-- function loadImages(sources, callback) {--%>
|
<%-- var count = 0,--%>
|
<%-- images = {},--%>
|
<%-- imgNum = 0;--%>
|
<%-- for (src in sources) {--%>
|
<%-- imgNum++;--%>
|
<%-- }--%>
|
<%-- for (src in sources) {--%>
|
<%-- images[src] = new Image();--%>
|
|
<%-- images[src].onload = function () {--%>
|
<%-- if (++count >= imgNum) {--%>
|
<%-- callback(images);--%>
|
<%-- }--%>
|
<%-- }--%>
|
<%-- images[src].src = sources[src];--%>
|
<%-- }--%>
|
<%-- };--%>
|
|
<%-- function getTrackColor(yanse) {--%>
|
<%-- var color;--%>
|
<%-- if (yanse == "红色") {--%>
|
<%-- var color = "red";--%>
|
<%-- } else if (yanse == "绿色") {--%>
|
<%-- var color = "green";--%>
|
<%-- } else if (yanse == "蓝色") {--%>
|
<%-- var color = "blue";--%>
|
<%-- } else if (yanse == "白色") {--%>
|
<%-- var color = "white";--%>
|
<%-- } else if (yanse == "黑色") {--%>
|
<%-- } else if (yanse == "黄色") {--%>
|
<%-- var color = "yellow";--%>
|
<%-- }--%>
|
<%-- return color--%>
|
<%-- };--%>
|
|
<%-- function getExistFence_all(leixing) {--%>
|
<%-- var fencelist = {};--%>
|
<%-- var fencecolor = {};--%>
|
<%-- var fencename = {};--%>
|
<%-- var fencetype = {};--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: 'POST',--%>
|
<%-- url: "/hxzkuwb/getFloorFence_all.do",--%>
|
<%-- dataType: 'json',--%>
|
<%-- data: {},--%>
|
<%-- success: function (data) {--%>
|
<%-- let tmp = new Set();--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- tmp.add(data[i].floor);--%>
|
<%-- };--%>
|
<%-- let tmpl = Array.from(tmp);--%>
|
<%-- for (i in tmpl) {--%>
|
<%-- fencelist[tmpl[i]] = [];--%>
|
<%-- fencecolor[tmpl[i]] = [];--%>
|
<%-- fencename[tmpl[i]] = [];--%>
|
<%-- fencetype[tmpl[i]] = [];--%>
|
<%-- }--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- fencelist[data[i].floor].push(data[i].zuobiao);--%>
|
<%-- fencecolor[data[i].floor].push(data[i].color);--%>
|
<%-- fencename[data[i].floor].push(data[i].name);--%>
|
<%-- fencetype[data[i].floor].push(data[i].type);--%>
|
<%-- }--%>
|
<%-- }--%>
|
<%-- });--%>
|
<%-- if (leixing == "zuobiao") {--%>
|
<%-- return fencelist--%>
|
<%-- } else if (leixing == "color") {--%>
|
<%-- return fencecolor--%>
|
<%-- } else if (leixing == "name") {--%>
|
<%-- return fencename--%>
|
<%-- } else if (leixing == "type") {--%>
|
<%-- return fencetype--%>
|
<%-- };--%>
|
<%-- };--%>
|
|
<%-- function getDrawColor(yanse) {--%>
|
<%-- var color;--%>
|
<%-- if (yanse == "红色") {--%>
|
<%-- var color = "rgba(255,0,0,0.3)";--%>
|
<%-- } else if (yanse == "绿色") {--%>
|
<%-- var color = "rgba(0,255,0,0.3)";--%>
|
<%-- } else if (yanse == "蓝色") {--%>
|
<%-- var color = "rgba(0,0,255,0.3)";--%>
|
<%-- } else if (yanse == "白色") {--%>
|
<%-- var color = "rgba(255,255,255,0.3)";--%>
|
<%-- } else if (yanse == "黑色") {--%>
|
<%-- var color = "rgba(0,0,0,0.3)";--%>
|
<%-- }--%>
|
<%-- return color--%>
|
<%-- };--%>
|
<%-- function inFenceOrNot(fence_list, node_list) {--%>
|
<%-- //fence_list[x,y]--%>
|
<%-- //node_list[x,y]--%>
|
<%-- if (fence_list.length == 2) { //矩形--%>
|
<%-- if (node_list[0] >= Math.min(fence_list[0][0], fence_list[1][0]) && node_list[0] <= Math.max(fence_list[0][0], fence_list[1][0])) {--%>
|
<%-- if (node_list[1] >= Math.min(fence_list[0][1], fence_list[1][1]) && node_list[1] <= Math.max(fence_list[0][1], fence_list[1][1])) {--%>
|
<%-- return true //在考勤区域--%>
|
<%-- }--%>
|
<%-- }--%>
|
<%-- return false //不在考勤区域--%>
|
<%-- } else if (fence_list.length > 2) { //多边形--%>
|
<%-- for (var c = false, i = -1, l = fence_list.length, j = l - 1; ++i < l; j = i)--%>
|
<%-- ((fence_list[i][1] <= node_list[1] && node_list[1] < fence_list[j][1]) || (fence_list[j][1] <= node_list[1] && node_list[1] < fence_list[i][1]))--%>
|
<%-- && (node_list[0] < (fence_list[j][0] - fence_list[i][0]) * (node_list[1] - fence_list[i][1]) / (fence_list[j][1] - fence_list[i][1]) + fence_list[i][0])--%>
|
<%-- && (c = !c);--%>
|
<%-- return c;--%>
|
<%-- }--%>
|
<%-- };--%>
|
|
<%-- function getGas(leixing) {--%>
|
<%-- var gaslist = [];--%>
|
<%-- var gasnongdu = [];--%>
|
<%-- var gastype = [];--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: 'POST',--%>
|
<%-- url: "/hxzkoa/getGas_list.do",--%>
|
<%-- dataType: 'json',--%>
|
<%-- data: {},--%>
|
<%-- success: function (data) {--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- gaslist.push([data[i].x, data[i].y]);--%>
|
<%-- gasnongdu.push(data[i].nong_du);--%>
|
<%-- gastype.push(data[i].gas_type);--%>
|
<%-- }--%>
|
<%-- }--%>
|
<%-- });--%>
|
<%-- if (leixing == "zuobiao") {--%>
|
<%-- return gaslist--%>
|
<%-- } else if (leixing == "type") {--%>
|
<%-- return gastype--%>
|
<%-- } else if (leixing == "nongdu") {--%>
|
<%-- return gasnongdu--%>
|
<%-- };--%>
|
<%-- };--%>
|
|
<%-- function getRealPosition(current_floor) {--%>
|
<%-- var realposition = [];--%>
|
<%-- $.ajax({--%>
|
<%-- async: false,--%>
|
<%-- type: 'POST',--%>
|
<%-- url: "/hxzkuwb/getRealPosition.do",--%>
|
<%-- dataType: 'json',--%>
|
<%-- data: {--%>
|
<%-- floor: current_floor,--%>
|
<%-- },--%>
|
<%-- success: function (data) {--%>
|
<%-- for (var i = 0; i < data.length; i++) {--%>
|
<%-- //playMark[id,name,power,life,x,y,time]--%>
|
<%-- realposition.push([data[i].ptagid, data[i].pname, data[i].ppower, data[i].ponline, data[i].px, data[i].py, data[i].paddtiem, data[i].pfence == 1 || data[i].psos == 1, data[i].psousuo, data[i].pshipin, data[i].pdepartment, data[i].baoliu22,data[i].bumencolor])--%>
|
<%-- }--%>
|
<%-- },--%>
|
<%-- });--%>
|
<%-- return realposition--%>
|
<%-- };--%>
|
|
<%-- // function str_to_time(str) {--%>
|
<%-- // //根据字符串转换成对应的时间(秒)--%>
|
<%-- // if (str == "不显示实时轨迹") {--%>
|
<%-- // return 0;--%>
|
<%-- // } else if (str == "10秒钟") {--%>
|
<%-- // return 10;--%>
|
<%-- // } else if (str == "30秒钟") {--%>
|
<%-- // return 30;--%>
|
<%-- // } else if (str == "1分钟") {--%>
|
<%-- // return 60;--%>
|
<%-- // } else if (str == "10分钟") {--%>
|
<%-- // return 600;--%>
|
<%-- // } else if (str == "30分钟") {--%>
|
<%-- // return 1800;--%>
|
<%-- // } else if (str == "1小时") {--%>
|
<%-- // return 3600;--%>
|
<%-- // };--%>
|
<%-- // };--%>
|
|
<%-- // function getTracknow(current_floor, tagid_str, time) {--%>
|
<%-- // var finalrealtrack = {};--%>
|
<%-- // $.ajax({--%>
|
<%-- // async: false,--%>
|
<%-- // type: 'POST',--%>
|
<%-- // url: "/hxzkuwb/getRealTrack.do",--%>
|
<%-- // dataType: 'json',--%>
|
<%-- // data: {--%>
|
<%-- // time: time,--%>
|
<%-- // floor: current_floor,--%>
|
<%-- // tagid: tagid_str,--%>
|
<%-- // },--%>
|
<%-- // success: function (data) {--%>
|
<%-- // for (var i = 0; i < data.length; i++) {--%>
|
<%-- // finalrealtrack[data[i][0].tagid] = [];--%>
|
<%-- // for (var j = 0; j < data[i].length; j++) {--%>
|
<%-- // finalrealtrack[data[i][0].tagid].push([data[i][j].x, data[i][j].y, data[i][j].time])--%>
|
<%-- // }--%>
|
<%-- // }--%>
|
<%-- // },--%>
|
<%-- // });--%>
|
<%-- // return finalrealtrack;--%>
|
<%-- // };--%>
|
|
<%-- // function getAnchorInfo_all() {--%>
|
<%-- // var anchorList_on = {};--%>
|
<%-- // var anchorList_off = {};--%>
|
<%-- // $.ajax({--%>
|
<%-- // async: false,--%>
|
<%-- // type: 'POST',--%>
|
<%-- // url: "/hxzkuwb/getAnchorInfo_all.do",--%>
|
<%-- // dataType: 'json',--%>
|
<%-- // data: {},--%>
|
<%-- // success: function (data) {--%>
|
<%-- // let tmp = new Set();--%>
|
<%-- // for (var i = 0; i < data.length; i++) {--%>
|
<%-- // tmp.add(data[i].layer);--%>
|
<%-- // };--%>
|
<%-- // let tmpl = Array.from(tmp);--%>
|
<%-- // for (i in tmpl) {--%>
|
<%-- // anchorList_on[tmpl[i]] = [];--%>
|
<%-- // anchorList_off[tmpl[i]] = [];--%>
|
<%-- // }--%>
|
<%-- // for (var i = 0; i < data.length; i++) {--%>
|
<%-- // if (data[i].anchormode == "1") {--%>
|
<%-- // anchorList_on[data[i].layer].push([data[i].anchorid, data[i].posx, data[i].posy, data[i].posz, data[i].greatetime]);--%>
|
<%-- // } else if (data[i].anchormode == "0") {--%>
|
<%-- // anchorList_off[data[i].layer].push([data[i].anchorid, data[i].posx, data[i].posy, data[i].posz, data[i].greatetime]);--%>
|
<%-- //--%>
|
<%-- // }--%>
|
<%-- // }--%>
|
<%-- // }--%>
|
<%-- // });--%>
|
<%-- // return [anchorList_on, anchorList_off]--%>
|
<%-- // };--%>
|
|
<%-- /**该方法用来绘制一个有填充色的圆角矩形--%>
|
<%-- *@param cxt:canvas的上下文环境--%>
|
<%-- *@param x:左上角x轴坐标--%>
|
<%-- *@param y:左上角y轴坐标--%>
|
<%-- *@param width:矩形的宽度--%>
|
<%-- *@param height:矩形的高度--%>
|
<%-- *@param radius:圆的半径--%>
|
<%-- *@param fillColor:填充颜色--%>
|
<%-- **/--%>
|
<%-- function fillRoundRect(cxt, x, y, width, height, radius, /*optional*/ fillColor) {--%>
|
<%-- //圆的直径必然要小于矩形的宽高--%>
|
<%-- if (2 * radius > width || 2 * radius > height) { return false; }--%>
|
|
<%-- cxt.save();--%>
|
<%-- cxt.translate(x, y);--%>
|
<%-- //绘制圆角矩形的各个边--%>
|
<%-- drawRoundRectPath(cxt, width, height, radius);--%>
|
<%-- cxt.fillStyle = fillColor || "#000"; //若是给定了值就用给定的值否则给予默认值--%>
|
<%-- cxt.fill();--%>
|
<%-- cxt.restore();--%>
|
<%-- }--%>
|
|
<%-- function drawRoundRectPath(cxt, width, height, radius) {--%>
|
<%-- cxt.beginPath(0);--%>
|
<%-- //从右下角顺时针绘制,弧度从0到1/2PI--%>
|
<%-- cxt.arc(width - radius, height - radius, radius, 0, Math.PI / 2);--%>
|
|
<%-- //矩形下边线--%>
|
<%-- cxt.lineTo(radius, height);--%>
|
<%-- //左下角圆弧,弧度从1/2PI到PI--%>
|
<%-- cxt.arc(radius, height - radius, radius, Math.PI / 2, Math.PI);--%>
|
|
<%-- //矩形左边线--%>
|
<%-- cxt.lineTo(0, radius);--%>
|
|
<%-- //左上角圆弧,弧度从PI到3/2PI--%>
|
<%-- cxt.arc(radius, radius, radius, Math.PI, Math.PI * 3 / 2);--%>
|
|
<%-- //上边线--%>
|
<%-- cxt.lineTo(width - radius, 0);--%>
|
|
<%-- //右上角圆弧--%>
|
<%-- cxt.arc(width - radius, radius, radius, Math.PI * 3 / 2, Math.PI * 2);--%>
|
|
<%-- //右边线--%>
|
<%-- cxt.lineTo(width, height - radius);--%>
|
<%-- cxt.closePath();--%>
|
<%-- }--%>
|
<%--</script>--%>
|
<!-- 常用函数结束 -->
|
|
<!-- > END PAGE FUNCTION SCRIPTS -->
|
<!-- > END PAGE FUNCTION SCRIPTS -->
|
|
<script>
|
function FindShowJiZhan() {
|
var realposition = [];
|
$.ajax({
|
async: false,
|
type: 'Get',
|
url: "/hxzkuwb/FindSanWeiJiZhan",
|
dataType: 'json',
|
success: function (data) {
|
realposition = data;
|
},
|
});
|
return realposition
|
};
|
|
function FindShowWangGuan() {
|
var realposition = [];
|
$.ajax({
|
async: false,
|
type: 'Get',
|
url: "/hxzkuwb/FindGateWayList",
|
dataType: 'json',
|
success: function (data) {
|
realposition = data;
|
},
|
});
|
return realposition
|
};
|
|
|
//显示更多
|
function ello(){
|
var td = $("#ello").css("display");
|
if(td == "block"){
|
$("#ello").fadeOut(600)
|
$("#topbottom").fadeOut(600)
|
}else{
|
$("#ello").fadeIn(600)
|
$("#topbottom").fadeIn(600)
|
}
|
|
}
|
|
var showData = "username="+localStorage.getItem("username")
|
$.get("/hxzkuwb/findScreenRole",showData,function (data){
|
if (data.jizhanshow == "1"){
|
document.getElementById("showJiZhan").checked = true;
|
}
|
if (data.wangguanshow == "1"){
|
document.getElementById("ShowWangGuan").checked = true;
|
}
|
if (sessionStorage.getItem("PerCircles") == "Yes"){
|
document.getElementById("JuJiXianShi").checked = true
|
}else{
|
document.getElementById("JuJiXianShi").checked = false
|
}
|
})
|
|
|
function showWangGuan(){
|
var flag = document.getElementById("ShowWangGuan")
|
var wangguanshow;
|
if (flag.checked) {
|
//设置网关显示
|
wangguanshow = "1";
|
localStorage.setItem("wangguanshow","1")
|
} else {
|
//设置网关隐藏
|
wangguanshow = "0";
|
localStorage.setItem("wangguanshow","0")
|
}
|
var data = "wangguanshow="+wangguanshow;
|
$.get("/hxzkuwb/upScreenSheZhi",data,function (data){
|
|
})
|
}
|
function showJiZhan(){
|
var flag = document.getElementById("showJiZhan")
|
var jizhanshow;
|
if (flag.checked) {
|
//设置基站显示
|
jizhanshow = "1";
|
localStorage.setItem("jizhanshow","1")
|
} else {
|
//设置基站隐藏
|
jizhanshow = "0";
|
localStorage.setItem("jizhanshow","0")
|
}
|
var data = "jizhanshow="+jizhanshow;
|
$.get("/hxzkuwb/upScreenSheZhi",data,function (data){
|
|
})
|
}
|
function QuYuKuangXuan(){
|
var flag = document.getElementById("QuYuKuangXuan")
|
if (flag.checked) {
|
//开启区域框选
|
sessionStorage.setItem("QuYuKuangXuan","1")
|
sessionStorage.setItem("kqhuizhi",true)
|
} else {
|
//关闭区域框选
|
sessionStorage.setItem("QuYuKuangXuan","0")
|
sessionStorage.setItem("kqhuizhi","false1")
|
}
|
}
|
function JuJiXianShi(){
|
var flag = document.getElementById("JuJiXianShi")
|
if (flag.checked) {
|
//开启聚集显示
|
sessionStorage.setItem("PerCircles","Yes")
|
} else {
|
//关闭聚集显示
|
sessionStorage.setItem("PerCircles","No")
|
|
}
|
}
|
|
function showLiXian(){
|
var flag = document.getElementById("ShowLiXianes")
|
if (flag.checked) {
|
//开启离线显示
|
sessionStorage.setItem("oNLine","Yes")
|
onLine = 1;
|
} else {
|
//关闭离线显示
|
sessionStorage.setItem("oNLine","No")
|
onLine = 0;
|
|
}
|
}
|
sessionStorage.setItem("oNLine","No")
|
|
|
|
|
|
// $.get("/hxzkuwb/findMapShow",function (data){
|
// // $(".MapShow").append('<li id="topbottom" style="display: none;"><img src="HomeImg/tobottom.png" style="width:3%"></li>')
|
// $(".MapShow").append('<li style="width: 40%;display: inline-block"><a href="javascript:;" onClick="yckb()" style="display: inline-block;font-size: 12px;color: '+data[0].coolr+'" id="ykcbs"><img src="/hxzkuwb/Icon/隐藏看板.png" alt="隐藏看板" title="隐藏看板" style="width: 20%"></a><span style="color: #07F4F6">隐藏看板</span></li>')
|
// if(data[0].ishow == "显示"){
|
// $(".MapShow").append('<li style="width: 40%;display: inline-block" id="maps"><input type="checkbox" id="sanweis" onClick="Qh1()" style="display: none;position: relative;top: 2px"/><a href="javascript:;" class="ts1" style="font-size: 12px;color: #07F4F6" onClick="Qh1()" id="qh1"><img src="/hxzkuwb/Icon/3D地图.png" title="切换地图" alt="切换地图" style="width: 20%"></a><br><span style="color: #07F4F6">三维地图</span></li>')
|
// }else{
|
// Qh()
|
// }
|
// if(data[1].ishow == "显示"){
|
//
|
// }
|
// $(".MapShow").append('<li onclick="ello()" style="margin-left: 3%;cursor:pointer;display: inline-block;color: #07F4F6 "><img src="/hxzkuwb/Icon/查看更多.png" title="更多操作" style="width: 20%" alt="更多操作"><br>更多操作</li>')
|
// })
|
|
|
function Cxgj(){
|
$("#cxgjs").fadeOut(500)
|
}
|
var table = layui.table;
|
function ChongDianPower(){
|
$("#fen1").toggle()
|
$("#PowerShuaXin").toggle()
|
layer.msg('操作成功')
|
}
|
function ChongDianPowerShuaXin(){
|
table.reload('PowerPerson', {
|
url: '/hxzkuwb/findPowerPerson' // 新的数据接口地址
|
});
|
$("#fen1").toggle()
|
setTimeout(function (){
|
$("#fen1").toggle()
|
},300)
|
layer.msg('刷新成功')
|
}
|
</script>
|
</html>
|