You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
354 lines
13 KiB
354 lines
13 KiB
<#include "../_include/_t.ftl"/>
|
|
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>${p['title']}${p['version']}</title>
|
|
<!--<link rel="shortcut icon" href="${ctx}/favicon.ico" type="image/x-icon"/>-->
|
|
<#include "../_include/_h.ftl"/>
|
|
<#include "../_include/_l.ftl"/>
|
|
<#include "../_include/_j.ftl"/>
|
|
<#include "../_include/_e.ftl"/>
|
|
<#include "../_include/_c_1.ftl"/>
|
|
<#include "../_include/_boc.ftl"/>
|
|
<#include "../_include/_index_1.ftl"/>
|
|
<script type="text/javascript" src="${ctx}/js/mqttws31.js"></script>
|
|
<script type="text/javascript" src="${ctx}/js/iotpush.js"></script>
|
|
<script type="text/javascript" src="${ctx}/js/remsg.js"></script>
|
|
<link href="${ctx}/style/BOC/css/css.css" type="text/css" rel="stylesheet"/>
|
|
</head>
|
|
<body>
|
|
<!-- 菜单 start -->
|
|
<div class="menu" style="top: 0;">
|
|
<!-- <ul class="clearfix">
|
|
<li url="${ctx}/index/data1" on="0" class="menu_fl selected" style="margin-left: 36px;">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon1.png">首页</div>
|
|
</li>
|
|
<li url="${ctx}/work1/madin" on="0" class="menu_fl">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon2.png">消防管理</div>
|
|
</li>
|
|
<li url="${ctx}/bdata/bdata/大数据/1" on="0" class="menu_fl">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon3.png">大数据</div>
|
|
</li>
|
|
<li url="${ctx}/work/edit/edit/系统设置/1" on="0" class="menu_fr" style="margin-right: 36px;">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon6.png">系统设置</div>
|
|
</li>
|
|
<li url="${ctx}/gis/index" on="1" class="menu_fr">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon5.png">三维可视化</div>
|
|
</li>
|
|
<li url="${ctx}/rms" on="0" class="menu_fr">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon4.png">物联网</div>
|
|
</li>
|
|
</ul> -->
|
|
<ul class="clearfix">
|
|
<li url="${ctx}/index/main1" on="0" class="menu_fl" style="margin-left: 36px;">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon1.png">首页</div>
|
|
</li>
|
|
<li url="${ctx}/rms" on="0" class="menu_fl">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon4.png">物联网监测</div>
|
|
</li>
|
|
<li id="wbxc" url="${ctx}/work1/madin" on="0" class="menu_fl">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon2.png">维保巡查</div>
|
|
</li>
|
|
<!-- <li url="#" on="0" class="menu_fl">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon3.png">大数据</div>
|
|
</li> -->
|
|
<li url="${ctx}/work/edit/edit/1/系统设置/1" on="0" class="menu_fr" style="margin-right: 36px;">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon6.png">系统设置</div>
|
|
</li>
|
|
<li on="0" url="${ctx}/bdata/bdata/大数据/1" class="menu_fr">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon5.png">统计分析</div>
|
|
</li>
|
|
<#if manager_user['usersUid'] == 'zgyhlczh'>
|
|
<li url="http://47.104.236.109:8061/index.html" on="0" class="menu_fr">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon4.png">三维可视化</div>
|
|
</li>
|
|
<#else>
|
|
<li url="http://${znfxUrl}" on="2" class="menu_fr">
|
|
<div><img src="${ctx}/style/cls1/img/menu-icon4.png">智能分析</div>
|
|
</li>
|
|
</#if>
|
|
</ul>
|
|
<div class="dropdown">
|
|
<a class="dropbtn"><img src="${ctx}/style/cls1/img/menu-icon7.png"></a>
|
|
<div class="dropdown-content">
|
|
<span></span>
|
|
<a id="show_own"><img src="${ctx}/style/cls1/img/yonghu-icon1.png">个人资料</a>
|
|
<a id="show_pwd"><img src="${ctx}/style/cls1/img/yonghu-icon2.png">修改密码</a>
|
|
<a id="show_out"><img src="${ctx}/style/cls1/img/yonghu-icon3.png">退出登录</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<!-- 菜单 end -->
|
|
<!-- 头部 start -->
|
|
<div class="header" style="top: 0;">
|
|
<div class="logo"><img src="${ctx}/style/cls1/img/logo.png"></div>
|
|
</div>
|
|
<div style="z-index: 0; position: absolute;top: 79px;width: 732px;height: 52px; color: #b5e0ff;font-size: 16px;">
|
|
<div style="width: 217px;height: 30px;float: left;margin-left: 77px;margin-top: 10px;">
|
|
<span>${.now?string('yyyy-MM-dd')}</span>
|
|
<span id="theClock"></span>
|
|
</div>
|
|
<!-- <iframe scrolling="no" style="margin-top: 10px;"
|
|
src="https://tianqiapi.com/api.php?style=tq&skin=pear&color=b5e0ff&fontsize=14&align=center" frameborder="0" width="80%" height="24" allowtransparency="true"></iframe> -->
|
|
<iframe id="weather" scrolling="no" style="margin-top: 10px;" frameborder="0" width="400px" height="30" allowtransparency="true"></iframe>
|
|
</div>
|
|
<div class="sy-tzgg fr" id="tzggclick" style="cursor:pointer">
|
|
<div class="sy-tzgg-icon fl">
|
|
<img src="${ctx}/style/index/img/tzgg-icon.png">
|
|
</div>
|
|
<div class="fl ml-10">通知</div>
|
|
</div>
|
|
<div class="unit"
|
|
style="z-index: 0; position: absolute; right: 0px; top: 79px;">
|
|
<div>
|
|
<img src="${ctx}/style/BOC/img/unit-icon.png" width="20"><span id="soc_addr" style="margin-left: 5px;"></span>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 头部 end -->
|
|
<div class="content">
|
|
<iframe id="index_main_0" style="border: 0px;width: 100%;height:calc(100vh - 120px);" src="${ctx}/index/main1"></iframe>
|
|
<!--<iframe id="index_main_0" style="border: 0px;width: 100%;height:calc(100vh - 120px);" src="${ctx}/bdata/bdata/大数据/1"></iframe> -->
|
|
</div>
|
|
<iframe id="index_main_1" style="display:none;border: 0px;width: 100%;height:100vh;z-index:1;position: absolute;top: 0; " src=""></iframe>
|
|
<script type="text/javascript">
|
|
var tk;
|
|
var xx;
|
|
var sb = $("#index_main_0")[0];
|
|
layuiplus.on(function(){
|
|
layuiplus.init(0);
|
|
|
|
var days = new Array("日", "一", "二", "三", "四", "五", "六");
|
|
showDT();
|
|
function showDT() {
|
|
var currentDT = new Date();
|
|
var y, m, date, day, hs, ms, ss, theDateStr;
|
|
y = currentDT.getFullYear(); //四位整数表示的年份
|
|
m = currentDT.getMonth(); //月
|
|
date = currentDT.getDate(); //日
|
|
day = currentDT.getDay(); //星期
|
|
hs = currentDT.getHours(); //时
|
|
ms = currentDT.getMinutes(); //分
|
|
ss = currentDT.getSeconds(); //秒
|
|
theDateStr = hs + ":" + ms + ":" + ss + " 星期" + days[day];
|
|
document.getElementById("theClock").innerHTML = theDateStr;
|
|
// setTimeout 在执行时,是在载入后延迟指定时间后,去执行一次表达式,仅执行一次
|
|
window.setTimeout(showDT, 1000);
|
|
}
|
|
|
|
|
|
$("ul[class='clearfix'] > li").each(function(){
|
|
var _this = $(this);
|
|
_this.click(function(){
|
|
var _url = _this.attr("url");
|
|
var _on = _this.attr("on");
|
|
if(_on == '0'){
|
|
$(".content").show();
|
|
$("#index_main_1").hide();
|
|
$("#index_main_0").attr("src",_url);
|
|
$("#index_main_1").attr("src","");
|
|
$(this).siblings().removeClass("selected");
|
|
$(this).addClass("selected");
|
|
}
|
|
if(_on == '1'){
|
|
$(".content").hide();
|
|
$("#index_main_1").show();
|
|
$("#index_main_1").attr("src",_url);
|
|
$(this).siblings().removeClass("selected");
|
|
$(this).addClass("selected");
|
|
}
|
|
if(_on == '2'){
|
|
var _u = "http://"+window.location.host.split(":")[0]+"${rmsUrl}/?IOTP=ZNFX";
|
|
$(".content").show();
|
|
$("#index_main_1").hide();
|
|
$("#index_main_0").attr("src",_u);
|
|
$("#index_main_1").attr("src","");
|
|
$(this).siblings().removeClass("selected");
|
|
$(this).addClass("selected");
|
|
}
|
|
});
|
|
});
|
|
|
|
|
|
$("#show_pwd").click(function(e){
|
|
//var x = e.originalEvent.x || e.originalEvent.layerX || 0;
|
|
//var y = e.originalEvent.y || e.originalEvent.layerY || 0;
|
|
layer.open({
|
|
type:1,
|
|
title:false,
|
|
closeBtn:false,
|
|
//offset:[y,x],
|
|
area:"auto",
|
|
shade:0.3,
|
|
//id:''//设定一个id,防止重复弹出
|
|
btn:["提交新密码","取消"],
|
|
btnAlign:"c",
|
|
//move:true,//false关闭拖拽/默认.layui-layer-title可不写
|
|
content:"<div style=\"padding:10px;line-height:22px;color:#fff;font-weight:300;font-size:16px;\"><input type=\"password\" id=\"npwd\" class=\"layui-input\" placeholder=\"请输入您的新密码\" autocomplete=\"off\" style=\"font-size:16px;height:30px;line-height:30px;text-align:center;\"/></div>",
|
|
yes:function(index,layero){
|
|
var npwd = $("#npwd").val();
|
|
if(npwd == ""){
|
|
$("#npwd").focus();
|
|
return false;
|
|
}
|
|
$.ajax({
|
|
type:"get",
|
|
url:ctx+"/pwd",
|
|
data:{usersPwd:npwd},
|
|
dataType:"json",
|
|
success:function(data){
|
|
if(data.status == true){
|
|
layer.close(index);
|
|
layer.msg("新密码修改成功",{time:2000});
|
|
}
|
|
}
|
|
});
|
|
}
|
|
});
|
|
});
|
|
$("#show_own").click(function(e){
|
|
var _html = "<div style=\"padding:10px;color:#fff;font-weight:300;\">"+
|
|
"<input type=\"text\" id=\"index_newUsersName\" placeholder=\"姓名\" class=\"layui-input\" style=\"width:360px;margin-bottom:20px;\"/>"+
|
|
"<input type=\"text\" id=\"index_newUsersTel\" placeholder=\"电话\" class=\"layui-input\" style=\"width:360px;margin-bottom:20px;\"/>"+
|
|
"<input type=\"text\" id=\"index_newUsersEmail\" placeholder=\"邮箱\" class=\"layui-input\" style=\"width:360px;\"/>"+
|
|
"</div>";
|
|
layer.open({
|
|
type:1,
|
|
title:false,
|
|
closeBtn:false,
|
|
//offset:"r",
|
|
area:["420px","auto"],
|
|
shade:0.3,
|
|
//id:''//设定一个id,防止重复弹出
|
|
btn:["确定","取消"],
|
|
btnAlign:"c",
|
|
content:_html,
|
|
success:function(){
|
|
$.ajax({
|
|
type:"get",
|
|
url:ctx+"/own/0",
|
|
data:{usersUid:"${manager_user['usersUid']}"},
|
|
dataType:"json",
|
|
success:function(data){
|
|
$("#index_newUsersName").val(data.usersName);
|
|
$("#index_newUsersTel").val(data.tel);
|
|
$("#index_newUsersEmail").val(data.email);
|
|
}
|
|
});
|
|
},
|
|
yes:function(index){
|
|
var usersName = $("#index_newUsersName");
|
|
if(usersName.val() == ""){
|
|
usersName.focus();
|
|
layer.tips("<span style='color:#000000;'>请输入姓名</span>","#index_newUsersName",{tips:[2,'#ffffff']});
|
|
return false;
|
|
}
|
|
var usersTel = $("#index_newUsersTel");
|
|
if(usersTel.val() == ""){
|
|
usersTel.focus();
|
|
layer.tips("<span style='color:#000000;'>请输入电话</span>","#index_newUsersTel",{tips:[2,'#ffffff']});
|
|
return false;
|
|
}
|
|
var usersEmail = $("#index_newUsersEmail");
|
|
if(usersEmail.val() == ""){
|
|
usersEmail.focus();
|
|
layer.tips("<span style='color:#000000;'>请输入邮箱</span>","#index_newUsersEmail",{tips:[2,'#ffffff']});
|
|
return false;
|
|
}
|
|
$.ajax({
|
|
type:"get",
|
|
url:ctx+"/own/1",
|
|
data:{usersUid:$("#index_newUsersUid").val(),usersName:usersName.val(),tel:usersTel.val(),email:usersEmail.val()},
|
|
dataType:"json",
|
|
success:function(data){
|
|
if(data.status == true){
|
|
$("#index_work_name1").html(usersName.val());
|
|
$("#index_work_name2").html(usersName.val());
|
|
layer.msg("修改成功",{time:2000});
|
|
layer.close(index);
|
|
|
|
}
|
|
}
|
|
});
|
|
}
|
|
});
|
|
});
|
|
$("#show_out").click(function(){
|
|
layer.open({
|
|
type:1,
|
|
title:false,
|
|
closeBtn:false,
|
|
area:"auto",
|
|
shade:0.3,
|
|
//id:''//设定一个id,防止重复弹出
|
|
btn:["确定","取消"],
|
|
btnAlign:"c",
|
|
//move:true,//false关闭拖拽/默认.layui-layer-title可不写
|
|
content:"<div style=\"padding:10px;line-height:22px;color:#fff;font-weight:300;font-size:16px;\">退出云平台?<br/><br/>点击“确定”退出,否者点击“取消”返回。<br/><br/>确定退出?</div>",
|
|
yes:function(index,layero){
|
|
//跳转退出
|
|
window.location.href = ctx+"/unsignin";
|
|
}
|
|
});
|
|
});
|
|
$("#tzggclick").click(function(){
|
|
$(".content").show();
|
|
$("#index_main_1").hide();
|
|
$("#index_main_0").attr("src","${ctx}/work1/madin");
|
|
$("#index_main_1").attr("src","");
|
|
$(this).siblings().removeClass("selected");
|
|
$(this).addClass("selected");
|
|
$("#wbxc").addClass("selected");
|
|
});
|
|
startMqttServer("${manager_user['groupId']}");
|
|
|
|
tk = function(data,DEVICE_SN,ALARM_REASONNAME,ADDR,ALARM_TIME){
|
|
if(xx != null){
|
|
$("#indexXx").html(data);
|
|
}else{
|
|
xx = layer.open({
|
|
type:1,
|
|
title:false,
|
|
closeBtn:true,
|
|
id:"indexXx",
|
|
area:["auto","300px"],
|
|
anim:2,
|
|
title:"消息提示",
|
|
shade:0,
|
|
//id:''//设定一个id,防止重复弹出
|
|
offset: 'rb',
|
|
//move:true,//false关闭拖拽/默认.layui-layer-title可不写
|
|
content:data,
|
|
cancel: function(index, layero){
|
|
xx = null;
|
|
}
|
|
});
|
|
}
|
|
//var arr = '<span>${manager_user["groupName"]}</span>报警设备:'+DEVICE_SN+' 报警原因:'+ALARM_REASONNAME+' 位置:'+ADDR+' 时间:'+ALARM_TIME;
|
|
var arr = '时间:'+ALARM_TIME+',安装位置:'+ADDR+',报警原因:'+ALARM_REASONNAME+',报警设备:'+DEVICE_SN;
|
|
sb.contentWindow.pushData(arr);
|
|
}
|
|
|
|
//自动匹配当前账号的位置 显示天气信息
|
|
// var city = "${manager_user['regionVal']}";
|
|
// var _city;
|
|
// if(city.length > 2){
|
|
// _city = city.replace("县", "").replace("区", "").replace("市", "");
|
|
// }else{
|
|
// _city = city;
|
|
// }
|
|
// $("#weather").attr("src", "https://tianqiapi.com/api.php?style=tz&skin=pear&color=b5e0ff&fontsize=16&align=center&city="+_city);
|
|
$("#weather").attr("src", "https://tianqiapi.com/api.php?style=tz&skin=pear&color=b5e0ff&fontsize=16&align=center");
|
|
|
|
//针对于右上角单位显示名称超出范围
|
|
var group_name = "${manager_user['groupName']}";
|
|
if(group_name != null && group_name.length > 13){
|
|
group_name = group_name.substring(0,13) + "...";
|
|
}
|
|
$("#soc_addr").html(group_name);
|
|
$("#soc_addr").attr("title", "${manager_user['groupName']}");
|
|
})
|
|
|
|
</script>
|
|
</body>
|
|
</html>
|