Compare commits

...

26 Commits

Author SHA1 Message Date
许宏杰 c9ad23c7cd 环境区别
1 month ago
许宏杰 4e9d69459c 测试环境与打包环境
1 month ago
吕天方 1f7b82e74a 不同环境的区别
2 months ago
吕天方 66d0ef5162 +1
2 months ago
吕天方 26ee5bf60c 悬停加宽度
2 months ago
吕天方 83ebf6799e bugfix
2 months ago
吕天方 3f0cb5dd58 部署公司环境更改文件
2 months ago
吕天方 7c9f5c5991 相似同类事件新增详情弹框
2 months ago
吕天方 3c77b6e2ba 预警因素--增加悬停文字提示
2 months ago
吕天方 26e93afcb3 退回/上报去除校验
3 months ago
吕天方 b151d746a5 弹框更换
3 months ago
吕天方 d855b165b6 新增试用码提示
4 months ago
吕天方 b90d3ec072 token存储换localStorage、baseURL换网址截取、异常接口取消调用、高德切片换内网扒下的切片图片、
4 months ago
吕天方 6f5f121d23 路由拦截去除、单页面无感登录、公钥私钥修改、本地路由配置、路由获取不走请求
5 months ago
吕天方 031a5b9eeb 紧急事件上报/重训练必须修改标题
5 months ago
吕天方 e8f1cbf1f1 事件预警时间修改字段、bugflx
5 months ago
吕天方 826457efbb 本地路由配置
5 months ago
吕天方 b9eefe7993 算法异常获取
5 months ago
吕天方 23170d465c 弹框修改、传参修改
5 months ago
吕天方 3407340a06 预警审核列表修改
5 months ago
吕天方 552c448d5c 接口新增参数、弹框在页面复用
5 months ago
吕天方 c5753c4763 基本功能完善
6 months ago
吕天方 ec1eac282f 更新代码
6 months ago
吕天方 7fa52f6038 地图渲染
6 months ago
吕天方 29c09a5921 侧边栏样式修改
6 months ago
吕天方 14d7411a11 修改
6 months ago

@ -1,11 +1,3 @@
###
# @Descripttion:
# @version:
# @Author: JC9527
# @Date: 2024-01-25 11:41:56
# @LastEditors: JC9527
# @LastEditTime: 2024-03-12 16:51:26
###
# 页面标题
VUE_APP_TITLE = 数字高新驾驶舱-算法预警服务平台
@ -14,7 +6,11 @@ ENV = 'development'
# 若依管理系统/开发环境
# VUE_APP_BASE_API = '/dev-api'
VUE_APP_BASE_API = 'http://192.168.0.104:9102/api'
VUE_APP_BASE_API = 'http://192.168.0.128:9102/api'
# VUE_APP_BASE_API = 'http://39.101.188.84:9102/api'
#是否正式环境 正式true 测试false
VUE_APP_ISTEST= false
# 路由懒加载
VUE_CLI_BABEL_TRANSPILE_MODULES = true

@ -5,4 +5,10 @@ VUE_APP_TITLE = 数字高新驾驶舱-算法预警服务平台
ENV = 'production'
# 若依管理系统/生产环境
# VUE_APP_BASE_API = 'http://39.101.188.84:9102/api'
VUE_APP_BASE_API = 'http://localhost:9002/api'
#是否正式环境 正式true 测试false
VUE_APP_ISTEST= true

@ -48,7 +48,11 @@
"js-beautify": "1.13.0",
"js-cookie": "3.0.1",
"jsencrypt": "3.0.0-rc.1",
"leaflet": "^1.9.4",
"leaflet.markercluster": "^1.5.3",
"nprogress": "0.2.0",
"proj4": "^2.12.0",
"proj4leaflet": "^1.0.2",
"quill": "1.3.7",
"screenfull": "5.0.2",
"sortablejs": "1.10.2",

@ -0,0 +1,139 @@
import request from '@/utils/request'
// 查询算法事件列表
export function new100Page() {
return request({
url: '/earlyWarningAudit/massEvents/new100Page',
method: 'get',
})
}
// 右侧预警列表
export function colonyPage(params){
return request({
url: '/earlyWarningAudit/massEvents/colonyPage',
method: 'get',
params
})
}
// 分页查询审核工单列表
export function auditList(id,params){
return request({
url: '/earlyWarningAudit/massEvents/auditList/' + id,
method: 'get',
params
})
}
// 查询工单详情
export function getMassEvents(id){
return request({
url: '/earlyWarningAudit/massEvents/' + id,
method: 'get',
})
}
// 修改事件标题
export function editTitle(data){
return request({
url: '/earlyWarningAudit/massEvents/edit',
method: 'post',
data
})
}
// 事件上报或退回
export function eventChangeIsReport(data){
return request({
url: '/earlyWarningAudit/massEvents/eventChangeIsReport',
method: 'post',
data
})
}
// 分页条件查询相似事件调用记录数据
export function colonyEventPage(params){
return request({
url: '/earlyWarningAudit/similar/colonyPage',
method: 'get',
params
})
}
// 查询相似事件数据
export function similarEventsPage(id){
return request({
url: '/earlyWarningAudit/similar/similarEventsPage/' + id,
method: 'get',
})
}
// 相似事件提交重训练
export function noAccordWith(data){
return request({
url: '/earlyWarningAudit/similar/noAccordWith',
method: 'post',
data
})
}
// 取最新一条事件(预警钟)
export function limitOneMsg(){
return request({
url: '/earlyWarningAudit/massEvents/limitOneMsg',
method: 'get',
})
}
// 获取日志错误信息
export function getErrorMsg(){
return request({
url: '/earlyWarningAudit/massEvents/getErrorMsg',
method: 'get',
headers:{
"clientId" :'3YSE6O8fRACPPRVCqAlxgkhzMG+tasXXYgdDsiWPi/U=',
"clientSecret" :'kdoiIv5Wn2VvPG0sSGNF9Q4SVvu3CoBy+m6e8skq3AY=',
}
})
}
// 登录
// export function login(data){
// return request({
// url: '/earlyWarningAudit/massEvents/login',
// method: 'psot',
// data
// })
// }
export function login(username, password) {
const data = {
username,
password,
}
return request({
url: '/earlyWarningAudit/massEvents/login',
headers: {
isToken: false,
repeatSubmit: false
},
method: 'post',
data: data
})
}
export function verificationCode(params){
return request({
url: '/earlyWarningAudit/massEvents/verificationCode',
method: 'get',
params
})
}
export function verify (){
return request({
url: '/earlyWarningAudit/massEvents/verify',
method: 'get',
})
}

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none" version="1.1" width="14" height="14" viewBox="0 0 14 14"><defs><clipPath id="master_svg0_2_29"><rect x="0" y="0" width="14" height="14" rx="0"/></clipPath></defs><g clip-path="url(#master_svg0_2_29)"><g><path d="M7.07259,2.45188C7.07259,2.71403,6.84763,2.9265499999999998,6.57013,2.9265499999999998C6.29389,2.9265499999999998,6.06974,2.71415,6.06768,2.45252L6.06768,1.474676C6.06768,1.21252,6.29264,1,6.57013,1C6.84763,1,7.07259,1.21252,7.07259,1.474676L7.07259,2.45188ZM3.37514,4.2068200000000004C3.16381,4.3776399999999995,2.84538,4.35199,2.66773,4.14983L2.22422,3.53852C2.06521,3.33701,2.10003,3.05332,2.30364,2.89154C2.50725,2.7297599999999997,2.80906,2.74596,2.99196,2.9285L3.43683,3.53852C3.61495,3.73922,3.58734,4.03828,3.37514,4.2068200000000004ZM10.2813,4.16278C10.1863,4.2595,10.0529,4.3144100000000005,9.91319,4.31432C9.71385,4.31324,9.53398,4.20108,9.45457,4.02833C9.37517,3.85559,9.41121,3.65485,9.54646,3.5165L10.051,2.95764C10.2397,2.7658300000000002,10.5572,2.7549,10.7602,2.93323C10.9632,3.11156,10.9746,3.41159,10.7858,3.60327L10.2813,4.16278ZM6.24796,3.76905L6.52969,3.76905C8.57837,3.7712,10.2386,5.33963,10.2408,7.27506L10.2408,11.1359L2.79797,11.1359L2.79797,7.02833C2.80061,5.22932,4.34368,3.77155,6.24796,3.76905ZM3.8015,10.18787L9.23731,10.18787L9.23731,7.27506C9.23505,5.86298,8.02371,4.7189,6.529,4.71711L6.24796,4.71711C4.89826,4.71711,3.8015,5.75324,3.8015,7.02833L3.8015,10.18787ZM1.93987,6.4922C1.89805,6.7213,1.68611,6.88768,1.44004,6.88457C1.38452,6.88457,1.32762,6.87679,1.27347,6.85737L0.333686,6.33412C0.0728458,6.24668,-0.0635701,5.97603,0.0289921,5.72961C0.121554,5.48319,0.408043,5.35431,0.668883,5.44176L1.60798,5.96435C1.84095,6.03927,1.98168,6.26309,1.93987,6.4922ZM12.3775,5.44305C12.6467,5.37954,12.9193,5.53488,12.9855,5.78951C13.0512,6.04341,12.8874,6.30016,12.6188,6.36326L11.6324,6.73821C11.3635,6.80136,11.0914,6.64654,11.0247,6.39248C10.958,6.13843,11.1221,5.88145,11.3911,5.81865L12.3775,5.44305ZM6.70928,7.1164L7.38722,7.54575C7.47188,7.59882,7.53683,7.67558,7.57298,7.76528C7.68266,7.95567,7.64153,8.19722,7.4633,8.346160000000001L6.24316,9.36027C6.14856,9.43992,6.02998,9.47878,5.91208,9.47878C5.70384,9.47762,5.51787,9.3554,5.44432,9.17135C5.37076,8.987300000000001,5.42483,8.77946,5.58031,8.648579999999999L6.33433,8.020430000000001L5.65639,7.59108C5.43274,7.44891,5.36822,7.16506,5.51039,6.94868C5.53307,6.90755,5.56142,6.86944,5.5947,6.83535L6.6613,5.80894C6.8551,5.62173,7.17287,5.61847,7.37094,5.80165C7.569,5.98483,7.5723,6.28504,7.37831,6.47206L6.70928,7.1164ZM1.50105,12.051L11.5988,12.051C11.8834,12.041,12.1198,12.2563,12.1198,12.5253C12.1198,12.7944,11.8834,13.0096,11.5988,12.9997L1.50105,12.9997C1.23096,12.9902,1.01716,12.7806,1.01716,12.5253C1.01716,12.27,1.23096,12.0604,1.50105,12.051Z" fill-rule="evenodd" fill="#FFFFFF" fill-opacity="1" style="mix-blend-mode:passthrough"/></g></g></svg>

After

Width:  |  Height:  |  Size: 2.9 KiB

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none" version="1.1" width="14" height="13.999999046325684" viewBox="0 0 14 13.999999046325684"><defs><clipPath id="master_svg0_2_25"><rect x="0" y="13.999999046325684" width="14" height="13.999999046325684" rx="0"/></clipPath></defs><g transform="matrix(1,0,0,-1,0,27.999998092651367)" clip-path="url(#master_svg0_2_25)"><g><path d="M12.6254,14.874999046325684C12.901,14.874999046325684,13.125,15.098999046325684,13.125,15.374624046325684L13.125,26.626299046325684C13.125,26.902199046325684,12.9013,27.125899046325685,12.6254,27.125899046325685L1.373751,27.125899046325685C1.097815,27.125399046325683,0.874517012,26.901299046325683,0.875000667572,26.625399046325683L0.875000667572,15.373749046325683C0.875000667572,15.098999046325684,1.099001,14.874999046325684,1.3746260000000001,14.874999046325684L12.6263,14.874999046325684L12.6254,14.874999046325684ZM12.25,15.749999046325684L1.7500010000000001,15.749999046325684L1.7500010000000001,26.249999046325684L12.25,26.249999046325684L12.25,15.749999046325684ZM10.0625,23.624999046325684C10.30413,23.624999046325684,10.5,23.820879046325686,10.5,24.062499046325684C10.5,24.30411904632568,10.30413,24.499999046325684,10.0625,24.499999046325684L3.9375,24.499999046325684C3.69588,24.499999046325684,3.5,24.30411904632568,3.5,24.062499046325684C3.5,23.820879046325686,3.69588,23.624999046325684,3.9375,23.624999046325684L10.0625,23.624999046325684ZM7.89075,21.577499046325684C8.13237,21.577499046325684,8.32825,21.773379046325683,8.32825,22.014999046325684C8.32825,22.25661904632568,8.13237,22.452499046325684,7.89075,22.452499046325684L3.9375,22.452499046325684C3.69588,22.452499046325684,3.5,22.25661904632568,3.5,22.014999046325684C3.5,21.773379046325683,3.69588,21.577499046325684,3.9375,21.577499046325684L7.89075,21.577499046325684ZM10.0625,21.577499046325684C10.30413,21.577499046325684,10.5,21.773379046325683,10.5,22.014999046325684C10.5,22.25661904632568,10.30413,22.452499046325684,10.0625,22.452499046325684C9.82088,22.452499046325684,9.625,22.25661904632568,9.625,22.014999046325684C9.625,21.773379046325683,9.82088,21.577499046325684,10.0625,21.577499046325684ZM10.0625,17.499999046325684C10.30413,17.499999046325684,10.5,17.695879046325683,10.5,17.937499046325684L10.5,20.562499046325684C10.5,20.804119046325685,10.30413,20.999999046325684,10.0625,20.999999046325684C9.82088,20.999999046325684,9.625,20.804119046325685,9.625,20.562499046325684L9.625,17.937499046325684C9.625,17.695879046325683,9.82088,17.499999046325684,10.0625,17.499999046325684ZM7.89075,19.547499046325683C8.13237,19.547499046325683,8.32825,19.743369046325682,8.32825,19.984999046325683C8.32825,20.226619046325684,8.13237,20.422499046325683,7.89075,20.422499046325683L3.9375,20.422499046325683C3.69588,20.422499046325683,3.5,20.226619046325684,3.5,19.984999046325683C3.5,19.743369046325682,3.69588,19.547499046325683,3.9375,19.547499046325683L7.89075,19.547499046325683ZM7.89075,17.499999046325684C8.13237,17.499999046325684,8.32825,17.695879046325683,8.32825,17.937499046325684C8.32825,18.179119046325685,8.13237,18.374999046325684,7.89075,18.374999046325684L3.9375,18.374999046325684C3.69588,18.374999046325684,3.5,18.179119046325685,3.5,17.937499046325684C3.5,17.695879046325683,3.69588,17.499999046325684,3.9375,17.499999046325684L7.89075,17.499999046325684Z" fill="#FFFFFF" fill-opacity="1" style="mix-blend-mode:passthrough"/></g></g></svg>

After

Width:  |  Height:  |  Size: 3.4 KiB

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" fill="none" version="1.1" width="14" height="14" viewBox="0 0 14 14"><defs><clipPath id="master_svg0_2_20"><rect x="0" y="0" width="14" height="14" rx="0"/></clipPath></defs><g clip-path="url(#master_svg0_2_20)"><g><path d="M12.5465,13.18999755859375L0.453488,13.18999755859375C0.203034,13.18999755859375,0,12.97119755859375,0,12.70129755859375L0,1.29868055859375C5.97131e-8,1.02878855859375,0.203034,0.80999755859375,0.453488,0.80999755859375L12.5465,0.80999755859375C12.797,0.80999759076745,13,1.02878855859375,13,1.29868055859375L13,12.70129755859375C13,12.97119755859375,12.797,13.18999755859375,12.5465,13.18999755859375ZM0.906977,12.21259755859375L12.093,12.21259755859375L12.093,1.78736355859375L0.906977,1.78736355859375L0.906977,12.21259755859375Z" fill="#FFFFFF" fill-opacity="1" style="mix-blend-mode:passthrough"/></g><g><path d="M5.20582,9.4295L6.92423,5.79765L7.6386,6.300879999999999L5.92019,9.93273L5.20582,9.4295ZM8.52804,10L7.94447,9.28793L9.11092,7.86461L7.94447,6.4413L8.52804,5.72921L10.2774,7.86461L8.52804,10ZM4.3159,10L2.56656,7.86461L4.3159,5.72921L4.89946,6.4413L3.73301,7.86461L4.89946,9.28793L4.3159,10ZM0,3L13,3L13,3.503235L0,3.503235L0,3Z" fill="#FFFFFF" fill-opacity="1" style="mix-blend-mode:passthrough"/></g></g></svg>

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 712 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 779 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 625 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 912 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 966 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

@ -1,4 +1,4 @@
@font-face {
/* @font-face {
font-family: "Source Han Sans CN-Regular";
src: url("./font/SourceHanSansCN-Regular.otf");
}
@ -21,7 +21,14 @@
@font-face {
font-family: "DIN-Medium";
src: url("./font/DIN-Medium.otf");
} */
@font-face {
font-family: "AlibabaPuHuiTi";
src: url("../font/Alibaba-PuHuiTi-Regular.woff2");
}
@font-face {
font-family: "AlibabaPuHuiTi-Bold";
src: url("../font/Alibaba-PuHuiTi-Bold.woff2");
}

@ -0,0 +1,132 @@
.L-ultimately-container {
// margin: 20px;
background-color: #fff;
border-radius: 5px;
height: calc(100% - 40px);
overflow-y: scroll;
padding: 20px 0 10px 0;
header {
padding: 0 20px;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 700;
font-size: 18px;
color: #3D3D3D;
.title-span {
margin-left: 20px;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #CCCCCC;
}
}
.tabs {
margin-top: 10px;
.el-tabs {
height: 100%;
.el-tabs__header {
margin-bottom: 0 !important;
}
.el-tabs__item {
padding: 0 20px !important;
width: 130px;
text-align: center;
}
.el-tabs__active-bar {
width: 60px;
border-radius: 5px;
height: 4px;
}
.el-tabs__nav-wrap::after {
left: 20px;
right: 20px;
width: calc(100% - 40px);
}
//
.el-tabs__item.is-active {
}
}
}
.container-info {
height: calc(100% - 138px);
padding: 0 20px;
header {
width: 100%;
background-color: #FAFBFC;
padding: 20px;
.el-form-item {
margin-bottom: 0;
margin-right: 60px;
.el-form-item__label {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #3D3D3D;
}
.el-form-item__content {
.el-input {
.el-input__inner {
border-radius: 2px;
height: 32px;
width: 240px;
}
}
.el-date-editor {
width: 480px;
height: 32px;
border-radius: 2px;
}
}
}
}
section {
margin-top: 20px;
.el-table {
th {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 500;
font-size: 14px;
color: #3D3D3D;
height: 50px;
background-color: #F9FAFC;
border: none;
}
td {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #666666;
text-align: left;
color: #666666;
}
.table-operation {
text-align: center;
}
.table-operation-anniu {
.cell {
display: flex;
justify-content: center;
}
.go-audit {
cursor: pointer;
display: flex;
align-items: center;
img {
width: 20px;
height: 21px;
margin-right: 2px;
}
.span {
color: #2F8AE5;
}
}
}
}
.el-table::before {
height: 0;
}
}
}
}

@ -5,6 +5,9 @@
@import './sidebar.scss';
@import './btn.scss';
@import './public.scss';
@import './general.scss';
@import './leaflet.scss';
@import "./font.css";
body {
height: 100%;

@ -0,0 +1,100 @@
//
.leaflet-popup-content-wrapper {
background-color: transparent !important;
box-shadow: none !important;
.leaflet-popup-content {
width: 340px !important;
}
}
.leaflet-popup-close-button {
display: none;
}
.leaflet-popup-tip-container {
display: none;
}
.marsk-box {
.markerDialog {
border-radius: 5px;
background-color: #fff;
.markerTitle {
display: flex;
align-items: center;
flex-wrap: nowrap;
justify-content: space-between;
background-color: #F4F9FD;
border-radius: 5px 5px 0 0;
padding: 5px 10px;
.marker-msgTitle {
font-family: "AlibabaPuHuiTi";
font-weight: 700;
font-size: 18px;
color: #3D3D3D;
margin-right: 40px;
}
.markerClose {
font-size: 16px;
cursor: pointer;
color: #808080;
font-weight: bold;
}
}
.markerContent {
padding: 20px 10px;
display: grid;
grid-template-columns: 1fr;
row-gap: 10px;
.contentInfo {
display: flex;
.infoLabel {
width: 80px;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 16px;
color: #666666;
display: flex;
.labelBox {
flex: 1;
text-align-last: justify;
text-align: justify;
}
}
.infoValue {
flex: 1;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 16px;
color: #666666;
span {
font-family: "AlibabaPuHuiTi-Bold";
color: #F43147;
}
}
}
}
.markerBtns {
display: flex;
align-items: center;
justify-content: space-between;
padding: 0px 10px 20px 10px;
.btn-audit,.btn-detailInfo {
width: 48%;
border-radius: 5px;
display: flex;
align-items: center;
justify-content: center;
line-height: 30px;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #FFFFFF;
background: #2F8AE5;
cursor: pointer;
}
.btn-detailInfo {
color: #666666;
background: #E5E5E5;
}
}
}
}

@ -2,7 +2,7 @@
margin: 20px;
background-color: #fff;
border-radius: 5px;
height: calc(100vh - 40px);
height: calc(100% - 40px);
overflow-y: scroll;
padding: 20px 0 45px 0;
//
@ -15,19 +15,6 @@
.reset {
border: 1px solid #DEE2EE;
}
// label
.el-form-item {
margin-right: 20px;
// margin-bottom: 0;
}
.el-form-item__label {
font-size: 14px;
font-family: Source Han Sans CN-Medium, Source Han Sans CN;
font-weight: 500;
color: #4D5158;
padding: 0;
// line-height: 18px;
}
.el-form-item__content {
//
.el-input__inner {
@ -50,25 +37,6 @@
color: #292F38;
}
}
.el-tabs {
.el-tabs__header {
margin-bottom: 0;
}
.el-tabs__item {
font-size: 14px;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #8E9298;
-webkit-background-clip: text;
padding-left: 20px !important;
}
.el-tabs__item.is-active {
font-size: 16px;
font-family: Source Han Sans CN-Bold, Source Han Sans CN;
font-weight: bold;
color: #323233;
}
}
.table-box {
padding: 0 20px;
margin-top: 10px;
@ -118,6 +86,15 @@
.el-table__cell {
padding: 0;
}
.columnFactor {
div {
overflow:hidden;
text-overflow: ellipsis;
-webkit-line-clamp: 2;
display: -webkit-box;
-webkit-box-orient: vertical;
}
}
}
}
.L_tabs {
@ -156,10 +133,8 @@
// height: 85%;
padding-top: 10px;
.foot-main {
padding-bottom: 20px;
background: white;
.table-box {
height: 500px;
}
}
.headerText {
@ -184,6 +159,14 @@
position: relative;
cursor: pointer;
span {
margin-left: 20px;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #CCCCCC;
}
&::before {
content: "";
width: 26px;
@ -195,6 +178,73 @@
}
}
}
.arithmetic-query {
padding: 20px;
border-bottom: 1px solid #DEE2EE;
.el-form-item {
margin-bottom: 0;
margin-right: 60px;
.el-form-item__label {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #3D3D3D;
}
.el-form-item__content {
.el-input {
.el-input__inner {
border-radius: 2px;
height: 32px;
width: 240px;
}
}
.el-date-editor {
width: 480px;
height: 32px;
border-radius: 2px;
}
}
}
}
//
header {
padding: 0 20px;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 700;
font-size: 18px;
color: #3D3D3D;
}
.tabs-header {
margin-top: 10px;
.tabs-title {
width: 100%;
border-bottom: 1px solid #DEE2EE;
display: flex;
margin-bottom: 20px;
.await-audit,.already-affirm {
cursor: pointer;
padding: 8px 30px;
border-top: 1px solid #DEE2EE;
border-right: 1px solid #DEE2EE;
}
.await-audit {
border-left: 1px solid #DEE2EE;
}
.active-tab {
background-color: #3f3f3f;
color: #fefefe;
}
}
.el-form {
padding: 0 20px;
}
.tabs-line {
width: 100%;
height: 1px;
background: #DEE2EE;
margin: 20px 0;
}
}
}
.app-container::-webkit-scrollbar {
display: none;
@ -216,142 +266,497 @@
width: 70%;
}
}
.el-dialog {
.travel {
background: #FFFFFF;
border-radius: 8px;
.el-dialog__header {
border-radius: 8px 8px 0 0;
background: #F8F9FA;
height: 40px;
padding: 10px;
.el-dialog__title {
font-size: 14px;
.dialog-title {
display: flex;
align-items: center;
justify-content: space-between;
font-size: 18px;
font-family: Source Han Sans CN;
font-weight: 400;
color: #333333;
.dialog-title-text {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 500;
font-size: 18px;
color: #3D3D3D;
position: relative;
margin-left: 5px;
}
.dialog-title-text::before {
content: "";
position: absolute;
width: 2px;
height: 16px;
left: -5px;
top: 5px;
background-color: #2F8AE5;
}
i {
cursor: pointer;
}
}
}
.el-dialog__body {
padding: 10px;
.dialog-foot {
.el-form-item__content {
padding: 10px 20px;
.audit-generalize {
// .topRow {
// margin-bottom: 10px;
// }
//
.grid-content {
display: flex;
justify-content: flex-end;
align-items: center;
.designate,.save,.resetFields,.el-button {
cursor: pointer;
margin: 10px 0;
.grid-title {
font-size: 14px;
}
.grid-value {
border-radius: 2px;
height: 32px;
width: 240px;
border: 1px solid #E5E5E5;
padding: 0 15px;
line-height: 32px;
}
// value
.warning-type {
color: #d9011c;
}
// value
.grid-value-btn {
display: flex;
align-items: center;
justify-content: center;
padding: 0 15px;
background-color: #F88129;
border-radius: 4px;
margin: 0 10px;
img {
width: 14px;
margin-right: 4px;
padding-right: 10px;
.el-input {
.el-input__inner {
border-radius: 2px;
height: 32px;
width: 240px;
}
}
.el-button {
margin-left: 10px;
background: rgba(47,138,229,0.1);
border-radius: 2px 2px 2px 2px;
padding: 8px 15px;
span {
display: flex;
align-items: center;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 14px;
color: #2F8AE5;
img {
width: 14px;
height: 14px;
margin-right: 5px;
}
}
}
}
}
.lookTitle {
display: flex;
align-items: center;
// margin: 10px 0;
.grid-content {
display: flex;
align-items: center;
margin: 10px 0;
.grid-title {
font-size: 14px;
}
.grid-value {
border-radius: 2px;
height: 32px;
width: 240px;
border: 1px solid #E5E5E5;
padding: 0 15px;
line-height: 32px;
white-space: nowrap; /* 不换行 */
overflow: hidden; /* 隐藏超出范围的文本 */
text-overflow: ellipsis; /* 省略号 */
}
}
.el-button {
margin-left: 10px;
background: rgba(47,138,229,0.1);
border-radius: 2px 2px 2px 2px;
padding: 8px 15px;
span {
font-size: 12px;
font-family: Source Han Sans CN;
display: flex;
align-items: center;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
color: #FFFFFF;
line-height: 30px;
font-size: 14px;
color: #2F8AE5;
img {
width: 14px;
height: 14px;
margin-right: 5px;
}
}
}
.resetFields {
background-color: #FFFFFF;
border: 1px solid #DEE2EE;
span {
color: #4D5158;
}
//
.work-order-info {
display: grid;
grid-template-columns: 1fr;
row-gap: 10px;
.work-order-items {
display: flex;
.work-order-label {
width: 110px;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 16px;
color: #666666;
display: flex;
justify-content: flex-end;
}
// .work-order-top-label {
// justify-content: flex-start;
// }
.work-order-value {
flex: 1;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 16px;
color: #666666;
padding-right: 10px;
}
.work-order-change-value {
width: 400px;
white-space: nowrap; /* 不换行 */
overflow: hidden; /* 隐藏超出范围的文本 */
text-overflow: ellipsis; /* 省略号 */
}
}
.resetFields:hover {
color: #4D5158 !important;
.work-order-item {
display: flex;
align-items: center;
.work-order-item-left {
display: flex;
align-items: center;
.work-order-label {
width: 110px;
display: flex;
align-items: center;
justify-content: flex-end;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 16px;
color: #666666;
}
.el-input {
height: 32px;
width: 240px;
.el-input__inner {
border-radius: 2px;
width: 100%;
height: 100%;
}
}
.work-order-value-value {
width: 240px;
white-space: nowrap; /* 不换行 */
overflow: hidden; /* 隐藏超出范围的文本 */
text-overflow: ellipsis; /* 省略号 */
}
.value-value {
flex:1;
width: 100%;
}
}
.el-button {
margin-left: 10px;
background: rgba(47,138,229,0.1);
border-radius: 2px 2px 2px 2px;
padding: 8px 15px;
span {
display: flex;
align-items: center;
font-family: "AlibabaPuHuiTi";
font-weight: 400;
font-size: 14px;
color: #2F8AE5;
img {
width: 14px;
height: 14px;
margin-right: 5px;
}
}
}
}
.save {
margin-right: 0;
background-color: #1E80EB;
}
//
#newmapTwo {
width: 100%;
height: 300px;
}
}
.audit-table {
.table-box {
padding: 0;
.el-table {
.anjianmiaoshu {
.cell {
display: -webkit-box; /* 必需的,使用弹性盒模型 */
-webkit-box-orient: vertical; /* 必需的,设置弹性盒方向为垂直 */
-webkit-line-clamp: 2; /* 显示的行数 */
overflow: hidden; /* 隐藏超出范围的内容 */
text-overflow: ellipsis; /* 省略号 */
}
}
.anjianmiaoshuTwo {
display: -webkit-box; /* 必需的,使用弹性盒模型 */
width: 20ch;
-webkit-box-orient: vertical; /* 必需的,设置弹性盒方向为垂直 */
-webkit-line-clamp: 1; /* 显示的行数 */
overflow: hidden; /* 隐藏超出范围的内容 */
text-overflow: ellipsis; /* 省略号 */
}
.sign {
color: #D9001B;
}
.unmark {
color: #32B16C;
}
.operation-box {
.cell {
display: flex;
align-items: center;
justify-content: center;
}
}
.operation {
display: flex;
align-items: center;
.el-radio-group {
label {
&:nth-child(1) {
margin-right: 15px;
}
}
.el-radio__label {
padding-left: 1px;
}
// input[aria-hidden="true"] {
// display: none !important;
// }
}
.el-button {
padding: 0;
}
// .tagsImg {
// width: 20px;
// height: 20px;
// margin-right: 10px;
// }
}
}
}
}
}
.dialog-footer {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
.el-button {
margin: 0 10px;
}
}
}
//
.L-app-map-container {
margin: 20px;
background-color: #fff;
border-radius: 5px;
height: calc(100vh - 40px);
width: calc(100% - 40px);
overflow-y: scroll;
background-color: #ccc;
// height: calc(100vh - 80px);
// width: calc(100% - 40px);
width: 100%;
height: 100%;
// overflow-y: scroll;
position: relative;
#newmap {
width: 100%;
height: 100%;
}
.warning-list {
position: absolute;
right: 0;
top: 0;
bottom: 0;
width: 25%;
right: 20px;
top: 20px;
bottom: 20px;
width: 26%;
z-index: 1000;
background-color: #fff;
border-radius: 10px;
.warning-list-title {
line-height: 50px;
text-align: center;
background-color: #e6f7ff;
font-weight: bold;
border-radius: 10px 10px 0 0;
line-height: 40px;
padding: 0 20px;
background-color: rgba(47,138,229,0.05);
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 700;
font-size: 16px;
color: #3D3D3D;
}
.warning-list-content {
padding: 10px;
.warning-list-search {
display: flex;
align-items: center;
margin-bottom: 5px;
.el-input__inner {
border-radius: 5px 0 0 5px;
}
.el-input-group__append {
border-radius: 0 5px 5px 0;
}
.el-button {
margin-left: 5px;
// height: 36px;
border-radius: 0 5px 5px 0;
background-color:#2F8AE5;
color: #fff;
}
}
.warning-list-list {
display: grid;
grid-template-columns: 1fr;
grid-row-gap: 10px;
padding: 5px;
margin: 5px;
height: calc(100vh - 300px);
overflow-y: scroll;
.lists {
padding: 5px;
border-radius: 10px;
padding: 20px 10px;
background-color: #FAFAFA;
.hearder {
display: flex;
.warning-title {
flex: 1;
// padding-top: 3px;
}
.anniu {
margin-left: 5px;
// display: flex;
// align-items: center;
// justify-content: center;
line-height: 30px;
height: 30px;
padding: 0 10px;
margin-right: 10px;
// padding: 3px 6px;
padding: 3px 5px 3px 7px;
border-radius: 5px;
border: 1px solid #d9001b;
width: 40px;
height: 40px;
flex-wrap: wrap;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
letter-spacing: 2px;
font-weight: 500;
font-size: 12px;
// display: flex;
// justify-content: space-between;
// align-content: space-between;
// flex-wrap: wrap;
}
// 12345
.qunti {
color: #F43147;
background: rgba(244,49,71,0.1);
}
.tongren{
color: #2BC4C4;
background: rgba(43,196,196,0.1);
}
.jinji{
background: rgba(245,154,35,0.1);
color: #F59A23;
}
.zhongdian{
background: rgba(162,75,243,0.1);
color: #a24bf3;
}
.yiren{
color: #F954A5;
background: rgba(249,84,165,0.1);
}
}
.content {
display: flex;
margin: 10px 0 0 0;
.content-left {
flex: 1;
flex-direction: column;
margin: 10px 0;
.content-top,.content-bottom {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 12px;
color: #666666;
padding: 0 10px;
display: flex;
align-items: center;
}
.content-right {
margin-left: 5px;
.el-button {
height: 100%;
width: 80px;
.content-top {
img {
width: 11px;
height: 12px;
margin-right: 20px;
}
}
.content-bottom {
margin-top: 10px;
img {
width: 12px;
height: 12px;
margin-right: 20px;
}
}
}
.foot {
width: 100%;
.el-button {
width: 100%;
}
.eventInfo {
width: 100%;
display: flex;
align-items: center;
background-color: #fff;
border-radius: 5px;
padding: 8px 0;
position: relative;
.audit,.info {
flex: 1;
display: flex;
align-items: center;
justify-content: center;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 12px;
cursor: pointer;
}
.audit {
color: #808080;
}
.info {
color: #2F8AE5;
}
span {
position: absolute;
left: 50%;
width: 1px;
height: 40%;
background-color: #F2F2F2;
}
}
}
}
}
.warning-list-footer {
.pagination-container {
.el-pagination {
width: 100%;
overflow: hidden;
}
}
}
}
}
@ -362,19 +767,41 @@
padding: 10px 20px;
display: grid;
grid-template-columns: 1fr;
grid-row-gap: 5px;
grid-row-gap: 10px;
border-radius: 5px;
border: 1px solid #DEE2EE;
box-shadow: 5px 5px 5px 5px rgba(0, 0, 0, 0.1);
// border: 1px solid #DEE2EE;
box-shadow: 0px 0px 8px 0px rgba(0,0,0,0.1);
background: #FFFFFF;
z-index: 1000;
.warning-events-event {
display: flex;
align-items: center;
cursor: pointer;
.warning-events-event-img {
margin-right: 10px;
width: 20px;
height: 29px;
}
.warning-events-event-text {
font-size: 12px;
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 14px;
color: #666666;
}
}
}
}
.el-message-box {
width: 430px;
}
.el-message-box__container {
margin: 0 0 35px 0;
.el-message-box__message {
position: relative;
.warningText {
position: absolute;
left: 0px;
top: 35px;
}
}
}

@ -2,7 +2,7 @@
.main-container {
// height: 100%;
height: calc(100% - 40px);
height: calc(100% - 50px);
transition: margin-left .28s;
margin-left: $base-sidebar-width;
position: relative;
@ -18,10 +18,10 @@
width: $base-sidebar-width !important;
background-color: $base-menu-background;
// height: 100%;
height: calc(100% - 40px);
height: calc(100% - 50px);
position: fixed;
font-size: 0px;
top: 40px;
top: 50px;
bottom: 0;
left: 0;
z-index: 1001;
@ -76,6 +76,22 @@
overflow: hidden !important;
text-overflow: ellipsis !important;
white-space: nowrap !important;
line-height: 40px;
height: 40px;
}
.cesileiming {
background-color: rgba(100,113,129,0.5);
margin: 10px 0;
li,.el-submenu__title {
background-color: transparent !important;
}
.cesileiming-a {
li {
background-color: rgba(47,138,229,0.5) !important;
color: #fff !important;
}
}
}
// menu hover

@ -9,9 +9,12 @@ $yellow:#FEC171;
$panGreen: #30B08F;
//
$base-menu-color:#bfcbd9;
// $base-menu-color:#bfcbd9;
$base-menu-color:#FFFFFF;
$base-menu-color-active:#f4f4f5;
$base-menu-background:#304156;
// $base-menu-background:#304156;
// $base-menu-background:rgba(100,113,129,0.5);
$base-menu-background: #314158;
$base-logo-title-color: #ffffff;
$base-menu-light-color:rgba(0,0,0,.70);
@ -19,6 +22,7 @@ $base-menu-light-background:#ffffff;
$base-logo-light-title-color: #001529;
$base-sub-menu-background:#1f2d3d;
// $base-sub-menu-background:rgba(100,113,129,0.5);
$base-sub-menu-hover:#001528;
//
@ -36,7 +40,8 @@ $base-sub-menu-background:#000c17;
$base-sub-menu-hover:#001528;
*/
$base-sidebar-width: 200px;
// $base-sidebar-width: 200px;
$base-sidebar-width: 220px;
// the :export directive is the magic sauce for webpack
// https://www.bluematador.com/blog/how-to-share-variables-between-js-and-sass

@ -9,6 +9,7 @@
:pager-count="pagerCount"
:total="total"
v-bind="$attrs"
:small="small"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"
/>
@ -48,6 +49,10 @@ export default {
type: String,
default: 'total, sizes, prev, pager, next, jumper'
},
small: {
type: Boolean,
default: false
},
background: {
type: Boolean,
default: true

@ -171,8 +171,8 @@ export default {
<style lang="scss">
.topmenu-container.el-menu--horizontal > .el-menu-item {
float: left;
height: 50px !important;
line-height: 50px !important;
height: 40px !important;
line-height: 40px !important;
color: #999093 !important;
padding: 0 5px !important;
margin: 0 10px !important;

@ -0,0 +1,145 @@
<template>
<div class="event-box" v-if="errorInfo && isTrue">
<div class="event-background-two"></div>
<div class="event-right">
<div class="msgType">算法运行异常</div>
<div class="msgContent">请及时联系运维人员进行处理</div>
</div>
</div>
<div class="event-box" v-else-if="eventInfoTrue && !isTrue" @click="lookInfo">
<div class="event-background"></div>
<div class="event-right">
<div class="msgType">{{ eventInfo.msgTypeName }}</div>
<div class="msgContent">{{ eventInfo.title }}</div>
</div>
<urgency-audit
title="事件详情"
ref="urgencyAudit"
:auditStatus="2"
></urgency-audit>
</div>
</template>
<script>
import { limitOneMsg, getErrorMsg } from "@/api/eventPage/index";
import urgencyAudit from "@/views/components/urgencyAudit.vue";
export default {
components: {
urgencyAudit,
},
data() {
return {
eventInfo: {},
isTrue: true,
ErrorMsgTime: "",
errorInfo: true,
eventInfoTrue: true,
};
},
//
watch: {
$route: {
handler(route) {
//
if (!JSON.parse(process.env.VUE_APP_ISTEST)) {
let timeOne;
let timeTwo;
this.isTrue = true;
this.getGetErrorMsg();
//
timeOne = setInterval(() => {
this.getGetErrorMsg();
}, 60000);
}
},
immediate: true,
},
},
methods: {
//
getLimitOneMsg() {
limitOneMsg().then((res) => {
if (res.data) {
this.eventInfo = res.data;
this.eventInfoTrue = true;
} else {
this.eventInfoTrue = false;
}
});
},
//
getGetErrorMsg() {
getErrorMsg().then((res) => {
if (res.data == "算法运行异常") {
this.isTrue = true;
this.errorInfo = true;
this.$store.dispatch("debug/changeDebugTime", res.data[0]);
} else {
this.isTrue = false;
this.errorInfo = false;
this.eventInfo = res.data[0];
// if(res.data) {
// this.$store.dispatch("debug/changeDebugTime", res.data)
// this.ErrorMsgTime = res.data;
// // this.errorInfo = true;
// } else {
// this.$store.dispatch("debug/changeDebugTime", '')
// // this.errorInfo = false;
// }
}
});
},
lookInfo() {
// console.log(this.eventInfo,"this.eventInfo");
this.$refs.urgencyAudit.open(this.eventInfo);
},
},
};
</script>
<style lang="scss" scoped>
.event-box {
display: flex;
width: 500px;
height: 40px;
border-radius: 20px;
background: #4c4c4c;
padding: 0 10px;
align-items: center;
cursor: pointer;
.event-background {
background: url("../../assets/images/eventPrompt.png");
background-size: 100% 100%;
width: 30px;
height: 30px;
margin-right: 5px;
}
.event-background-two {
background: url("../../assets/images/debugTwo.png");
border-radius: 50%;
padding: 5px;
background-size: 95% 95%;
background-repeat: no-repeat; /* 不平铺 */
width: 30px;
height: 30px;
margin-right: 5px;
}
.event-right {
display: flex;
flex-direction: column;
.msgType {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 700;
font-size: 14px;
color: #f43147;
}
.msgContent {
font-family: AlibabaPuHuiTi, AlibabaPuHuiTi;
font-weight: 400;
font-size: 12px;
color: #ffffff;
}
}
}
</style>

@ -29,7 +29,7 @@ export default {
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
height: calc(100vh - 40px);
height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;

@ -15,9 +15,10 @@ export default {
render(h, context) {
const { icon, title } = context.props
const vnodes = []
if (icon) {
if (icon && icon !== '#') {
vnodes.push(<svg-icon icon-class={icon}/>)
} else if (icon && icon == '#'){
vnodes.push(<svg-icon display="none" icon-class={icon}/>)
}
if (title) {

@ -1,7 +1,8 @@
<template>
<div v-if="!item.hidden">
<template v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren)&&!item.alwaysShow">
<app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path, onlyOneChild.query)">
<!-- :class="(onlyOneChild.path == 'index' || onlyOneChild.path == 'warningAppear') ? 'cesileiming' : ''" -->
<app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path, onlyOneChild.query)" :class="hasOneShowingChildTwo(item) ? 'cesileiming-a' : ''">
<el-menu-item :index="resolvePath(onlyOneChild.path)" :class="{'submenu-title-noDropdown':!isNest}">
<item :icon="onlyOneChild.meta.icon||(item.meta&&item.meta.icon)" :title="onlyOneChild.meta.title" />
</el-menu-item>
@ -52,7 +53,10 @@ export default {
},
data() {
this.onlyOneChild = null
return {}
return {
indexCurrent: false,
warningAppearCurrent: false,
}
},
methods: {
hasOneShowingChild(children = [], parent) {
@ -82,6 +86,15 @@ export default {
return false
},
hasOneShowingChildTwo(item){
if(item.children) {
if ((item.children && item.children[0].path == "index" && this.indexCurrent) || (item.children && item.children[0].path == "warningAppear" && this.warningAppearCurrent)) {
return true;
} else {
return false;
}
}
},
resolvePath(routePath, routeQuery) {
if (isExternal(routePath)) {
return routePath
@ -95,6 +108,24 @@ export default {
}
return path.resolve(this.basePath, routePath)
}
}
},
watch:{
$route:{
handler(route){
if(route.path == "/index") {
this.indexCurrent = true;
this.warningAppearCurrent = false;
} else if(route.path == "/warningAppear") {
this.warningAppearCurrent = true;
this.indexCurrent = false;
} else {
this.indexCurrent = false;
this.warningAppearCurrent = false;
}
// console.log(this.warningAppearCurrent,"warningAppearCurrent");
},
immediate:true,
}
},
}
</script>

@ -13,6 +13,7 @@
mode="vertical"
>
<sidebar-item
class="cesileiming"
v-for="(route, index) in sidebarRouters"
:key="route.path + index"
:item="route"
@ -44,7 +45,8 @@ export default {
return path;
},
showLogo() {
return this.$store.state.settings.sidebarLogo;
// return this.$store.state.settings.sidebarLogo;
return false;
},
variables() {
return variables;

@ -1,22 +1,27 @@
<template>
<div :class="classObj" class="app-wrapper" :style="{'--current-color': theme}">
<header class="app-header">
<div class="header-title">数字高新驾驶舱-算法预警服务平台</div>
<div class="right-menu">
<el-dropdown class="avatar-container right-menu-item hover-effect" trigger="click">
<div class="avatar-wrapper">
<img :src="avatar" class="user-avatar">
<i class="el-icon-caret-bottom" />
</div>
<el-dropdown-menu slot="dropdown">
<router-link to="/user/profile">
<el-dropdown-item>个人中心</el-dropdown-item>
</router-link>
<el-dropdown-item divided @click.native="logout">
<span>退出登录</span>
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<div class="header-title"> <img src="@/assets/images/logo@2x.png" alt=""> <span>数字高新驾驶舱-算法审核平台</span></div>
<div class="right-box">
<event-prompt></event-prompt>
<div class="right-menu">
<el-dropdown class="avatar-container right-menu-item hover-effect" trigger="click">
<div class="avatar-wrapper">
<!-- <img :src="avatar" class="user-avatar"> -->
<img src="@/assets/images/touxiang.png" class="user-avatar">
<i class="el-icon-caret-bottom" />
</div>
<el-dropdown-menu slot="dropdown">
<!-- <router-link to="/user/profile">
<el-dropdown-item>个人中心</el-dropdown-item>
</router-link> -->
<!-- divided -->
<el-dropdown-item @click.native="logout">
<span>退出登录</span>
</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
</div>
</header>
<div v-if="device==='mobile'&&sidebar.opened" class="drawer-bg" @click="handleClickOutside"/>
@ -41,6 +46,8 @@ import { AppMain, Navbar, Settings, Sidebar, TagsView } from './components'
import ResizeMixin from './mixin/ResizeHandler'
import { mapState, mapGetters } from 'vuex'
import variables from '@/assets/styles/variables.scss'
import eventPrompt from "@/components/eventPrompt"
export default {
name: 'Layout',
@ -50,7 +57,8 @@ export default {
RightPanel,
Settings,
Sidebar,
TagsView
TagsView,
eventPrompt
},
mixins: [ResizeMixin],
computed: {
@ -88,7 +96,8 @@ export default {
type: 'warning'
}).then(() => {
this.$store.dispatch('LogOut').then(() => {
location.href = '/index';
// location.href = '/index';
this.$router.replace("/login");
})
}).catch(() => {});
}
@ -107,17 +116,31 @@ export default {
width: 100%;
.app-header {
background-color: #304156;
height: 40px;
background-color: #3f3f3f;
height: 50px;
padding: 0px 20px;
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: space-between;
.header-title {
line-height: 40px;
display: flex;
align-items: center;
height: 50px;
line-height: 50px;
color: #fff;
img {
width: 20px;
height: 20px;
margin-right: 10px;
}
}
.right-box {
display: flex;
align-items: center;
}
.right-menu {
margin-left: 40px;
float: right;
&:focus {

@ -2,6 +2,7 @@ import store from '@/store'
const { body } = document
const WIDTH = 992 // refer to Bootstrap's responsive design
// const WIDTH = 100 // refer to Bootstrap's responsive design
export default {
watch: {
@ -34,11 +35,13 @@ export default {
$_resizeHandler() {
if (!document.hidden) {
const isMobile = this.$_isMobile()
store.dispatch('app/toggleDevice', isMobile ? 'mobile' : 'desktop')
if (isMobile) {
store.dispatch('app/closeSideBar', { withoutAnimation: true })
}
// 设置侧边栏不会随着尺寸变小不收起
// store.dispatch('app/toggleDevice', isMobile ? 'mobile' : 'desktop')
// if (isMobile) {
// store.dispatch('app/closeSideBar', { withoutAnimation: true })
// }
}
}
}

@ -7,6 +7,8 @@ import './assets/styles/element-variables.scss'
import '@/assets/styles/index.scss' // global css
import '@/assets/styles/ruoyi.scss' // ruoyi css
import 'leaflet/dist/leaflet.css' // leaflet样式
import App from './App'
import store from './store'
import router from './router'
@ -63,6 +65,20 @@ Vue.use(plugins)
Vue.use(VueMeta)
DictData.install()
Vue.directive('removeAriaHiddent', {
bind(el, binding) {
let ariaEls = el.querySelectorAll('.el-radio__original');
ariaEls.forEach(element => {
element.removeAttribute('aria-hidden')
});
}
})
/**
* 还原只需还原路由拦截文件里和注释掉本地路由配置单页面mounted里登录去掉即可
*
*/
/**
* If you don't want to use mock-server
* you want to use MockJs for mock api

@ -1,66 +1,82 @@
/*
* @Descripttion:
* @version:
* @Author: JC9527
* @Date: 2024-01-25 11:41:56
* @LastEditors: JC9527
* @LastEditTime: 2024-02-22 14:39:44
*/
import router from './router'
import store from './store'
import { Message } from 'element-ui'
import NProgress from 'nprogress'
import 'nprogress/nprogress.css'
import { getToken } from '@/utils/auth'
import { isRelogin } from '@/utils/request'
import router from "./router";
import store from "./store";
import { Message } from "element-ui";
import NProgress from "nprogress";
import "nprogress/nprogress.css";
import { getToken } from "@/utils/auth";
import { isRelogin } from "@/utils/request";
NProgress.configure({ showSpinner: false })
NProgress.configure({ showSpinner: false });
const whiteList = ['/login', '/register']
const whiteList = ["/login", "/register"];
router.beforeEach((to, from, next) => {
NProgress.start()
NProgress.start();
// 准备地址对接权限
// if(window.location.href.includes("cyToken=") && window.location.href.includes("userName=")) {
// var regOne = new RegExp(/[?&]cyToken=([^&#]+)/);
// var regTwo = new RegExp(/[?&]userName=([^&#]+)/);
// const queryOne = window.location.href.match(regOne);
// const queryTwo = window.location.href.match(regTwo);
// const cyToken = queryOne && queryOne[1];
// const userName = queryTwo && queryTwo[1];
// // console.log(cyToken,"cyToken");
// // console.log(userName,"userName");
// }
// 正式环境 !不是公司环境
if (
process.env.NODE_ENV === "production" &&
JSON.parse(process.env.VUE_APP_ISTEST)
) {
next();
NProgress.done();
return;
}
if (getToken()) {
to.meta.title && store.dispatch('settings/setTitle', to.meta.title)
to.meta.title && store.dispatch("settings/setTitle", to.meta.title);
/* has token*/
if (to.path === '/login') {
next({ path: '/' })
NProgress.done()
if (to.path === "/login") {
next({ path: "/" });
NProgress.done();
} else if (whiteList.indexOf(to.path) !== -1) {
next()
next();
} else {
if (store.getters.roles.length === 0) {
isRelogin.show = true
isRelogin.show = true;
// 判断当前用户是否已拉取完user_info信息
store.dispatch('GetInfo').then(() => {
isRelogin.show = false
store.dispatch('GenerateRoutes').then(accessRoutes => {
// 根据roles权限生成可访问的路由表
router.addRoutes(accessRoutes) // 动态添加可访问路由表
next({ ...to, replace: true }) // hack方法 确保addRoutes已完成
})
}).catch(err => {
store.dispatch('LogOut').then(() => {
Message.error(err)
next({ path: '/' })
})
store
.dispatch("GetInfo")
.then(() => {
isRelogin.show = false;
store.dispatch("GenerateRoutes").then((accessRoutes) => {
// 根据roles权限生成可访问的路由表
router.addRoutes(accessRoutes); // 动态添加可访问路由表
next({ ...to, replace: true }); // hack方法 确保addRoutes已完成
});
})
.catch((err) => {
store.dispatch("LogOut").then(() => {
Message.error(err);
next({ path: "/" });
});
});
} else {
next()
next();
}
}
} else {
// 没有token
if (whiteList.indexOf(to.path) !== -1) {
// 在免登录白名单,直接进入
next()
next();
} else {
next(`/login?redirect=${encodeURIComponent(to.fullPath)}`) // 否则全部重定向到登录页
NProgress.done()
next(`/login?redirect=${encodeURIComponent(to.fullPath)}`); // 否则全部重定向到登录页
NProgress.done();
}
}
})
});
router.afterEach(() => {
NProgress.done()
})
NProgress.done();
});

@ -0,0 +1,156 @@
import Layout from "@/layout";
export function getFilterRouter() {
let list = [];
// 正式环境
if (
process.env.NODE_ENV === "production" &&
JSON.parse(process.env.VUE_APP_ISTEST)
) {
list = [
{
path: "/index",
component: () => import("@/views/index"),
name: "Index",
meta: { title: "算法运行监测", icon: "", affix: true },
},
{
path: "/warningAppear",
component: () => import("@/views/warningManage/warningAppear"),
name: "WarningAppear",
meta: { title: "预警呈现", icon: "", affix: true },
},
{
path: "/groupEvent",
component: () =>
import("@/views/warningManage/warningAudit/groupEvent"),
name: "GroupEvent",
meta: { title: "驾驶舱群体事件", icon: "", affix: true },
},
{
path: "/instancyEvent",
component: () =>
import("@/views/warningManage/warningAudit/instancyEvent"),
name: "InstancyEvent",
meta: { title: "驾驶舱紧急事件", icon: "", affix: true },
},
{
path: "/oneToManyEvent",
component: () =>
import("@/views/warningManage/warningAudit/oneToManyEvent"),
name: "OneToManyEvent",
meta: { title: "驾驶舱一人多诉事件", icon: "", affix: true },
},
{
path: "/oneToOneEvent",
component: () =>
import("@/views/warningManage/warningAudit/oneToOneEvent"),
name: "OneToOneEvent",
meta: { title: "驾驶舱同人同诉事件", icon: "", affix: true },
},
{
path: "/emphasisEvent",
component: () =>
import("@/views/warningManage/warningAudit/emphasisEvent"),
name: "EmphasisEvent",
meta: { title: "驾驶舱重点人员事件", icon: "", affix: true },
},
{
path: "/similarity",
component: () =>
import("@/views/warningManage/warningAudit/similarity"),
name: "Similarity",
meta: { title: "驾驶舱相似同类事件", icon: "", affix: true },
},
{
path: "/user",
component: Layout,
hidden: true,
redirect: "noredirect",
children: [
{
path: "profile",
component: () => import("@/views/system/user/profile/index"),
name: "Profile",
meta: { title: "个人中心", icon: "user" },
},
],
},
];
return list;
}
list = [
{
path: "/system/user-auth",
component: Layout,
hidden: true,
permissions: ["system:user:edit"],
children: [
{
path: "role/:userId(\\d+)",
component: () => import("@/views/system/user/authRole"),
name: "AuthRole",
meta: { title: "分配角色", activeMenu: "/system/user" },
},
],
},
{
path: "/system/role-auth",
component: Layout,
hidden: true,
permissions: ["system:role:edit"],
children: [
{
path: "user/:roleId(\\d+)",
component: () => import("@/views/system/role/authUser"),
name: "AuthUser",
meta: { title: "分配用户", activeMenu: "/system/role" },
},
],
},
{
path: "/system/dict-data",
component: Layout,
hidden: true,
permissions: ["system:dict:list"],
children: [
{
path: "index/:dictId(\\d+)",
component: () => import("@/views/system/dict/data"),
name: "Data",
meta: { title: "字典数据", activeMenu: "/system/dict" },
},
],
},
{
path: "/monitor/job-log",
component: Layout,
hidden: true,
permissions: ["monitor:job:list"],
children: [
{
path: "index/:jobId(\\d+)",
component: () => import("@/views/monitor/job/log"),
name: "JobLog",
meta: { title: "调度日志", activeMenu: "/monitor/job" },
},
],
},
{
path: "/tool/gen-edit",
component: Layout,
hidden: true,
permissions: ["tool:gen:edit"],
children: [
{
path: "index/:tableId(\\d+)",
component: () => import("@/views/tool/gen/editTable"),
name: "GenEdit",
meta: { title: "修改生成配置", activeMenu: "/tool/gen" },
},
],
},
];
return list;
}

@ -1,10 +1,11 @@
import Vue from 'vue'
import Router from 'vue-router'
import Vue from "vue";
import Router from "vue-router";
Vue.use(Router)
Vue.use(Router);
/* Layout */
import Layout from '@/layout'
import Layout from "@/layout";
import { getFilterRouter } from "./filterRouter";
/**
* Note: 路由配置项
@ -29,42 +30,42 @@ import Layout from '@/layout'
*/
// 公共路由
export const constantRoutes = [
export let constantRoutes = [
{
path: '/redirect',
path: "/redirect",
component: Layout,
hidden: true,
children: [
{
path: '/redirect/:path(.*)',
component: () => import('@/views/redirect')
}
]
path: "/redirect/:path(.*)",
component: () => import("@/views/redirect"),
},
],
},
{
path: '/login',
component: () => import('@/views/login'),
hidden: true
path: "/login",
component: () => import("@/views/login"),
hidden: true,
},
{
path: '/register',
component: () => import('@/views/register'),
hidden: true
path: "/register",
component: () => import("@/views/register"),
hidden: true,
},
{
path: '/404',
component: () => import('@/views/error/404'),
hidden: true
path: "/404",
component: () => import("@/views/error/404"),
hidden: true,
},
{
path: '/401',
component: () => import('@/views/error/401'),
hidden: true
path: "/401",
component: () => import("@/views/error/401"),
hidden: true,
},
{
path: '',
path: "",
component: Layout,
redirect: 'index',
redirect: "index",
// children: [
// {
// path: 'index',
@ -74,124 +75,30 @@ export const constantRoutes = [
// },
// ]
},
// {
// path: '/eventList',
// component: Layout,
// redirect: 'eventList',
// children: [
// {
// path: '/eventList',
// component: () => import('@/views/eventList'),
// name: 'EventList',
// meta: { title: '算法事件列表', icon: '', affix: true }
// },
// ]
// },
{
path: '/user',
component: Layout,
hidden: true,
redirect: 'noredirect',
children: [
{
path: 'profile',
component: () => import('@/views/system/user/profile/index'),
name: 'Profile',
meta: { title: '个人中心', icon: 'user' }
}
]
}
]
// 以下测试环境需注释掉 - 正式环境用
];
constantRoutes = [...constantRoutes, ...getFilterRouter()];
// 动态路由,基于用户权限动态去加载
export const dynamicRoutes = [
{
path: '/system/user-auth',
component: Layout,
hidden: true,
permissions: ['system:user:edit'],
children: [
{
path: 'role/:userId(\\d+)',
component: () => import('@/views/system/user/authRole'),
name: 'AuthRole',
meta: { title: '分配角色', activeMenu: '/system/user' }
}
]
},
{
path: '/system/role-auth',
component: Layout,
hidden: true,
permissions: ['system:role:edit'],
children: [
{
path: 'user/:roleId(\\d+)',
component: () => import('@/views/system/role/authUser'),
name: 'AuthUser',
meta: { title: '分配用户', activeMenu: '/system/role' }
}
]
},
{
path: '/system/dict-data',
component: Layout,
hidden: true,
permissions: ['system:dict:list'],
children: [
{
path: 'index/:dictId(\\d+)',
component: () => import('@/views/system/dict/data'),
name: 'Data',
meta: { title: '字典数据', activeMenu: '/system/dict' }
}
]
},
{
path: '/monitor/job-log',
component: Layout,
hidden: true,
permissions: ['monitor:job:list'],
children: [
{
path: 'index/:jobId(\\d+)',
component: () => import('@/views/monitor/job/log'),
name: 'JobLog',
meta: { title: '调度日志', activeMenu: '/monitor/job' }
}
]
},
{
path: '/tool/gen-edit',
component: Layout,
hidden: true,
permissions: ['tool:gen:edit'],
children: [
{
path: 'index/:tableId(\\d+)',
component: () => import('@/views/tool/gen/editTable'),
name: 'GenEdit',
meta: { title: '修改生成配置', activeMenu: '/tool/gen' }
}
]
}
]
// 动态路由,基于用户权限动态去加载 - 公司及本地环境
export const dynamicRoutes = JSON.parse(process.env.VUE_APP_ISTEST)
? []
: getFilterRouter();
// 防止连续点击多次路由报错
let routerPush = Router.prototype.push;
let routerReplace = Router.prototype.replace;
// push
Router.prototype.push = function push(location) {
return routerPush.call(this, location).catch(err => err)
}
return routerPush.call(this, location).catch((err) => err);
};
// replace
Router.prototype.replace = function push(location) {
return routerReplace.call(this, location).catch(err => err)
}
return routerReplace.call(this, location).catch((err) => err);
};
export default new Router({
mode: 'history', // 去掉url中的#
// 测试环境注释掉
mode: "history", // 去掉url中的#
scrollBehavior: () => ({ y: 0 }),
routes: constantRoutes
})
routes: constantRoutes,
});

@ -15,5 +15,6 @@ const getters = {
topbarRouters:state => state.permission.topbarRouters,
defaultRoutes:state => state.permission.defaultRoutes,
sidebarRouters:state => state.permission.sidebarRouters,
debugTime:state => state.debug.debugTime
}
export default getters

@ -7,6 +7,7 @@ import tagsView from './modules/tagsView'
import permission from './modules/permission'
import settings from './modules/settings'
import getters from './getters'
import debug from './modules/debug'
Vue.use(Vuex)
@ -17,7 +18,8 @@ const store = new Vuex.Store({
user,
tagsView,
permission,
settings
settings,
debug
},
getters
})

@ -2,7 +2,9 @@ import Cookies from 'js-cookie'
const state = {
sidebar: {
opened: Cookies.get('sidebarStatus') ? !!+Cookies.get('sidebarStatus') : true,
// opened: Cookies.get('sidebarStatus') ? !!+Cookies.get('sidebarStatus') : true,
// 默认侧边栏打开
opened: true,
withoutAnimation: false,
hide: false
},

@ -0,0 +1,22 @@
const state = {
debugTime:"",
}
const mutations = {
CHANGE_TIME: (state, debugTime) => {
state.debugTime = debugTime
},
}
const actions = {
changeDebugTime({ commit },debugTime) {
commit('CHANGE_TIME',debugTime)
},
}
export default {
namespaced: true,
state,
mutations,
actions
}

@ -6,6 +6,7 @@ const storageSetting = JSON.parse(localStorage.getItem('layout-setting')) || ''
const state = {
title: '',
theme: storageSetting.theme || '#409EFF',
// theme: storageSetting.theme || '#fff',
sideTheme: storageSetting.sideTheme || sideTheme,
showSettings: showSettings,
topNav: storageSetting.topNav === undefined ? topNav : storageSetting.topNav,

@ -2,17 +2,16 @@ import JSEncrypt from 'jsencrypt/bin/jsencrypt.min'
// 密钥对生成 http://web.chacuo.net/netrsakeypair
const publicKey = 'MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAKoR8mX0rGKLqzcWmOzbfj64K8ZIgOdH\n' +
'nzkXSOVOZbFu/TJhZ7rFAN+eaGkl3C4buccQd/EjEsj9ir7ijT7h96MCAwEAAQ=='
const publicKey = 'MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJ2wJTZWLnLZuRppAOevdiloiXfXE3i9rAr1rBg31sj1xAnhfRuDChoo63kMyZBifeiOcNCr49GeO3j+7NlY+yMCAwEAAQ=='
const privateKey = 'MIIBVAIBADANBgkqhkiG9w0BAQEFAASCAT4wggE6AgEAAkEAqhHyZfSsYourNxaY\n' +
'7Nt+PrgrxkiA50efORdI5U5lsW79MmFnusUA355oaSXcLhu5xxB38SMSyP2KvuKN\n' +
'PuH3owIDAQABAkAfoiLyL+Z4lf4Myxk6xUDgLaWGximj20CUf+5BKKnlrK+Ed8gA\n' +
'kM0HqoTt2UZwA5E2MzS4EI2gjfQhz5X28uqxAiEA3wNFxfrCZlSZHb0gn2zDpWow\n' +
'cSxQAgiCstxGUoOqlW8CIQDDOerGKH5OmCJ4Z21v+F25WaHYPxCFMvwxpcw99Ecv\n' +
'DQIgIdhDTIqD2jfYjPTY8Jj3EDGPbH2HHuffvflECt3Ek60CIQCFRlCkHpi7hthh\n' +
'YhovyloRYsM+IS9h/0BzlEAuO0ktMQIgSPT3aFAgJYwKpqRYKlLDVcflZFCKY7u3\n' +
'UP8iWi1Qw0Y='
const privateKey = 'MIIBVQIBADANBgkqhkiG9w0BAQEFAASCAT8wggE7AgEAAkEAnbAlNlYuctm5GmkA\n'+
'5692KWiJd9cTeL2sCvWsGDfWyPXECeF9G4MKGijreQzJkGJ96I5w0Kvj0Z47eP7s\n'+
'2Vj7IwIDAQABAkEAgbPrR+BnYEy5toF8HxXx6Wl0+T/NYlkQ9ArTPTBg2PYTXSvT\n'+
'LoJqrWss688w7WIwUz5lyVKKeRFWkxe9T4RIUQIhAM6BMCzJybFtAszEgBBDdtxj\n'+
'eDiXAk3zcsqcltHE/i/PAiEAw3ulbhgLYnXJIfymCsMgnyrESOyQxKDhQOm2Pnj/\n'+
'YG0CICx9Corroic2S/8falOWpTnPuCvA5L80bouV9qwUm4pjAiEAkJ4U0NHw+jJx\n'+
'Tjd/D08z/wzAkcKRhyYN/tvn+2fAZjECICkVQ6VWohPiibqIdVffCwXK3jSi5SJ3\n'+
'ddcmzYQBJFLv'
// 加密
export function encrypt(txt) {

File diff suppressed because one or more lines are too long

@ -0,0 +1,246 @@
/*
* Leaflet Heatmap Overlay
*
* Copyright (c) 2008-2016, Patrick Wied (https://www.patrick-wied.at)
* Dual-licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
* and the Beerware (http://en.wikipedia.org/wiki/Beerware) license.
*/
; (function (name, context, factory) {
// Supports UMD. AMD, CommonJS/Node.js and browser context
if (typeof module !== "undefined" && module.exports) {
module.exports = factory(
require('./heatmap.min.js'),
require('leaflet')
);
} else if (typeof define === "function" && define.amd) {
define(['./heatmap.min.js', 'leaflet'], factory);
} else {
// browser globals
if (typeof window.h337 === 'undefined') {
throw new Error('heatmap.js must be loaded before the leaflet heatmap plugin');
}
if (typeof window.L === 'undefined') {
throw new Error('Leaflet must be loaded before the leaflet heatmap plugin');
}
context[name] = factory(window.h337, window.L);
}
})("HeatmapOverlay", this, function (h337, L) {
'use strict';
// Leaflet < 0.8 compatibility
if (typeof L.Layer === 'undefined') {
L.Layer = L.Class;
}
var HeatmapOverlay = L.Layer.extend({
initialize: function (config) {
this.cfg = config;
this._el = L.DomUtil.create('div', 'leaflet-zoom-hide');
this._data = [];
this._max = 1;
this._min = 0;
this.cfg.container = this._el;
},
onAdd: function (map) {
var size = map.getSize();
this._map = map;
this._width = size.x;
this._height = size.y;
this._el.style.width = size.x + 'px';
this._el.style.height = size.y + 'px';
this._el.style.position = 'absolute';
this._origin = this._map.layerPointToLatLng(new L.Point(0, 0));
map.getPanes().overlayPane.appendChild(this._el);
if (!this._heatmap) {
this._heatmap = h337.create(this.cfg);
}
// this resets the origin and redraws whenever
// the zoom changed or the map has been moved
map.on('moveend', this._reset, this);
this._draw();
},
addTo: function (map) {
map.addLayer(this);
return this;
},
onRemove: function (map) {
// remove layer's DOM elements and listeners
map.getPanes().overlayPane.removeChild(this._el);
map.off('moveend', this._reset, this);
},
_draw: function () {
if (!this._map) { return; }
var mapPane = this._map.getPanes().mapPane;
var point = mapPane._leaflet_pos;
// reposition the layer
this._el.style[HeatmapOverlay.CSS_TRANSFORM] = 'translate(' +
-Math.round(point.x) + 'px,' +
-Math.round(point.y) + 'px)';
this._update();
},
_update: function () {
var bounds, zoom, scale;
var generatedData = { max: this._max, min: this._min, data: [] };
bounds = this._map.getBounds();
zoom = this._map.getZoom();
scale = Math.pow(2, zoom);
if (this._data.length == 0) {
if (this._heatmap) {
this._heatmap.setData(generatedData);
}
return;
}
var latLngPoints = [];
var radiusMultiplier = this.cfg.scaleRadius ? scale : 1;
var localMax = 0;
var localMin = 0;
var valueField = this.cfg.valueField;
var len = this._data.length;
while (len--) {
var entry = this._data[len];
var value = entry[valueField];
var latlng = entry.latlng;
// we don't wanna render points that are not even on the map ;-)
if (!bounds.contains(latlng)) {
continue;
}
// local max is the maximum within current bounds
localMax = Math.max(value, localMax);
localMin = Math.min(value, localMin);
var point = this._map.latLngToContainerPoint(latlng);
var latlngPoint = { x: Math.round(point.x), y: Math.round(point.y) };
latlngPoint[valueField] = value;
var radius;
if (entry.radius) {
radius = entry.radius * radiusMultiplier;
} else {
radius = (this.cfg.radius || 2) * radiusMultiplier;
}
latlngPoint.radius = radius;
latLngPoints.push(latlngPoint);
}
if (this.cfg.useLocalExtrema) {
generatedData.max = localMax;
generatedData.min = localMin;
}
generatedData.data = latLngPoints;
this._heatmap.setData(generatedData);
},
setData: function (data) {
this._max = data.max || this._max;
this._min = data.min || this._min;
var latField = this.cfg.latField || 'lat';
var lngField = this.cfg.lngField || 'lng';
var valueField = this.cfg.valueField || 'value';
// transform data to latlngs
var data = data.data;
var len = data.length;
var d = [];
while (len--) {
var entry = data[len];
var latlng = new L.LatLng(entry[latField], entry[lngField]);
var dataObj = { latlng: latlng };
dataObj[valueField] = entry[valueField];
if (entry.radius) {
dataObj.radius = entry.radius;
}
d.push(dataObj);
}
this._data = d;
this._draw();
},
// experimential... not ready.
addData: function (pointOrArray) {
if (pointOrArray.length > 0) {
var len = pointOrArray.length;
while (len--) {
this.addData(pointOrArray[len]);
}
} else {
var latField = this.cfg.latField || 'lat';
var lngField = this.cfg.lngField || 'lng';
var valueField = this.cfg.valueField || 'value';
var entry = pointOrArray;
var latlng = new L.LatLng(entry[latField], entry[lngField]);
var dataObj = { latlng: latlng };
dataObj[valueField] = entry[valueField];
this._max = Math.max(this._max, dataObj[valueField]);
this._min = Math.min(this._min, dataObj[valueField]);
if (entry.radius) {
dataObj.radius = entry.radius;
}
this._data.push(dataObj);
this._draw();
}
},
_reset: function () {
this._origin = this._map.layerPointToLatLng(new L.Point(0, 0));
var size = this._map.getSize();
if (this._width !== size.x || this._height !== size.y) {
this._width = size.x;
this._height = size.y;
this._el.style.width = this._width + 'px';
this._el.style.height = this._height + 'px';
this._heatmap._renderer.setDimensions(this._width, this._height);
}
this._draw();
}
});
HeatmapOverlay.CSS_TRANSFORM = (function () {
var div = document.createElement('div');
var props = [
'transform',
'WebkitTransform',
'MozTransform',
'OTransform',
'msTransform'
];
for (var i = 0; i < props.length; i++) {
var prop = props[i];
if (div.style[prop] !== undefined) {
return prop;
}
}
return props[0];
})();
return HeatmapOverlay;
});

@ -0,0 +1,233 @@
// this L.CRS.Baidu from https://github.com/muyao1987/leaflet-tileLayer-baidugaode/blob/master/src/tileLayer.baidu.js
if (L.Proj) {
L.CRS.Baidu = new L.Proj.CRS(
"EPSG:900913",
"+proj=merc +a=6378206 +b=6356584.314245179 +lat_ts=0.0 +lon_0=0.0 +x_0=0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs",
{
resolutions: (function () {
var level = 19;
var res = [];
res[0] = Math.pow(2, 18);
for (var i = 1; i < level; i++) {
res[i] = Math.pow(2, 18 - i);
}
return res;
})(),
origin: [0, 0],
bounds: L.bounds([20037508.342789244, 0], [0, 20037508.342789244]),
}
);
}
L.TileLayer.ChinaProvider = L.TileLayer.extend({
initialize: function (type, options) {
// (type, Object)
var providers = L.TileLayer.ChinaProvider.providers;
options = options || {};
var parts = type.split(".");
var providerName = parts[0];
var mapName = parts[1];
var mapType = parts[2];
var url = providers[providerName][mapName][mapType];
options.subdomains = providers[providerName].Subdomains;
options.key = options.key || providers[providerName].key;
if ("tms" in providers[providerName]) {
options.tms = providers[providerName]["tms"];
}
L.TileLayer.prototype.initialize.call(this, url, options);
},
getTileUrl: function (coords) {
var data = {
s: this._getSubdomain(coords),
x: coords.x,
y: coords.y,
z: this._getZoomForUrl(),
};
if (this._map && !this._map.options.crs.infinite) {
var invertedY = this._globalTileRange.max.y - coords.y;
if (this.options.tms) {
data["y"] = invertedY;
}
data["-y"] = invertedY;
}
data.sx = data.x >> 4;
data.sy = ((1 << data.z) - data.y) >> 4;
return L.Util.template(this._url, L.Util.extend(data, this.options));
},
createTile: function (coords) {
// 创建一个用于绘图的 <canvas> 元素
var tile = L.DomUtil.create("canvas", "leaflet-tile");
// 根据选项设置瓦片的宽度和高度
var size = this.getTileSize();
tile.width = size.x;
tile.height = size.y;
// 获得一个 canvas 上下文,并使用 coords.x、coords.y 和 coords.z 在上面画东西
var ctx = tile.getContext("2d");
// 使用传入的 URL 模板替换变量
var url = this._url
.replace("{s}", this._getSubdomain(coords))
.replace("{x}", coords.x)
.replace("{y}", coords.y)
.replace("{z}", this._getZoomForUrl());
// 创建一个图像对象来加载瓦片
var img = new Image();
img.src = url; // 替换为你的图片路径
img.setAttribute("crossOrigin", "anonymous");
/**获取外部接受的颜色*/
var color = this.options.color;
// 当图片加载完成后,绘制到 Canvas 上
img.onload = function () {
// 绘制图片到 Canvas 上
ctx.drawImage(img, 0, 0, tile.width, tile.height);
if (color) {
// 获取图像的像素数据
var imageData = ctx.getImageData(0, 0, tile.width, tile.height);
// 获取原来的图片的像素颜色
var pixels = imageData.data;
for (let i = 0; i < pixels.length; i += 4) {
const r = pixels[i],
g = pixels[i + 1],
b = pixels[i + 2],
a = pixels[i + 3];
//计算灰度
var grayVal = (r + g + b) / 3;
//灰度反转--会使图片整体变成灰色--方便上色
grayVal = 255 - grayVal;
//将灰度替换掉原始的颜色
pixels[i] = grayVal + color.r;
pixels[i + 1] = grayVal + color.g;
pixels[i + 2] = grayVal + color.b;
//设置一个前景透明度,以便和背景混合
if (color.a) {
pixels[i + 3] = a * color.a;
}
}
// 将修改后的像素数据放回 Canvas
ctx.putImageData(imageData, 0, 0);
}
};
// 返回瓦片,以便在屏幕上呈现
return tile;
},
});
L.TileLayer.ChinaProvider.providers = {
TianDiTu: {
Normal: {
Map: "//t{s}.tianditu.gov.cn/DataServer?T=vec_w&X={x}&Y={y}&L={z}&tk={key}",
Annotion:
"//t{s}.tianditu.gov.cn/DataServer?T=cva_w&X={x}&Y={y}&L={z}&tk={key}",
},
Satellite: {
Map: "//t{s}.tianditu.gov.cn/DataServer?T=img_w&X={x}&Y={y}&L={z}&tk={key}",
Annotion:
"//t{s}.tianditu.gov.cn/DataServer?T=cia_w&X={x}&Y={y}&L={z}&tk={key}",
},
Terrain: {
Map: "//t{s}.tianditu.gov.cn/DataServer?T=ter_w&X={x}&Y={y}&L={z}&tk={key}",
Annotion:
"//t{s}.tianditu.gov.cn/DataServer?T=cta_w&X={x}&Y={y}&L={z}&tk={key}",
},
Subdomains: ["0", "1", "2", "3", "4", "5", "6", "7"],
key: "174705aebfe31b79b3587279e211cb9a",
},
GaoDe: {
Normal: {
// Map: 'https://webst0{s}.is.autonavi.com/appmaptile?style=7&x={x}&y={y}&z={z}' //高清
// Map: '//webrd0{s}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&scale=1&style=8&x={x}&y={y}&z={z}'
// http://202.102.20.34:9001
Map: JSON.parse(process.env.VUE_APP_ISTEST)
? location.origin + "/map/{z}/{x}/{y}.png"
: "https://webst0{s}.is.autonavi.com/appmaptile?style=7&x={x}&y={y}&z={z}",
},
Satellite: {
Map: "https://webst0{s}.is.autonavi.com/appmaptile?style=6&x={x}&y={y}&z={z}",
Annotion:
"https://webst0{s}.is.autonavi.com/appmaptile?style=8&x={x}&y={y}&z={z}",
},
Subdomains: ["1", "2", "3", "4"],
},
Google: {
Normal: {
Map: "//www.google.cn/maps/vt?lyrs=m@189&gl=cn&x={x}&y={y}&z={z}",
},
Satellite: {
Map: "//www.google.cn/maps/vt?lyrs=s@189&gl=cn&x={x}&y={y}&z={z}",
Annotion: "//www.google.cn/maps/vt?lyrs=y@189&gl=cn&x={x}&y={y}&z={z}",
},
Subdomains: [],
},
Geoq: {
Normal: {
Map: "//map.geoq.cn/ArcGIS/rest/services/ChinaOnlineCommunity/MapServer/tile/{z}/{y}/{x}",
PurplishBlue:
"//map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetPurplishBlue/MapServer/tile/{z}/{y}/{x}",
Gray: "//map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetGray/MapServer/tile/{z}/{y}/{x}",
Warm: "//map.geoq.cn/ArcGIS/rest/services/ChinaOnlineStreetWarm/MapServer/tile/{z}/{y}/{x}",
},
Theme: {
Hydro:
"//thematic.geoq.cn/arcgis/rest/services/ThematicMaps/WorldHydroMap/MapServer/tile/{z}/{y}/{x}",
},
Subdomains: [],
},
OSM: {
Normal: {
Map: "//{s}.tile.osm.org/{z}/{x}/{y}.png",
},
Subdomains: ["a", "b", "c"],
},
Baidu: {
Normal: {
Map: "//online{s}.map.bdimg.com/onlinelabel/?qt=tile&x={x}&y={y}&z={z}&styles=pl&scaler=1&p=1",
},
Satellite: {
Map: "//shangetu{s}.map.bdimg.com/it/u=x={x};y={y};z={z};v=009;type=sate&fm=46",
Annotion:
"//online{s}.map.bdimg.com/tile/?qt=tile&x={x}&y={y}&z={z}&styles=sl&v=020",
},
Subdomains: "0123456789",
tms: true,
},
Tencent: {
Normal: {
Map: "//rt{s}.map.gtimg.com/tile?z={z}&x={x}&y={-y}&type=vector&styleid=3",
},
Satellite: {
Map: "//p{s}.map.gtimg.com/sateTiles/{z}/{sx}/{sy}/{x}_{-y}.jpg",
},
Terrain: {
Map: "//p{s}.map.gtimg.com/demTiles/{z}/{sx}/{sy}/{x}_{-y}.jpg",
},
Subdomains: "0123",
},
};
L.tileLayer.chinaProvider = function (type, options) {
return new L.TileLayer.ChinaProvider(type, options);
};

@ -0,0 +1,143 @@
/* eslint-disable */
L.CoordConver = function () {
function a(b, c) {
var d =
-100 +
2 * b +
3 * c +
0.2 * c * c +
0.1 * b * c +
0.2 * Math.sqrt(Math.abs(b)),
d = d + (2 * (20 * Math.sin(6 * b * e) + 20 * Math.sin(2 * b * e))) / 3,
d = d + (2 * (20 * Math.sin(c * e) + 40 * Math.sin((c / 3) * e))) / 3
return (d +=
(2 * (160 * Math.sin((c / 12) * e) + 320 * Math.sin((c * e) / 30))) / 3)
}
function f(b, c) {
var d =
300 +
b +
2 * c +
0.1 * b * b +
0.1 * b * c +
0.1 * Math.sqrt(Math.abs(b)),
d = d + (2 * (20 * Math.sin(6 * b * e) + 20 * Math.sin(2 * b * e))) / 3,
d = d + (2 * (20 * Math.sin(b * e) + 40 * Math.sin((b / 3) * e))) / 3
return (d +=
(2 * (150 * Math.sin((b / 12) * e) + 300 * Math.sin((b / 30) * e))) / 3)
}
this.getCorrdType = function (b) {
var c = 'wgs84'
switch (b.split('.')[0]) {
case 'Geoq':
case 'GaoDe':
case 'Google':
c = 'gcj02'
break
case 'Baidu':
c = 'bd09'
break
case 'OSM':
case 'TianDiTu':
c = 'wgs84'
}
return c
}
this.bd09_To_gps84 = function (b, c) {
var d = this.bd09_To_gcj02(b, c)
return this.gcj02_To_gps84(d.lng, d.lat)
}
this.gps84_To_bd09 = function (b, c) {
var d = this.gps84_To_gcj02(b, c)
return this.gcj02_To_bd09(d.lng, d.lat)
}
this.gps84_To_gcj02 = function (b, c) {
var d = a(b - 105, c - 35),
k = f(b - 105, c - 35),
l = (c / 180) * e,
g = Math.sin(l),
g = 1 - n * g * g,
m = Math.sqrt(g),
d = (180 * d) / (((h * (1 - n)) / (g * m)) * e),
k = (180 * k) / ((h / m) * Math.cos(l) * e)
return { lng: b + k, lat: c + d }
}
this.gcj02_To_gps84 = function (b, c) {
var d = a(b - 105, c - 35),
k = f(b - 105, c - 35),
l = (c / 180) * e,
g = Math.sin(l),
g = 1 - n * g * g,
m = Math.sqrt(g),
d = (180 * d) / (((h * (1 - n)) / (g * m)) * e),
k = (180 * k) / ((h / m) * Math.cos(l) * e)
return { lng: 2 * b - (b + k), lat: 2 * c - (c + d) }
}
this.gcj02_To_bd09 = function (b, c) {
var d = Math.sqrt(b * b + c * c) + 2e-5 * Math.sin(c * p),
a = Math.atan2(c, b) + 3e-6 * Math.cos(b * p)
return { lng: d * Math.cos(a) + 0.0065, lat: d * Math.sin(a) + 0.006 }
}
this.bd09_To_gcj02 = function (b, c) {
var d = b - 0.0065,
a = c - 0.006,
e = Math.sqrt(d * d + a * a) - 2e-5 * Math.sin(a * p),
d = Math.atan2(a, d) - 3e-6 * Math.cos(d * p)
return { lng: e * Math.cos(d), lat: e * Math.sin(d) }
}
var e = 3.141592653589793,
h = 6378245,
n = 0.006693421622965943,
p = (3e3 * e) / 180
}
L.coordConver = function () {
return new L.CoordConver()
}
L.TileLayer.ChinaProvider.include({
addTo: function (a) {
a.options.corrdType || (a.options.corrdType = this.options.corrdType)
a.addLayer(this)
return this
},
})
L.tileLayer.chinaProvider = function (a, f) {
f = f || {}
f.corrdType = L.coordConver().getCorrdType(a)
return new L.TileLayer.ChinaProvider(a, f)
}
L.GridLayer.include({
_setZoomTransform: function (a, f, e) {
var h = f
void 0 != h &&
this.options &&
('gcj02' == this.options.corrdType
? (h = L.coordConver().gps84_To_gcj02(f.lng, f.lat))
: 'bd09' == this.options.corrdType &&
(h = L.coordConver().gps84_To_bd09(f.lng, f.lat)))
f = this._map.getZoomScale(e, a.zoom)
e = a.origin
.multiplyBy(f)
.subtract(this._map._getNewPixelOrigin(h, e))
.round()
L.Browser.any3d
? L.DomUtil.setTransform(a.el, e, f)
: L.DomUtil.setPosition(a.el, e)
},
_getTiledPixelBounds: function (a) {
var f = a
void 0 != f &&
this.options &&
('gcj02' == this.options.corrdType
? (f = L.coordConver().gps84_To_gcj02(a.lng, a.lat))
: 'bd09' == this.options.corrdType &&
(f = L.coordConver().gps84_To_bd09(a.lng, a.lat)))
a = this._map
var e = a._animatingZoom
? Math.max(a._animateToZoom, a.getZoom())
: a.getZoom(),
e = a.getZoomScale(e, this._tileZoom),
f = a.project(f, this._tileZoom).floor()
a = a.getSize().divideBy(2 * e)
return new L.Bounds(f.subtract(a), f.add(a))
},
})

@ -0,0 +1,335 @@
/* eslint-disable */
(function (factory, window) {
// define an AMD module that relies on 'leaflet'
if (typeof define === 'function' && define.amd) {
define(['leaflet'], factory);
// define a Common JS module that relies on 'leaflet'
} else if (typeof exports === 'object') {
module.exports = factory(require('leaflet'));
}
// attach your plugin to the global 'L' letiable
if (typeof window !== 'undefined' && window.L) {
window.L.ArrowPath = factory(L);
}
}(function (L) {
L.SVG.include({
_updateStyle: function (layer) {
let path = layer._path,
options = layer.options;
if (!path) {
return;
}
if (options.stroke) {
path.setAttribute('stroke', options.color);
path.setAttribute('stroke-opacity', options.opacity);
path.setAttribute('stroke-width', options.weight);
path.setAttribute('stroke-linecap', options.lineCap);
path.setAttribute('stroke-linejoin', options.lineJoin);
if (options.dashArray) {
path.setAttribute('stroke-dasharray', options.dashArray);
} else {
path.removeAttribute('stroke-dasharray');
}
if (options.dashOffset) {
path.setAttribute('stroke-dashoffset', options.dashOffset);
} else {
path.removeAttribute('stroke-dashoffset');
}
} else {
path.setAttribute('stroke', 'none');
}
if (options.fill) {
this._polyFill(layer, path, options);
path.setAttribute('fill-opacity', options.fillOpacity);
path.setAttribute('fill-rule', options.fillRule || 'evenodd');
} else {
path.setAttribute('fill', 'none');
}
},
_polyFill(layer, path, options) {
let fillColor = options.fillColor;
let isLinearGradient = fillColor.match(/^linearGradient\(/);
let isRadialGradient = fillColor.match(/^radialGradient\(/);
if (fillColor.match(/^#/)) {
path.setAttribute('fill', fillColor || options.color);
} else if (isLinearGradient || isRadialGradient) {
let gradientOpt = this._addGradient(fillColor);
if (isLinearGradient) {
this._addLinearGradient(layer, gradientOpt);
} else {
this._addRadialGradient(layer, gradientOpt);
}
} else if (fillColor.match(/^url\(/)) {
this._fillByImage(layer);
}
},
_addLinearGradient: function (layer, gradientOpt) {
let path = layer._path;
let colorStr = layer.options.fillColor;
let gradientId = 'gradient' + gradientOpt.index;
this._addDefs();
if (!gradientOpt.exist) {
let gradient = L.SVG.create('linearGradient');
gradient.setAttribute('id', gradientId);
let arrMap = this._getLinearProperties(colorStr, ['linearGradient(', ')']);
this._addStops(gradient, arrMap);
this._addAngle(gradient, arrMap.angle);
this._defs.appendChild(gradient);
}
path.setAttribute('fill', 'url(#' + gradientId + ')');
},
_addRadialGradient: function (layer, gradientOpt) {
let path = layer._path;
let colorStr = layer.options.fillColor;
let gradientId = 'gradient' + gradientOpt.index;
this._addDefs();
if (!gradientOpt.exist) {
let gradient = L.SVG.create('radialGradient');
gradient.setAttribute('id', gradientId);
let arrMap = this._getRadialProperties(colorStr, ['radialGradient(', ')']);
this._addStops(gradient, arrMap);
this._addAttribute(gradient, arrMap);
//
this._defs.appendChild(gradient);
}
path.setAttribute('fill', 'url(#' + gradientId + ')');
},
_addAttribute(gradient, arr) {
gradient.setAttribute('cx', arr.cx);
gradient.setAttribute('cy', arr.cy);
gradient.setAttribute('r', arr.r);
gradient.setAttribute('fx', arr.fx);
gradient.setAttribute('fy', arr.fy);
},
_getRadialProperties(colorStr, replaceArr) {
let string = colorStr;
for (let i = 0, l = replaceArr.length; i < l; i++) {
let str = replaceArr[i];
string = string.replace(str, '');
}
let arrays = string.split(/[\,]+/);
let colorArr = arrays.slice(5);
let resColors = [];
let resOffsets = [];
let offsetNum = 0;
for (let i = 0, l = colorArr.length; i < l; i++) {
let str = colorArr[i];
let opts = str.trim().split(/\s+/);
resColors.push(opts[0]);
if (opts.length > 1 || i === l - 1) {
let offset;
if (opts.length > 1) {
offset = parseFloat(opts[1]);
} else {
offset = 100;
}
let len = resOffsets.length;
if (offsetNum > 0) {
let startNum = len - offsetNum - 1;
let startVal = parseFloat(resOffsets[startNum]);
let step = (offset - startVal) / (offsetNum + 1);
for (let j = 1; j <= offsetNum; j++) {
resOffsets[startNum + j] = startVal + step * j + '%';
}
offsetNum = 0;
}
resOffsets.push(offset + '%');
} else {
if (i !== 0) {
offsetNum = offsetNum + 1;
resOffsets.push('');
} else {
resOffsets.push('0%');
}
}
}
return {
cx: arrays[0].trim(),
cy: arrays[1].trim(),
r: arrays[2].trim(),
fx: arrays[3].trim(),
fy: arrays[4].trim(),
colors: resColors,
offsets: resOffsets
}
},
_addGradient(gradient) {
if (!this._gradientArray) {
this._gradientArray = [];
}
let gradientStr = gradient.split(/[\s\,\-\(\)]+/).join('');
let index = this._gradientArray.indexOf(gradientStr);
if (index > -1) {
return { index: index, exist: true }
}
this._gradientArray.push(gradientStr);
return { index: this._gradientArray.length - 1, exist: false }
},
_addDefs() {
if (!this._defs) {
this._defs = L.SVG.create('defs');
this._container.appendChild(this._defs);
}
},
_addAngle(gradient, angle) {
gradient.setAttribute('x1', '0');
gradient.setAttribute('y1', '0');
gradient.setAttribute('x2', '1');
gradient.setAttribute('y2', '0');
gradient.setAttribute('gradientTransform', 'rotate(' + angle.replace('deg', '') + ')');
},
_addStops(gradient, options) {
let colors = options.colors;
let offsets = options.offsets;
for (let i = 0, len = colors.length; i < len; i++) {
let stop = L.SVG.create('stop');
stop.setAttribute('offset', offsets[i]);
stop.setAttribute('stop-color', colors[i]);
gradient.appendChild(stop);
}
},
_getLinearProperties(colorStr, replaceArr) {
let string = colorStr;
for (let i = 0, l = replaceArr.length; i < l; i++) {
let str = replaceArr[i];
string = string.replace(str, '');
}
let arrays = string.split(/[\,]+/);
let colorArr = arrays.slice(1);
let resAngle = arrays[0].trim();
let resColors = [];
let resOffsets = [];
let offsetNum = 0;
for (let i = 0, l = colorArr.length; i < l; i++) {
let str = colorArr[i];
let opts = str.trim().split(/\s+/);
resColors.push(opts[0]);
if (opts.length > 1 || i === l - 1) {
let offset;
if (opts.length > 1) {
offset = parseFloat(opts[1]);
} else {
offset = 100;
}
let len = resOffsets.length;
if (offsetNum > 0) {
let startNum = len - offsetNum - 1;
let startVal = parseFloat(resOffsets[startNum]);
let step = (offset - startVal) / (offsetNum + 1);
for (let j = 1; j <= offsetNum; j++) {
resOffsets[startNum + j] = startVal + step * j + '%';
}
offsetNum = 0;
}
resOffsets.push(offset + '%');
} else {
if (i !== 0) {
offsetNum = offsetNum + 1;
resOffsets.push('');
} else {
resOffsets.push('0%');
}
}
}
return {
angle: resAngle,
colors: resColors,
offsets: resOffsets
}
},
//借鉴自插件leaflet-polygon-fillPattern
_fillByImage: function (layer) {
let path = layer._path,
options = layer.options,
fill = options.fillColor;
this._addDefs();
let _img_url = fill.replace(/url\(+/, '').replace(/\)+/, '');/*.substring(4, fill.length - 1)*/
let _refOption = this._addRefId(_img_url);
let _ref_id = _img_url + _refOption.index;
if (!_refOption.exist) {
this._addPattern(_img_url, _ref_id, options);
}
path.setAttribute('fill', "url(#" + _ref_id + ")");
},
_addRefId(url) {
if (!this._imgUrls) {
this._imgUrls = [];
}
let index = this._imgUrls.indexOf(url);
if (index > -1) {
return { index: index, exist: true }
}
this._imgUrls.push(url);
return { index: this._imgUrls.length - 1, exist: false }
},
_addPattern(_img_url, _ref_id, options) {
let _im = new Image();
_im.src = _img_url;
let _p = L.SVG.create('pattern');
_p.setAttribute('id', _ref_id);
_p.setAttribute('x', '0');
_p.setAttribute('y', '0');
_p.setAttribute('patternUnits', 'userSpaceOnUse');
_p.setAttribute('width', '24');
_p.setAttribute('height', '24');
let _rect = L.SVG.create('rect');
_rect.setAttribute('width', 24);
_rect.setAttribute('height', 24);
_rect.setAttribute('x', 0);
_rect.setAttribute('x', 0);
_rect.setAttribute('fill', options.fillColor || options.color);
let _img = L.SVG.create('image');
_img.setAttribute('x', '0');
_img.setAttribute('y', '0');
_img.setAttributeNS('http://www.w3.org/1999/xlink', 'href', _img_url);
_img.setAttribute('width', '24');
_img.setAttribute('height', '24');
_p.appendChild(_rect);
_p.appendChild(_img);
this._defs.appendChild(_p);
_im.onload = function () {
_p.setAttribute('width', _im.width);
_p.setAttribute('height', _im.height);
_img.setAttribute('width', _im.width);
_img.setAttribute('height', _im.height);
};
}
})
}, window));

@ -1,114 +1,159 @@
import axios from 'axios'
import { Notification, MessageBox, Message, Loading } from 'element-ui'
import store from '@/store'
import { getToken } from '@/utils/auth'
import errorCode from '@/utils/errorCode'
import axios from "axios";
import { Notification, MessageBox, Message, Loading } from "element-ui";
import store from "@/store";
import { getToken } from "@/utils/auth";
import errorCode from "@/utils/errorCode";
import { tansParams, blobValidate } from "@/utils/ruoyi";
import cache from '@/plugins/cache'
import { saveAs } from 'file-saver'
import cache from "@/plugins/cache";
import { saveAs } from "file-saver";
let downloadLoadingInstance;
// 是否显示重新登录
export let isRelogin = { show: false };
axios.defaults.headers['Content-Type'] = 'application/json;charset=utf-8'
axios.defaults.headers["Content-Type"] = "application/json;charset=utf-8";
// 创建axios实例
const service = axios.create({
// axios中请求配置有baseURL选项表示请求URL公共部分
baseURL: process.env.NODE_ENV === "production" ? location.origin + '/api' : process.env.VUE_APP_BASE_API,
baseURL: JSON.parse(process.env.VUE_APP_ISTEST)
? location.origin + "/api"
: process.env.VUE_APP_BASE_API,
// 超时
timeout: 10000
})
timeout: 10000,
});
// request拦截器
service.interceptors.request.use(config => {
// 是否需要设置 token
const isToken = (config.headers || {}).isToken === false
// 是否需要防止数据重复提交
const isRepeatSubmit = (config.headers || {}).repeatSubmit === false
if (getToken() && !isToken) {
config.headers['Authorization'] = 'Bearer ' + getToken() // 让每个请求携带自定义token 请根据实际情况自行修改
}
// get请求映射params参数
if (config.method === 'get' && config.params) {
let url = config.url + '?' + tansParams(config.params);
url = url.slice(0, -1);
config.params = {};
config.url = url;
}
if (!isRepeatSubmit && (config.method === 'post' || config.method === 'put')) {
const requestObj = {
url: config.url,
data: typeof config.data === 'object' ? JSON.stringify(config.data) : config.data,
time: new Date().getTime()
service.interceptors.request.use(
(config) => {
// 是否需要设置 token
const isToken = (config.headers || {}).isToken === false;
// 是否需要防止数据重复提交
const isRepeatSubmit = (config.headers || {}).repeatSubmit === false;
if (!JSON.parse(process.env.VUE_APP_ISTEST)) {
if (getToken() && !isToken) {
config.headers["Authorization"] = "Bearer " + getToken(); // 让每个请求携带自定义token 请根据实际情况自行修改
}
} else {
if (localStorage.getItem("Admin-Token") && !isToken) {
config.headers["Authorization"] =
"Bearer " + localStorage.getItem("Admin-Token"); // 让每个请求携带自定义token 请根据实际情况自行修改
}
}
const requestSize = Object.keys(JSON.stringify(requestObj)).length; // 请求数据大小
const limitSize = 5 * 1024 * 1024; // 限制存放数据5M
if (requestSize >= limitSize) {
console.warn(`[${config.url}]: ` + '请求数据大小超出允许的5M限制无法进行防重复提交验证。')
return config;
// get请求映射params参数
if (config.method === "get" && config.params) {
let url = config.url + "?" + tansParams(config.params);
url = url.slice(0, -1);
config.params = {};
config.url = url;
}
const sessionObj = cache.session.getJSON('sessionObj')
if (sessionObj === undefined || sessionObj === null || sessionObj === '') {
cache.session.setJSON('sessionObj', requestObj)
} else {
const s_url = sessionObj.url; // 请求地址
const s_data = sessionObj.data; // 请求数据
const s_time = sessionObj.time; // 请求时间
const interval = 1000; // 间隔时间(ms),小于此时间视为重复提交
if (s_data === requestObj.data && requestObj.time - s_time < interval && s_url === requestObj.url) {
const message = '数据正在处理,请勿重复提交';
console.warn(`[${s_url}]: ` + message)
return Promise.reject(new Error(message))
if (
!isRepeatSubmit &&
(config.method === "post" || config.method === "put")
) {
const requestObj = {
url: config.url,
data:
typeof config.data === "object"
? JSON.stringify(config.data)
: config.data,
time: new Date().getTime(),
};
const requestSize = Object.keys(JSON.stringify(requestObj)).length; // 请求数据大小
const limitSize = 5 * 1024 * 1024; // 限制存放数据5M
if (requestSize >= limitSize) {
console.warn(
`[${config.url}]: ` +
"请求数据大小超出允许的5M限制无法进行防重复提交验证。"
);
return config;
}
const sessionObj = cache.session.getJSON("sessionObj");
if (
sessionObj === undefined ||
sessionObj === null ||
sessionObj === ""
) {
cache.session.setJSON("sessionObj", requestObj);
} else {
cache.session.setJSON('sessionObj', requestObj)
const s_url = sessionObj.url; // 请求地址
const s_data = sessionObj.data; // 请求数据
const s_time = sessionObj.time; // 请求时间
const interval = 1000; // 间隔时间(ms),小于此时间视为重复提交
if (
s_data === requestObj.data &&
requestObj.time - s_time < interval &&
s_url === requestObj.url
) {
const message = "数据正在处理,请勿重复提交";
console.warn(`[${s_url}]: ` + message);
return Promise.reject(new Error(message));
} else {
cache.session.setJSON("sessionObj", requestObj);
}
}
}
return config;
},
(error) => {
console.log(error);
Promise.reject(error);
}
return config
}, error => {
console.log(error)
Promise.reject(error)
})
);
// 响应拦截器
service.interceptors.response.use(res => {
service.interceptors.response.use(
(res) => {
// 未设置状态码则默认成功状态
const code = res.data.code || 200;
// 获取错误信息
const msg = errorCode[code] || res.data.msg || errorCode['default']
const msg = errorCode[code] || res.data.msg || errorCode["default"];
// 二进制数据则直接返回
if (res.request.responseType === 'blob' || res.request.responseType === 'arraybuffer') {
return res.data
if (
res.request.responseType === "blob" ||
res.request.responseType === "arraybuffer"
) {
return res.data;
}
if (code === 401) {
if (!isRelogin.show) {
isRelogin.show = true;
MessageBox.confirm('登录状态已过期,您可以继续留在该页面,或者重新登录', '系统提示', { confirmButtonText: '重新登录', cancelButtonText: '取消', type: 'warning' }).then(() => {
isRelogin.show = false;
store.dispatch('LogOut').then(() => {
location.href = '/index';
MessageBox.confirm(
"登录状态已过期,您可以继续留在该页面,或者重新登录",
"系统提示",
{
confirmButtonText: "重新登录",
cancelButtonText: "取消",
type: "warning",
}
)
.then(() => {
isRelogin.show = false;
store.dispatch("LogOut").then(() => {
location.href = "/index";
});
})
}).catch(() => {
isRelogin.show = false;
});
}
return Promise.reject('无效的会话,或者会话已过期,请重新登录。')
.catch(() => {
isRelogin.show = false;
});
}
return Promise.reject("无效的会话,或者会话已过期,请重新登录。");
} else if (code === 500) {
Message({ message: msg, type: 'error' })
return Promise.reject(new Error(msg))
Message({ message: msg, type: "error" });
return Promise.reject(new Error(msg));
} else if (code === 601) {
Message({ message: msg, type: 'warning' })
return Promise.reject('error')
Message({ message: msg, type: "warning" });
return Promise.reject("error");
} else if (code !== 200) {
Notification.error({ title: msg })
return Promise.reject('error')
Notification.error({ title: msg });
return Promise.reject("error");
} else {
return res.data
return res.data;
}
},
error => {
console.log('err' + error)
(error) => {
console.log("err" + error);
let { message } = error;
if (message == "Network Error") {
message = "后端接口连接异常";
@ -117,36 +162,48 @@ service.interceptors.response.use(res => {
} else if (message.includes("Request failed with status code")) {
message = "系统接口" + message.substr(message.length - 3) + "异常";
}
Message({ message: message, type: 'error', duration: 5 * 1000 })
return Promise.reject(error)
Message({ message: message, type: "error", duration: 5 * 1000 });
return Promise.reject(error);
}
)
);
// 通用下载方法
export function download(url, params, filename, config) {
downloadLoadingInstance = Loading.service({ text: "正在下载数据,请稍候", spinner: "el-icon-loading", background: "rgba(0, 0, 0, 0.7)", })
return service.post(url, params, {
transformRequest: [(params) => { return tansParams(params) }],
headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
responseType: 'blob',
...config
}).then(async (data) => {
const isBlob = blobValidate(data);
if (isBlob) {
const blob = new Blob([data])
saveAs(blob, filename)
} else {
const resText = await data.text();
const rspObj = JSON.parse(resText);
const errMsg = errorCode[rspObj.code] || rspObj.msg || errorCode['default']
Message.error(errMsg);
}
downloadLoadingInstance.close();
}).catch((r) => {
console.error(r)
Message.error('下载文件出现错误,请联系管理员!')
downloadLoadingInstance.close();
})
downloadLoadingInstance = Loading.service({
text: "正在下载数据,请稍候",
spinner: "el-icon-loading",
background: "rgba(0, 0, 0, 0.7)",
});
return service
.post(url, params, {
transformRequest: [
(params) => {
return tansParams(params);
},
],
headers: { "Content-Type": "application/x-www-form-urlencoded" },
responseType: "blob",
...config,
})
.then(async (data) => {
const isBlob = blobValidate(data);
if (isBlob) {
const blob = new Blob([data]);
saveAs(blob, filename);
} else {
const resText = await data.text();
const rspObj = JSON.parse(resText);
const errMsg =
errorCode[rspObj.code] || rspObj.msg || errorCode["default"];
Message.error(errMsg);
}
downloadLoadingInstance.close();
})
.catch((r) => {
console.error(r);
Message.error("下载文件出现错误,请联系管理员!");
downloadLoadingInstance.close();
});
}
export default service
export default service;

@ -0,0 +1,333 @@
<template>
<el-dialog
:visible.sync="showCK"
width="80%"
:show-close="false"
:close-on-click-modal="false"
:close-on-press-escape="false"
custom-class="travel"
>
<div slot="title" class="dialog-title">
<div class="dialog-title-text">{{ title }}</div>
<i @click="close" class="el-icon-close"></i>
</div>
<div class="audit-generalize">
<el-row>
<el-col :span="8">
<div class="grid-content" v-if="auditStatus == 1">
<div class="grid-title">概括名称</div>
<div class="grid-value-btn">
<el-tooltip class="item" effect="light" :content="audioInfo.title" placement="top">
<!-- @blur="titleBlur" -->
<el-input class="grid-value-value" v-loading="InputLoading" v-model="audioInfo.title" placeholder="概括名称" :disabled="disabled"></el-input>
</el-tooltip>
<el-button size="mini" @click="changeTitle"><img src="@/assets/images/changeTitle.png" alt=""> 修改标题</el-button>
</div>
</div>
<div class="lookTitle" v-else>
<div class="grid-content">
<div class="grid-title">概括名称</div>
<el-tooltip class="item" effect="light" :content="audioInfo.title" placement="top">
<div class="grid-value">{{ audioInfo.title }}</div>
</el-tooltip>
</div>
<el-button size="mini" v-if="audioInfo.titleBefore" @click="lookTitleBefore"><img src="@/assets/images/changeTitle.png" alt=""> </el-button>
</div>
</el-col>
<el-col :span="8">
<div class="grid-content">
<div class="grid-title">预警时间</div>
<div class="grid-value">{{ audioInfo.firstWarnTimeDate || audioInfo.caseDate }}</div>
</div>
</el-col>
<el-col :span="8">
<div class="grid-content">
<div class="grid-title">事件数量</div>
<div class="grid-value">{{ audioInfo.nums }}</div>
</div>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<div class="grid-content">
<div class="grid-title">预警因素</div>
<el-tooltip class="item" effect="light" :content="audioInfo.warnFactor" placement="top">
<div class="grid-value">{{ audioInfo.warnFactor }}</div>
</el-tooltip>
</div>
</el-col>
<el-col :span="8">
<div class="grid-content">
<div class="grid-title">预警类别</div>
<div class="grid-value warning-type">{{ audioInfo.msgType == '1' ? "群体事件" : audioInfo.msgType == '2' ? "同人同诉" : audioInfo.msgType == '3' ? "紧急事件" : audioInfo.msgType == '4' ? "重点人员" : audioInfo.msgType == '5' ? "一人多诉" : "" }}</div>
</div>
</el-col>
</el-row>
</div>
<div class="audit-table">
<section class="table-box">
<div class="table-item">
<el-table v-loading="loading" :data="tableData" :cell-class-name="addStyle" border>
<el-table-column
type="index"
label="序号"
width="55"
align="center"
/>
<el-table-column label="工单编号" align="center" prop="caseSerial">
</el-table-column>
<el-table-column label="案件描述" width="180" align="center" prop="caseContent">
<template slot-scope="scope">
<el-tooltip class="item" effect="light" placement="top">
<template slot="content">
<p style="width: 400px;">{{ scope.row.caseContent }}</p>
</template>
<div class="anjianmiaoshuTwo"> {{ scope.row.caseContent }}</div>
</el-tooltip>
</template>
</el-table-column>
<el-table-column label="地点" align="center" prop="caseAddress">
</el-table-column>
<el-table-column label="上报时间" align="center" prop="caseDate">
</el-table-column>
<el-table-column label="审核时间" v-if="auditStatus == 2" align="center" prop="auditTime">
</el-table-column>
<el-table-column label="审核结果" v-if="auditStatus == 2" align="center" prop="isReport">
<template slot-scope="scope">
<span class="sign" v-if="scope.row.isReport == 1 || scope.row.isReport == 2"></span>
<span class="unmark" v-else></span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="operation-box" >
<template slot-scope="scope">
<div class="operation">
<el-radio-group v-model="scope.row.radio" @change.native="changRadio(scope.row)" v-if="auditStatus == 1">
<el-radio v-removeAriaHiddent :label="1">符合</el-radio>
<el-radio v-removeAriaHiddent :label="2" value="13212">不符合</el-radio>
</el-radio-group>
<el-button @click="toDetail(scope.row)" type="text" style="margin-left: 20px;" class="sqbtn sqbtn1">
查看详情
</el-button>
</div>
</template>
</el-table-column>
</el-table>
</div>
</section>
<div class="my-pagination">
<pagination
:total="total"
:page="pages.current"
:limit="pages.size"
@pagination="getPagination"
:current-page.sync="pages.current"
></pagination>
</div>
</div>
<div slot="footer" class="dialog-footer" v-if="auditStatus == 1">
<el-button type="primary" @click="reported(1)"></el-button>
<!-- <el-button type="info" plain>不上报</el-button> -->
<el-button type="danger" @click="reported(2)">退</el-button>
<!-- <el-button type="success" @click="reported(3)"></el-button> -->
</div>
<el-dialog
width="30%"
title="查看标题"
:visible.sync="innerVisible"
append-to-body>
<el-descriptions :column="1">
<el-descriptions-item label="当前标题">{{ audioInfo.title }}</el-descriptions-item>
<el-descriptions-item label="历史标题">{{ audioInfo.titleBefore }}</el-descriptions-item>
</el-descriptions>
</el-dialog>
<urgency-audit title="工单详情" ref="urgencyAudit" :auditStatus="auditStatusTwo"></urgency-audit>
</el-dialog>
</template>
<script>
import { auditList, eventChangeIsReport, editTitle } from "@/api/eventPage"
import urgencyAudit from '@/views/components/urgencyAudit.vue'
export default {
components:{
urgencyAudit
},
data() {
return {
showCK:false,
audioInfo:{},
backupsInfo:{},
loading:false,
InputLoading:false,
tableData:[],
total:0,
pages: {
current: 1,
size: 10
},
disabled:true,
multipleSelection: [],
innerVisible:false,
auditStatusTwo: 1,
}
},
props:{
title:{
type:String,
default:""
},
auditStatus:{
type:Number,
required: true
}
},
methods:{
//
open(row){
this.audioInfo = {...row};
this.backupsInfo = {...row};
this.showCK = true;
this.getList(row.innerEventId);
},
//
close(){
this.showCK = false;
this.InputLoading = false;
this.loading = false;
this.multipleSelection = [];
this.pages = {
current: 1,
size: 10
}
},
getList(id){
this.loading = true;
auditList(id,{...this.pages}).then(res=>{
const deepCopy = JSON.parse(JSON.stringify(res.data.records));
this.tableData = deepCopy;
if(this.multipleSelection.length > 0) {
this.tableData.forEach(item=>{
this.$set(item, 'radio', 1);
this.multipleSelection.forEach(itemTwo=>{
if(itemTwo == item.caseSerial) {
this.$set(item, 'radio', 2);
}
})
})
} else {
this.tableData.map(item=>{
this.$set(item, 'radio', 1);
})
}
this.total = res.data.total;
this.loading = false;
}).catch(err=>{
this.loading = false;
})
},
//
toDetail(item){
// console.log(item);
this.auditStatusTwo = 2;
this.$refs.urgencyAudit.open(this.audioInfo,item);
},
changRadio(row){
if(row.radio == 2) {
this.multipleSelection.push(row.caseSerial);
} else if(row.radio == 1){
this.multipleSelection = this.multipleSelection.filter((item)=> item !== row.caseSerial)
}
},
// /退
reported(id){
this.$confirm(`确定要${id == 1 ? '重新上报驾驶舱' : id == 2 ? '退回重训练' : id == 3 ? '审核通过':''}吗?`, "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}).then(() => {
if(id !== 3) {
// if(this.multipleSelection.length > 0 || this.backupsInfo.title !== this.audioInfo.title) {
if(this.backupsInfo.title !== this.audioInfo.title) {
eventChangeIsReport({isReport:id,caseSerial:this.multipleSelection,innerEventId:this.audioInfo.innerEventId,newTitle:this.audioInfo.title,oldTitle:this.backupsInfo.title}).then(res=>{
// console.log(res);
this.multipleSelection = [];
this.$message({
type: "success",
message: id == 1 ? '已上报驾驶舱' : '已退回重训练' + "!",
});
this.$emit('closeDialog')
this.close();
})
} else {
eventChangeIsReport({isReport:id,caseSerial:this.multipleSelection,innerEventId:this.audioInfo.innerEventId}).then(res=>{
// console.log(res);
this.multipleSelection = [];
this.$message({
type: "success",
message: id == 1 ? '已上报驾驶舱' : '已退回重训练' + "!",
});
this.$emit('closeDialog')
this.close();
})
}
// } else {
// this.$message.error(`${id == 1 ? '' : id == 2 ? '退' : ''}`);
// }
} else {
if(this.backupsInfo.title !== this.audioInfo.title) {
this.$message.error(`您已修改标题,请上报驾驶舱或退回重训练`);
} else if(this.multipleSelection.length > 0) {
this.$message.error(`您已标记工单为不符合,请上报驾驶舱或退回重训练`);
} else {
eventChangeIsReport({isReport:id,innerEventId:this.audioInfo.innerEventId}).then(res=>{
// console.log(res);
this.$message({
type: "success",
message: "审核完成",
});
this.$emit('closeDialog')
this.close();
})
}
}
})
},
//
lookTitleBefore(){
this.innerVisible = true;
},
//
changeTitle(){
this.disabled = false;
},
//
titleBlur(){
this.disabled = true;
if(this.backupsInfo.title !== this.audioInfo.title) {
// this.InputLoading = true;
// editTitle({title:this.audioInfo.title, innerEventId:this.audioInfo.innerEventId}).then(res=>{
// if(res.code == 200) {
// this.$message({
// type: "success",
// message: "!",
// });
// this.InputLoading = false;
// }
// }).catch(err=>{
// this.InputLoading = false;
// })
}
},
//
getPagination(pages) {
this.pages.current = pages.page;
this.pages.size = pages.limit;
this.getList(this.audioInfo.innerEventId);
},
//
addStyle({row, column, rowIndex, columnIndex}) {
if(columnIndex === 2) {
return "columnFactor"
}
},
},
}
</script>

@ -0,0 +1,198 @@
<template>
<el-dialog
:visible.sync="showCK"
width="85%"
:show-close="false"
:close-on-click-modal="false"
:close-on-press-escape="false"
custom-class="travel"
>
<div slot="title" class="dialog-title">
<div class="dialog-title-text">{{ title }}</div>
<i @click="close" class="el-icon-close"></i>
</div>
<div class="audit-generalize">
<el-row>
<el-col :span="12">
<div class="grid-content">
<div class="grid-title">事件名称</div>
<div class="grid-value">{{ audioInfo.title }}</div>
</div>
</el-col>
<el-col :span="12">
<div class="grid-content">
<div class="grid-title">调用时间</div>
<div class="grid-value">{{ audioInfo.createTime }}</div>
</div>
</el-col>
</el-row>
</div>
<div class="audit-table">
<section class="table-box">
<div class="table-item">
<el-table v-loading="loading" :data="tableData" :cell-class-name="addStyle" border>
<el-table-column
type="index"
label="序号"
width="55"
align="center"
/>
<el-table-column label="工单编号" align="center" prop="resultId">
</el-table-column>
<el-table-column label="案件描述" align="center" prop="content" class-name="anjianmiaoshu">
</el-table-column>
<el-table-column label="地点" align="center" prop="place">
</el-table-column>
<el-table-column label="相似度" align="center" prop="similarity">
<template slot-scope="scope">
<span>{{ scope.row.similarity }}%</span>
</template>
</el-table-column>
<el-table-column label="上报时间" align="center" prop="sbsj">
</el-table-column>
<el-table-column label="审核时间" v-if="auditStatus == 2" align="center" prop="createTime">
</el-table-column>
<el-table-column label="审核结果" v-if="auditStatus == 2" align="center" prop="isReport">
<template slot-scope="scope">
<span class="sign" v-if="scope.row.isReport == 1 || scope.row.isReport == 2 "></span>
<span class="unmark" v-else></span>
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="operation-box">
<template slot-scope="scope">
<div class="operation">
<!-- <img class="tagsImg" src="@/assets/images/tags.png" alt="" v-if="scope.row.isReport"> -->
<el-button @click="toDetail(scope.row)" type="text" style="margin-right: 5px;" class="sqbtn sqbtn1">
查看详情
</el-button>
<el-button @click="sign(scope.row)" type="text" style="color: #D9001B;" v-if="auditStatus == 1 && !scope.row.showTags">
不符合
</el-button>
<el-button @click="sign(scope.row)" type="text" style="color: #D9001B;" v-if="auditStatus == 1 && scope.row.showTags">
已标记不符合
</el-button>
</div>
</template>
</el-table-column>
</el-table>
</div>
</section>
</div>
<div slot="footer" class="dialog-footer" v-if="auditStatus == 1">
<!-- <el-button type="primary" @click="reported(1)"></el-button> -->
<!-- <el-button type="info" plain>不上报</el-button> -->
<!-- <el-button type="danger" @click="reported(2)">退</el-button> -->
<el-button type="primary" @click="reported">退</el-button>
</div>
<urgency-audit title="相似同类事件详情" ref="urgencyAudit" :auditStatus="2"></urgency-audit>
</el-dialog>
</template>
<script>
import { similarEventsPage, noAccordWith } from "@/api/eventPage"
import urgencyAudit from '@/views/components/urgencyAudit.vue'
export default {
components:{
urgencyAudit
},
data() {
return {
showCK:false,
audioInfo:{},
loading:false,
InputLoading:false,
tableData:[],
disabled:true,
multipleSelection: []
}
},
props:{
title:{
type:String,
default:""
},
auditStatus:{
type:Number,
required: true
}
},
methods:{
//
open(row){
this.audioInfo = {...row};
this.showCK = true;
this.getList(row.targetId);
},
//
close(){
this.showCK = false;
this.InputLoading = false;
this.loading = false;
this.multipleSelection = [];
},
getList(id){
this.loading = true;
similarEventsPage(id).then(res=>{
this.tableData = [...res.data];
if(this.multipleSelection.length > 0) {
this.tableData.map(item=>{
this.multipleSelection.map(itemTwo=>{
if(item.targetId = itemTwo) {
this.$set(item, 'showTags', true);
}
})
})
} else {
this.tableData.map(item=>{
// item.showTags = true;
this.$set(item, 'showTags', false);
})
}
this.loading = false;
}).catch(err=>{
this.loading = false;
})
},
//
toDetail(row){
this.$refs.urgencyAudit.open(this.audioInfo,row);
},
//
sign(row){
this.tableData.map(item=>{
if(item.resultId == row.resultId) {
item.showTags = !item.showTags;
// console.log(item.showTags,"item.showTags");
if(item.showTags) {
this.multipleSelection.push(row.resultId)
} else {
this.multipleSelection = this.multipleSelection.filter(itemTwo => itemTwo !== row.resultId);
}
}
})
// console.log(this.multipleSelection,"this.multipleSelection");
},
// /退
reported(){
// console.log(this.multipleSelection);
// console.log(this.audioInfo.innerEventId);
noAccordWith({resultId:this.multipleSelection}).then(res=>{
// console.log(res);
this.multipleSelection = [];
this.$message({
type: "success",
message: "已提交重训练!",
});
this.close();
this.$emit('closeDialog')
})
},
//
addStyle({row, column, rowIndex, columnIndex}) {
if(columnIndex === 2) {
return "columnFactor"
}
},
},
}
</script>

@ -0,0 +1,439 @@
<!-- 紧急事件审核弹框 -->
<template>
<el-dialog
:visible.sync="showCK"
v-if="showCK"
width="60%"
:show-close="false"
:append-to-body="true"
:close-on-click-modal="false"
:close-on-press-escape="false"
custom-class="travel"
>
<div slot="title" class="dialog-title">
<div class="dialog-title-text">{{ title }}</div>
<i @click="close" class="el-icon-close"></i>
</div>
<div class="audit-generalize">
<el-row>
<el-col :span="14" v-if="!isTrue">
<div class="work-order-info ">
<div class="work-order-item" v-if="auditStatus == 1">
<div class="work-order-item-left">
<div class="work-order-label">
<div class="work-order-labelBox">事件名称</div>
<span></span>
</div>
<el-tooltip class="item" effect="light" :content="eventInfo.title" placement="top">
<!-- @blur="titleBlur" -->
<el-input class="work-order-value-value" v-model="eventInfo.title" :disabled="disabled"></el-input>
</el-tooltip>
</div>
<el-button size="mini" @click="disabled = false"><img src="@/assets/images/changeTitle.png" alt=""> 修改标题</el-button>
</div>
<div class="work-order-item" v-else>
<div class="work-order-item-left">
<div class="work-order-label">
<div class="work-order-labelBox">事件名称</div>
<span></span>
</div>
<el-tooltip class="item" effect="light" :content="eventInfo.title" placement="top">
<div class="work-order-value work-order-value-value" :class="!eventInfo.titleBefore ? 'value-value':''">{{ eventInfo.title }}</div>
</el-tooltip>
</div>
<el-button size="mini" v-if="eventInfo.titleBefore" @click="innerVisible = true"><img src="@/assets/images/changeTitle.png" alt=""> </el-button>
</div>
<div class="work-order-items" v-if="eventInfo.auditTime">
<div class="work-order-label">
<div class="work-order-labelBox">审核时间</div>
<span></span>
</div>
<div class="work-order-value">{{ eventInfo.auditTime }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">预警因素</div>
<span></span>
</div>
<div class="work-order-value">{{ eventInfo.warnFactor }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">预警时间</div>
<span></span>
</div>
<div class="work-order-value">{{ eventInfo.firstWarnTimeDate }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">预警类别</div>
<span></span>
</div>
<div class="work-order-value">{{ eventInfo.msgTypeName }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox order-labelBox">事件来源</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.scenceName }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">诉求类型</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseType }}</div>
</div>
<!-- <div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">案件类型</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseAccord }}</div>
</div> -->
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">工单标题</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseTitle }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">制单时间</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseDate }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">诉求内容</div>
<span></span>
</div>
<div class="work-order-value">
{{ audioInfo.caseContent }}
</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">位置描述</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseAddress }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">来电号码</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.creatorTel }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">服务对象姓名</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.creatorName }}</div>
</div>
</div>
</el-col>
<el-col :span="14" v-else>
<div class="work-order-info ">
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox order-labelBox">工单编号</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseSerial }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox order-labelBox">事件来源</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.scenceName }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">诉求类型</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseType }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">工单标题</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseTitle }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">制单时间</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseDate }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">诉求内容</div>
<span></span>
</div>
<div class="work-order-value">
{{ audioInfo.caseContent }}
</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">位置描述</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.caseAddress }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">来电号码</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.creatorTel }}</div>
</div>
<div class="work-order-items">
<div class="work-order-label">
<div class="work-order-labelBox">服务对象姓名</div>
<span></span>
</div>
<div class="work-order-value">{{ audioInfo.creatorName }}</div>
</div>
</div>
</el-col>
<el-col :span="10">
<div id="newmapTwo" v-loading="mapLoading"></div>
</el-col>
</el-row>
</div>
<div slot="footer" class="dialog-footer" v-if="auditStatus == 1">
<el-button type="primary" @click="reported(1)"></el-button>
<!-- <el-button type="info" plain>不上报</el-button> -->
<el-button type="danger" @click="reported(2)">退</el-button>
<!-- <el-button type="success" @click="reported(3)"></el-button> -->
</div>
<el-dialog
width="30%"
title="查看标题"
:visible.sync="innerVisible"
append-to-body>
<el-descriptions :column="1">
<el-descriptions-item label="当前标题">{{ eventInfo.title }}</el-descriptions-item>
<el-descriptions-item label="历史标题">{{ eventInfo.titleBefore }}</el-descriptions-item>
</el-descriptions>
</el-dialog>
</el-dialog>
</template>
<script>
import L from "leaflet";
import 'leaflet.markercluster';
import "leaflet.markercluster/dist/MarkerCluster.css"
import "proj4";
import "proj4leaflet";
import "@/utils/lib/leaflet.ChineseTmsProviders.js";
import "@/utils/lib/leaflet.mapCorrection.min.js";
import { auditList, eventChangeIsReport, editTitle, getMassEvents } from "@/api/eventPage"
export default {
data() {
return {
showCK:false,
audioInfo:{},
eventInfo:{},
backupsInfo:{},
loading:false,
mapLoading:false,
mapLayers: {
mapLayer1: null,
},
disabled: true,
innerVisible:false,
isTrue: true,
}
},
props:{
title:{
type:String,
default:""
},
auditStatus:{
type:Number,
required: true
},
},
mounted(){
},
methods:{
//
open(row,item){
this.showCK = true;
this.eventInfo = {...row}
this.backupsInfo = {...row}
if(item){
this.isTrue = true;
if(item.caseSerial) {
this.getListTwo(item.caseSerial);
} else {
this.getListTwo(item.resultId);
}
} else if(!item && this.eventInfo.msgType == '3'){
this.isTrue = false;
this.getList(row.innerEventId);
} else {
this.isTrue = false;
this.audioInfo = {...row}
}
this.$nextTick(() => {
this.initMap();
});
},
//
close(){
this.showCK = false;
this.loading = false;
},
initMap(){
this.map = L.map("newmapTwo", {
// crs: L.CRS.Baidu,
center: [31.324624, 120.582904],
zoom: 12,
attributionControl: false,
zoomControl: false,
});
this.basemap = L.tileLayer.chinaProvider("GaoDe.Normal.Map", {
maxZoom: 14,
minZoom: 5,
});
this.map.addLayer(this.basemap);
this.map.createPane("mapLayer1");
this.map.getPane("mapLayer1").style.zIndex = 501;
this.map.getPane("mapLayer1").style.pointerEvents = "none";
this.mapLayers.mapLayer1 = L.featureGroup().addTo(this.map);
},
getList(id){
this.loading = true;
auditList(id).then(res=>{
this.audioInfo = {...res.data.records[0]};
if(this.audioInfo.caseLnglat) {
let iconUrl2 = require("@/assets/images/icon2.png");
//
var myIcon2 = L.icon({
iconUrl: iconUrl2,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
let lat = this.audioInfo.caseLnglat.split(",")[1];
let lon = this.audioInfo.caseLnglat.split(",")[0];
let marker = L.marker(
L.latLng(lat, lon),
{ icon: myIcon2 }
)
// .addTo(this.mapLayers.mapLayer1)
this.mapLayers.mapLayer1.addLayer(marker);
const bounds = this.mapLayers.mapLayer1.getBounds();
let center = bounds.getCenter();
this.map.setView(center, 12);
}
this.loading = false;
}).catch(err=>{
this.loading = false;
})
},
getListTwo(id){
this.loading = true;
getMassEvents(id).then(res=>{
this.audioInfo = {...res.data};
if(this.audioInfo.caseLnglat) {
let iconUrl2 = require("@/assets/images/icon2.png");
//
var myIcon2 = L.icon({
iconUrl: iconUrl2,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
let lat = this.audioInfo.caseLnglat.split(",")[1];
let lon = this.audioInfo.caseLnglat.split(",")[0];
let marker = L.marker(
L.latLng(lat, lon),
{ icon: myIcon2 }
)
// .addTo(this.mapLayers.mapLayer1)
this.mapLayers.mapLayer1.addLayer(marker);
const bounds = this.mapLayers.mapLayer1.getBounds();
let center = bounds.getCenter();
this.map.setView(center, 12);
}
// console.log(res,"res");
this.loading = false;
}).catch(err=>{
this.loading = false;
})
},
titleBlur(){
this.disabled = true;
if(this.backupsInfo.title !== this.eventInfo.title) {
// editTitle({title:this.eventInfo.title, innerEventId:this.eventInfo.innerEventId}).then(res=>{
// if(res.code == 200) {
// this.$message({
// type: "success",
// message: "!",
// });
// }
// })
}
},
// /退
reported(id){
// console.log(this.multipleSelection);
// console.log(this.audioInfo.innerEventId);
this.$confirm(`确定要${id == 1 ? '重新上报驾驶舱' : id == 2 ? '退回重训练' : id == 3 ? '审核通过':''}吗?`, "警告", {
confirmButtonText: "确定",
cancelButtonText: "取消",
type: "warning",
}).then(() => {
if(id !== 3) {
eventChangeIsReport({isReport:id,caseSerial:[this.audioInfo.caseSerial],innerEventId:this.eventInfo.innerEventId,newTitle:this.eventInfo.title,oldTitle:this.backupsInfo.title}).then(res=>{
// console.log(res);
this.$message({
type: "success",
message: id == 1 ? '已上报驾驶舱' : '已退回重训练' + "!",
});
this.$emit('closeDialog')
this.close();
})
} else {
if(this.backupsInfo.title !== this.eventInfo.title) {
this.$message.error(`您已修改标题,请上报驾驶舱或退回重训练`);
} else {
eventChangeIsReport({isReport:id,caseSerial:[this.audioInfo.caseSerial],innerEventId:this.eventInfo.innerEventId}).then(res=>{
// console.log(res);
this.$message({
type: "success",
message: "审核完成",
});
this.$emit('closeDialog')
this.close();
})
}
}
})
},
//
addStyle({row, column, rowIndex, columnIndex}) {
if(columnIndex === 2) {
return "columnFactor"
}
},
},
}
</script>

@ -5,19 +5,35 @@
<div class="searchP">查询条件</div>
</div>
<el-form :inline="true" :model="form" ref="formOne">
<el-form-item label="事件标题:" prop="incidentName">
<el-form-item label="事件标题:" prop="title">
<el-input v-model="form.title" placeholder="请输入名称"></el-input>
</el-form-item>
<el-form-item label="事件类型:" prop="incidentType">
<el-form-item label="事件类型:" prop="msgTypeName">
<!-- <el-select v-model="form.msgTypeName" placeholder="请选择类型">
<el-option label="暴漏垃圾" value="shanghai"></el-option>
<el-option label="市容环境" value="beijing"></el-option>
</el-select> -->
<el-input v-model="form.msgTypeName" placeholder="请输入事件类型名称"></el-input>
<el-input
v-model="form.msgTypeName"
placeholder="请输入事件类型名称"
></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" size="mini" icon="el-icon-search" @click="onSubmit('formOne')" class="onSubmit">查询</el-button>
<el-button size="mini" icon="el-icon-refresh-left" @click="reset('formOne')" class="reset">重置</el-button>
<el-button
type="primary"
size="mini"
icon="el-icon-search"
@click="onSubmit('formOne')"
class="onSubmit"
>查询</el-button
>
<el-button
size="mini"
icon="el-icon-refresh-left"
@click="reset('formOne')"
class="reset"
>重置</el-button
>
</el-form-item>
</el-form>
</div>
@ -35,7 +51,11 @@
width="55"
align="center"
/>
<el-table-column label="时间" align="center" prop="firstWarnTimeDate">
<el-table-column
label="时间"
align="center"
prop="firstWarnTimeDate"
>
</el-table-column>
<el-table-column label="类型" align="center" prop="msgTypeName">
</el-table-column>
@ -47,22 +67,38 @@
<template slot-scope="scope">
<div
style="
display: flex;
align-items: center;
justify-content: center;
display: flex;
align-items: center;
justify-content: center;
"
>
<div class="state-sub">
<div v-if="scope.row.state == 1" class="colors wancengColor"></div>
<div v-if="scope.row.state == 2" class="colors yichuliColor"></div>
<div v-if="scope.row.state == 3" class="colors yizhuofei"></div>
<div v-if="scope.row.state == null || scope.row.state == ''" class="colors yanqiColor"></div>
<div
v-if="scope.row.state == 1"
class="colors wancengColor"
></div>
<div
v-if="scope.row.state == 2"
class="colors yichuliColor"
></div>
<div
v-if="scope.row.state == 3"
class="colors yizhuofei"
></div>
<div
v-if="scope.row.state == null || scope.row.state == ''"
class="colors yanqiColor"
></div>
</div>
<div class="state-sub2">
<div v-if="scope.row.state == 1"></div>
<div v-if="scope.row.state == 2"></div>
<div v-if="scope.row.state == 3"></div>
<div v-if="scope.row.state == null || scope.row.state == ''"></div>
<div
v-if="scope.row.state == null || scope.row.state == ''"
>
正常
</div>
</div>
</div>
</template>
@ -141,93 +177,100 @@
</div> -->
<div class="team-main">
<div>状态:</div>
<div>{{ dialogData.state == 1 ? '未通过' : dialogData.state == 2 ? '已办结' : dialogData.state == 3 ? '作废' : '正常' }}</div>
<div>
{{
dialogData.state == 1
? "未通过"
: dialogData.state == 2
? "已办结"
: dialogData.state == 3
? "作废"
: "正常"
}}
</div>
</div>
</div>
</el-dialog>
</div>
</template>
<script>
import { getEvents,getEventById } from "@/api/platform/index"
import { getEvents, getEventById } from "@/api/platform/index";
export default {
data() {
return {
form:{
msgTypeName: '',
title: '',
form: {
msgTypeName: "",
title: "",
},
pages: {
current: 1,
size: 10,
},
loading:false,
loading: false,
tableData: [],
total:1,
showCK:false,
dialogLoading:false,
dialogData:{},
}
total: 1,
showCK: false,
dialogLoading: false,
dialogData: {},
};
},
mounted() {
this.getList();
},
methods:{
methods: {
//
getPagination(pages){
getPagination(pages) {
console.log(pages);
this.pages.current = pages.page;
this.pages.size = pages.limit;
this.getList()
this.getList();
},
//
getList(){
getList() {
this.loading = true;
getEvents(this.pages).then(res=>{
getEvents(this.pages).then((res) => {
console.log(res);
this.loading = false;
this.tableData = res.data.records;
this.total = res.data.total;
})
});
},
//
onSubmit(){
onSubmit() {
this.pages = {
current: 1,
size: 10
}
this.pages = {...this.pages,...this.form}
size: 10,
};
this.pages = { ...this.pages, ...this.form };
this.getList();
},
//
reset(formRef){
reset(formRef) {
this.$refs[formRef].resetFields();
this.pages = {
current: 1,
size: 10
}
size: 10,
};
this.form = {
msgTypeName: '',
title: '',
}
msgTypeName: "",
title: "",
};
this.getList();
},
//
toDetail(row) {
this.dialogLoading = true;
this.showCK = true;
getEventById(row.innerEventId).then(res=>{
getEventById(row.innerEventId).then((res) => {
this.dialogData = res.data;
this.dialogLoading = false;
})
});
},
//
approveReset() {
this.showCK = false;
},
},
}
};
</script>
<style lang="scss" scoped>
</style>
<style lang="scss" scoped></style>

@ -1,32 +1,78 @@
<template>
<div class="L-app-container home">
<div class="tabsBottom">
<div class="foot-main">
<div class="headerText">
<div class="searchP">算法运行监测</div>
<div class="L-app-container home" id="L-size-main">
<div class="tabsBottom" :style="tabHeader">
<div class="headerText">
<div class="searchP">
运行监测
<span v-if="!debugTime"
>算法运行正常数据获取正常数据推送上一次时间
<span v-if="tableData.length > 0">{{
tableData[0].runningTime
}}</span></span
>
<span v-else
>算法运行异常数据获取异常数据推送上一次时间
<span>{{ debugTime.firstWarnTimeDate }}</span></span
>
</div>
<section class="table-box">
<div class="table-item">
<el-table v-loading="loading" :data="tableData" border>
<el-table-column
type="index"
label="序号"
width="55"
align="center"
/>
<el-table-column label="算法运行时间" align="center" prop="runningTime">
</el-table-column>
<el-table-column label="获取事件条数" align="center" prop="hqTotal">
</el-table-column>
<el-table-column label="推送驾驶舱条数" align="center" prop="tsTotal">
</el-table-column>
</el-table>
</div>
</section>
</div>
<div class="arithmetic-query">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="运行时间:">
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</div>
<section class="table-box">
<el-table v-loading="loading" :data="tableData" border>
<el-table-column
type="index"
label="序号"
width="55"
align="center"
/>
<el-table-column
label="算法运行时间"
align="center"
prop="runningTime"
>
</el-table-column>
<el-table-column label="获取事件条数" align="center" prop="hqTotal">
</el-table-column>
<el-table-column label="推送驾驶舱条数" align="center" prop="tsTotal">
</el-table-column>
</el-table>
</section>
</div>
<div class="my-pagination">
<pagination
id="L-pagination"
:total="total"
:page="pages.current"
:limit="pages.size"
@ -38,12 +84,16 @@
</template>
<script>
import tabContent from "./components/algorithmTime"
import { getEventLogs } from "@/api/platform/index"
// import tabContent from "./components/algorithmTime"
import { getEventLogs } from "@/api/platform/index";
import { mapState, mapGetters } from "vuex";
import { login, verify, verificationCode } from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
export default {
components:{
tabContent
},
// components:{
// tabContent
// },
name: "Index",
data() {
return {
@ -51,49 +101,127 @@ export default {
current: 1,
size: 10,
},
loading:false,
loading: false,
tableData: [],
total:0,
total: 0,
tabHeader: {
height: "",
},
formInline: {
time: [],
},
};
},
computed: {
...mapGetters(["debugTime"]),
},
mounted() {
this.getList();
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// console.log(currentDate >= targetDate);
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
//使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
handleClick(tab, event){
// if (this.activeName == "type") {
// this.type = true;
// this.grade = false;
// this.source = false;
// } else if (this.activeName == "grade") {
// this.type = false;
// this.grade = true;
// this.source = false;
// } else if (this.activeName == "source") {
// this.type = false;
// this.grade = false;
// this.source = true;
// }
//
resetQuery() {
this.formInline = {
time: [],
};
this.pages = {
current: 1,
size: 10,
};
this.getList();
},
//
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pages = { ...this.pages, ...this.formInline };
this.getList();
},
//
getList(){
getList() {
this.loading = true;
getEventLogs(this.pages).then(res=>{
getEventLogs(this.pages).then((res) => {
this.loading = false;
this.total = res.data.total;
this.tableData = res.data.records;
})
});
},
//
getPagination(pages){
getPagination(pages) {
this.pages.current = pages.page;
this.pages.size = pages.limit;
this.getList()
this.getList();
},
}
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader.height = elementHeight - paginationtHeight - 100 + "px";
},
},
};
</script>
<style scoped lang="scss">
</style>
<style scoped lang="scss"></style>

@ -1,8 +1,8 @@
<template>
<div class="app-container">
<el-row :gutter="20">
<!-- <el-row :gutter="20"> -->
<!--部门数据-->
<el-col :span="4" :xs="24">
<!-- <el-col :span="4" :xs="24">
<div class="head-container">
<el-input
v-model="deptName"
@ -26,9 +26,9 @@
@node-click="handleNodeClick"
/>
</div>
</el-col>
</el-col> -->
<!--用户数据-->
<el-col :span="20" :xs="24">
<el-col :span="24" :xs="24">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="用户名称" prop="userName">
<el-input
@ -200,7 +200,7 @@
@pagination="getList"
/>
</el-col>
</el-row>
<!-- </el-row> -->
<!-- 添加或修改用户配置对话框 -->
<el-dialog :title="title" :visible.sync="open" width="600px" append-to-body>

@ -1,88 +1,560 @@
<template>
<div class="L-app-map-container">
预警呈现
<div class="warning-list">
<div class="warning-list-title">预警列表</div>
<div class="warning-list-content">
<div class="warning-list-search">
<el-input v-model="input" placeholder="请输入关键字"></el-input>
<el-button type="primary" size="medium" @click="query"></el-button>
<!-- <el-input v-model="input" placeholder="请输入关键字"></el-input>
<el-button type="primary" size="medium" @click="query"></el-button> -->
<el-input placeholder="请输入关键字" v-model="queryParams.title">
<i
v-if="queryParams.title"
class="el-icon-close el-input__icon"
slot="suffix"
@click="handleIconClick"
>
</i>
<el-button
type="primary"
size="medium"
@click="query"
slot="append"
icon="el-icon-search"
></el-button>
</el-input>
</div>
<div class="warning-list-list">
<div class="lists" v-for="(item,index) in 5">
<div class="hearder">
<div class="warning-title">虎丘区馨泰花苑76号楼发生火灾或存在发生火灾的隐患</div>
<div class="anniu">群体事件</div>
</div>
<div class="content">
<div class="content-left">
<div>高新区何山路124号四季花园小区</div>
<div>2023-07-30 14:26:30</div>
<el-radio-group
v-model="queryParams.isReport"
@change="getList"
class="years-select"
size="small"
fill="#1890FF"
>
<el-radio-button :label="6">全部</el-radio-button>
<el-radio-button :label="4">待审核</el-radio-button>
<el-radio-button :label="5">已审核</el-radio-button>
<!-- <el-radio-button :label="3">审核通过</el-radio-button> -->
</el-radio-group>
<div class="warning-list-list" v-loading="loading">
<div v-if="eventList.length > 0">
<div class="lists" v-for="(item, index) in eventList">
<div class="hearder">
<!--群体事件1同人同诉2紧急事件3重点人员4一人多诉5 -->
<div
class="anniu"
:class="
item.msgType == '1'
? 'qunti'
: item.msgType == '2'
? 'tongren'
: item.msgType == '3'
? 'jinji'
: item.msgType == '4'
? 'zhongdian'
: item.msgType == '5'
? 'yiren'
: ''
"
>
{{ item.msgTypeName }}
</div>
<div class="warning-title">{{ item.title }}</div>
</div>
<div class="content">
<div class="content-top">
<img src="@/assets/images/address.png" alt="" />
<span>{{ item.address }}</span>
</div>
<div class="content-bottom">
<img src="@/assets/images/time.png" alt="" />
<span>{{ item.firstWarnTimeDate }}</span>
</div>
</div>
<div class="content-right">
<div v-if="index != 0"></div>
<div v-if="index != 0"></div>
<el-button v-else type="primary" size="mini" @click="audit"></el-button>
<div class="foot">
<el-button
v-if="!item.isReport"
type="primary"
size="mini"
@click="audit(item)"
>审核</el-button
>
<el-button v-else size="mini" @click="detailInfo(item)"
>查看详情</el-button
>
</div>
</div>
</div>
<div class="right-main" v-else>
<el-divider content-position="center">暂无</el-divider>
</div>
</div>
<div class="warning-list-footer">
<pagination
v-show="total > 0"
:total="total"
layout="total, prev, pager, next, jumper"
:pagerCount="5"
:background="false"
:small="true"
:page.sync="queryParams.current"
:limit.sync="queryParams.size"
@pagination="getList"
/>
</div>
</div>
</div>
<div class="warning-events">
<div class="warning-events-event" v-for="(item,index) in event">
<div class="warning-events-event-img">图片</div>
<div class="warning-events-event-text" :style="{color:item.color}">{{ item.text }}</div>
<div class="warning-events-event" v-for="(item, index) in event">
<img class="warning-events-event-img" :src="item.img" alt="" />
<!-- :style="{color:item.color}" -->
<div class="warning-events-event-text">{{ item.text }}</div>
</div>
</div>
<div id="newmap" v-loading="mapLoading"></div>
<event-audit
:title="urgencyTitle"
ref="eventAudit"
:auditStatus="auditStatus"
@closeDialog="mountedMethods"
></event-audit>
<urgency-audit
:title="urgencyTitle"
ref="urgencyAudit"
:auditStatus="auditStatus"
@closeDialog="mountedMethods"
></urgency-audit>
</div>
</template>
<script>
import L from "leaflet";
import "leaflet.markercluster";
import "leaflet.markercluster/dist/MarkerCluster.css";
import "proj4";
import "proj4leaflet";
import "@/utils/lib/leaflet.ChineseTmsProviders.js";
import "@/utils/lib/leaflet.mapCorrection.min.js";
import {
new100Page,
colonyPage,
login,
verify,
verificationCode,
} from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import urgencyAudit from "@/views/components/urgencyAudit.vue";
import EventAudit from "@/views/components/eventAudit.vue";
export default {
components: {
EventAudit,
urgencyAudit,
},
data() {
return {
input:"",
event:[
input: "",
event: [
{
img:"",
text:"群体事件",
color:"#d9001b"
img: require("../../assets/images/icon-qtsj-1@2x.png"),
text: "群体事件",
color: "#d9001b",
},
{
img:"",
text:"紧急事件",
color:"#f59a23"
img: require("../../assets/images/icon-jjsj-1@2x.png"),
text: "紧急事件",
color: "#f59a23",
},
{
img:"",
text:"一人多诉",
color:"#d22379"
img: require("../../assets/images/icon-yrds-1@2x.png"),
text: "一人多诉",
color: "#d22379",
},
{
img:"",
text:"同人同诉",
color:"#2aa515"
img: require("../../assets/images/icon-trts-1@2x.png"),
text: "同人同诉",
color: "#2aa515",
},
{
img:"",
text:"重点人员",
color:"#8400ff"
img: require("../../assets/images/icon-zdry-1@2x.png"),
text: "重点人员",
color: "#8400ff",
},
]
],
queryParams: {
current: 1,
size: 10,
title: "",
isReport: 6,
},
total: 0,
eventList: [],
map: null,
basemap: null,
layerVectorLabel: null,
loading: false,
mapLoading: false,
mapLayers: {
mapLayer1: null,
mapLayer2: null,
mapLayer3: null,
mapLayer4: null,
mapLayer5: null,
},
auditStatus: 1,
urgencyTitle: "事件详情",
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// 使
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
localStorage.setItem("Admin-Token", res.token);
// setToken(res.token)
this.$nextTick(() => {
this.initMap();
});
this.getList();
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
localStorage.setItem("Admin-Token", res.token);
this.$nextTick(() => {
this.initMap();
});
this.getList();
});
}
});
} else {
// 使
this.$nextTick(() => {
this.initMap();
});
this.getList();
}
},
methods:{
//
query(){
methods: {
mountedMethods() {
this.$nextTick(() => {
this.initMap();
});
this.getList();
},
getList() {
this.loading = true;
colonyPage(this.queryParams)
.then((res) => {
this.eventList = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.loading = false;
});
},
initMap() {
this.map = L.map("newmap", {
// crs: L.CRS.Baidu,
center: [31.324624, 120.582904],
zoom: 12,
attributionControl: false,
zoomControl: false,
});
this.basemap = L.tileLayer.chinaProvider("GaoDe.Normal.Map", {
maxZoom: 14,
minZoom: 5,
});
// this.basemap = L.tileLayer(
// 'https://t{s}.tianditu.gov.cn/vec_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=vec&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=e64b3084dbc6333293d73a1e7b39463e',
// {
// maxZoom: 18,
// minZoom: 9,
// subdomains: ['0', '1', '2', '3', '4', '5', '6', '7'],
// }
// )
// /
// this.layerVectorLabel = L.tileLayer(
// 'https://t{s}.tianditu.gov.cn/cva_w/wmts?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&LAYER=cva&STYLE=default&TILEMATRIXSET=w&FORMAT=tiles&TILEMATRIX={z}&TILEROW={y}&TILECOL={x}&tk=e64b3084dbc6333293d73a1e7b39463e',
// {
// maxZoom: 18,
// minZoom: 9,
// subdomains: ['0', '1', '2', '3', '4', '5', '6', '7'],
// }
// )
this.map.addLayer(this.basemap);
// this.map.addLayer(this.layerVectorLabel)
this.map.createPane("mapLayer1");
this.map.getPane("mapLayer1").style.zIndex = 501;
this.map.getPane("mapLayer1").style.pointerEvents = "none";
this.map.createPane("mapLayer2");
this.map.getPane("mapLayer2").style.zIndex = 501;
this.map.getPane("mapLayer2").style.pointerEvents = "none";
this.map.createPane("mapLayer3");
this.map.getPane("mapLayer3").style.zIndex = 501;
this.map.getPane("mapLayer3").style.pointerEvents = "none";
this.map.createPane("mapLayer4");
this.map.getPane("mapLayer4").style.zIndex = 501;
this.map.getPane("mapLayer4").style.pointerEvents = "none";
this.map.createPane("mapLayer5");
this.map.getPane("mapLayer5").style.zIndex = 501;
this.map.getPane("mapLayer5").style.pointerEvents = "none";
this.mapLayers.mapLayer1 = L.featureGroup().addTo(this.map);
this.mapLayers.mapLayer2 = L.featureGroup().addTo(this.map);
this.mapLayers.mapLayer3 = L.featureGroup().addTo(this.map);
this.mapLayers.mapLayer4 = L.featureGroup().addTo(this.map);
this.mapLayers.mapLayer5 = L.featureGroup().addTo(this.map);
this.getPosition();
},
getPosition() {
this.mapLoading = true;
new100Page()
.then((res) => {
let iconUrl1 = require("@/assets/images/icon1.png");
let iconUrl2 = require("@/assets/images/icon2.png");
let iconUrl3 = require("@/assets/images/icon3.png");
let iconUrl4 = require("@/assets/images/icon4.png");
let iconUrl5 = require("@/assets/images/icon5.png");
var myIcon1 = L.icon({
iconUrl: iconUrl1,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
var myIcon2 = L.icon({
iconUrl: iconUrl2,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
var myIcon3 = L.icon({
iconUrl: iconUrl3,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
var myIcon4 = L.icon({
iconUrl: iconUrl4,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
var myIcon5 = L.icon({
iconUrl: iconUrl5,
iconSize: [38, 50], //
iconAnchor: [19, 29], // "tip" 使CSS
popupAnchor: [-3, -76], // popup
});
let arr = [...res.data];
arr.map((item, index) => {
// 12345
if (item.msgType == "1") {
let lat = item.caseLnglat.split(",")[1];
let lon = item.caseLnglat.split(",")[0];
let marker = L.marker(L.latLng(lat, lon), { icon: myIcon1 });
this.mapLayers.mapLayer1.addLayer(marker);
this.markerClick(marker, index, item);
} else if (item.msgType == "3") {
let lat = item.caseLnglat.split(",")[1];
let lon = item.caseLnglat.split(",")[0];
let marker = L.marker(L.latLng(lat, lon), { icon: myIcon2 });
this.mapLayers.mapLayer2.addLayer(marker);
this.markerClick(marker, index, item);
} else if (item.msgType == "5") {
let lat = item.caseLnglat.split(",")[1];
let lon = item.caseLnglat.split(",")[0];
let marker = L.marker(L.latLng(lat, lon), { icon: myIcon3 });
this.mapLayers.mapLayer3.addLayer(marker);
this.markerClick(marker, index, item);
} else if (item.msgType == "2") {
let lat = item.caseLnglat.split(",")[1];
let lon = item.caseLnglat.split(",")[0];
let marker = L.marker(L.latLng(lat, lon), { icon: myIcon4 });
this.mapLayers.mapLayer4.addLayer(marker);
this.markerClick(marker, index, item);
} else if (item.msgType == "4") {
let lat = item.caseLnglat.split(",")[1];
let lon = item.caseLnglat.split(",")[0];
let marker = L.marker(L.latLng(lat, lon), { icon: myIcon5 });
this.mapLayers.mapLayer5.addLayer(marker);
this.markerClick(marker, index, item);
}
});
this.mapLoading = false;
})
.catch((err) => {
this.mapLoading = false;
});
},
markerClick(marker, index, item) {
const that = this;
marker.on("click", (e) => {
//
marker.unbindPopup();
marker
.bindPopup(
`<div class="markerDialog">
<div class="markerTitle">
<span class="marker-msgTitle">${item.title}</span>
<i class="el-icon-close markerClose" id="markerClose${index}"></i>
</div>
<div class="markerContent">
<div class="contentInfo">
<div class="infoLabel">
<div class="labelBox">预警时间</div>
<span></span>
</div>
<div class="infoValue">${item.firstWarnTimeDate}</div>
</div>
<div class="contentInfo">
<div class="infoLabel">
<div class="labelBox">预警类别</div>
<span></span>
</div>
<div class="infoValue">${
item.msgType == "1"
? "群体事件"
: item.msgType == "2"
? "同人同诉"
: item.msgType == "3"
? "紧急事件"
: item.msgType == "4"
? "重点人员"
: item.msgType == "5"
? "一人多诉"
: ""
}</div>
</div>
<div class="contentInfo">
<div class="infoLabel">
<div class="labelBox"> </div>
<span></span>
</div>
<div class="infoValue">${item.address}</div>
</div>
<div class="contentInfo">
<div class="infoLabel">
<div class="labelBox">事件数量</div>
<span></span>
</div>
<div class="infoValue"><span>${item.nums}</span></div>
</div>
</div>
<div class="markerBtns">
<div class="btn-audit" id="markerAudit${index}">审核</div>
<div class="btn-detailInfo" id="markerInfo${index}">查看详情</div>
</div>
</div>`,
{
className: "marsk-box",
offset: L.point(0, 75),
}
)
.openPopup();
//ElementsById()elementaddEventListener()
document
.querySelector(`#markerClose` + index)
.addEventListener("click", function () {
marker.closePopup();
});
//
document
.querySelector(`#markerAudit` + index)
.addEventListener("click", function () {
that.urgencyTitle = "事件审核";
that.auditStatus = 1;
if (item.msgType == "3") {
that.$refs.urgencyAudit.open(item);
} else {
that.$refs.eventAudit.open(item);
}
});
//
document
.querySelector(`#markerInfo` + index)
.addEventListener("click", function () {
that.urgencyTitle = "事件详情";
if (item.msgType == "3") {
that.auditStatus = 2;
that.$refs.urgencyAudit.open(item);
} else {
that.auditStatus = 2;
that.$refs.eventAudit.open(item);
}
});
});
},
//
query() {
this.queryParams.current = 1;
this.queryParams.size = 10;
this.getList();
},
handleIconClick() {
this.queryParams.title = "";
this.queryParams.current = 1;
this.queryParams.size = 10;
this.getList();
},
//
audit(){
audit(item) {
this.urgencyTitle = "事件审核";
if (item.msgType == "3") {
this.auditStatus = 1;
this.$refs.urgencyAudit.open(item);
} else {
this.auditStatus = 1;
this.$refs.eventAudit.open(item);
}
},
//
auditPass() {},
//
detailInfo(item) {
this.urgencyTitle = "事件详情";
if (item.msgType == "3") {
this.auditStatus = 2;
this.$refs.urgencyAudit.open(item);
} else {
this.auditStatus = 2;
this.$refs.eventAudit.open(item);
}
},
},
}
};
</script>

@ -0,0 +1,348 @@
<!-- 驾驶舱重点人员事件 -->
<template>
<div class="L-ultimately-container">
<header>
驾驶舱重点人员事件
<span class="title-span"
>解释重点人员发生投诉的情况规则7天内同一人发生超过7次的只分析五失人员关注人员名单根据人员手机号匹配当天同一个人合并一条如果当天再发生不再推送新事件第二天再发生再推送新事件</span
>
</header>
<div class="tabs">
<el-tabs
v-model="activeName"
@tab-click="handleClick"
style="color: #edeef0"
>
<el-tab-pane label="待审核" name="first" />
<el-tab-pane label="已上报" name="second" />
<el-tab-pane label="重训练" name="third" />
<!-- <el-tab-pane label="审核通过" name="four" /> -->
</el-tabs>
</div>
<div class="container-info" id="L-size-main">
<header id="L-header">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="事件标题:">
<el-input
v-model="formInline.title"
placeholder="请输入"
></el-input>
</el-form-item>
<el-form-item label="预警时间:">
<!-- <el-date-picker
class="ignoreElement"
v-model="formInline.firstWarnTimeDate"
format="yyyy"
value-format="yyyy"
type="year"
placeholder="选择年份">
</el-date-picker> -->
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</header>
<section>
<!-- :height="tabHeader" -->
<el-table v-loading="loading" :data="tableData" :height="tabHeader">
<el-table-column
type="index"
label="序号"
width="100px"
class-name="table-operation"
align="center"
/>
<el-table-column
label="事件标题"
key="title"
width="400px"
prop="title"
/>
<el-table-column
label="预警时间"
key="firstWarnTimeDate"
width="300px"
prop="firstWarnTimeDate"
/>
<el-table-column
label="预警因素"
key="warnFactor"
width="400px"
prop="warnFactor"
/>
<el-table-column
label="事件数量"
key="nums"
width="100px"
prop="nums"
align="center"
>
<template slot-scope="scope">
<div style="text-align: center">{{ scope.row.nums }}</div>
</template>
</el-table-column>
<el-table-column
label="操作"
class-name="table-operation-anniu"
align="center"
>
<template slot-scope="scope">
<div
@click="audit(scope.row)"
class="go-audit"
v-if="activeName == 'first'"
>
<img src="@/assets/images/audit.png" alt="" />
<span>审核</span>
</div>
<el-button
v-else
@click="audit(scope.row)"
type="text"
style="margin-right: 5px"
class="sqbtn sqbtn1"
>
查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
id="L-pagination"
:total="total"
:page="pagination.current"
:limit="pagination.size"
layout="total, prev, pager, next, jumper"
@pagination="getPagination"
:current-page.sync="pagination.current"
></pagination>
</section>
</div>
<event-audit
title="事件审核"
ref="eventAudit"
:auditStatus="auditStatus"
@closeDialog="getList"
></event-audit>
</div>
</template>
<script>
import { colonyPage, login, verify, verificationCode } from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import EventAudit from "@/views/components/eventAudit.vue";
export default {
components: {
EventAudit,
},
data() {
return {
activeName: "first",
active: 0,
formInline: {
title: "",
time: [],
},
loading: false,
tableData: [],
tabHeader: null,
total: 0,
pagination: {
current: 1,
size: 10,
msgType: "4",
isReport: null,
},
auditStatus: 1,
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
// 使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
handleClick(e) {
if (this.activeName == "first") {
this.pagination.isReport = 4;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 1;
this.getList();
} else if (this.activeName == "second") {
this.pagination.isReport = 1;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "third") {
this.pagination.isReport = 2;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "four") {
this.pagination.isReport = 3;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
}
},
//
getPagination(pages) {
this.pagination.current = pages.page;
this.pagination.size = pages.limit;
this.getList();
},
getList() {
this.loading = true;
colonyPage(this.pagination)
.then((res) => {
this.tableData = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.tableData = [];
this.loading = false;
});
},
resetQuery() {
this.formInline = {
title: "",
time: [],
};
this.pagination = {
current: 1,
size: 10,
msgType: "4",
isReport:
this.activeName == "first"
? null
: this.activeName == "second"
? 1
: this.activeName == "third"
? 2
: null,
};
this.getList();
},
//
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pagination = { ...this.pagination, ...this.formInline };
this.getList();
},
audit(item) {
this.$refs.eventAudit.open(item);
},
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const header = document.getElementById("L-header"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const headerHeight = header.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader = elementHeight - headerHeight - paginationtHeight;
},
},
};
</script>
<style lang="scss" scoped></style>

@ -0,0 +1,356 @@
<!-- 驾驶舱群体事件 -->
<template>
<div class="L-ultimately-container">
<header>
驾驶舱群体事件
<span class="title-span"
>解释同地点同一件事发生多起规则3天内同地点同一件事发生超过10次的如果超过30天则创建新事件如果当天再发生不再推送新事件第二天再发生再推送新事件</span
>
</header>
<div class="tabs">
<el-tabs
v-model="activeName"
@tab-click="handleClick"
style="color: #edeef0"
>
<el-tab-pane label="待审核" name="first" />
<el-tab-pane label="已上报" name="second" />
<el-tab-pane label="重训练" name="third" />
<!-- <el-tab-pane label="审核通过" name="four" /> -->
</el-tabs>
</div>
<div class="container-info" id="L-size-main">
<header id="L-header">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="事件标题:">
<el-input
v-model="formInline.title"
placeholder="请输入"
></el-input>
</el-form-item>
<el-form-item label="预警时间:">
<!-- <el-date-picker
class="ignoreElement"
v-model="formInline.firstWarnTimeDate"
format="yyyy"
value-format="yyyy"
type="year"
placeholder="选择年份">
</el-date-picker> -->
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</header>
<section>
<!-- :height="tabHeader" -->
<el-table v-loading="loading" :data="tableData" :height="tabHeader">
<el-table-column
type="index"
label="序号"
width="100px"
class-name="table-operation"
align="center"
/>
<el-table-column
label="事件标题"
key="title"
width="300px"
prop="title"
/>
<el-table-column
label="预警时间"
key="firstWarnTimeDate"
width="200px"
prop="firstWarnTimeDate"
/>
<el-table-column
label="高发时间"
key="gfTime"
width="200px"
prop="gfTime"
/>
<el-table-column
label="预警因素"
key="warnFactor"
width="300px"
prop="warnFactor"
/>
<el-table-column
label="事件数量"
key="nums"
width="100px"
prop="nums"
align="center"
>
<template slot-scope="scope">
<div style="text-align: center">{{ scope.row.nums }}</div>
</template>
</el-table-column>
<el-table-column
label="操作"
class-name="table-operation-anniu"
align="center"
>
<template slot-scope="scope">
<div
@click="audit(scope.row)"
class="go-audit"
v-if="activeName == 'first'"
>
<img src="@/assets/images/audit.png" alt="" />
<span>审核</span>
</div>
<el-button
v-else
@click="audit(scope.row)"
type="text"
style="margin-right: 5px"
class="sqbtn sqbtn1"
>
查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
id="L-pagination"
:total="total"
:page="pagination.current"
:limit="pagination.size"
layout="total, prev, pager, next, jumper"
@pagination="getPagination"
:current-page.sync="pagination.current"
></pagination>
</section>
</div>
<event-audit
title="事件审核"
ref="eventAudit"
:auditStatus="auditStatus"
@closeDialog="getList"
></event-audit>
</div>
</template>
<script>
import { colonyPage, login, verify, verificationCode } from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import EventAudit from "@/views/components/eventAudit.vue";
export default {
components: {
EventAudit,
},
data() {
return {
activeName: "first",
active: 0,
formInline: {
title: "",
time: [],
},
loading: false,
tableData: [],
tabHeader: null,
total: 0,
pagination: {
current: 1,
size: 10,
msgType: "1",
isReport: null,
},
auditStatus: 1,
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
// if(currentDate >= targetDate) {
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
// 使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
// tab
handleClick(e) {
if (this.activeName == "first") {
this.pagination.isReport = 4;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 1;
this.getList();
} else if (this.activeName == "second") {
this.pagination.isReport = 1;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "third") {
this.pagination.isReport = 2;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "four") {
this.pagination.isReport = 3;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
}
},
//
getPagination(pages) {
this.pagination.current = pages.page;
this.pagination.size = pages.limit;
this.getList();
},
getList() {
this.loading = true;
colonyPage(this.pagination)
.then((res) => {
this.tableData = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.tableData = [];
this.loading = false;
});
},
resetQuery() {
this.formInline = {
title: "",
time: [],
};
this.pagination = {
current: 1,
size: 10,
msgType: "1",
isReport:
this.activeName == "first"
? null
: this.activeName == "second"
? 1
: this.activeName == "third"
? 2
: null,
};
this.getList();
},
//
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pagination = { ...this.pagination, ...this.formInline };
this.getList();
},
audit(item) {
this.$refs.eventAudit.open(item);
},
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const header = document.getElementById("L-header"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const headerHeight = header.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader = elementHeight - headerHeight - paginationtHeight;
},
},
};
</script>
<style lang="scss" scoped></style>

@ -0,0 +1,358 @@
<!-- 驾驶舱紧急事件 -->
<template>
<div class="L-ultimately-container">
<header>
驾驶舱紧急事件
<span class="title-span"
>解释社会治安类紧急突发事件规则跳楼放火杀人灾害火灾救火打架群架斗殴殴打受伤车祸受伤地震等类型</span
>
</header>
<div class="tabs">
<el-tabs
v-model="activeName"
@tab-click="handleClick"
style="color: #edeef0"
>
<el-tab-pane label="待审核" name="first" />
<el-tab-pane label="已上报" name="second" />
<el-tab-pane label="重训练" name="third" />
<!-- <el-tab-pane label="审核通过" name="four" /> -->
</el-tabs>
</div>
<div class="container-info" id="L-size-main">
<header id="L-header">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="事件标题:">
<el-input
v-model="formInline.title"
placeholder="请输入"
></el-input>
</el-form-item>
<el-form-item label="预警时间:">
<!-- <el-date-picker
class="ignoreElement"
v-model="formInline.firstWarnTimeDate"
format="yyyy"
value-format="yyyy"
type="year"
placeholder="选择年份">
</el-date-picker> -->
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</header>
<section>
<!-- :height="tabHeader" -->
<el-table v-loading="loading" :data="tableData" :height="tabHeader">
<el-table-column
type="index"
label="序号"
width="100px"
class-name="table-operation"
align="center"
/>
<el-table-column
label="事件标题"
key="title"
width="400px"
prop="title"
/>
<el-table-column
label="预警时间"
key="firstWarnTimeDate"
width="300px"
prop="firstWarnTimeDate"
/>
<el-table-column
label="预警因素"
key="warnFactor"
width="350px"
prop="warnFactor"
/>
<el-table-column
label="审核时间"
key="auditTime"
v-if="activeName !== 'first'"
width="180px"
prop="auditTime"
align="center"
>
<template slot-scope="scope">
<div style="text-align: center">{{ scope.row.auditTime }}</div>
</template>
</el-table-column>
<el-table-column
label="操作"
class-name="table-operation-anniu"
align="center"
>
<template slot-scope="scope">
<div
@click="audit(scope.row)"
class="go-audit"
v-if="activeName == 'first'"
>
<img src="@/assets/images/audit.png" alt="" />
<span>审核</span>
</div>
<el-button
v-else
@click="audit(scope.row)"
type="text"
style="margin-right: 5px"
class="sqbtn sqbtn1"
>
查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
id="L-pagination"
:total="total"
:page="pagination.current"
:limit="pagination.size"
layout="total, prev, pager, next, jumper"
@pagination="getPagination"
:current-page.sync="pagination.current"
></pagination>
</section>
</div>
<urgency-audit
:title="dialogTitle"
ref="urgencyAudit"
:auditStatus="auditStatus"
@closeDialog="getList"
></urgency-audit>
</div>
</template>
<script>
import { colonyPage, login, verify, verificationCode } from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import urgencyAudit from "@/views/components/urgencyAudit.vue";
export default {
components: {
urgencyAudit,
},
data() {
return {
activeName: "first",
active: 0,
formInline: {
title: "",
time: [],
},
loading: false,
tableData: [],
tabHeader: null,
total: 0,
pagination: {
current: 1,
size: 10,
msgType: "3",
isReport: 4,
},
auditStatus: 1,
auditMapStatus: 1,
dialogTitle: "事件审核",
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
// 使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
handleClick(e) {
if (this.activeName == "first") {
this.pagination.isReport = 4;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 1;
this.auditMapStatus = 1;
this.dialogTitle = "事件审核";
this.getList();
} else if (this.activeName == "second") {
this.pagination.isReport = 1;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.auditMapStatus = 2;
this.dialogTitle = "事件详情";
this.getList();
} else if (this.activeName == "third") {
this.pagination.isReport = 2;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.auditMapStatus = 2;
this.dialogTitle = "事件详情";
this.getList();
} else if (this.activeName == "four") {
this.pagination.isReport = 3;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.auditMapStatus = 2;
this.getList();
}
},
//
getPagination(pages) {
this.pagination.current = pages.page;
this.pagination.size = pages.limit;
this.getList();
},
getList() {
this.loading = true;
colonyPage(this.pagination)
.then((res) => {
this.tableData = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.tableData = [];
this.loading = false;
});
},
resetQuery() {
this.formInline = {
title: "",
time: [],
};
this.pagination = {
current: 1,
size: 10,
msgType: "3",
isReport:
this.activeName == "first"
? 4
: this.activeName == "second"
? 1
: this.activeName == "third"
? 2
: null,
};
this.getList();
},
//
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pagination = { ...this.pagination, ...this.formInline };
this.getList();
},
audit(item) {
this.$refs.urgencyAudit.open(item);
},
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const header = document.getElementById("L-header"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const headerHeight = header.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader = elementHeight - headerHeight - paginationtHeight;
},
},
};
</script>
<style lang="scss" scoped></style>

@ -0,0 +1,348 @@
<!-- 驾驶舱一人多诉事件 -->
<template>
<div class="L-ultimately-container">
<header>
驾驶舱一人多诉事件
<span class="title-span"
>解释一人多诉的情况关注这个人多次投诉规则15天内同一人发生超过5次的如果超过30天则创建新事件如果当天再发生不再推送新事件第二天再发生再推送新事件</span
>
</header>
<div class="tabs">
<el-tabs
v-model="activeName"
@tab-click="handleClick"
style="color: #edeef0"
>
<el-tab-pane label="待审核" name="first" />
<el-tab-pane label="已上报" name="second" />
<el-tab-pane label="重训练" name="third" />
<!-- <el-tab-pane label="审核通过" name="four" /> -->
</el-tabs>
</div>
<div class="container-info" id="L-size-main">
<header id="L-header">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="事件标题:">
<el-input
v-model="formInline.title"
placeholder="请输入"
></el-input>
</el-form-item>
<el-form-item label="预警时间:">
<!-- <el-date-picker
class="ignoreElement"
v-model="formInline.firstWarnTimeDate"
format="yyyy"
value-format="yyyy"
type="year"
placeholder="选择年份">
</el-date-picker> -->
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</header>
<section>
<!-- :height="tabHeader" -->
<el-table v-loading="loading" :data="tableData" :height="tabHeader">
<el-table-column
type="index"
label="序号"
width="100px"
class-name="table-operation"
align="center"
/>
<el-table-column
label="事件标题"
key="title"
width="400px"
prop="title"
/>
<el-table-column
label="预警时间"
key="firstWarnTimeDate"
width="300px"
prop="firstWarnTimeDate"
/>
<el-table-column
label="预警因素"
key="warnFactor"
width="400px"
prop="warnFactor"
/>
<el-table-column
label="事件数量"
key="nums"
width="100px"
prop="nums"
align="center"
>
<template slot-scope="scope">
<div style="text-align: center">{{ scope.row.nums }}</div>
</template>
</el-table-column>
<el-table-column
label="操作"
class-name="table-operation-anniu"
align="center"
>
<template slot-scope="scope">
<div
@click="audit(scope.row)"
class="go-audit"
v-if="activeName == 'first'"
>
<img src="@/assets/images/audit.png" alt="" />
<span>审核</span>
</div>
<el-button
v-else
@click="audit(scope.row)"
type="text"
style="margin-right: 5px"
class="sqbtn sqbtn1"
>
查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
id="L-pagination"
:total="total"
:page="pagination.current"
:limit="pagination.size"
layout="total, prev, pager, next, jumper"
@pagination="getPagination"
:current-page.sync="pagination.current"
></pagination>
</section>
</div>
<event-audit
title="事件审核"
ref="eventAudit"
:auditStatus="auditStatus"
@closeDialog="getList"
></event-audit>
</div>
</template>
<script>
import { colonyPage, login, verify, verificationCode } from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import EventAudit from "@/views/components/eventAudit.vue";
export default {
components: {
EventAudit,
},
data() {
return {
activeName: "first",
active: 0,
formInline: {
title: "",
time: [],
},
loading: false,
tableData: [],
tabHeader: null,
total: 0,
pagination: {
current: 1,
size: 10,
msgType: "5",
isReport: null,
},
auditStatus: 1,
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
// 使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
handleClick(e) {
if (this.activeName == "first") {
this.pagination.isReport = 4;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 1;
this.getList();
} else if (this.activeName == "second") {
this.pagination.isReport = 1;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "third") {
this.pagination.isReport = 2;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "four") {
this.pagination.isReport = 3;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
}
},
//
getPagination(pages) {
this.pagination.current = pages.page;
this.pagination.size = pages.limit;
this.getList();
},
getList() {
this.loading = true;
colonyPage(this.pagination)
.then((res) => {
this.tableData = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.tableData = [];
this.loading = false;
});
},
resetQuery() {
this.formInline = {
title: "",
time: [],
};
this.pagination = {
current: 1,
size: 10,
msgType: "5",
isReport:
this.activeName == "first"
? null
: this.activeName == "second"
? 1
: this.activeName == "third"
? 2
: null,
};
this.getList();
},
//
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pagination = { ...this.pagination, ...this.formInline };
this.getList();
},
audit(item) {
this.$refs.eventAudit.open(item);
},
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const header = document.getElementById("L-header"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const headerHeight = header.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader = elementHeight - headerHeight - paginationtHeight;
},
},
};
</script>
<style lang="scss" scoped></style>

@ -0,0 +1,350 @@
<!-- 驾驶舱同人同述事件 -->
<template>
<div class="L-ultimately-container">
<header>
驾驶舱同人同述事件
<span class="title-span"
>解释同人同诉的情况关注这件事情多次投诉未解决规则15天内同一人发生超过5次的如果超过30天则创建新事件如果当天再发生不再推送新事件第二天再发生再推送新事件</span
>
</header>
<div class="tabs">
<el-tabs
v-model="activeName"
@tab-click="handleClick"
style="color: #edeef0"
>
<el-tab-pane label="待审核" name="first" />
<el-tab-pane label="已上报" name="second" />
<el-tab-pane label="重训练" name="third" />
<!-- <el-tab-pane label="审核通过" name="four" /> -->
</el-tabs>
</div>
<div class="container-info" id="L-size-main">
<header id="L-header">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="事件标题:">
<el-input
v-model="formInline.title"
placeholder="请输入"
></el-input>
</el-form-item>
<el-form-item label="预警时间:">
<!-- <el-date-picker
class="ignoreElement"
v-model="formInline.firstWarnTimeDate"
format="yyyy"
value-format="yyyy"
type="year"
placeholder="选择年份">
</el-date-picker> -->
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</header>
<section>
<!-- :height="tabHeader" -->
<el-table v-loading="loading" :data="tableData" :height="tabHeader">
<el-table-column
type="index"
label="序号"
width="100px"
class-name="table-operation"
align="center"
/>
<el-table-column
label="事件标题"
key="title"
width="400px"
prop="title"
/>
<el-table-column
label="预警时间"
key="firstWarnTimeDate"
width="300px"
prop="firstWarnTimeDate"
/>
<el-table-column
label="预警因素"
key="warnFactor"
width="400px"
prop="warnFactor"
/>
<el-table-column
label="事件数量"
key="nums"
width="100px"
prop="nums"
align="center"
>
<template slot-scope="scope">
<div style="text-align: center">{{ scope.row.nums }}</div>
</template>
</el-table-column>
<el-table-column
label="操作"
class-name="table-operation-anniu"
align="center"
>
<template slot-scope="scope">
<div
@click="audit(scope.row)"
class="go-audit"
v-if="activeName == 'first'"
>
<img src="@/assets/images/audit.png" alt="" />
<span>审核</span>
</div>
<el-button
v-else
@click="audit(scope.row)"
type="text"
style="margin-right: 5px"
class="sqbtn sqbtn1"
>
查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
id="L-pagination"
:total="total"
:page="pagination.current"
:limit="pagination.size"
layout="total, prev, pager, next, jumper"
@pagination="getPagination"
:current-page.sync="pagination.current"
></pagination>
</section>
</div>
<event-audit
title="事件审核"
ref="eventAudit"
:auditStatus="auditStatus"
@closeDialog="getList"
></event-audit>
</div>
</template>
<script>
import { colonyPage, login, verify, verificationCode } from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import EventAudit from "@/views/components/eventAudit.vue";
export default {
components: {
EventAudit,
},
data() {
return {
activeName: "first",
active: 0,
formInline: {
title: "",
time: [],
},
loading: false,
tableData: [],
tabHeader: null,
total: 0,
pagination: {
current: 1,
size: 10,
msgType: "2",
isReport: null,
},
auditStatus: 1,
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
// 使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
handleClick(e) {
if (this.activeName == "first") {
this.pagination.isReport = 4;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 1;
this.getList();
} else if (this.activeName == "second") {
this.pagination.isReport = 1;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "third") {
this.pagination.isReport = 2;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.auditStatus = 2;
this.getList();
} else if (this.activeName == "four") {
this.pagination.isReport = 3;
this.pagination.startTime = "";
this.pagination.endTime = "";
this.pagination.title = "";
this.formInline.title = "";
this.formInline.time = [];
this.auditStatus = 2;
this.getList();
}
},
//
getPagination(pages) {
this.pagination.current = pages.page;
this.pagination.size = pages.limit;
this.getList();
},
getList() {
this.loading = true;
colonyPage(this.pagination)
.then((res) => {
this.tableData = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.tableData = [];
this.loading = false;
});
},
resetQuery() {
this.formInline = {
title: "",
time: [],
};
this.pagination = {
current: 1,
size: 10,
msgType: "2",
isReport:
this.activeName == "first"
? null
: this.activeName == "second"
? 1
: this.activeName == "third"
? 2
: null,
};
this.getList();
},
//
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pagination = { ...this.pagination, ...this.formInline };
this.getList();
},
audit(item) {
this.$refs.eventAudit.open(item);
},
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const header = document.getElementById("L-header"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const headerHeight = header.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader = elementHeight - headerHeight - paginationtHeight;
},
},
};
</script>
<style lang="scss" scoped></style>

@ -0,0 +1,313 @@
<!-- 驾驶舱相似同类事件 -->
<template>
<div class="L-ultimately-container">
<header>
驾驶舱相似同类事件
<span class="title-span"
>解释分析出与目标工单的属于同类型的相似事件规则返回相似度排名超过0.92的结果最多返回10条</span
>
</header>
<div class="tabs">
<el-tabs
v-model="activeName"
@tab-click="handleClick"
style="color: #edeef0"
>
<el-tab-pane label="调用记录" name="first" />
<el-tab-pane label="重训练" name="third" />
</el-tabs>
</div>
<div class="container-info" id="L-size-main">
<header id="L-header">
<el-form
:inline="true"
:model="formInline"
size="small"
class="demo-form-inline"
>
<el-form-item label="事件标题:">
<el-input
v-model="formInline.title"
placeholder="请输入"
></el-input>
</el-form-item>
<el-form-item label="调用时间:">
<!-- <el-date-picker
class="ignoreElement"
v-model="formInline.firstWarnTimeDate"
format="yyyy"
value-format="yyyy"
type="year"
placeholder="选择年份">
</el-date-picker> -->
<el-date-picker
v-model="formInline.time"
format="yyyy-MM-dd HH:mm:ss"
value-format="yyyy-MM-dd HH:mm:ss"
type="datetimerange"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="请选择"
>
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button size="mini" @click="resetQuery('queryFrom')"
>重置</el-button
>
<el-button
size="mini"
type="primary"
@click="handleQuery('queryFrom')"
>查询</el-button
>
</el-form-item>
</el-form>
</header>
<section>
<!-- :height="tabHeader" -->
<el-table v-loading="loading" :data="tableData" :height="tabHeader">
<el-table-column
type="index"
label="序号"
width="100px"
class-name="table-operation"
align="center"
/>
<el-table-column
label="事件标题"
key="title"
width="400px"
prop="title"
/>
<el-table-column
label="调用时间"
key="createTime"
width="300px"
prop="createTime"
/>
<el-table-column
label="关联事件数量"
key="count"
width="200px"
prop="count"
align="center"
>
<template slot-scope="scope">
<div style="text-align: center">{{ scope.row.count }}</div>
</template>
</el-table-column>
<el-table-column
label="操作"
class-name="table-operation-anniu"
align="center"
>
<template slot-scope="scope">
<div
@click="audit(scope.row)"
class="go-audit"
v-if="activeName == 'first'"
>
<img src="@/assets/images/audit.png" alt="" />
<span>审核</span>
</div>
<el-button
v-else
@click="audit(scope.row)"
type="text"
style="margin-right: 5px"
class="sqbtn sqbtn1"
>
查看详情
</el-button>
</template>
</el-table-column>
</el-table>
<pagination
id="L-pagination"
:total="total"
:page="pagination.current"
:limit="pagination.size"
layout="total, prev, pager, next, jumper"
@pagination="getPagination"
:current-page.sync="pagination.current"
></pagination>
</section>
</div>
<relevancyEventAudit
title="关联事件审核"
ref="eventAudit"
:auditStatus="auditStatus"
@closeDialog="getList"
/>
</div>
</template>
<script>
import {
colonyEventPage,
login,
verify,
verificationCode,
} from "@/api/eventPage";
import { setToken } from "@/utils/auth";
import { encrypt } from "@/utils/jsencrypt";
import relevancyEventAudit from "@/views/components/relevancyEventAudit.vue";
export default {
components: {
relevancyEventAudit,
},
data() {
return {
activeName: "first",
active: 0,
formInline: {
title: "",
time: [],
},
loading: false,
tableData: [],
tabHeader: null,
total: 0,
pagination: {
current: 1,
size: 10,
isReport: null,
},
auditStatus: 1,
};
},
mounted() {
// const currentDate = new Date();
// const targetDate = new Date(2024, 10, 1, 0, 0, 0);
if (JSON.parse(process.env.VUE_APP_ISTEST)) {
// 使
verify().then((res) => {
if (!res.data) {
this.$prompt(
'<div>算法已有3个月未迭代请联系算法人员进行迭代优化。</div><div class="warningText">正式使用码签约合同有效期2年有效期至2026年11月1日</div>',
"提示",
{
confirmButtonText: "确定",
type: "warning",
closeOnPressEscape: false,
showCancelButton: false,
closeOnClickModal: false,
dangerouslyUseHTMLString: true,
showInput: true,
showClose: false,
beforeClose: (action, instance, done) => {
if (action === "confirm") {
if (instance.inputValue == "88888888") {
done();
} else {
this.$message.error("试用码错误!");
}
}
},
}
).then(({ value }) => {
verificationCode({ verificationCode: value }).then((res) => {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
});
});
} else {
login("admin", encrypt("Suanfa@2024//**...")).then((res) => {
// setToken(res.token)
localStorage.setItem("Admin-Token", res.token);
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
});
}
});
} else {
// 使
this.getList();
this.cancalDebounce();
window.addEventListener("resize", this.cancalDebounce);
}
},
destroyed() {
window.removeEventListener("resize", this.cancalDebounce);
},
methods: {
// tab
handleClick(e) {
if (this.activeName == "first") {
this.pagination.isReport = null;
this.auditStatus = 1;
this.getList();
} else if (this.activeName == "third") {
this.pagination.isReport = 1;
this.auditStatus = 2;
this.getList();
}
},
//
getPagination(pages) {
this.pagination.current = pages.page;
this.pagination.size = pages.limit;
this.getList();
},
getList() {
this.loading = true;
colonyEventPage(this.pagination)
.then((res) => {
this.tableData = res.data.records;
this.total = res.data.total;
this.loading = false;
})
.catch((err) => {
this.tableData = [];
this.loading = false;
});
},
resetQuery() {
this.formInline = {
title: "",
time: [],
};
this.pagination = {
current: 1,
size: 10,
isReport:
this.activeName == "first"
? null
: this.activeName == "third"
? 1
: null,
};
this.getList();
},
handleQuery() {
if (this.formInline.time.length > 0) {
this.formInline.startTime = this.formInline.time[0];
this.formInline.endTime = this.formInline.time[1];
}
this.pagination = { ...this.pagination, ...this.formInline };
this.getList();
},
audit(item) {
this.$refs.eventAudit.open(item);
},
//
cancalDebounce() {
const element = document.getElementById("L-size-main"); // ID
const header = document.getElementById("L-header"); // ID
const pagination = document.getElementById("L-pagination"); // ID
const elementHeight = element.offsetHeight;
const headerHeight = header.offsetHeight;
const paginationtHeight = pagination.offsetHeight;
this.tabHeader = elementHeight - headerHeight - paginationtHeight;
},
},
};
</script>
<style lang="scss" scoped></style>

@ -18,7 +18,8 @@ module.exports = {
// 部署生产环境和开发环境下的URL。
// 默认情况下Vue CLI 会假设你的应用是被部署在一个域名的根路径上
// 例如 https://www.ruoyi.vip/。如果应用被部署在一个子路径上,你就需要用这个选项指定这个子路径。例如,如果你的应用被部署在 https://www.ruoyi.vip/admin/,则设置 baseUrl 为 /admin/。
publicPath: process.env.NODE_ENV === "production" ? "/" : "/",
// publicPath: process.env.NODE_ENV === "production" ? "/demo/SzplatformWeb" : "/",
publicPath: process.env.NODE_ENV === "production" ? "./" : "/",
// 在npm run build 或 yarn build 时 生成文件的目录名称要和baseUrl的生产环境路径一致默认dist
outputDir: 'dist',
// 用于放置生成的静态资源 (js、css、img、fonts) 的;(项目打包之后,静态资源会放在这个文件夹下)

Loading…
Cancel
Save