Commit 4f20a78d authored by zhouts's avatar zhouts

告警界面修改

parent e4473dfa
...@@ -20,4 +20,6 @@ public interface CodeMapper { ...@@ -20,4 +20,6 @@ public interface CodeMapper {
int updatemanualcode(String name,String alarmlevel); int updatemanualcode(String name,String alarmlevel);
Code selectalarmNum (String keyid);
} }
\ No newline at end of file
package im.zhaojun.system.model; package im.zhaojun.system.model;
import lombok.Data;
import java.io.Serializable; import java.io.Serializable;
@Data
public class Code implements Serializable { public class Code implements Serializable {
private String key; private String key;
...@@ -13,6 +11,78 @@ public class Code implements Serializable { ...@@ -13,6 +11,78 @@ public class Code implements Serializable {
private Integer rectifytime ; private Integer rectifytime ;
private Integer manualchecktime; private Integer manualchecktime;
private Integer pushchecktime ; private Integer pushchecktime ;
private Integer maxnum;
private Integer alarmnum;
public String getKey() {
return key;
}
public void setKey(String key) {
this.key = key;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public String getAlarmlevel() {
return alarmlevel;
}
public void setAlarmlevel(String alarmlevel) {
this.alarmlevel = alarmlevel;
}
public Integer getRectifytime() {
return rectifytime;
}
public void setRectifytime(Integer rectifytime) {
this.rectifytime = rectifytime;
}
public Integer getManualchecktime() {
return manualchecktime;
}
public void setManualchecktime(Integer manualchecktime) {
this.manualchecktime = manualchecktime;
}
public Integer getPushchecktime() {
return pushchecktime;
}
public void setPushchecktime(Integer pushchecktime) {
this.pushchecktime = pushchecktime;
}
public Integer getMaxnum() {
return maxnum;
}
public void setMaxnum(Integer maxnum) {
this.maxnum = maxnum;
}
public Integer getAlarmnum() {
return alarmnum;
}
public void setAlarmnum(Integer alarmnum) {
this.alarmnum = alarmnum;
}
} }
\ No newline at end of file
package im.zhaojun.system.service; package im.zhaojun.system.service;
import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageHelper;
import im.zhaojun.common.exception.DuplicateNameException;
import im.zhaojun.common.shiro.ShiroActionProperties;
import im.zhaojun.common.util.TreeUtil;
import im.zhaojun.system.mapper.CodeMapper; import im.zhaojun.system.mapper.CodeMapper;
import im.zhaojun.system.mapper.UserMapper;
import im.zhaojun.system.mapper.UserRoleMapper;
import im.zhaojun.system.model.Code; import im.zhaojun.system.model.Code;
import im.zhaojun.system.model.Menu;
import im.zhaojun.system.model.User;
import org.apache.shiro.authz.UnauthorizedException;
import org.apache.shiro.crypto.hash.Md5Hash;
import org.apache.shiro.session.Session;
import org.apache.shiro.session.mgt.eis.SessionDAO;
import org.apache.shiro.subject.SimplePrincipalCollection;
import org.apache.shiro.subject.support.DefaultSubjectContext;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.*; import java.util.*;
...@@ -63,7 +49,9 @@ public class CodeService { ...@@ -63,7 +49,9 @@ public class CodeService {
public boolean updatemanualcode(String name,String alarmlevel) { public boolean updatemanualcode(String name,String alarmlevel) {
return codeMapper.updatemanualcode(name, alarmlevel) == 1; return codeMapper.updatemanualcode(name, alarmlevel) == 1;
} }
public Code selectalarmNum(String keyid){
return codeMapper.selectalarmNum(keyid);
}
} }
\ No newline at end of file
...@@ -10,7 +10,9 @@ ...@@ -10,7 +10,9 @@
<result column="rectifytime" jdbcType="INTEGER" property="rectifytime" /> <result column="rectifytime" jdbcType="INTEGER" property="rectifytime" />
<result column="manualchecktime" jdbcType="INTEGER" property="manualchecktime" /> <result column="manualchecktime" jdbcType="INTEGER" property="manualchecktime" />
<result column="pushchecktime" jdbcType="INTEGER" property="pushchecktime" /> <result column="pushchecktime" jdbcType="INTEGER" property="pushchecktime" />
<result column="repeattime" jdbcType="INTEGER" property="repeattime" /> <result column="maxnum" jdbcType="INTEGER" property="maxnum" />
<result column="alarmnum" jdbcType="INTEGER" property="alarmnum" />
</resultMap> </resultMap>
<update id="updatecode" parameterType="java.util.List"> <update id="updatecode" parameterType="java.util.List">
...@@ -44,7 +46,7 @@ ...@@ -44,7 +46,7 @@
</update> </update>
<select id="selectAllWithKey" resultMap="BaseResultMap"> <select id="selectAllWithKey" resultMap="BaseResultMap">
select * from t_code where type=1 select * from t_code where type=2
</select> </select>
...@@ -59,6 +61,8 @@ ...@@ -59,6 +61,8 @@
<update id="updatemanualcode"> <update id="updatemanualcode">
update t_code set name=#{name ,jdbcType=VARCHAR},alarmlevel=#{alarmlevel,jdbcType=VARCHAR} where key='send' update t_code set name=#{name ,jdbcType=VARCHAR},alarmlevel=#{alarmlevel,jdbcType=VARCHAR} where key='send'
</update> </update>
<select id="selectalarmNum" resultMap="BaseResultMap">
select * from t_code where type=2 and key=#{key,jdbcType=VARCHAR}
</select>
</mapper> </mapper>
\ No newline at end of file
...@@ -138,7 +138,7 @@ ...@@ -138,7 +138,7 @@
recordtype "type", recordtype "type",
name "typename" name "typename"
from traffalarmrecord a,t_code b from traffalarmrecord a,t_code b
where upper(a.recordtype)=b.key and b.type=1 and fdid||'_'||channelid in( where upper(a.recordtype)=b.key and b.type=2 and fdid||'_'||channelid in(
select b.videoid select b.videoid
from deptdefaultvideo b from deptdefaultvideo b
<if test="deptId != '' and deptId != null and deptId!='-1' "> <if test="deptId != '' and deptId != null and deptId!='-1' ">
......
This diff is collapsed.
//获取当前系统时间 //获取当前系统时间
function getTime() { function getTime() {
var now_today = new Date(); var now_today = new Date();
......
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
.dtree-toolbar-fixed a i:hover{opacity:0.8;filter:Alpha(opacity=80);} .dtree-toolbar-fixed a i:hover{opacity:0.8;filter:Alpha(opacity=80);}
/* 树基本*/ /* 树基本*/
.dtree{width:260px;} .dtree{width:360px;}
.dtree-nav-item{line-height:33px;padding-left:16px;} .dtree-nav-item{line-height:33px;padding-left:16px;}
.dtree-nav-ul-sid{display: none;} .dtree-nav-ul-sid{display: none;}
.dtree-none-text{font-size: 12px;text-align: center;color: gray;} .dtree-none-text{font-size: 12px;text-align: center;color: gray;}
......
...@@ -22,12 +22,12 @@ ...@@ -22,12 +22,12 @@
<div id="tree-xzxq"></div> <div id="tree-xzxq"></div>
</div> </div>
<div class="right-nav"> <div class="right-nav">
<div class="center-nav"> <div class="center-nav" id="jgsb">
<div class="div-right-top"> <div class="div-right-top">
<span class="pub-span">监控名称:</span> <span class="pub-span">监控名称:</span>
<input type="text" class="form-control input-pub" id="ryxm"> <input type="text" class="form-control input-pub" id="ryxm">
<button type="button" class="btn btn-sm pub-btn" @click="queryRY(1,true)">查询</button> <button type="button" class="btn btn-sm pub-btn" @click="queryRY(1,true)">查询</button>
<!--<button type="button" class="btn btn-sm pub-btn" @click="add">新增</button>--> <button type="button" class="btn btn-sm pub-btn" @click="add">新增</button>
</div> </div>
<div style="height:calc(100% - 130px);margin-top: 20px;text-align: center" class="tables"> <div style="height:calc(100% - 130px);margin-top: 20px;text-align: center" class="tables">
<table class="table table-td"> <table class="table table-td">
...@@ -195,75 +195,10 @@ ...@@ -195,75 +195,10 @@
<script src="../bootstrap/js/bootstrap.js"></script> <script src="../bootstrap/js/bootstrap.js"></script>
<script src="../bootstrap/js/bootstrap-treeview.js"></script> <script src="../bootstrap/js/bootstrap-treeview.js"></script>
<script src="../bootstrap/js/bootstrap-paginator.js"></script> <script src="../bootstrap/js/bootstrap-paginator.js"></script>
<script src="../js/util/httputil.js"></script> <script src="../js/util/http_util.js"></script>
<script src="../js/vue.js"></script> <script src="../js/vue.js"></script>
<script src="../js/jgsbgl/jgsbgl.js"></script> <script src="../js/jgsbgl/jgsbgl.js"></script>
<script> <script>
layui.config({
base: '/lib/layui/extend/'
}).extend({
formSelects: 'formSelects-v4'
}).use(['form', 'layer', 'formSelects', 'dtree'], function () {
$ = layui.jquery;
var form = layui.form
, layer = layui.layer
, formSelects = layui.formSelects
, dtree = layui.dtree;
dtree.renderSelect({
elem: "#deptTree",
url: "/depttree/tree",
dataStyle: "layuiStyle",
width: "100%",
method: "GET",
dot: false,
accordion: true,
menubar: true,
response: {
statusCode: 0,
message: "msg",
treeId: "id",
parentId: "parentId",
title: "name"
},
done: function() {
var deptId = [[${user?.deptId + ''}]] ;
dtree.dataInit("deptTree", deptId);
dtree.setSelectValue("deptTree");
}
});
dtree.on("node('deptTree')" ,function(obj){
$("#deptId").val(obj.param.nodeId);
});
form.on('submit(add)', function (form) {
form.field.role = formSelects.value('role-select', 'val');
$.post('/user', form.field, function (result) {
handlerResult(result, addDone);
});
return false;
});
//监听提交
form.on('submit(edit)', function (form) {
form.field._method = 'PUT';
form.field.role = formSelects.value('role-select', 'val');
$.post('/user', form.field, function (result) {
handlerResult(result, editDone);
});
return false;
});
function addDone(data) {
layer.msg("添加成功", {icon: 6});
setTimeout(function(){ window.parent.location.reload(true); }, 1500);
}
function editDone(data) {
layer.msg("修改成功", {icon: 6});
setTimeout(function(){ window.parent.location.reload(true); }, 1500);
}
});
</script> </script>
</html> </html>
\ No newline at end of file
...@@ -40,8 +40,8 @@ ...@@ -40,8 +40,8 @@
<div class="layui-col-md3"> <div class="layui-col-md3">
<div class="layui-card"> <div class="layui-card">
<div class="layui-card-header">监控事件树</div> <div class="layui-card-header">监控事件树</div>
<div class="layui-card-body" id="toolbarDiv"> <div class="layui-card-body" id="toolbarDiv" style="width: 360px;!important;">
<ul id="menuTree" class="dtree" data-id="0"></ul> <ul id="menuTree" class="dtree" data-id="0" ></ul>
</div> </div>
</div> </div>
</div> </div>
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
<div class="layui-card"> <div class="layui-card">
<div class="layui-card-header" id="card-header">菜单列表</div> <div class="layui-card-header" id="card-header">菜单列表</div>
<div class="layui-card-body"> <div class="layui-card-body">
<table class="layui-hide" id="menu-table"></table> <table class="layui-hide" id="menu-table" style="width: 360px;"></table>
</div> </div>
</div> </div>
</div> </div>
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
<link rel="stylesheet" href="../bootstrap/css/bootstrap-treeview.css"> <link rel="stylesheet" href="../bootstrap/css/bootstrap-treeview.css">
<link rel="stylesheet" href="../bootstrap/css/bootstrap-switch.min.css"> <link rel="stylesheet" href="../bootstrap/css/bootstrap-switch.min.css">
<link rel="stylesheet" href="../css/sjcx.css"> <link rel="stylesheet" href="../css/sjcx.css">
<link rel="stylesheet" href="../css/jkglsj.css">
<link rel="stylesheet" href="../css/photoviewer.css"> <link rel="stylesheet" href="../css/photoviewer.css">
<link rel="stylesheet" href="../css/animate.css"> <link rel="stylesheet" href="../css/animate.css">
<link rel="stylesheet" href="../css/noticejs.css"> <!--<link rel="stylesheet" href="../css/viewer.min.css">--> <link rel="stylesheet" href="../css/noticejs.css"> <!--<link rel="stylesheet" href="../css/viewer.min.css">-->
...@@ -85,7 +86,7 @@ ...@@ -85,7 +86,7 @@
</div> </div>
<div class="show-icon" :style="{'background':(item.processstatus==0||item.processstatus==null)?'#ff9c2b':(item.processstatus==2)?'#fc3939':(item.processstatus==1)?'#2fba08':'#cccccc'}" v-text="item.processstatus==0||item.processstatus==null?'未处理':item.processstatus==1?'正检':item.processstatus==2?'误检':'重复事件'"></div> <div class="show-icon" :style="{'background':(item.processstatus==0||item.processstatus==null)?'#ff9c2b':(item.processstatus==2)?'#fc3939':(item.processstatus==1)?'#2fba08':'#cccccc'}" v-text="item.processstatus==0||item.processstatus==null?'未处理':item.processstatus==1?'正检':item.processstatus==2?'误检':'重复事件'"></div>
<div class="li-top"> <div class="li-top">
<img :src="'data:image/png;base64,'+item.imagedata" :id="'img'+item.id"> <img :src="'/TrafficStatistics/fielagent?ftpPath='+ item.imagedata" :id="'img'+item.id">
<!-- <canvas :id="'cvs'+item.id" style="position: absolute;pointer-events: none;left:0;width:100%;height:100%"></canvas>--> <!-- <canvas :id="'cvs'+item.id" style="position: absolute;pointer-events: none;left:0;width:100%;height:100%"></canvas>-->
</div> </div>
<div class="li-center"> <div class="li-center">
...@@ -297,15 +298,15 @@ ...@@ -297,15 +298,15 @@
<span v-text="item.ss_type==1?'正检':item.ss_type==2?'误检':item.ss_type==3?'重复事件':''"></span> <span v-text="item.ss_type==1?'正检':item.ss_type==2?'误检':item.ss_type==3?'重复事件':''"></span>
</div> </div>
</div> </div>
<div class="div_modal"> <!--<div class="div_modal">-->
<div class="div_modal_span"> <!--<div class="div_modal_span">-->
<span>是否锁定:</span> <!--<span>是否锁定:</span>-->
</div> <!--</div>-->
<div class="div_modal_span1"> <!--<div class="div_modal_span1">-->
<input type="checkbox" :name="'a1ss_'+index" :value="item.videoid" :checked="item.checked" <!--<input type="checkbox" :name="'a1ss_'+index" :value="item.videoid" :checked="item.checked"-->
style="width: 19px;height: 19px;" @click="cli_input(item,$event,index,2)"/> <!--style="width: 19px;height: 19px;" @click="cli_input(item,$event,index,2)"/>-->
</div> <!--</div>-->
</div> <!--</div>-->
</div> </div>
</div> </div>
</div> </div>
...@@ -368,15 +369,15 @@ ...@@ -368,15 +369,15 @@
<span v-text="item.ss_type==1?'正检':item.ss_type==2?'误检':item.ss_type==3?'重复事件':''"></span> <span v-text="item.ss_type==1?'正检':item.ss_type==2?'误检':item.ss_type==3?'重复事件':''"></span>
</div> </div>
</div> </div>
<div class="div_modal"> <!--<div class="div_modal">-->
<div class="div_modal_span"> <!--<div class="div_modal_span">-->
<span>是否锁定:</span> <!--<span>是否锁定:</span>-->
</div> <!--</div>-->
<div class="div_modal_span1"> <!--<div class="div_modal_span1">-->
<input type="checkbox" :name="'a2ss_'+index" :value="item.videoid" :checked="item.checked" <!--<input type="checkbox" :name="'a2ss_'+index" :value="item.videoid" :checked="item.checked"-->
style="width: 19px;height: 19px;" @click="cli_input(item,$event,index,3)"/> <!--style="width: 19px;height: 19px;" @click="cli_input(item,$event,index,3)"/>-->
</div> <!--</div>-->
</div> <!--</div>-->
</div> </div>
</div> </div>
</div> </div>
......
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