Commit b9d94a67 authored by wangjinjing's avatar wangjinjing

事件,工程添加告警提醒弹窗提醒

parent 8d197cd0
...@@ -14,7 +14,7 @@ datasource.druid.validationQuery=SELECT 'x' FROM DUAL ...@@ -14,7 +14,7 @@ datasource.druid.validationQuery=SELECT 'x' FROM DUAL
# 格式为:ip地址:端口:用户名:密码 # 格式为:ip地址:端口:用户名:密码
# 端口号一定要写,例如:192.168.2.100:21:reader:reader # 端口号一定要写,例如:192.168.2.100:21:reader:reader
ftp.host=localhost:21:hzjt:1qaz2wsx ftp.host=33.65.250.179:21:hzjt:1qaz2wsx
alarm.subscribe.data.key=gs:traff:alarmlist alarm.subscribe.data.key=gs:traff:alarmlist
...@@ -39,6 +39,6 @@ gs.traff.cloud.department.fileagent.url=http://33.50.1.22:8888/agent/fileAgent?f ...@@ -39,6 +39,6 @@ gs.traff.cloud.department.fileagent.url=http://33.50.1.22:8888/agent/fileAgent?f
alarmrecord.check.push.recordtype=1 alarmrecord.check.push.recordtype=1
eventsend.url=http://localhost:8089/sendEvents eventsend.url=http://33.65.250.179:8089/sendEvents
devicesend.url=http://localhost:8089/traffdevicewriteresult/sendDevices devicesend.url=http://33.65.250.179:8089/traffdevicewriteresult/sendDevices
devicesend.timeout=1000 devicesend.timeout=1000
\ No newline at end of file
...@@ -210,7 +210,7 @@ public class LoginController { ...@@ -210,7 +210,7 @@ public class LoginController {
HttpHeaders headers = new HttpHeaders(); HttpHeaders headers = new HttpHeaders();
headers.setContentType(MediaType.APPLICATION_JSON_UTF8); headers.setContentType(MediaType.APPLICATION_JSON_UTF8);
HttpEntity<String> requestEntity = new HttpEntity<>(message, headers); HttpEntity<String> requestEntity = new HttpEntity<>(message, headers);
return restTemplate.postForObject("http://localhost:" + 8089 + "/alarmevent", requestEntity, ResultObj.class); return restTemplate.postForObject("http://33.65.250.179:" + 8089 + "/alarmevent", requestEntity, ResultObj.class);
} }
......
...@@ -2,12 +2,12 @@ spring.profiles.active=dev ...@@ -2,12 +2,12 @@ spring.profiles.active=dev
server.port=8082 server.port=8082
#spring.datasource.username=hzjt spring.datasource.username=hzjt
#spring.datasource.password=hzjt spring.datasource.password=hzjt
#spring.datasource.url=jdbc:oracle:thin:@localhost:1521:helowin spring.datasource.url=jdbc:oracle:thin:@33.65.250.179:1521:helowin
spring.datasource.username=test #spring.datasource.username=test
spring.datasource.password=test #spring.datasource.password=test
spring.datasource.url=jdbc:oracle:thin:@192.168.168.212:1523:helowin #spring.datasource.url=jdbc:oracle:thin:@192.168.168.212:1523:helowin
spring.datasource.driver-class-name=oracle.jdbc.OracleDriver spring.datasource.driver-class-name=oracle.jdbc.OracleDriver
# ��ʼ����С����С����� # ��ʼ����С����С�����
...@@ -30,7 +30,7 @@ spring.jackson.date-format=yyyy-MM-dd HH:mm:ss ...@@ -30,7 +30,7 @@ spring.jackson.date-format=yyyy-MM-dd HH:mm:ss
spring.jackson.time-zone=GMT+8 spring.jackson.time-zone=GMT+8
# #
#spring.redis.host=localhost #spring.redis.host=localhost
spring.redis.host=127.0.0.1 spring.redis.host=33.65.250.179
spring.redis.port=6379 spring.redis.port=6379
spring.cache.type=redis spring.cache.type=redis
spring.cache.redis.time-to-live=600000 spring.cache.redis.time-to-live=600000
...@@ -67,9 +67,9 @@ spring.devtools.restart.exclude=static/**,public/** ...@@ -67,9 +67,9 @@ spring.devtools.restart.exclude=static/**,public/**
managername=admin managername=admin
devicesend.url=http://localhost:8089/traffdevicewriteresult/sendDevices devicesend.url=http://33.65.250.179:8089/traffdevicewriteresult/sendDevices
devicesend.timeout=1000 devicesend.timeout=1000
flvurl=http://localhost:8089/getflv flvurl=http://33.65.250.179:8089/getflv
json.resisurl=http://33.50.1.21:57081/record/ecvs json.resisurl=http://33.50.1.21:57081/record/ecvs
qingzhi.devicewrite.url=http://33.50.1.213:38080/api/jtldpt/impld/deviceWrite qingzhi.devicewrite.url=http://33.50.1.213:38080/api/jtldpt/impld/deviceWrite
...@@ -78,8 +78,8 @@ qingzhi.devicewrite.timeout=5000 ...@@ -78,8 +78,8 @@ qingzhi.devicewrite.timeout=5000
qingzhi.eventwrite.url=http://33.50.1.213:38080/api/jtldpt/impld/trafficEventWrite qingzhi.eventwrite.url=http://33.50.1.213:38080/api/jtldpt/impld/trafficEventWrite
qingzhi.eventwrite.timeout=5000 qingzhi.eventwrite.timeout=5000
eventsend.url=http://localhost:8089/sendEvents eventsend.url=http://33.65.250.179:8089/sendEvents
pushrecordurl=localhost:8089/sendtouser pushrecordurl=33.65.250.179:8089/sendtouser
ipstrs=33.55.1.85,33.55.1.86,33.55.1.87,33.55.1.88,33.55.1.89,33.55.1.90,33.55.1.91,33.55.1.92,33.55.1.93,33.55.1.94,33.55.1.95,33.55.1.96,33.51.6.97,33.60.1.7,33.54.3.240,33.53.1.171,33.52.1.222,33.61.1.23,33.57.1.22 ipstrs=33.55.1.85,33.55.1.86,33.55.1.87,33.55.1.88,33.55.1.89,33.55.1.90,33.55.1.91,33.55.1.92,33.55.1.93,33.55.1.94,33.55.1.95,33.55.1.96,33.51.6.97,33.60.1.7,33.54.3.240,33.53.1.171,33.52.1.222,33.61.1.23,33.57.1.22
ipurl=:8001/api/traffic-incident/restartAutoRule ipurl=:8001/api/traffic-incident/restartAutoRule
\ No newline at end of file
...@@ -1249,7 +1249,7 @@ let arr_right_s = []; ...@@ -1249,7 +1249,7 @@ let arr_right_s = [];
//websocket连接 //websocket连接
let d = new Date().getTime(); let d = new Date().getTime();
let web_ip = "ws:/localhost:8089/websocket/" + d; let web_ip = "ws:/33.65.250.179:8089/websocket/" + d;
let wss = new WebSocket(web_ip); let wss = new WebSocket(web_ip);
wss.onopen = function () { wss.onopen = function () {
console.log("连接成功"); console.log("连接成功");
...@@ -1532,7 +1532,7 @@ $('[name="status"]').bootstrapSwitch({ ...@@ -1532,7 +1532,7 @@ $('[name="status"]').bootstrapSwitch({
//推送近5分钟数据 //推送近5分钟数据
function websocket_s(ds) { function websocket_s(ds) {
let web_ips = "ws:/localhost:8089/websocket/" + ds; let web_ips = "ws:/33.65.250.179:8089/websocket/" + ds;
ws_j5fz = new WebSocket(web_ips); ws_j5fz = new WebSocket(web_ips);
ws_j5fz.onopen = function () { ws_j5fz.onopen = function () {
console.log("连接成功"); console.log("连接成功");
...@@ -1582,7 +1582,7 @@ function websocket_s(ds) { ...@@ -1582,7 +1582,7 @@ function websocket_s(ds) {
//推送自动规则 //推送自动规则
function websocket_gzdj(video_id, items, indexs_1) { function websocket_gzdj(video_id, items, indexs_1) {
let web_ips = "ws:/localhost:8089/websocket/" + video_id; let web_ips = "ws:/33.65.250.179:8089/websocket/" + video_id;
let ws_gzdj = new WebSocket(web_ips); let ws_gzdj = new WebSocket(web_ips);
ws_gzdj.onopen = function () { ws_gzdj.onopen = function () {
console.log("连接成功"); console.log("连接成功");
......
...@@ -1249,7 +1249,7 @@ let arr_right_s = []; ...@@ -1249,7 +1249,7 @@ let arr_right_s = [];
//websocket连接 //websocket连接
let d = new Date().getTime(); let d = new Date().getTime();
let web_ip = "ws:/localhost:8089/websocket/" + d; let web_ip = "ws:/33.65.250.179:8089/websocket/" + d;
let wss = new WebSocket(web_ip); let wss = new WebSocket(web_ip);
wss.onopen = function () { wss.onopen = function () {
console.log("连接成功"); console.log("连接成功");
...@@ -1520,7 +1520,7 @@ $('[name="status"]').bootstrapSwitch({ ...@@ -1520,7 +1520,7 @@ $('[name="status"]').bootstrapSwitch({
//推送近5分钟数据 //推送近5分钟数据
function websocket_s(ds) { function websocket_s(ds) {
let web_ips = "ws:/localhost:8089/websocket/" + ds; let web_ips = "ws:/33.65.250.179:8089/websocket/" + ds;
ws_j5fz = new WebSocket(web_ips); ws_j5fz = new WebSocket(web_ips);
ws_j5fz.onopen = function () { ws_j5fz.onopen = function () {
console.log("连接成功"); console.log("连接成功");
...@@ -1570,7 +1570,7 @@ function websocket_s(ds) { ...@@ -1570,7 +1570,7 @@ function websocket_s(ds) {
//推送自动规则 //推送自动规则
function websocket_gzdj(video_id, items, indexs_1) { function websocket_gzdj(video_id, items, indexs_1) {
let web_ips = "ws:/localhost:8089/websocket/" + video_id; let web_ips = "ws:/33.65.250.179:8089/websocket/" + video_id;
let ws_gzdj = new WebSocket(web_ips); let ws_gzdj = new WebSocket(web_ips);
ws_gzdj.onopen = function () { ws_gzdj.onopen = function () {
console.log("连接成功"); console.log("连接成功");
......
...@@ -617,7 +617,7 @@ $('[data-gallery=manual]').click(function (e) { ...@@ -617,7 +617,7 @@ $('[data-gallery=manual]').click(function (e) {
new PhotoViewer(items, options); new PhotoViewer(items, options);
}); });
let d = new Date().getTime(); let d = new Date().getTime();
let web_ip = "ws:/localhost:8089/websocket/" + d; let web_ip = "ws:/33.65.250.179:8089/websocket/" + d;
let wss = new WebSocket(web_ip); let wss = new WebSocket(web_ip);
wss.onopen = function () { wss.onopen = function () {
console.log("连接成功"); console.log("连接成功");
......
let state_sj = true; let state_sj = true;
let nodeCheckedSilent = false; let nodeCheckedSilent = false;
let nodeUncheckedSilent = false; let nodeUncheckedSilent = false;
let audioPlay = document.getElementById('audio')
audioPlay.play()
setTimeout(() => {
audioPlay.pause()
audioPlay.load()
}, 10)
let vue_sjcx = new Vue({ let vue_sjcx = new Vue({
el: '#sjcx', el: '#sjcx',
data: { data: {
...@@ -666,7 +673,7 @@ $('[data-gallery=manual]').click(function (e) { ...@@ -666,7 +673,7 @@ $('[data-gallery=manual]').click(function (e) {
let d = new Date().getTime(); let d = new Date().getTime();
let web_ip = "ws:/localhost:8089/websocket/" + d; let web_ip = "ws:/33.65.250.179:8089/websocket/" + d;
let wss = new WebSocket(web_ip); let wss = new WebSocket(web_ip);
wss.onopen = function () { wss.onopen = function () {
console.log("连接成功"); console.log("连接成功");
...@@ -678,7 +685,7 @@ wss.onmessage = function (evt) { ...@@ -678,7 +685,7 @@ wss.onmessage = function (evt) {
// console.log(data); // console.log(data);
if (data.type == "alarm") { if (data.type == "alarm") {
if (data.data.type == 'TRAFFIC_INCIDENT_ALARM') { if (data.data.type == 'TRAFFIC_INCIDENT_ALARM') {
if(!state_sj){ if(state_sj==false){
if(!vue_sjcx.check_s){ if(!vue_sjcx.check_s){
return; return;
} }
...@@ -718,7 +725,7 @@ wss.onmessage = function (evt) { ...@@ -718,7 +725,7 @@ wss.onmessage = function (evt) {
// //事件等级 // //事件等级
let sjdj = ''; let sjdj = '';
vue_sjcx.data_sjlxs.forEach((item, index)=> { vue_sjcx.data_sjlxs.forEach((item, index)=> {
if ( item.id == data.data.incident_type) { if ( item.id.toLowerCase()== data.data.incident_type.toLowerCase()) {
bjlx = item.name; bjlx = item.name;
sjdj = item.alarmlevel; sjdj = item.alarmlevel;
} }
......
let state_sj = false; let state_sj = true;
let vue_sjcx = new Vue({ let vue_sjcx = new Vue({
el: '#sjcx', el: '#sjcx',
data: { data: {
...@@ -685,7 +685,7 @@ $('[data-gallery=manual]').click(function (e) { ...@@ -685,7 +685,7 @@ $('[data-gallery=manual]').click(function (e) {
new PhotoViewer(items, options); new PhotoViewer(items, options);
}); });
let d = new Date().getTime(); let d = new Date().getTime();
let web_ip = "ws:/localhost:8089/websocket/" + d; let web_ip = "ws:/33.65.250.179:8089/websocket/" + d;
let wss = new WebSocket(web_ip); let wss = new WebSocket(web_ip);
wss.onopen = function () { wss.onopen = function () {
console.log("连接成功"); console.log("连接成功");
...@@ -696,14 +696,18 @@ wss.onmessage = function (evt) { ...@@ -696,14 +696,18 @@ wss.onmessage = function (evt) {
var data = JSON.parse(event.data); var data = JSON.parse(event.data);
// console.log(data); // console.log(data);
if (data.type == "alarm") { if (data.type == "alarm") {
if (data.data.recordtype == 'ROADWORKS' || data.data.recordtype == 'ROADWORKS_OUT_OF_LINE') { if (data.data.incident_type == 'ROADWORKS' || data.data.incident_type == 'ROADWORKS_OUT_OF_LINE') {
//排除工程检测 //排除工程检测
return; return;
} }
if (!state_sj) { if (data.data.type == 'TRAFFIC_INCIDENT_ALARM') {
vue_sjcx.query(1, true); if(state_sj==false){
return; if(!vue_sjcx.check_s){
} return;
}
vue_sjcx.query(1, true);
return;
}
//if_cz 判断前来的事件是不是本部门下的 //if_cz 判断前来的事件是不是本部门下的
let if_cz = false; let if_cz = false;
//jk_video_id为监控id //jk_video_id为监控id
...@@ -727,7 +731,7 @@ wss.onmessage = function (evt) { ...@@ -727,7 +731,7 @@ wss.onmessage = function (evt) {
//事件等级 //事件等级
let sjdj = ''; let sjdj = '';
vue_sjcx.data_sjlxs.forEach((item, index)=> { vue_sjcx.data_sjlxs.forEach((item, index)=> {
if ( item.id == data.data.incident_type) { if ( item.id.toLowerCase() == data.data.incident_type.toLowerCase()) {
bjlx = item.name; bjlx = item.name;
sjdj = item.alarmlevel; sjdj = item.alarmlevel;
} }
...@@ -874,7 +878,8 @@ wss.onmessage = function (evt) { ...@@ -874,7 +878,8 @@ wss.onmessage = function (evt) {
}).show(); }).show();
//播放声音 //播放声音
let myMp3 = document.getElementById("audio"); let myMp3 = document.getElementById("audio");
audio.play(); // audio.play();
}
} }
} }
......
...@@ -705,7 +705,7 @@ laydate.render({ ...@@ -705,7 +705,7 @@ laydate.render({
} }
}); });
function websocket_s(d) { function websocket_s(d) {
let web_ip = "ws:/localhost:8089/websocket/" + d; let web_ip = "ws:/33.65.250.179:8089/websocket/" + d;
wss = new WebSocket(web_ip); wss = new WebSocket(web_ip);
wss.onopen = function () { wss.onopen = function () {
console.log("连接成功"); console.log("连接成功");
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
</head> </head>
<body> <body>
<div id="page-sy"> <div id="page-sy">
<audio id="audio" src="../img/4083.mp3"></audio> <audio id="audio" muted="muted" src="../img/4083.mp3"></audio>
<div class="right-nav"> <div class="right-nav">
<div class="tab-content content-sjfx"> <div class="tab-content content-sjfx">
<div role="tabpanel" class="tab-pane active" id="sjcx"> <div role="tabpanel" class="tab-pane active" id="sjcx">
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
</head> </head>
<body> <body>
<div id="page-sy"> <div id="page-sy">
<audio id="audio" src="../img/4083.mp3"></audio> <audio id="audio" muted="muted" src="../img/4083.mp3"></audio>
<div class="right-nav"> <div class="right-nav">
<div class="tab-content content-sjfx"> <div class="tab-content content-sjfx">
<div role="tabpanel" class="tab-pane active" id="sjcx"> <div role="tabpanel" class="tab-pane active" id="sjcx">
...@@ -62,8 +62,9 @@ ...@@ -62,8 +62,9 @@
<span class="pub-span" style="margin-left: 10px;">自动弹窗 <span class="pub-span" style="margin-left: 10px;">自动弹窗
<input id="status" type="checkbox" @click="zdtx" checked> <input id="status" type="checkbox" @click="zdtx" checked>
</span> </span>
</div> </span>
<div> <div>
<span style="float:left;line-height: 52px;margin-right: 10px;">事件类型:</span> <span style="float:left;line-height: 52px;margin-right: 10px;">事件类型:</span>
<ul class="nav nav-pills " role="tablist"> <ul class="nav nav-pills " role="tablist">
<li role="presentation" :class="['tab-pane',(index==num)?'active':'']" <li role="presentation" :class="['tab-pane',(index==num)?'active':'']"
...@@ -416,7 +417,7 @@ ...@@ -416,7 +417,7 @@
<div class="modal-body"> <div class="modal-body">
<div> <div>
<div class="top-video"> <div class="top-video">
<video id="my_video_1" class="video-js" controls preload="auto" width="480" height="280" <video id="my_video_1" class="video-js" controls preload="auto" width="480" height="280"
ref='video' v-show="show_s" style="object-fit: fill;width: 100%;height: 100%;" :src="video_src"> ref='video' v-show="show_s" style="object-fit: fill;width: 100%;height: 100%;" :src="video_src">
</video > </video >
<img :src="img_src_s" v-show="!show_s" style="width: 100%;height: 100%;cursor: zoom-in;" data-gallery="manual"> <img :src="img_src_s" v-show="!show_s" style="width: 100%;height: 100%;cursor: zoom-in;" data-gallery="manual">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment