From 0afd9781a7cb3d224ad6eafcd45d02903abe741f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E9=92=A6?= <360013221@qq.com> Date: Sat, 18 May 2024 17:43:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=83=A8=E5=88=86=E9=9C=80?= =?UTF-8?q?=E6=B1=822024-05-18?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ruoyi-ui/src/common/menuData.js | 12 + .../components/RoadStateCard/data.js | 8 + .../RoadStateCard/images/confirmed22.svg | 32 + .../RoadStateCard/images/processed24.svg | 31 + .../RoadStateCard/images/processing21.svg | 33 + .../RoadStateCard/images/toBeConfirmed23.svg | 32 + .../Dialogs/PerceiveEvent/index.vue | 345 ++- .../components/HomeFrameControl/index.vue | 26 +- .../components/RoadAndEvents/utils/map.js | 10 +- .../DeviceControl/components/ScopeTable.vue | 6 +- .../Cards/DeviceControl/index.vue | 10 +- .../event/event/EventDetailDialog/data.js | 2 +- .../event/event/EventDetailDialog/index.vue | 124 +- .../smart/analysis/data.js | 28 + .../smart/analysis/images/refresh.svg | 22 + .../smart/analysis/index.vue | 34 + .../Carousel/images/arrow.svg | 36 + .../EventDetailDialog/Carousel/index.vue | 126 + .../eventAnalysis/EventDetailDialog/data.js | 177 ++ .../eventPlanDialog/index.vue | 521 ++++ .../EventDetailDialog/formTable/index.vue | 336 +++ .../eventAnalysis/EventDetailDialog/index.vue | 406 +++ .../EventDetailDialog/qbbDialog/index.vue | 381 +++ .../FormEvent/PresetFormItems.js | 1228 ++++++++ .../eventAnalysis/FormEvent/data.js | 2537 +++++++++++++++++ .../eventAnalysis/FormEvent/index.vue | 258 ++ .../pages/perception/eventAnalysis/data.js | 226 ++ .../eventAnalysis/images/export.svg | 14 + .../eventAnalysis/images/insert.svg | 9 + .../eventAnalysis/images/refresh.svg | 22 + .../pages/perception/eventAnalysis/index.vue | 321 +++ 31 files changed, 7147 insertions(+), 206 deletions(-) create mode 100644 ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processed24.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processing21.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/toBeConfirmed23.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/analysis/data.js create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/analysis/images/refresh.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/maintenanceOperations/smart/analysis/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/Carousel/images/arrow.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/Carousel/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/data.js create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/eventPlanDialog/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/formTable/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/qbbDialog/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/FormEvent/PresetFormItems.js create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/FormEvent/data.js create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/FormEvent/index.vue create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/data.js create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/images/export.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/images/insert.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/images/refresh.svg create mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/index.vue diff --git a/ruoyi-ui/src/common/menuData.js b/ruoyi-ui/src/common/menuData.js index 2e53651d..4260bd4f 100644 --- a/ruoyi-ui/src/common/menuData.js +++ b/ruoyi-ui/src/common/menuData.js @@ -37,6 +37,12 @@ export default [ name: "perceptionTrafficSituation", component: "perception/trafficSituation/index.vue", }, + { + title: "感知事件分析", + path: "/perception/eventAnalysis", + name: "perceptionEventAnalysis", + component: "perception/eventAnalysis/index.vue", + }, ], }, { @@ -177,6 +183,12 @@ export default [ path: "/maintain/smart/manage", component: "maintenanceOperations/smart/manage/index.vue", }, + { + title: "设备数据分析", + name: "deviceDataAnalysis", + path: "/maintain/smart/analysis", + component: "maintenanceOperations/smart/analysis/index.vue", + }, ], }, { diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/data.js b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/data.js index d094e48e..0832e2de 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/data.js +++ b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/data.js @@ -10,4 +10,12 @@ export const statusMap = { 4: "processing", // 待确认 5: "toBeConfirmed", + // 上报 + 21: "processing21", + // 已完成 + 22: "confirmed22", + // 已终止 + 23: "toBeConfirmed23", + // 自动结束 + 24: "processed24", }; diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg new file mode 100644 index 00000000..e38d7fde --- /dev/null +++ b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg @@ -0,0 +1,32 @@ + + + diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processed24.svg b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processed24.svg new file mode 100644 index 00000000..9a6ff56c --- /dev/null +++ b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processed24.svg @@ -0,0 +1,31 @@ + + + diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processing21.svg b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processing21.svg new file mode 100644 index 00000000..8623846e --- /dev/null +++ b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processing21.svg @@ -0,0 +1,33 @@ + + + diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/toBeConfirmed23.svg b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/toBeConfirmed23.svg new file mode 100644 index 00000000..9a0317bb --- /dev/null +++ b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/toBeConfirmed23.svg @@ -0,0 +1,32 @@ + + + diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/PerceiveEvent/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/PerceiveEvent/index.vue index 9a59b27b..b80b50af 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/PerceiveEvent/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/PerceiveEvent/index.vue @@ -13,7 +13,7 @@ - + @@ -43,7 +43,91 @@ import { markerClusterIns } from "@screen/pages/Home/components/RoadAndEvents/ut import { eventMap } from "@screen/pages/Home/components/RoadAndEvents/utils/buttonEvent"; let vehicleTypeList = []; - +const _formList = [{ + label: "报警时间:", + key: "warningTime", + type: "text", + }, + { + label: "事件地点:", + key: "stakeMark", + type: "text", + }, + { + label: "路段方向:", + key: "direction", + type: "text", + isAlone: true, + }, + { + label: "事件来源:", + key: "warningSource", + type: "text", + enum: "InfoWarningSource", + }, + { + label: "事件类型:", + key: "warningType", + type: "select", + options: { + disabled: true, + options: WarningTypeList, + }, + ons: { + change: (value, { data }) => { + this.formList[5].options.options = + WarningSubclassList[value] || []; + data.warningSubclass = null; + }, + }, + }, + { + label: "细分类型:", + key: "warningSubclass", + type: "select", + options: { + options: [], + }, + }, + // { + // label: "车辆类型:", + // key: "vehicleType", + // type: "select", + // options: { + // options: vehicleTypeList + // }, + // }, + { + label: "事件描述:", + key: "remark", + options: { + type: "textarea", + maxlength: 100, + autosize: { minRows: 3, maxRows: 3 }, + showWordLimit: true, + }, + }, + { + label: "影响车道:", + key: "lane", + type: "CheckboxGroup", + options: { + // activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: LaneOccupancyList, + gap: "12px", + }, + }, + { + label: "持续时长:", + key: "duration", + type: "text", + }, + // { + // label: "天气情况:", + // key: "weather", + // type: "text", + // }, +] function getDuration(warningTime) { const currentTime = moment(); const specifiedTime = moment(warningTime); @@ -94,92 +178,8 @@ export default { // deviceVendors: "XXX厂家", // time: "2023/01/02 09:09:09" }, - formList: [ - { - label: "报警时间:", - key: "warningTime", - type: "text", - }, - { - label: "事件地点:", - key: "stakeMark", - type: "text", - }, - { - label: "路段方向:", - key: "direction", - type: "text", - isAlone: true, - }, - { - label: "事件来源:", - key: "warningSource", - type: "text", - enum: "InfoWarningSource", - }, - { - label: "事件类型:", - key: "warningType", - type: "select", - options: { - disabled: true, - options: WarningTypeList, - }, - ons: { - change: (value, { data }) => { - this.formList[5].options.options = - WarningSubclassList[value] || []; - data.warningSubclass = null; - }, - }, - }, - { - label: "细分类型:", - key: "warningSubclass", - type: "select", - options: { - options: [], - }, - }, - // { - // label: "车辆类型:", - // key: "vehicleType", - // type: "select", - // options: { - // options: vehicleTypeList - // }, - // }, - { - label: "事件描述:", - key: "remark", - options: { - type: "textarea", - maxlength: 100, - autosize: { minRows: 6, maxRows: 6 }, - showWordLimit: true, - }, - }, - { - label: "影响车道:", - key: "lane", - type: "CheckboxGroup", - options: { - // activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: LaneOccupancyList, - gap: "12px", - }, - }, - { - label: "持续时长:", - key: "duration", - type: "text", - }, - // { - // label: "天气情况:", - // key: "weather", - // type: "text", - // }, - ], + formList: [], + loading:false, }; }, async created() { @@ -196,42 +196,116 @@ export default { this.dialogData.pictures = otherConfig.pictures } - console.log(1122, this.dialogData, 3344); + this.formList = [..._formList] }, beforeDestroy() { clearInterval(this.interval); }, methods: { onDelete() { - const id = this.dialogData.id; - id && - this.$confirm("确定误报吗?", "提示", { - confirmButtonText: "确定", - cancelButtonText: "取消", - type: "warning", - }).then(() => { - request({ - url: `/business/warning/delete`, - method: "post", - data: { id }, - }).then((result) => { - if (result.code == 200) Message.success("成功!"); - else Message.error(result?.msg); - const item = { title: "感知事件" }; - - eventMap[`事件专题/${item.title}_close`]?.call( - this, - item, - (item) => { - return item?.extData?.id == id; + const self = this; + if(this.formList.length === _formList.length ){ + this.formList.splice(6,0,{ + label: "解除类型:", + key: "relieveType", + type: "RadioGroup", + isAlone: true, + required: true, + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "误报解除", + }, + { + key: "2", + label: "已结束", }, - "special" - ); - //触发全局监听事件 - this.$root.$emit('refresh-event'); - // markerClusterIns.setData(); + { + key: "3", + label: "无需处理", + }, + { + key: "4", + label: "其它", + } + ], + }, + }) + this.formList.splice(7,0,{ + label: "解除原因:", // 标题 + key: "relieveReason", //数据存储字段 + isAlone: true, // 单独一行 + type: "input", //组件类型(el-input 去掉el-即可) 不填默认为input + options: { //element原生formItem属性 + type: "textarea", + autosize: true, + maxlength: 200, + autosize: { minRows: 3, maxRows: 3 }, + showWordLimit: true, + } + }) + } else { + this.$refs.FormConfigRef.validate() + .then((result) => { + this.loading = true; + request({ + url: `/business/warning/falseAlarm`, + method: "post", + data: { + id: this.dialogData.id, + relieveType: result.relieveType, + relieveReason: result.relieveReason + }, + }).then((result) => { + + if (result.code == 200) Message.success("成功!"); + else Message.error(result?.msg); + this.obverseVisible = false; + this.loading = false; + setTimeout(() => { + self.$root.$emit('delete-event'); + //触发全局监听事件 + self.$root.$emit('refresh-event'); + }, 500); + + + }); + }) + .catch((err) => { }); - }); + } + // 2024-05-18 修改为二次确认,增加误报类型和误报原因 + // const id = this.dialogData.id; + // id && + // this.$confirm("确定误报吗?", "提示", { + // confirmButtonText: "确定", + // cancelButtonText: "取消", + // type: "warning", + // }).then(() => { + // request({ + // url: `/business/warning/delete`, + // method: "post", + // data: { id }, + // }).then((result) => { + // if (result.code == 200) Message.success("成功!"); + // else Message.error(result?.msg); + // const item = { title: "感知事件" }; + + // eventMap[`事件专题/${item.title}_close`]?.call( + // this, + // item, + // (item) => { + // return item?.extData?.id == id; + // }, + // "special" + // ); + // //触发全局监听事件 + // this.$root.$emit('refresh-event'); + // // markerClusterIns.setData(); + // }); + // }); }, getVehicleTypeList(fn) { if (vehicleTypeList.length) { @@ -275,35 +349,6 @@ export default { .then(({ data, code }) => { if (code != 200) return Message.error("详情获取失败"); - // data = { - // "searchValue": null, - // "createBy": null, - // "createTime": "2024-07-23 14:18:58", - // "updateBy": null, - // "updateTime": "2024-02-01 15:55:34", - // "remark": "111", - // "params": {}, - // "id": "1", - // "stakeMark": "k103+900", - // "direction": "1", - // "deptId": null, - // "warningState": 1, - // "warningTime": null, - // "userId": null, - // "warningSource": 1, - // "warningLevel": null, - // "warningType": 1, - // "warningSubclass": null, - // "warningTitle": null, - // "otherConfig": null, - // "lane": null, - // "sectionName": null, - // "number": 0, - // "type": null, - // "sectionId": null, - // "longitude": "116.493888", - // "latitude": "36.291145" - // }; data.duration = this.convertSecToHHmmss(data.duration); this.data = { ...data, @@ -334,16 +379,6 @@ export default { }, updateEvent() { this.btnLoading = true; - - // console.log({ - // id: this.dialogData.id, - // warningType: this.data.warningType, - // warningSubclass: this.data.warningSubclass, - // remark: this.data.remark, - // vehicleType: this.data.vehicleType, - // lane: this.data.lane - // }) - request({ url: `/perceivedEvents/warning/updateWarning`, method: "post", diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/HomeFrameControl/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/HomeFrameControl/index.vue index c0e31c42..93f8a409 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/HomeFrameControl/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/HomeFrameControl/index.vue @@ -21,7 +21,8 @@ { this.activeIcon = null; }"> -