From b7dc324c3b7e7b2229fcba81f95bb5819c8f639f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E9=92=A6?= <360013221@qq.com> Date: Mon, 20 May 2024 18:05:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=83=A8=E5=88=86=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/Dialog/index.vue | 2 +- .../RoadStateCard/images/confirmed22.svg | 3 +- .../RoadStateCard/images/processed24.svg | 3 +- .../RoadStateCard/images/processing21.svg | 3 +- .../RoadStateCard/images/toBeConfirmed23.svg | 3 +- .../JiHeExpressway/components/Video/Video.vue | 2 +- .../JiHeExpressway/components/Video/index.vue | 3 +- .../components/DeviceControlDialog.vue | 6 +- .../Dialogs/RoadNetworkFacilities/data.js | 58 +- .../Dialogs/RoadNetworkFacilities/index.vue | 17 +- .../CrowdnessIndicatorRankings/index.vue | 1 + .../Cards/DispatchLiaison/index.vue | 4 +- .../DisposalProcess/DialogVisible/index.vue | 45 +- .../Cards/DisposalProcess/index.vue | 4 +- .../EditEventInformationDialog/data.js | 4635 +++++++++-------- .../EditEventInformationDialog/index.vue | 77 +- .../EventInformation/images/congestion.svg | 2 +- .../AddControlEventInfoDialog/data.js | 2 +- .../control/event/commandDispatch/index.vue | 2 +- .../control/event/event/FormEvent/data.js | 2 +- .../eventPlanDialog/index.vue | 521 -- .../EventDetailDialog/formTable/index.vue | 336 -- .../eventAnalysis/EventDetailDialog/index.vue | 323 +- .../EventDetailDialog/qbbDialog/index.vue | 381 -- .../eventAnalysis/FormEvent/data.js | 2 +- .../pages/perception/eventAnalysis/index.vue | 44 +- 26 files changed, 2419 insertions(+), 4062 deletions(-) delete mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/eventPlanDialog/index.vue delete mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/formTable/index.vue delete mode 100644 ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/qbbDialog/index.vue diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/Dialog/index.vue b/ruoyi-ui/src/views/JiHeExpressway/components/Dialog/index.vue index 8aa137f6..59094591 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/components/Dialog/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/components/Dialog/index.vue @@ -211,7 +211,7 @@ export default { } .dialog-content { - padding: 9px 21px 27px 21px; + padding: 9px 21px 9px 21px; max-height: 95vh; overflow-y: auto; } diff --git a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg index e38d7fde..e797e069 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg +++ b/ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg @@ -1,7 +1,6 @@ - +
@@ -27,6 +26,8 @@ import Video from "@screen/components/VideoMulti"; import request from "@/utils/request"; import { dialogDelayVisible } from "./../mixin"; import { tabList } from './data' +import { DirectionTypes } from "@screen/utils/enum.js" + // 所有交通事件的详情 export default { @@ -61,7 +62,19 @@ export default { if (dData.otherConfig) { let otherConfig = JSON.parse(dData.otherConfig); dData.latitude = otherConfig.dimension - dData = { ...dData, ...otherConfig } + if(dData.direction){ + dData.direction = DirectionTypes[dData.direction] + } + let resPointList = await request({ + url: `dc/sideSlope/GetMeasurePointList`, + method: "get", + }); + if (resPointList.code != 200) return Message.error(result?.msg); + let pointList = {}; + if(resPointList.data && resPointList.data.result && resPointList.data.result.length > 0){ + pointList = resPointList.data.result[0] + } + dData = { ...dData, ...otherConfig,...pointList } } this.data = dData; // console.log('this.data', this.data) diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue index 0314e34e..11a517ba 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue @@ -288,6 +288,7 @@ export default { const self = this; setTimeout(() => { // 获取map接口 + console.log(self.detailData,'----------') const { AMap, mapIns } = self.$refs.AMapContainerRef.getMapInstance(); const { longitude, dimension, eventName } = self.detailData; const icon = require(`@screen/images/layer/事件专题/${eventName}_active.svg`); diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DispatchLiaison/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DispatchLiaison/index.vue index 6e3654f9..99f71e17 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DispatchLiaison/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DispatchLiaison/index.vue @@ -100,7 +100,7 @@ export default { watch: { "provideData.detail"(newValue, oldValue) { this.provideDetail = newValue; - this.getCommandDispatch(); + this.getVehicleTypeList(); // console.log("建亭侯", this.provideDetail); }, @@ -130,7 +130,6 @@ export default { } }); this.dispatchList = res.data.listData; - console.log("调度联络返回============", res.data); this.dispatchData = res.data.resource ? res.data.resource : {}; this.staff = []; this.vehicle = []; @@ -174,6 +173,7 @@ export default { .then(({ data, code }) => { if (code != 200) return; //Message.error("详情获取失败"); this.vehicleTypeList = data; + this.getCommandDispatch(); }) .catch((err) => {}); }, diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/DialogVisible/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/DialogVisible/index.vue index 9108070e..46a243d9 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/DialogVisible/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/DialogVisible/index.vue @@ -574,7 +574,7 @@ import htmlDocx from "html-docx-js/dist/html-docx"; import Dialog from "@screen/components/Dialog/index"; import Form from "@screen/components/FormConfig"; import { formList, reportList } from "./data"; -import { tabConfigList } from "../../EventInformation/components/EditEventInformationDialog/data.js"; +import { configList } from "../../EventInformation/components/EditEventInformationDialog/data.js"; import Button from "@screen/components/Buttons/Button.vue"; import request from "@/utils/request"; import Pagination from "@screen/components/Pagination.vue"; @@ -680,7 +680,7 @@ export default { url: `/dc/system/event/eventSubclass/${this.eventId}`, //交通事件 method: "get", }); - + if (infoData.code != 200) return Message.error(infoData?.msg); let info = infoData.data; if (typeof info.stakeMark == "string") { @@ -689,42 +689,9 @@ export default { } this.fData = info; - let configList = tabConfigList.find( - (item) => item.label == this.fData.eventName - ); - this.formConfigList = configList.formConfig.list; + this.formConfigList = configList[info.eventName]; await Promise.all([ - //道路 - request({ - url: `/business/road/query`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - this.roads = []; - result.data.forEach((it) => { - this.roads.push({ key: it.id, label: it.roadName }); - }); - }) - .catch((err) => { - Message.error("查询失败4", err); - }), - //方向字典 - request({ - url: `/system/dict/data/type/iot_event_direction`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - this.direction = []; - result.data.forEach((it) => { - this.direction.push({ key: it.dictValue, label: it.dictLabel }); - }); - }) - .catch((err) => { - Message.error("查询失败5", err); - }), //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 request({ url: `/business/facility/query`, @@ -747,12 +714,6 @@ export default { ]); this.formConfigList.forEach((it) => { - if (it.key == "direction") { - it.options.options = this.direction; - } - if (it.key == "roadId") { - it.options.options = this.roads; - } if (it.key == "dcEventServiceArea.facilityId") { it.options.options = this.lwss.filter((ss) => ss.type == 6); } diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/index.vue index 47af8e59..2ffd968f 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/index.vue @@ -133,12 +133,12 @@
- @@ -181,7 +181,7 @@ export default { return { provideDetail: {}, dialogType: "", - dialogVisible: false, + dialogVisible: null, eventId: "", test: null, testRadio: "input", diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/data.js b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/data.js index b8294fd2..1391de20 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/data.js +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/data.js @@ -1,7 +1,32 @@ import * as PresetFormItems from "@screen/pages/control/event/event/FormEvent/PresetFormItems.js"; import request from "@/utils/request"; import { Message } from "element-ui"; - +const directionName = { + label: "方向:", + key: "direction", + required: true, + type: "select", + options: { + options: [ + { value: "济南方向", label: "济南方向" }, + { value: "菏泽方向", label: "菏泽方向" }, + ], + }, +}; +const freeway = { + label: "路线:", + required: true, + key: "roadName", + type: "select", + options: { + options: [ + { + key: "济菏高速", + label: "济菏高速", + }, + ], + }, +} const locationSelect = [ { value: "1", @@ -48,1713 +73,1675 @@ const locationSelect = [ label: "出口内广场", }, ]; +const inTunnel = { + label: "是否处在隧道:", + key: "inTunnel", + required: true, + type: "RadioGroup", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 1, + label: "是", + }, + { + key: 0, + label: "否", + }, + ], + }, +} -export const tabConfigList = [ - { - key: "TrafficAccident", - label: "交通事故", - formConfig: { - list: [ - { - ...PresetFormItems.callPolicePersonName, - key: "dcEventAccident.reporterName", - }, - { - ...PresetFormItems.callPolicePersonPhone, - key: "dcEventAccident.reporterPhoneNumber", +const isCongestionAhead = { + label: "前方是否拥堵:", + key: "dcEventAccident.congestionAhead", + type: "RadioGroup", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 0, + label: "是", + }, + { + key: 1, + label: "否", + }, + ], + }, +}; +const isForkRoad = { + label: "是否分岔口:", + key: "dcEventAccident.atIntersection", + type: "RadioGroup", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 0, + label: "是", + }, + { + key: 1, + label: "否", + }, + ], + }, +}; +const isCurveRoad = { + label: "是否处在弯道:", + key: "dcEventAccident.onCurve", + type: "RadioGroup", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 1, + label: "是", + }, + { + key: 0, + label: "否", + }, + ], + }, +}; + +export const configList = { + 车辆故障: [ + { + ...PresetFormItems.callPolicePersonName, + key: "dcEventVehicleAccident.reporterName", + }, + { + ...PresetFormItems.callPolicePersonPhone, + key: "dcEventVehicleAccident.reporterPhoneNumber", + }, + PresetFormItems.vehicleMalfunctionType, + PresetFormItems.eventLevel, + { + ...PresetFormItems.locationMode, + key: "dcEventVehicleAccident.locationType", + }, + freeway, + { + label: "服务区:", + key: "dcEventVehicleAccident.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.dcEventVehicleAccident?.locationType == 2) { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventVehicleAccident.location", + isAlone: false, + required: true, + options: { + placeholder: "服务区地点", + }, + visible: (data) => { + if (data?.dcEventVehicleAccident?.locationType == 2) { + return true; + } + return false; + }, + }, + { + label: "立交桥:", + key: "dcEventVehicleAccident.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.dcEventVehicleAccident?.locationType == 3) { + return true; + } + return false; + }, + ons: { + change(value, ...args) { + const { formList } = args.slice(-1)[0]; + + //匝道 + request({ + url: `/system/ramp/listAll?facilityId=${value}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let zd = []; + result.rows.forEach((it) => + zd.push({ key: it.id, label: it.rampName }) + ); + console.log("zd", zd); + formList.forEach((it) => { + if (it.key == "dcEventVehicleAccident.rampId") { + // console.log("it", it); + it.options.options = zd; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败2", err); + }); }, - PresetFormItems.trafficAccidentType, - PresetFormItems.eventLevel, - { - ...PresetFormItems.locationMode, - key: "dcEventAccident.locationType", + }, + }, + { + label: "匝道:", + key: "dcEventVehicleAccident.rampId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data?.dcEventVehicleAccident?.locationType == 3) { + return true; + } + return false; + }, + }, + { + label: "收费站:", + key: "dcEventVehicleAccident.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.dcEventVehicleAccident?.locationType == 4) { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventVehicleAccident.location", + type: "select", + isAlone: false, + required: true, + options: { + placeholder: "收费站地点", + options: locationSelect, + }, + visible: (data) => { + if (data?.dcEventVehicleAccident?.locationType == 4) { + return true; + } + return false; + }, + }, + directionName, + { ...PresetFormItems.station, + visible: (data) => { + if (data.dcEventVehicleAccident && data.dcEventVehicleAccident.locationType != 1) { + return false; + } + return true; + }, + }, + PresetFormItems.eventHappenTime, + PresetFormItems.aEstimatedReleaseTime, + { + ...PresetFormItems.pressure, + key: "dcEventVehicleAccident.trafficJam", + }, + { + ...PresetFormItems.weatherCondition, + key: "dcEventVehicleAccident.weatherCondition", + }, + { + ...isCongestionAhead, + key: "dcEventVehicleAccident.congestionAhead", + }, + { + ...isForkRoad, + key: "dcEventVehicleAccident.atIntersection", + }, + { + ...isCurveRoad, + key: "dcEventVehicleAccident.onCurve", + }, + { + ...inTunnel, + key: "dcEventVehicleAccident.inTunnel", + }, + PresetFormItems.laneOccupancy, + PresetFormItems.vehicleCondition("dcEventVehicleAccident"), + PresetFormItems.casualties("dcEventVehicleAccident"), + PresetFormItems.eventTitle, + PresetFormItems.eventDesc, + PresetFormItems.source, + ], + 交通事故: [ + { + ...PresetFormItems.callPolicePersonName, + key: "dcEventAccident.reporterName", + }, + { + ...PresetFormItems.callPolicePersonPhone, + key: "dcEventAccident.reporterPhoneNumber", + }, + PresetFormItems.trafficAccidentType, + PresetFormItems.eventLevel, + { + ...PresetFormItems.locationMode, + key: "dcEventAccident.locationType", + }, + freeway, + { + label: "服务区:", + key: "dcEventAccident.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.dcEventAccident?.locationType == 2) { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventAccident.location", + isAlone: false, + required: true, + options: { + placeholder: "服务区地点", + }, + visible: (data) => { + if (data?.dcEventAccident?.locationType == 2) { + return true; + } + return false; + }, + }, + { + label: "立交桥:", + key: "dcEventAccident.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.dcEventAccident?.locationType == 3) { + return true; + } + return false; + }, + ons: { + change(value, ...args) { + const { formList } = args.slice(-1)[0]; + + //匝道 + request({ + url: `/system/ramp/listAll?facilityId=${value}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let zd = []; + result.rows.forEach((it) => + zd.push({ key: it.id, label: it.rampName }) + ); + console.log("zd", zd); + formList.forEach((it) => { + if (it.key == "dcEventAccident.rampId") { + console.log("it", it); + it.options.options = zd; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败3", err); + }); }, - PresetFormItems.freeway, - { - label: "服务区:", - key: "dcEventAccident.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ + }, + }, + { + label: "匝道:", + key: "dcEventAccident.rampId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data?.dcEventAccident?.locationType == 3) { + return true; + } + return false; + }, + }, + { + label: "收费站:", + key: "dcEventAccident.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.dcEventAccident?.locationType == 4) { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventAccident.location", + type: "select", + isAlone: false, + required: true, + options: { + placeholder: "收费站地点", + options: locationSelect, + }, + visible: (data) => { + if (data?.dcEventAccident?.locationType == 4) { + return true; + } + return false; + }, + }, + directionName, + PresetFormItems.station, + PresetFormItems.eventHappenTime, + PresetFormItems.aEstimatedReleaseTime, + { ...PresetFormItems.pressure, key: "dcEventAccident.trafficJam" }, + { + ...PresetFormItems.weatherCondition, + key: "dcEventAccident.weatherCondition", + }, + { ...PresetFormItems.effect, key: "dcEventAccident.impactLevel" }, + { ...PresetFormItems.isArrives, key: "dcEventAccident.isReverseCargo" }, + { + ...PresetFormItems.isMaintenanceAccident, + key: "dcEventAccident.isMaintenance", + }, + { + ...PresetFormItems.trafficPolicePhone, + key: "dcEventAccident.policeContact", + }, + { + ...PresetFormItems.wreckerCalls, + key: "dcEventAccident.towingServiceContact", + }, + { + ...isCongestionAhead, + key: "dcEventAccident.congestionAhead", + }, + { + ...isForkRoad, + key: "dcEventAccident.atIntersection", + }, + { ...isCurveRoad, key: "dcEventAccident.onCurve" }, + { ...inTunnel, key: "dcEventAccident.inTunnel" }, + { ...PresetFormItems.spillName, key: "dcEventAccident.spillageItem" }, + { + ...PresetFormItems.ownerPhone, + key: "dcEventAccident.vehicleOwnerPhone", + }, + PresetFormItems.laneOccupancy, + PresetFormItems.vehicleCondition("dcEventAccident"), + PresetFormItems.casualties("dcEventAccident"), + PresetFormItems.eventTitle, + PresetFormItems.eventDesc, + PresetFormItems.source, + ], + 交通管制: [ + { + label: "管制设施:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "3-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "3-1", + label: "主线", + }, + { + key: "3-2", + label: "收费站", + }, + { + key: "3-3", + label: "立交", + }, + { + key: "3-4", + label: "服务区", + }, + ], + }, + ons: { + input(value, ...args) { + const { data, formList } = args.slice(-1)[0]; + const classify = formList.find( + (it) => it.key == "dcEventTrafficControl.classify" + ); + let ss = { + "3-1": "主线", + "3-2": "收费站", + "3-3": "立交", + "3-4": "服务区", + }; + let ad = { + 1: [ { - value: "选项1", - label: "黄金糕", + key: "1", + label: `${ss[value]}关闭`, }, ], - }, - visible: (data) => { - if (data?.dcEventAccident?.locationType == 2) { - return true; - } - return false; - }, - }, - { - label: "地点:", - key: "dcEventAccident.location", - isAlone: false, - required: true, - options: { - placeholder: "服务区地点", - }, - visible: (data) => { - if (data?.dcEventAccident?.locationType == 2) { - return true; - } - return false; - }, - }, - { - label: "立交桥:", - key: "dcEventAccident.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ + 2: [ { - value: "选项1", - label: "黄金糕", + key: "2", + label: "主线限行", }, - ], - }, - visible: (data) => { - if (data?.dcEventAccident?.locationType == 3) { - return true; - } - return false; - }, - ons: { - change(value, ...args) { - const { formList } = args.slice(-1)[0]; - - //匝道 - request({ - url: `/system/ramp/listAll?facilityId=${value}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let zd = []; - result.rows.forEach((it) => - zd.push({ key: it.id, label: it.rampName }) - ); - console.log("zd", zd); - formList.forEach((it) => { - if (it.key == "dcEventAccident.rampId") { - console.log("it", it); - it.options.options = zd; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败3", err); - }); - }, - }, - }, - { - label: "匝道:", - key: "dcEventAccident.rampId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data?.dcEventAccident?.locationType == 3) { - return true; - } - return false; - }, - }, - { - label: "收费站:", - key: "dcEventAccident.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ { - value: "选项1", - label: "黄金糕", + key: "3", + label: "主线间隔放行", }, - ], - }, - visible: (data) => { - if (data?.dcEventAccident?.locationType == 4) { - return true; - } - return false; - }, - }, - { - label: "地点:", - key: "dcEventAccident.location", - type: "select", - isAlone: false, - required: true, - options: { - placeholder: "收费站地点", - options: locationSelect, - }, - visible: (data) => { - if (data?.dcEventAccident?.locationType == 4) { - return true; - } - return false; - }, - }, - PresetFormItems.direction, - PresetFormItems.station, - PresetFormItems.eventHappenTime, - PresetFormItems.aEstimatedReleaseTime, - { ...PresetFormItems.pressure, key: "dcEventAccident.trafficJam" }, - { - ...PresetFormItems.weatherCondition, - key: "dcEventAccident.weatherCondition", - }, - { ...PresetFormItems.effect, key: "dcEventAccident.impactLevel" }, - { ...PresetFormItems.isArrives, key: "dcEventAccident.isReverseCargo" }, - { - ...PresetFormItems.isMaintenanceAccident, - key: "dcEventAccident.isMaintenance", - }, - { - ...PresetFormItems.trafficPolicePhone, - key: "dcEventAccident.policeContact", - }, - { - ...PresetFormItems.wreckerCalls, - key: "dcEventAccident.towingServiceContact", - }, - { - ...PresetFormItems.isCongestionAhead, - key: "dcEventAccident.congestionAhead", - }, - { - ...PresetFormItems.isForkRoad, - key: "dcEventAccident.atIntersection", - }, - { ...PresetFormItems.isCurveRoad, key: "dcEventAccident.onCurve" }, - { ...PresetFormItems.isInTunnel, key: "dcEventAccident.inTunnel" }, - { ...PresetFormItems.spillName, key: "dcEventAccident.spillageItem" }, - { - ...PresetFormItems.ownerPhone, - key: "dcEventAccident.vehicleOwnerPhone", - }, - PresetFormItems.laneOccupancy, - PresetFormItems.vehicleCondition("dcEventAccident"), - PresetFormItems.casualties("dcEventAccident"), - PresetFormItems.eventTitle, - PresetFormItems.eventDesc, - PresetFormItems.source, - ], - }, - }, - { - key: "VehicleFault", - label: "车辆故障", - formConfig: { - formOptions: {}, - list: [ - { - ...PresetFormItems.callPolicePersonName, - key: "dcEventVehicleAccident.reporterName", - }, - { - ...PresetFormItems.callPolicePersonPhone, - key: "dcEventVehicleAccident.reporterPhoneNumber", - }, - PresetFormItems.vehicleMalfunctionType, - PresetFormItems.eventLevel, - { - ...PresetFormItems.locationMode, - key: "dcEventVehicleAccident.locationType", - }, - PresetFormItems.freeway, - { - label: "服务区:", - key: "dcEventVehicleAccident.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ { - value: "选项1", - label: "黄金糕", + key: "4", + label: "主线并道", }, - ], - }, - visible: (data) => { - if (data?.dcEventVehicleAccident?.locationType == 2) { - return true; - } - return false; - }, - }, - { - label: "地点:", - key: "dcEventVehicleAccident.location", - isAlone: false, - required: true, - options: { - placeholder: "服务区地点", - }, - visible: (data) => { - if (data?.dcEventVehicleAccident?.locationType == 2) { - return true; - } - return false; - }, - }, - { - label: "立交桥:", - key: "dcEventVehicleAccident.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ { - value: "选项1", - label: "黄金糕", + key: "5", + label: "主线限速", }, ], - }, - visible: (data) => { - if (data?.dcEventVehicleAccident?.locationType == 3) { - return true; - } - return false; - }, - ons: { - change(value, ...args) { - const { formList } = args.slice(-1)[0]; + }; + classify.options.options = + ad[data.dcEventTrafficControl.controlType]; - //匝道 - request({ - url: `/system/ramp/listAll?facilityId=${value}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let zd = []; - result.rows.forEach((it) => - zd.push({ key: it.id, label: it.rampName }) - ); - console.log("zd", zd); - formList.forEach((it) => { - if (it.key == "dcEventVehicleAccident.rampId") { - // console.log("it", it); - it.options.options = zd; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败2", err); + if (data.dcEventTrafficControl) { + data.dcEventTrafficControl.facilityId = null; + } + let facilityType = 1; + if (value == "3-2") { + facilityType = 1; + } else if (value == "3-3") { + facilityType = 4; + } else if (value == "3-4") { + facilityType = 6; + } + if (value && value != "3-1") { + //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 + request({ + url: `/business/facility/query?facilityType=${facilityType}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let lwss = []; + result.data.forEach((it) => + lwss.push({ key: it.id, label: it.facilityName }) + ); + + formList.forEach((it) => { + if (it.key == "dcEventTrafficControl.facilityId") { + it.options.options = lwss; + } }); - }, - }, - }, - { - label: "匝道:", - key: "dcEventVehicleAccident.rampId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data?.dcEventVehicleAccident?.locationType == 3) { - return true; - } - return false; - }, - }, - { - label: "收费站:", - key: "dcEventVehicleAccident.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ - { - value: "选项1", - label: "黄金糕", - }, - ], - }, - visible: (data) => { - if (data?.dcEventVehicleAccident?.locationType == 4) { - return true; - } - return false; - }, - }, - { - label: "地点:", - key: "dcEventVehicleAccident.location", - type: "select", - isAlone: false, - required: true, - options: { - placeholder: "收费站地点", - options: locationSelect, - }, - visible: (data) => { - if (data?.dcEventVehicleAccident?.locationType == 4) { - return true; - } - return false; - }, - }, - PresetFormItems.direction, - { ...PresetFormItems.station, - visible: (data) => { - if (data.dcEventVehicleAccident && data.dcEventVehicleAccident.locationType != 1) { - return false; - } - return true; - }, - }, - PresetFormItems.eventHappenTime, - PresetFormItems.aEstimatedReleaseTime, - { - ...PresetFormItems.pressure, - key: "dcEventVehicleAccident.trafficJam", - }, - { - ...PresetFormItems.weatherCondition, - key: "dcEventVehicleAccident.weatherCondition", - }, - { - ...PresetFormItems.isCongestionAhead, - key: "dcEventVehicleAccident.congestionAhead", - }, - { - ...PresetFormItems.isForkRoad, - key: "dcEventVehicleAccident.atIntersection", - }, - { - ...PresetFormItems.isCurveRoad, - key: "dcEventVehicleAccident.onCurve", - }, - { - ...PresetFormItems.isInTunnel, - key: "dcEventVehicleAccident.inTunnel", + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败1", err); + }); + } }, - PresetFormItems.laneOccupancy, - PresetFormItems.vehicleCondition("dcEventVehicleAccident"), - PresetFormItems.casualties("dcEventVehicleAccident"), - PresetFormItems.eventTitle, - PresetFormItems.eventDesc, - PresetFormItems.source, - ], + }, }, - }, - { - key: "TrafficControl", - label: "交通管制", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "管制设施:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "3-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "3-1", - label: "主线", - }, + { + label: "管制分类:", + key: "dcEventTrafficControl.controlType", + type: "RadioGroup", + isAlone: true, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 1, + label: "封闭", + }, + { + key: 2, + label: "限行", + }, + ], + }, + ons: { + input(value, ...args) { + const { data, formList } = args.slice(-1)[0]; + const classify = formList.find( + (it) => it.key == "dcEventTrafficControl.classify" + ); + const measure = formList.find( + (it) => it.key == "dcEventTrafficControl.measure" + ); + let ss = { + "3-1": "主线", + "3-2": "收费站", + "3-3": "立交", + "3-4": "服务区", + }; + let ad = { + 1: [ { - key: "3-2", - label: "收费站", + key: "1", + label: `${ss[data.eventSubclass]}关闭`, }, + ], + 2: [ { - key: "3-3", - label: "立交", + key: "2", + label: "主线限行", }, { - key: "3-4", - label: "服务区", + key: "3", + label: "主线间隔放行", }, - ], - }, - ons: { - input(value, ...args) { - const { data, formList } = args.slice(-1)[0]; - const classify = formList.find( - (it) => it.key == "dcEventTrafficControl.classify" - ); - let ss = { - "3-1": "主线", - "3-2": "收费站", - "3-3": "立交", - "3-4": "服务区", - }; - let ad = { - 1: [ - { - key: "1", - label: `${ss[value]}关闭`, - }, - ], - 2: [ - { - key: "2", - label: "主线限行", - }, - { - key: "3", - label: "主线间隔放行", - }, - { - key: "4", - label: "主线并道", - }, - { - key: "5", - label: "主线限速", - }, - ], - }; - classify.options.options = - ad[data.dcEventTrafficControl.controlType]; - - if (data.dcEventTrafficControl) { - data.dcEventTrafficControl.facilityId = null; - } - let facilityType = 1; - if (value == "3-2") { - facilityType = 1; - } else if (value == "3-3") { - facilityType = 3; - } else if (value == "3-4") { - facilityType = 6; - } - if (value && value != "3-1") { - //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 - request({ - url: `/business/facility/query?facilityType=${facilityType}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let lwss = []; - result.data.forEach((it) => - lwss.push({ key: it.id, label: it.facilityName }) - ); - - formList.forEach((it) => { - if (it.key == "dcEventTrafficControl.facilityId") { - it.options.options = lwss; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败1", err); - }); - } - }, - }, - }, - { - label: "管制分类:", - key: "dcEventTrafficControl.controlType", - type: "RadioGroup", - isAlone: true, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ { - key: "1", - label: "封闭", + key: "4", + label: "主线并道", }, { - key: "2", - label: "限行", + key: "5", + label: "主线限速", }, ], - }, - ons: { - input(value, ...args) { - const { data, formList } = args.slice(-1)[0]; - const classify = formList.find( - (it) => it.key == "dcEventTrafficControl.classify" - ); - const measure = formList.find( - (it) => it.key == "dcEventTrafficControl.measure" - ); - let ss = { - "3-1": "主线", - "3-2": "收费站", - "3-3": "立交", - "3-4": "服务区", - }; - let ad = { - 1: [ - { - key: "1", - label: `${ss[data.eventSubclass]}关闭`, - }, - ], - 2: [ - { - key: "2", - label: "主线限行", - }, - { - key: "3", - label: "主线间隔放行", - }, - { - key: "4", - label: "主线并道", - }, - { - key: "5", - label: "主线限速", - }, - ], - }; - let cs = { - 1: [ - { - value: "1", - label: "临时关闭", - }, - ], - 2: [ - { - value: "2", - label: "限行车辆", - }, - { - value: "3", - label: "限行车道", - }, - { - value: "4", - label: "限行车道且限行车辆", - }, - { - value: "5", - label: "间隔放行", - }, - { - value: "6", - label: "并道行驶", - }, - { - value: "7", - label: "限速", - }, - ], - }; - measure.options.options = cs[value]; - classify.options.options = ad[value]; - }, - }, - }, - { - label: "分类:", - key: "dcEventTrafficControl.classify", - type: "RadioGroup", - isAlone: true, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ + }; + let cs = { + 1: [ { - key: "1", - label: "主线关闭", + value: "1", + label: "临时关闭", }, ], - }, - }, - { - label: "分类原因:", - key: "dcEventTrafficControl.controlCause", - type: "RadioGroup", - isAlone: true, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ + 2: [ { - key: "1", - label: "车流量大", + value: "2", + label: "限行车辆", }, { - key: "2", - label: "交通事故", + value: "3", + label: "限行车道", }, { - key: "3", - label: "恶劣天气", + value: "4", + label: "限行车道且限行车辆", }, { - key: "4", - label: "施工", + value: "5", + label: "间隔放行", }, { - key: "5", - label: "警备任务", + value: "6", + label: "并道行驶", }, { - key: "6", - label: "其他", + value: "7", + label: "限速", }, ], - }, - ons: { - input(value, ...args) { - const { formList } = args.slice(-1)[0]; - const config = formList.find( - (it) => it.key == "dcEventTrafficControl.causeType" - ); - let ad = { - 3: [ - { - value: "3-1", - label: "雨", - }, - { - value: "3-2", - label: "雪", - }, - { - value: "3-3", - label: "雾", - }, - { - value: "3-4", - label: "道路积水", - }, - { - value: "3-5", - label: "道路湿滑", - }, - { - value: "3-6", - label: "道路结冰", - }, - { - value: "3-7", - label: "沙尘暴", - }, - ], - 4: [ - { - value: "4-1", - label: "专项工程施工", - }, - { - value: "4-2", - label: "改扩建工程施工", - }, - { - value: "4-3", - label: "其他施工", - }, - ], - }; - config.options.options = ad[value]; - }, - }, - }, - PresetFormItems.isInTunnel, - { - label: "原因类型:", - key: "dcEventTrafficControl.causeType", - type: "select", - options: { - options: [], - }, - visible: (data) => { - if ( - data?.dcEventTrafficControl.controlCause == "3" || - data?.dcEventTrafficControl.controlCause == "4" - ) { - return true; - } - return false; - }, + }; + measure.options.options = cs[value]; + classify.options.options = ad[value]; }, - PresetFormItems.freeway, - PresetFormItems.direction, - PresetFormItems.emptyLine, - { - label: "出入口:", - key: "dcEventTrafficControl.exitsInlets", - type: "RadioGroup", - isAlone: true, - required: true, - default: "2", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "出口", + }, + }, + { + label: "分类:", + key: "dcEventTrafficControl.classify", + type: "RadioGroup", + isAlone: true, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "主线关闭", + }, + ], + }, + }, + { + label: "分类原因:", + key: "dcEventTrafficControl.controlCause", + type: "RadioGroup", + isAlone: true, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 1, + label: "车流量大", + }, + { + key: 2, + label: "交通事故", + }, + { + key: 3, + label: "恶劣天气", + }, + { + key: 4, + label: "施工", + }, + { + key: 5, + label: "警备任务", + }, + { + key: 6, + label: "其他", + }, + ], + }, + ons: { + input(value, ...args) { + const { formList } = args.slice(-1)[0]; + const config = formList.find( + (it) => it.key == "dcEventTrafficControl.causeType" + ); + let ad = { + 3: [ + { + value: "3-1", + label: "雨", }, { - key: "2", - label: "入口", + value: "3-2", + label: "雪", }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "3-2" || data?.eventSubclass == "3-4") { - return true; - } - return false; - }, - }, - { - label: "收费站:", - key: "dcEventTrafficControl.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - multiple: true, - }, - visible: (data) => { - if (data?.eventSubclass == "3-2") { - return true; - } - return false; - }, - }, - { - label: "立交桥:", - key: "dcEventTrafficControl.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - multiple: true, - }, - visible: (data) => { - if (data?.eventSubclass == "3-3") { - return true; - } - return false; - }, - ons: { - change(value, ...args) { - const { formList } = args.slice(-1)[0]; - - //匝道 - request({ - url: `/system/ramp/listAll?facilityId=${value}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let zd = []; - result.rows.forEach((it) => - zd.push({ key: it.id, label: it.rampName }) - ); - // console.log("zd", zd); - formList.forEach((it) => { - if (it.key == "dcEventTrafficControl.rampId") { - console.log("it", it); - it.options.options = zd; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败3", err); - }); - }, - }, - }, - { - label: "匝道:", - key: "dcEventTrafficControl.rampId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data?.eventSubclass == "3-3") { - return true; - } - return false; - }, - }, - { - label: "服务区:", - key: "dcEventTrafficControl.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data?.eventSubclass == "3-4") { - return true; - } - return false; - }, - }, - { - label: "措施:", - required: true, - key: "dcEventTrafficControl.measure", - type: "select", - options: { - options: [ { - value: "1", - label: "临时关闭", + value: "3-3", + label: "雾", }, - ], - }, - }, - { - label: "限制类型:", - key: "dcEventTrafficControl.limitedType", - required: true, - type: "select", - options: { - options: [ - { key: "1", label: "只允许" }, - { key: "2", label: "禁止" }, - ], - }, - visible: (data) => { - if (data?.dcEventTrafficControl.controlType == "2") { - return true; - } - return false; - }, - }, - { - label: "车辆类型:", - key: "dcEventTrafficControl.vehicleType", - required: true, - type: "select", - options: { - options: [ - { key: "1", label: "10座以下客车" }, - { key: "2", label: "10座以下客车(间隔放行)" }, - { key: "3", label: "19座以上客车" }, - { key: "4", label: "一型客车(不含面包车)" }, - { key: "5", label: "两客一危" }, - { key: "6", label: "三类以上班线客车" }, { - key: "7", - label: "四轴及四轴以上货车(运送生鲜果蔬、抗疫物资车辆除外)", + value: "3-4", + label: "道路积水", }, - { key: "8", label: "三轴及以上(含三轴)货车" }, - { key: "9", label: "3轴以上货车(不含危险品运输车)" }, - { key: "10", label: "3轴以上货车" }, - { key: "11", label: "四轴及以上(含四轴)货车" }, - { key: "12", label: "4轴以上货车(不含危险品运输车)" }, - { key: "13", label: "4轴以上货车" }, - { key: "14", label: "4轴以下货车" }, - { key: "15", label: "57座以上客车" }, - { key: "16", label: "五轴及以上货车" }, - { key: "17", label: "5轴以上货车" }, - { key: "18", label: "5轴以上货车(不含危险品运输车)" }, - { key: "19", label: "5轴以下货车" }, - { key: "20", label: "6座以上客车" }, - { key: "21", label: "6座以上面包车" }, - { key: "22", label: "7座以上客车" }, - { key: "23", label: "7座以下客车" }, - { key: "24", label: "8座以上客车" }, - // 25- 8座以下客车 - // 26- 8座以下客车(间隔放行) - // 27- 9座以上客车 - // 28- 半挂货车 - // 29- 车辆(不含10座以下客车) - // 30- 车辆(不含8座以下客车) - // 31- 车辆(不含小轿车) - // 32- 不可解体物品超限运输车 - // 33- 不可解体物品运输车 - // 34- 超长超宽超高车辆 - // 35- 车辆运输车 - // 36- 超限运输车 - // 37- 大型货车(不含危险品运输车) - // 38- 大型货车 - // 39- 大型客车 - // 40- 大中型货车 - // 41- 已安装ETC的客车 - // 42- 已安装ETC的小型客车 - // 43- 罐车 - // 44- 货车 - // 45- 黄牌货车 - // 46- 黄牌货车(不含危险品运输车) - // 47- 黄牌货车(运送民生物资车辆除外) - // 48- 核载总质量4.5吨以上货车(运送民生物资车辆除外) - // 49- 客车(包括小轿车) - // 50- 客运车辆 - // 51- 蓝牌货车 - // 52- 旅游包车 - // 53- 面包车 - // 54- 皮卡 - // 55- 全部车型 - // 56- (未安装ETC)车辆 - // 57- 外埠号牌车辆 - // 58- 危化品运输车 - // 59- 危险物品运输车 - // 60- 武装押运车辆 - // 61- 小轿车 - // 62- 厢式货车 - // 63- 小型车辆 - // 64- (已安装ETC)车辆 - // 65- 已安装ETC的货车 - // 66- 押款车辆 - // 67- 疫情防控物资运输车辆 - // 68- 运输剧毒、放射性物品车辆 - // 69- 运输枪支弹药、爆炸、剧毒、放射性物品车辆 - // 70- 营运客车 - // 71- 重型货车 - // 72- 核载总质量1.8吨以上货车 - // 73- 中型货车 - // 74- 小型车辆限速80公里/小时、大型车辆限速70 - ], - }, - visible: (data) => { - if (data?.dcEventTrafficControl.controlType == "2") { - return true; - } - return false; - }, - }, - { - label: "桩号:", - key: "stakeMark", - required: true, - type: "MultipleLabelItem", - options: { - options: [ { - prefix: { - text: "K", - style: { - color: "#3DE8FF", - }, - }, - key: "stakeMark[0]", + value: "3-5", + label: "道路湿滑", }, { - prefix: { - text: "+", - style: { - color: "#3DE8FF", - }, - }, - key: "stakeMark[1]", + value: "3-6", + label: "道路结冰", }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "3-1") { - return true; - } - return false; - }, - }, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.remark, - PresetFormItems.source, - ], - }, - }, - { - key: "TrafficCongestion", - label: "交通拥堵", - formConfig: { - formOptions: {}, - list: [ - { - label: "拥堵类型:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "4-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ { - key: "4-1", - label: "道路拥堵", + value: "3-7", + label: "沙尘暴", }, + ], + 4: [ { - key: "4-2", - label: "立交拥堵", + value: "4-1", + label: "专项工程施工", }, { - key: "4-3", - label: "收费站拥堵", + value: "4-2", + label: "改扩建工程施工", }, { - key: "4-4", - label: "服务区拥堵", + value: "4-3", + label: "其他施工", }, ], - }, - ons: { - input(value, ...args) { - const { data, formList } = args.slice(-1)[0]; - if (data.dcEventTrafficCongestion) { - data.dcEventTrafficCongestion.facilityId = null; - } - let facilityType = 1; - if (value == "4-2") facilityType = 3; - if (value == "4-3") facilityType = 1; - if (value == "4-4") facilityType = 6; - //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 - request({ - url: `/business/facility/query?facilityType=${facilityType}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let lwss = []; - result.data.forEach((it) => - lwss.push({ key: it.id, label: it.facilityName }) - ); - formList.forEach((it) => { - if (it.key == "dcEventTrafficCongestion.facilityId") { - it.options.options = lwss; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败1", err); - }); - }, - }, + }; + config.options.options = ad[value]; }, - { - ...PresetFormItems.congestionCause, - key: "dcEventTrafficCongestion.congestionCause", + }, + }, + inTunnel, + { + label: "原因类型:", + key: "dcEventTrafficControl.causeType", + type: "select", + options: { + options: [], + }, + visible: (data) => { + if ( + data?.dcEventTrafficControl.controlCause == "3" || + data?.dcEventTrafficControl.controlCause == "4" + ) { + return true; + } + return false; + }, + }, + freeway, + directionName, + PresetFormItems.emptyLine, + { + label: "出入口:", + key: "dcEventTrafficControl.exitsInlets", + type: "RadioGroup", + isAlone: true, + required: true, + default: "2", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: 1, + label: "出口", + }, + { + key: 2, + label: "入口", + }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "3-2" || data?.eventSubclass == "3-4") { + return true; + } + return false; + }, + }, + { + label: "收费站:", + key: "dcEventTrafficControl.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + multiple: true, + }, + visible: (data) => { + if (data?.eventSubclass == "3-2") { + return true; + } + return false; + }, + }, + { + label: "立交桥:", + key: "dcEventTrafficControl.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + multiple: true, + }, + visible: (data) => { + if (data?.eventSubclass == "3-3") { + return true; + } + return false; + }, + ons: { + change(value, ...args) { + const { formList } = args.slice(-1)[0]; + + //匝道 + request({ + url: `/system/ramp/listAll?facilityId=${value}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let zd = []; + result.rows.forEach((it) => + zd.push({ key: it.id, label: it.rampName }) + ); + // console.log("zd", zd); + formList.forEach((it) => { + if (it.key == "dcEventTrafficControl.rampId") { + console.log("it", it); + it.options.options = zd; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败3", err); + }); }, - { - label: "详细原因:", - key: "detailedReasons", - type: "RadioGroup", - isAlone: true, - required: true, - // default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "收费站广场拥堵导致出口压车", - }, - { - key: "2", - label: "收费站设备故障", - }, - { - key: "3", - label: "地方道路原因", - }, - { - key: "4", - label: "省内非集团所辖高速原因", - }, - { - key: "5", - label: "集团所辖道路拥堵", - }, - { - key: "6", - label: "集团所辖枢纽立交异常导致主线压车", - }, - { - key: "7", - label: "路侧起火", - }, - { - key: "8", - label: "备注项添加", + }, + }, + { + label: "匝道:", + key: "dcEventTrafficControl.rampId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data?.eventSubclass == "3-3") { + return true; + } + return false; + }, + }, + { + label: "服务区:", + key: "dcEventTrafficControl.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data?.eventSubclass == "3-4") { + return true; + } + return false; + }, + }, + { + label: "措施:", + required: true, + key: "dcEventTrafficControl.measure", + type: "select", + options: { + options: [ + { + value: "1", + label: "临时关闭", + }, + ], + }, + }, + { + label: "限制类型:", + key: "dcEventTrafficControl.limitedType", + required: true, + type: "select", + options: { + options: [ + { key: "1", label: "只允许" }, + { key: "2", label: "禁止" }, + ], + }, + visible: (data) => { + if (data?.dcEventTrafficControl.controlType == "2") { + return true; + } + return false; + }, + }, + { + label: "车辆类型:", + key: "dcEventTrafficControl.vehicleType", + required: true, + type: "select", + options: { + options: [ + { key: "1", label: "10座以下客车" }, + { key: "2", label: "10座以下客车(间隔放行)" }, + { key: "3", label: "19座以上客车" }, + { key: "4", label: "一型客车(不含面包车)" }, + { key: "5", label: "两客一危" }, + { key: "6", label: "三类以上班线客车" }, + { + key: "7", + label: "四轴及四轴以上货车(运送生鲜果蔬、抗疫物资车辆除外)", + }, + { key: "8", label: "三轴及以上(含三轴)货车" }, + { key: "9", label: "3轴以上货车(不含危险品运输车)" }, + { key: "10", label: "3轴以上货车" }, + { key: "11", label: "四轴及以上(含四轴)货车" }, + { key: "12", label: "4轴以上货车(不含危险品运输车)" }, + { key: "13", label: "4轴以上货车" }, + { key: "14", label: "4轴以下货车" }, + { key: "15", label: "57座以上客车" }, + { key: "16", label: "五轴及以上货车" }, + { key: "17", label: "5轴以上货车" }, + { key: "18", label: "5轴以上货车(不含危险品运输车)" }, + { key: "19", label: "5轴以下货车" }, + { key: "20", label: "6座以上客车" }, + { key: "21", label: "6座以上面包车" }, + { key: "22", label: "7座以上客车" }, + { key: "23", label: "7座以下客车" }, + { key: "24", label: "8座以上客车" }, + // 25- 8座以下客车 + // 26- 8座以下客车(间隔放行) + // 27- 9座以上客车 + // 28- 半挂货车 + // 29- 车辆(不含10座以下客车) + // 30- 车辆(不含8座以下客车) + // 31- 车辆(不含小轿车) + // 32- 不可解体物品超限运输车 + // 33- 不可解体物品运输车 + // 34- 超长超宽超高车辆 + // 35- 车辆运输车 + // 36- 超限运输车 + // 37- 大型货车(不含危险品运输车) + // 38- 大型货车 + // 39- 大型客车 + // 40- 大中型货车 + // 41- 已安装ETC的客车 + // 42- 已安装ETC的小型客车 + // 43- 罐车 + // 44- 货车 + // 45- 黄牌货车 + // 46- 黄牌货车(不含危险品运输车) + // 47- 黄牌货车(运送民生物资车辆除外) + // 48- 核载总质量4.5吨以上货车(运送民生物资车辆除外) + // 49- 客车(包括小轿车) + // 50- 客运车辆 + // 51- 蓝牌货车 + // 52- 旅游包车 + // 53- 面包车 + // 54- 皮卡 + // 55- 全部车型 + // 56- (未安装ETC)车辆 + // 57- 外埠号牌车辆 + // 58- 危化品运输车 + // 59- 危险物品运输车 + // 60- 武装押运车辆 + // 61- 小轿车 + // 62- 厢式货车 + // 63- 小型车辆 + // 64- (已安装ETC)车辆 + // 65- 已安装ETC的货车 + // 66- 押款车辆 + // 67- 疫情防控物资运输车辆 + // 68- 运输剧毒、放射性物品车辆 + // 69- 运输枪支弹药、爆炸、剧毒、放射性物品车辆 + // 70- 营运客车 + // 71- 重型货车 + // 72- 核载总质量1.8吨以上货车 + // 73- 中型货车 + // 74- 小型车辆限速80公里/小时、大型车辆限速70 + ], + }, + visible: (data) => { + if (data?.dcEventTrafficControl.controlType == "2") { + return true; + } + return false; + }, + }, + { + label: "桩号:", + key: "stakeMark", + required: true, + type: "MultipleLabelItem", + options: { + options: [ + { + prefix: { + text: "K", + style: { + color: "#3DE8FF", }, - ], - }, - ons: { - input(value, ...args) { - const { data, formList } = args.slice(-1)[0]; - if (data.dcEventTrafficCongestion) { - data.dcEventTrafficCongestion.facilityId = null; - } - if ( - data.dcEventTrafficCongestion.congestionCause == 1 && - value == 2 - ) { - console.log("value2", value); - //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 - request({ - url: `/business/facility/query?facilityType=1`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let sfz = []; - result.data.forEach((it) => - sfz.push({ key: it.id, label: it.facilityName }) - ); - formList.forEach((it) => { - if (it.key == "dcEventTrafficCongestion.facilityId") { - it.options.options = sfz; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败1", err); - }); - } }, + key: "stakeMark[0]", }, - visible: (data) => { - if ( - data?.eventSubclass == "4-1" && - (data?.dcEventTrafficCongestion?.congestionCause == 1 || - data?.dcEventTrafficCongestion?.congestionCause == 6) - ) { - return true; - } - return false; - }, - }, - { ...PresetFormItems.isInTunnel, isAlone: true }, - { - label: "高速公路:", - required: true, - key: "roadId", - type: "select", - options: { - options: [], - }, - visible: (data) => { - if (data?.eventSubclass == "4-1" || data?.eventSubclass == "4-3") { - return true; - } - return false; - }, - }, - { - label: "方向:", - key: "direction", - required: true, - type: "select", - options: { - options: [], - }, - visible: (data) => { - if (data?.eventSubclass == "4-1" || data?.eventSubclass == "4-3") { - return true; - } - return false; - }, - }, - { - label: "拥堵收费站:", - key: "dcEventTrafficCongestion.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ - { - value: "选项1", - label: "黄金糕", - }, - ], - }, - visible: (data) => { - if ( - data?.eventSubclass == "4-3" || - (data?.eventSubclass == "4-1" && - data?.dcEventTrafficCongestion.congestionCause == "1" && - data.detailedReasons == "2") - ) { - return true; - } - return false; - }, - }, - { - label: "地点:", - key: "dcEventTrafficCongestion.location", - type: "select", - isAlone: false, - required: true, - options: { - placeholder: "收费站地点", - options: locationSelect, - }, - visible: (data) => { - if (data?.eventSubclass == "4-3") { - return true; - } - return false; - }, - }, - { - label: "拥堵服务区:", - key: "dcEventTrafficCongestion.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ - { - value: "选项1", - label: "黄金糕", + { + prefix: { + text: "+", + style: { + color: "#3DE8FF", }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "4-4") { - return true; - } - return false; + }, + key: "stakeMark[1]", }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "3-1") { + return true; + } + return false; + }, + }, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.remark, + PresetFormItems.source, + ], + 交通拥堵: [ + { + label: "拥堵类型:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "4-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "4-1", + label: "道路拥堵", + }, + { + key: "4-2", + label: "立交拥堵", + }, + { + key: "4-3", + label: "收费站拥堵", + }, + { + key: "4-4", + label: "服务区拥堵", + }, + ], + }, + ons: { + input(value, ...args) { + const { data, formList } = args.slice(-1)[0]; + if (data.dcEventTrafficCongestion) { + data.dcEventTrafficCongestion.facilityId = null; + } + let facilityType = 1; + if (value == "4-2") facilityType = 3; + if (value == "4-3") facilityType = 1; + if (value == "4-4") facilityType = 6; + //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 + request({ + url: `/business/facility/query?facilityType=${facilityType}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let lwss = []; + result.data.forEach((it) => + lwss.push({ key: it.id, label: it.facilityName }) + ); + formList.forEach((it) => { + if (it.key == "dcEventTrafficCongestion.facilityId") { + it.options.options = lwss; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败1", err); + }); }, - { - label: "地点:", - key: "dcEventTrafficCongestion.location", - isAlone: false, - required: true, - options: { - placeholder: "地点描述", - }, - visible: (data) => { - if (data?.eventSubclass == "4-4") { - return true; - } - return false; - }, + }, + }, + { + ...PresetFormItems.congestionCause, + key: "dcEventTrafficCongestion.congestionCause", + }, + { + label: "详细原因:", + key: "detailedReasons", + type: "RadioGroup", + isAlone: true, + required: true, + // default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "收费站广场拥堵导致出口压车", + }, + { + key: "2", + label: "收费站设备故障", + }, + { + key: "3", + label: "地方道路原因", + }, + { + key: "4", + label: "省内非集团所辖高速原因", + }, + { + key: "5", + label: "集团所辖道路拥堵", + }, + { + key: "6", + label: "集团所辖枢纽立交异常导致主线压车", + }, + { + key: "7", + label: "路侧起火", + }, + { + key: "8", + label: "备注项添加", + }, + ], + }, + ons: { + input(value, ...args) { + const { data, formList } = args.slice(-1)[0]; + if (data.dcEventTrafficCongestion) { + data.dcEventTrafficCongestion.facilityId = null; + } + if ( + data.dcEventTrafficCongestion.congestionCause == 1 && + value == 2 + ) { + console.log("value2", value); + //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 + request({ + url: `/business/facility/query?facilityType=1`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let sfz = []; + result.data.forEach((it) => + sfz.push({ key: it.id, label: it.facilityName }) + ); + formList.forEach((it) => { + if (it.key == "dcEventTrafficCongestion.facilityId") { + it.options.options = sfz; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败1", err); + }); + } }, - { - label: "地点类型:", - key: "locationType", - type: "RadioGroup", - isAlone: true, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "单点", - }, - { - key: "2", - label: "多点", + }, + visible: (data) => { + if ( + data?.eventSubclass == "4-1" && + (data?.dcEventTrafficCongestion?.congestionCause == 1 || + data?.dcEventTrafficCongestion?.congestionCause == 6) + ) { + return true; + } + return false; + }, + }, + { ...inTunnel, isAlone: true }, + { + label: "高速公路:", + required: true, + key: "roadId", + type: "select", + options: { + options: [], + }, + visible: (data) => { + if (data?.eventSubclass == "4-1" || data?.eventSubclass == "4-3") { + return true; + } + return false; + }, + }, + { + label: "方向:", + key: "direction", + required: true, + type: "select", + options: { + options: [], + }, + visible: (data) => { + if (data?.eventSubclass == "4-1" || data?.eventSubclass == "4-3") { + return true; + } + return false; + }, + }, + { + label: "拥堵收费站:", + key: "dcEventTrafficCongestion.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if ( + data?.eventSubclass == "4-3" || + (data?.eventSubclass == "4-1" && + data?.dcEventTrafficCongestion.congestionCause == "1" && + data.detailedReasons == "2") + ) { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventTrafficCongestion.location", + type: "select", + isAlone: false, + required: true, + options: { + placeholder: "收费站地点", + options: locationSelect, + }, + visible: (data) => { + if (data?.eventSubclass == "4-3") { + return true; + } + return false; + }, + }, + { + label: "拥堵服务区:", + key: "dcEventTrafficCongestion.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "4-4") { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventTrafficCongestion.location", + isAlone: false, + required: true, + options: { + placeholder: "地点描述", + }, + visible: (data) => { + if (data?.eventSubclass == "4-4") { + return true; + } + return false; + }, + }, + { + label: "地点类型:", + key: "locationType", + type: "RadioGroup", + isAlone: true, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "单点", + }, + { + key: "2", + label: "多点", + }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "4-1") { + return true; + } + return false; + }, + }, + { + label: "桩号:", + key: "stakeMark", + required: true, + type: "MultipleLabelItem", + options: { + options: [ + { + prefix: { + text: "K", + style: { + color: "#3DE8FF", }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "4-1") { - return true; - } - return false; + }, + key: "stakeMark[0]", }, - }, - { - label: "桩号:", - key: "stakeMark", - required: true, - type: "MultipleLabelItem", - options: { - options: [ - { - prefix: { - text: "K", - style: { - color: "#3DE8FF", - }, - }, - key: "stakeMark[0]", + { + prefix: { + text: "+", + style: { + color: "#3DE8FF", }, - { - prefix: { - text: "+", - style: { - color: "#3DE8FF", - }, - }, - key: "stakeMark[1]", - }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "4-1" && data?.locationType == 1) { - return true; - } - return false; + }, + key: "stakeMark[1]", }, - }, - { - label: "起止桩号:", - key: "stakeMark", - required: true, - isAlone: true, - type: "MultipleLabelItem", - options: { - options: [ - { - prefix: { - text: "K", - style: { - color: "#3DE8FF", - }, - }, - key: "stakeMark[0]", - }, - { - prefix: { - text: "+", - style: { - color: "#3DE8FF", - }, - }, - key: "stakeMark[1]", - }, - { - prefix: { - text: "至K", - style: { - color: "#3DE8FF", - }, - }, - key: "endStakeMark[0]", - }, - { - prefix: { - text: "+", - style: { - color: "#3DE8FF", - }, - }, - key: "endStakeMark[1]", + ], + }, + visible: (data) => { + if (data?.eventSubclass == "4-1" && data?.locationType == 1) { + return true; + } + return false; + }, + }, + { + label: "起止桩号:", + key: "stakeMark", + required: true, + isAlone: true, + type: "MultipleLabelItem", + options: { + options: [ + { + prefix: { + text: "K", + style: { + color: "#3DE8FF", }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "4-1" && data?.locationType == 2) { - return true; - } - return false; + }, + key: "stakeMark[0]", }, - }, - { - label: "立交桥:", - key: "dcEventTrafficCongestion.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ - { - value: "选项1", - label: "黄金糕", + { + prefix: { + text: "+", + style: { + color: "#3DE8FF", }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "4-2") { - return true; - } - return false; - }, - ons: { - change(value, ...args) { - const { formList } = args.slice(-1)[0]; - - //匝道 - request({ - url: `/system/ramp/listAll?facilityId=${value}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let zd = []; - result.rows.forEach((it) => - zd.push({ key: it.id, label: it.rampName }) - ); - console.log("zd", zd); - formList.forEach((it) => { - if (it.key == "dcEventTrafficCongestion.rampId") { - console.log("it", it); - it.options.options = zd; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败3", err); - }); }, + key: "stakeMark[1]", }, - }, - { - label: "匝道:", - key: "dcEventTrafficCongestion.rampId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data?.eventSubclass == "4-2") { - return true; - } - return false; - }, - }, - - { - label: "拥堵里程:", - key: "dcEventTrafficCongestion.congestionMileage", - required: true, - type: "MultipleLabelItem", - options: { - options: [ - { - suffix: { - text: "千米", - }, - type: "InputNumber", - key: "dcEventTrafficCongestion.congestionMileage", + { + prefix: { + text: "至K", + style: { + color: "#3DE8FF", }, - ], + }, + key: "endStakeMark[0]", }, - }, - { - label: "最大拥堵里程:", - key: "dcEventTrafficCongestion.maxCongestionMileage", - required: true, - type: "MultipleLabelItem", - options: { - options: [ - { - suffix: { - text: "千米", - }, - type: "InputNumber", - key: "dcEventTrafficCongestion.maxCongestionMileage", + { + prefix: { + text: "+", + style: { + color: "#3DE8FF", }, - ], + }, + key: "endStakeMark[1]", }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "4-1" && data?.locationType == 2) { + return true; + } + return false; + }, + }, + { + label: "立交桥:", + key: "dcEventTrafficCongestion.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "4-2") { + return true; + } + return false; + }, + ons: { + change(value, ...args) { + const { formList } = args.slice(-1)[0]; + + //匝道 + request({ + url: `/system/ramp/listAll?facilityId=${value}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let zd = []; + result.rows.forEach((it) => + zd.push({ key: it.id, label: it.rampName }) + ); + console.log("zd", zd); + formList.forEach((it) => { + if (it.key == "dcEventTrafficCongestion.rampId") { + console.log("it", it); + it.options.options = zd; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败3", err); + }); }, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.remark, - PresetFormItems.source, - ], + }, }, - }, - { - key: "IllegalOnRoad", - label: "非法上路", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - PresetFormItems.illegalTriggeringType, - PresetFormItems.additionalNotes, - PresetFormItems.freeway, - PresetFormItems.direction, - PresetFormItems.station, - PresetFormItems.isInTunnel, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.problemDescription, - PresetFormItems.source, - ], + { + label: "匝道:", + key: "dcEventTrafficCongestion.rampId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data?.eventSubclass == "4-2") { + return true; + } + return false; + }, }, - }, - { - key: "BarricadesCleared", - label: "路障清除", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "障碍物类型:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "6-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "6-1", - label: "烟雾", - }, - { - key: "6-2", - label: "倒伏树木", - }, - { - key: "6-3", - label: "撒落物", - }, - { - key: "6-4", - label: "动物", - }, - { - key: "6-5", - label: "其他", - }, - ], + + { + label: "拥堵里程:", + key: "dcEventTrafficCongestion.congestionMileage", + required: true, + type: "MultipleLabelItem", + options: { + options: [ + { + suffix: { + text: "千米", + }, + type: "InputNumber", + key: "dcEventTrafficCongestion.congestionMileage", }, - }, - PresetFormItems.additionalNotes, - PresetFormItems.freeway, - PresetFormItems.direction, - PresetFormItems.station, - PresetFormItems.isInTunnel, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.problemDescription, - PresetFormItems.source, - ], + ], + }, }, - }, - { - key: "Construction", - label: "施工建设", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "施工类型:", - key: "key0123", - type: "RadioGroup", - isAlone: true, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "养护施工类施工", - }, - { - key: "2", - label: "工程建设类施工", - }, - ], - }, - ons: { - input(value, ...args) { - const { formList } = args.slice(-1)[0]; - const config = formList.find((it) => it.key == "eventSubclass"); - const ad = { - 1: [ - { - key: "7-1", - label: "道路养护施工", - }, - { - key: "7-2", - label: "收费站养护施工", - }, - { - key: "7-3", - label: "服务区养护施工", - }, - { - key: "7-4", - label: "枢纽立交匝道养护施工", - }, - { - key: "7-5", - label: "地方道路养护施工", - }, - ], - 2: [ - { - key: "7-6", - label: "道路建设施工", - }, - { - key: "7-7", - label: "收费站建设施工", - }, - { - key: "7-8", - label: "服务区建设施工", - }, - { - key: "7-9", - label: "枢纽立交匝道建设施工", - }, - { - key: "7-10", - label: "地方道路建设施工", - }, - ], - }; - config.options.options = ad[value] || []; + { + label: "最大拥堵里程:", + key: "dcEventTrafficCongestion.maxCongestionMileage", + required: true, + type: "MultipleLabelItem", + options: { + options: [ + { + suffix: { + text: "千米", }, + type: "InputNumber", + key: "dcEventTrafficCongestion.maxCongestionMileage", }, - }, - { - label: "施工分类:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "7-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ + ], + }, + }, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.remark, + PresetFormItems.source, + ], + 非法上路:[ + PresetFormItems.illegalTriggeringType, + PresetFormItems.additionalNotes, + freeway, + directionName, + PresetFormItems.station, + inTunnel, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.problemDescription, + PresetFormItems.source, + ], + 路障清除: [ + { + label: "障碍物类型:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "6-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "6-1", + label: "烟雾", + }, + { + key: "6-2", + label: "倒伏树木", + }, + { + key: "6-3", + label: "撒落物", + }, + { + key: "6-4", + label: "动物", + }, + { + key: "6-5", + label: "其他", + }, + ], + }, + }, + PresetFormItems.additionalNotes, + freeway, + directionName, + PresetFormItems.station, + inTunnel, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.problemDescription, + PresetFormItems.source, + ], + 施工建设: [ + { + label: "施工类型:", + key: "key0123", + type: "RadioGroup", + isAlone: true, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "养护施工类施工", + }, + { + key: "2", + label: "工程建设类施工", + }, + ], + }, + ons: { + input(value, ...args) { + const { formList } = args.slice(-1)[0]; + const config = formList.find((it) => it.key == "eventSubclass"); + const ad = { + 1: [ { key: "7-1", label: "道路养护施工", @@ -1776,763 +1763,783 @@ export const tabConfigList = [ label: "地方道路养护施工", }, ], - }, - ons: { - input(value, ...args) { - const { data, formList } = args.slice(-1)[0]; - if (data.dcEventConstruction) { - data.dcEventConstruction.facilityId = null; - } - let facilityType = 1; - if (value == "7-2" || value == "7-7") { - facilityType = 1; - } else if (value == "7-3" || value == "7-8") { - facilityType = 6; - } else if (value == "7-4" || value == "7-9") { - facilityType = 3; - } - if (value && (value != "7-1" && value != "7-6")) { - //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 - request({ - url: `/business/facility/query?facilityType=${facilityType}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let lwss = []; - result.data.forEach((it) => - lwss.push({ key: it.id, label: it.facilityName }) - ); - - formList.forEach((it) => { - if (it.key == "dcEventConstruction.facilityId") { - it.options.options = lwss; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败1", err); - }); - } - }, - }, - }, - { - label: "管制方式:", - key: "dcEventConstruction.controlMode", - type: "RadioGroup", - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "封闭", - }, - { - key: "2", - label: "不封闭", - }, - ], - }, - }, - PresetFormItems.isInTunnel, - { - //地点类型 - ...PresetFormItems.locationType, - key: "dcEventConstruction.locationType", - visible: (data) => { - if (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") { - return true; - } - return false; - }, - }, - { - label: "施工方式:", - key: "dcEventConstruction.constructionMethod", - type: "RadioGroup", - isAlone: false, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ + 2: [ { - key: "1", - label: "车道", + key: "7-6", + label: "道路建设施工", }, { - key: "2", - label: "其他", + key: "7-7", + label: "收费站建设施工", }, - ], - }, - visible: (data) => { - if (data.eventSubclass == "7-2" || data.eventSubclass == "7-7") { - return true; - } - return false; - }, - }, - { - label: "通行情况:", - key: "dcEventConstruction.trafficCondition", - type: "RadioGroup", - isAlone: true, - required: true, - default: "1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ { - key: "1", - label: "通行受限", + key: "7-8", + label: "服务区建设施工", }, { - key: "2", - label: "车辆谨慎慢行", + key: "7-9", + label: "枢纽立交匝道建设施工", }, { - key: "3", - label: "车辆正常通行", + key: "7-10", + label: "地方道路建设施工", }, ], - }, - visible: (data) => { - if ( - data.eventSubclass == "7-2" || - data.eventSubclass == "7-7" || - data.eventSubclass == "7-4" || - data.eventSubclass == "7-9" - ) { - return true; - } - return false; - }, - }, - PresetFormItems.freeway, - PresetFormItems.direction, - { - ...PresetFormItems.station, - visible: (data) => { - if ( - (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") && - data?.dcEventConstruction.locationType == "1" - ) { - return true; - } - return false; - }, + }; + config.options.options = ad[value] || []; }, - { - ...PresetFormItems.startEndStation, - visible: (data) => { - if ( - (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") && - data?.dcEventConstruction.locationType == "2" - ) { - return true; - } - return false; - }, - }, - // PresetFormItems.emptyLine, - { - ...PresetFormItems.laneOccupancy, - required: true, - visible: (data) => { - if (data?.dcEventConstruction.controlMode == "2") { - return true; - } - return false; - }, - }, - { - label: "收费站:", - key: "dcEventConstruction.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data.eventSubclass == "7-2" || data.eventSubclass == "7-7") { - return true; - } - return false; - }, - }, - { - label: "出入口:", - key: "dcEventConstruction.exitsInlets", - type: "RadioGroup", - isAlone: false, - required: true, - default: "2", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "出口", - }, - { - key: "2", - label: "入口", - }, - ], - }, - visible: (data) => { - if (data.eventSubclass == "7-2" || data.eventSubclass == "7-7") { - return true; - } - return false; - }, - }, - { - label: "服务区:", - key: "dcEventConstruction.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data.eventSubclass == "7-3" || data.eventSubclass == "7-8") { - return true; - } - return false; - }, - }, - { - label: "地点:", - key: "dcEventConstruction.location", - isAlone: false, - required: true, - options: { - placeholder: "服务区地点", - }, - visible: (data) => { - if (data.eventSubclass == "7-3" || data.eventSubclass == "7-8") { - return true; - } - return false; - }, - }, - { - label: "立交桥:", - key: "dcEventConstruction.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data.eventSubclass == "7-4" || data.eventSubclass == "7-9") { - return true; - } - return false; - }, - ons: { - change(value, ...args) { - const { formList } = args.slice(-1)[0]; + }, + }, + { + label: "施工分类:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "7-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "7-1", + label: "道路养护施工", + }, + { + key: "7-2", + label: "收费站养护施工", + }, + { + key: "7-3", + label: "服务区养护施工", + }, + { + key: "7-4", + label: "枢纽立交匝道养护施工", + }, + { + key: "7-5", + label: "地方道路养护施工", + }, + ], + }, + ons: { + input(value, ...args) { + const { data, formList } = args.slice(-1)[0]; + if (data.dcEventConstruction) { + data.dcEventConstruction.facilityId = null; + } + let facilityType = 1; + if (value == "7-2" || value == "7-7") { + facilityType = 1; + } else if (value == "7-3" || value == "7-8") { + facilityType = 6; + } else if (value == "7-4" || value == "7-9") { + facilityType = 3; + } + if (value && (value != "7-1" && value != "7-6")) { + //路网设施 1 收费站 2 桥梁 3 互通立交 4 枢纽立交 5 隧道 6 服务区 + request({ + url: `/business/facility/query?facilityType=${facilityType}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let lwss = []; + result.data.forEach((it) => + lwss.push({ key: it.id, label: it.facilityName }) + ); - //匝道 - request({ - url: `/system/ramp/listAll?facilityId=${value}`, - method: "get", - }) - .then((result) => { - if (result.code != 200) return Message.error(result?.msg); - let zd = []; - result.rows.forEach((it) => - zd.push({ key: it.id, label: it.rampName }) - ); - // console.log("zd", zd); - formList.forEach((it) => { - if (it.key == "dcEventConstruction.rampId") { - // console.log("it", it); - it.options.options = zd; - } - }); - }) - .catch((err) => { - console.log("err", err); - Message.error("查询失败3", err); + formList.forEach((it) => { + if (it.key == "dcEventConstruction.facilityId") { + it.options.options = lwss; + } }); - }, - }, - }, - { - label: "匝道:", - key: "dcEventConstruction.rampId", - type: "select", - isAlone: false, - required: true, - options: { - options: [], - }, - visible: (data) => { - if (data.eventSubclass == "7-4" || data.eventSubclass == "7-9") { - return true; - } - return false; - }, - }, - { - label: "地方道路名称:", - key: "dcEventConstruction.localRoadName", - isAlone: true, - required: true, - options: {}, - visible: (data) => { - if (data.eventSubclass == "7-5" || data.eventSubclass == "7-10") { - return true; - } - return false; - }, - }, - { - label: "特殊地点描述:", - key: "dcEventConstruction.specialPlaceDescription", - isAlone: true, - options: { - type: "textarea", - autosize: true, - maxlength: 50, - autosize: { minRows: 6, maxRows: 6 }, - showWordLimit: true, - }, - }, - { - ...PresetFormItems.specialConstruction, - key: "dcEventConstruction.specialConstruction", - }, - { - label: "专项施工名称:", - key: "dcEventConstruction.otherConstructionName", - isAlone: true, - options: {}, - visible: (data) => { - if (data?.dcEventConstruction.specialConstruction == "4") { - return true; - } - return false; - }, - }, - { - ...PresetFormItems.constructionMeasurement, - key: "dcEventConstruction.constructionMeasurement", - visible: (data) => { - if (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") { - return true; - } - return false; - }, + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败1", err); + }); + } }, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.remark, - PresetFormItems.source, - ], + }, }, - }, - { - key: "ServiceAreaAbnormal", - label: "服务区异常", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "异常分类:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "8-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "8-1", - label: "封闭、暂停营业", - }, - { - key: "8-2", - label: "重要设施停用", - }, - { - key: "8-3", - label: "其他异常", - }, - ], - }, - }, - PresetFormItems.freeway, - PresetFormItems.direction, - { - label: "服务区:", - key: "dcEventServiceArea.facilityId", - type: "select", - isAlone: false, - required: true, - options: { - options: [ - { - value: "选项1", - label: "黄金糕", - }, - ], - }, - }, - { - label: "停用设施:", - key: "dcEventServiceArea.disableFacility", - type: "select", - isAlone: false, - required: true, - options: { - options: [ - { - value: "1", - label: "卫生间", - }, - { - value: "2", - label: "餐厅", - }, - { - value: "3", - label: "停车场", - }, - { - value: "4", - label: "加油站", - }, - { - value: "5", - label: "充电桩", - }, - ], - }, - visible: (data) => { - if (data?.eventSubclass == "8-2") { - return true; - } - return false; - }, - }, - { - label: "出入口:", - key: "dcEventServiceArea.exitsInlets", - type: "RadioGroup", - isAlone: true, - required: true, - default: "2", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ - { - key: "1", - label: "出口", - }, - { - key: "2", - label: "入口", - }, - ], - }, + { + label: "管制方式:", + key: "dcEventConstruction.controlMode", + type: "RadioGroup", + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "封闭", + }, + { + key: "2", + label: "不封闭", + }, + ], + }, + }, + inTunnel, + { + //地点类型 + ...PresetFormItems.locationType, + key: "dcEventConstruction.locationType", + visible: (data) => { + if (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") { + return true; + } + return false; + }, + }, + { + label: "施工方式:", + key: "dcEventConstruction.constructionMethod", + type: "RadioGroup", + isAlone: false, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "车道", + }, + { + key: "2", + label: "其他", + }, + ], + }, + visible: (data) => { + if (data.eventSubclass == "7-2" || data.eventSubclass == "7-7") { + return true; + } + return false; + }, + }, + { + label: "通行情况:", + key: "dcEventConstruction.trafficCondition", + type: "RadioGroup", + isAlone: true, + required: true, + default: "1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "通行受限", + }, + { + key: "2", + label: "车辆谨慎慢行", + }, + { + key: "3", + label: "车辆正常通行", + }, + ], + }, + visible: (data) => { + if ( + data.eventSubclass == "7-2" || + data.eventSubclass == "7-7" || + data.eventSubclass == "7-4" || + data.eventSubclass == "7-9" + ) { + return true; + } + return false; + }, + }, + freeway, + directionName, + { + ...PresetFormItems.station, + visible: (data) => { + if ( + (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") && + data?.dcEventConstruction.locationType == "1" + ) { + return true; + } + return false; + }, + }, + { + ...PresetFormItems.startEndStation, + visible: (data) => { + if ( + (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") && + data?.dcEventConstruction.locationType == "2" + ) { + return true; + } + return false; + }, + }, + // PresetFormItems.emptyLine, + { + ...PresetFormItems.laneOccupancy, + required: true, + visible: (data) => { + if (data?.dcEventConstruction.controlMode == "2") { + return true; + } + return false; + }, + }, + { + label: "收费站:", + key: "dcEventConstruction.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data.eventSubclass == "7-2" || data.eventSubclass == "7-7") { + return true; + } + return false; + }, + }, + { + label: "出入口:", + key: "dcEventConstruction.exitsInlets", + type: "RadioGroup", + isAlone: false, + required: true, + default: "2", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "出口", + }, + { + key: "2", + label: "入口", + }, + ], + }, + visible: (data) => { + if (data.eventSubclass == "7-2" || data.eventSubclass == "7-7") { + return true; + } + return false; + }, + }, + { + label: "服务区:", + key: "dcEventConstruction.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data.eventSubclass == "7-3" || data.eventSubclass == "7-8") { + return true; + } + return false; + }, + }, + { + label: "地点:", + key: "dcEventConstruction.location", + isAlone: false, + required: true, + options: { + placeholder: "服务区地点", + }, + visible: (data) => { + if (data.eventSubclass == "7-3" || data.eventSubclass == "7-8") { + return true; + } + return false; + }, + }, + { + label: "立交桥:", + key: "dcEventConstruction.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data.eventSubclass == "7-4" || data.eventSubclass == "7-9") { + return true; + } + return false; + }, + ons: { + change(value, ...args) { + const { formList } = args.slice(-1)[0]; + + //匝道 + request({ + url: `/system/ramp/listAll?facilityId=${value}`, + method: "get", + }) + .then((result) => { + if (result.code != 200) return Message.error(result?.msg); + let zd = []; + result.rows.forEach((it) => + zd.push({ key: it.id, label: it.rampName }) + ); + // console.log("zd", zd); + formList.forEach((it) => { + if (it.key == "dcEventConstruction.rampId") { + // console.log("it", it); + it.options.options = zd; + } + }); + }) + .catch((err) => { + console.log("err", err); + Message.error("查询失败3", err); + }); }, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.remark, - PresetFormItems.source, - ], + }, }, - }, - { - key: "HiddenDangersEquipment", - label: "设施设备隐患", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "类型:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "9-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ + { + label: "匝道:", + key: "dcEventConstruction.rampId", + type: "select", + isAlone: false, + required: true, + options: { + options: [], + }, + visible: (data) => { + if (data.eventSubclass == "7-4" || data.eventSubclass == "7-9") { + return true; + } + return false; + }, + }, + { + label: "地方道路名称:", + key: "dcEventConstruction.localRoadName", + isAlone: true, + required: true, + options: {}, + visible: (data) => { + if (data.eventSubclass == "7-5" || data.eventSubclass == "7-10") { + return true; + } + return false; + }, + }, + { + label: "特殊地点描述:", + key: "dcEventConstruction.specialPlaceDescription", + isAlone: true, + options: { + type: "textarea", + autosize: true, + maxlength: 50, + autosize: { minRows: 6, maxRows: 6 }, + showWordLimit: true, + }, + }, + { + ...PresetFormItems.specialConstruction, + key: "dcEventConstruction.specialConstruction", + }, + { + label: "专项施工名称:", + key: "dcEventConstruction.otherConstructionName", + isAlone: true, + options: {}, + visible: (data) => { + if (data?.dcEventConstruction.specialConstruction == "4") { + return true; + } + return false; + }, + }, + { + ...PresetFormItems.constructionMeasurement, + key: "dcEventConstruction.constructionMeasurement", + visible: (data) => { + if (data.eventSubclass == "7-1" || data.eventSubclass == "7-6") { + return true; + } + return false; + }, + }, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.remark, + PresetFormItems.source, + ], + 服务区异常: [ + { + label: "异常分类:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "8-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "8-1", + label: "封闭、暂停营业", + }, + { + key: "8-2", + label: "重要设施停用", + }, + { + key: "8-3", + label: "其他异常", + }, + ], + }, + }, + freeway, + directionName, + { + label: "服务区:", + key: "dcEventServiceArea.facilityId", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "选项1", + label: "黄金糕", + }, + ], + }, + }, + { + label: "停用设施:", + key: "dcEventServiceArea.disableFacility", + type: "select", + isAlone: false, + required: true, + options: { + options: [ + { + value: "1", + label: "卫生间", + }, + { + value: "2", + label: "餐厅", + }, + { + value: "3", + label: "停车场", + }, + { + value: "4", + label: "加油站", + }, + { + value: "5", + label: "充电桩", + }, + ], + }, + visible: (data) => { + if (data?.eventSubclass == "8-2") { + return true; + } + return false; + }, + }, + { + label: "出入口:", + key: "dcEventServiceArea.exitsInlets", + type: "RadioGroup", + isAlone: true, + required: true, + default: "2", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "1", + label: "出口", + }, + { + key: "2", + label: "入口", + }, + ], + }, + }, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.remark, + PresetFormItems.source, + ], + 设施设备隐患: [ + { + label: "类型:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "9-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "9-1", + label: "摄像机", + }, + { + key: "9-2", + label: "护栏", + }, + { + key: "9-3", + label: "隔离栅", + }, + { + key: "9-4", + label: "情报板", + }, + { + key: "9-5", + label: "防眩板", + }, + { + key: "9-6", + label: "其他", + }, + ], + }, + }, + { + label: "设备补充说明:", + key: "eventSourceTips", + isAlone: true, + options: { + type: "textarea", + autosize: true, + maxlength: 150, + autosize: { minRows: 6, maxRows: 6 }, + showWordLimit: true, + }, + required: true, + }, + freeway, + directionName, + PresetFormItems.station, + inTunnel, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.problemDescription, + PresetFormItems.source, + ], + 异常天气: [ + { + label: "异常天气:", + key: "eventSubclass", + type: "RadioGroup", + isAlone: true, + required: true, + default: "10-1", + options: { + activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", + options: [ + { + key: "10-1", + label: "雨", + }, + { + key: "10-2", + label: "雪", + }, + { + key: "10-3", + label: "雾", + }, + { + key: "10-4", + label: "大风", + }, + { + key: "10-5", + label: "低温寒潮", + }, + { + key: "10-6", + label: "路面积雪", + }, + { + key: "10-7", + label: "路面结冰", + }, + { + key: "10-8", + label: "路面积水", + }, + { + key: "10-9", + label: "其他", + }, + ], + }, + ons: { + input(value, ...args) { + const { formList } = args.slice(-1)[0]; + const config = formList.find( + (it) => it.key == "dcEventAbnormalWeather.weatherSituation" + ); + let ad = { + "10-1": [ { - key: "9-1", - label: "摄像机", + key: "1-1", + label: "雨雾", }, { - key: "9-2", - label: "护栏", + key: "1-2", + label: "雨雪", }, { - key: "9-3", - label: "隔离栅", + key: "1-3", + label: "中雨", }, { - key: "9-4", - label: "情报板", + key: "1-4", + label: "小雨", }, { - key: "9-5", - label: "防眩板", + key: "1-5", + label: "大雨", }, { - key: "9-6", - label: "其他", + key: "1-6", + label: "暴雨", }, ], - }, - }, - { - label: "设备补充说明:", - key: "eventSourceTips", - isAlone: true, - options: { - type: "textarea", - autosize: true, - maxlength: 150, - autosize: { minRows: 6, maxRows: 6 }, - showWordLimit: true, - }, - required: true, - }, - PresetFormItems.freeway, - PresetFormItems.direction, - PresetFormItems.station, - PresetFormItems.isInTunnel, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.problemDescription, - PresetFormItems.source, - ], - }, - }, - { - key: "AbnormalWeather", - label: "异常天气", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "异常天气:", - key: "eventSubclass", - type: "RadioGroup", - isAlone: true, - required: true, - default: "10-1", - options: { - activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)", - options: [ + "10-2": [ { - key: "10-1", - label: "雨", + key: "2-1", + label: "小雪", }, { - key: "10-2", - label: "雪", + key: "2-2", + label: "中雪", }, { - key: "10-3", - label: "雾", + key: "2-3", + label: "大雪", }, { - key: "10-4", - label: "大风", + key: "2-4", + label: "暴雪", }, { - key: "10-5", - label: "低温寒潮", + key: "2-5", + label: "大暴雪", }, { - key: "10-6", - label: "路面积雪", + key: "2-6", + label: "特大暴雪", }, + ], + "10-3": [ { - key: "10-7", - label: "路面结冰", + key: "3-1", + label: "轻雾", }, { - key: "10-8", - label: "路面积水", + key: "3-2", + label: "大雾", }, { - key: "10-9", - label: "其他", + key: "3-3", + label: "浓雾", }, - ], - }, - ons: { - input(value, ...args) { - const { formList } = args.slice(-1)[0]; - const config = formList.find( - (it) => it.key == "dcEventAbnormalWeather.weatherSituation" - ); - let ad = { - "10-1": [ - { - key: "1-1", - label: "雨雾", - }, - { - key: "1-2", - label: "雨雪", - }, - { - key: "1-3", - label: "中雨", - }, - { - key: "1-4", - label: "小雨", - }, - { - key: "1-5", - label: "大雨", - }, - { - key: "1-6", - label: "暴雨", - }, - ], - "10-2": [ - { - key: "2-1", - label: "小雪", - }, - { - key: "2-2", - label: "中雪", - }, - { - key: "2-3", - label: "大雪", - }, - { - key: "2-4", - label: "暴雪", - }, - { - key: "2-5", - label: "大暴雪", - }, - { - key: "2-6", - label: "特大暴雪", - }, - ], - "10-3": [ - { - key: "3-1", - label: "轻雾", - }, - { - key: "3-2", - label: "大雾", - }, - { - key: "3-3", - label: "浓雾", - }, - { - key: "3-4", - label: "强浓雾", - }, - { - key: "3-5", - label: "团雾", - }, - ], - }; - config.options.options = ad[value]; - }, - }, - }, - { - ...PresetFormItems.weatherSituation, - key: "dcEventAbnormalWeather.weatherSituation", - }, - PresetFormItems.additionalNotes, - PresetFormItems.freeway, - PresetFormItems.direction, - PresetFormItems.startEndStation, - { - label: "紧急级别:", - key: "dcEventAbnormalWeather.emergencyLevel", - required: true, - type: "select", - options: { - options: [ { - value: "1", - label: "一般", + key: "3-4", + label: "强浓雾", }, { - value: "2", - label: "紧急", + key: "3-5", + label: "团雾", }, ], - }, + }; + config.options.options = ad[value]; }, - PresetFormItems.isInTunnel, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.problemDescription, - PresetFormItems.source, - ], + }, }, - }, - { - key: "OtherEvents", - label: "其他事件", - formConfig: { - formOptions: { - column: 2, - }, - list: [ - { - label: "事件说明:", - key: "eventSourceTips", - isAlone: true, - options: { - type: "textarea", - autosize: true, - maxlength: 150, - autosize: { minRows: 6, maxRows: 6 }, - showWordLimit: true, - }, - }, - PresetFormItems.freeway, - PresetFormItems.direction, - PresetFormItems.station, - PresetFormItems.isInTunnel, - PresetFormItems.startTime, - PresetFormItems.expectedEndTime, - PresetFormItems.problemDescription, - PresetFormItems.source, - ], + { + ...PresetFormItems.weatherSituation, + key: "dcEventAbnormalWeather.weatherSituation", }, - }, -]; + PresetFormItems.additionalNotes, + freeway, + directionName, + PresetFormItems.startEndStation, + { + label: "紧急级别:", + key: "dcEventAbnormalWeather.emergencyLevel", + required: true, + type: "select", + options: { + options: [ + { + value: "1", + label: "一般", + }, + { + value: "2", + label: "紧急", + }, + ], + }, + }, + inTunnel, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.problemDescription, + PresetFormItems.source, + ], + 其他事件: [ + { + label: "事件说明:", + key: "eventSourceTips", + isAlone: true, + options: { + type: "textarea", + autosize: true, + maxlength: 150, + autosize: { minRows: 6, maxRows: 6 }, + showWordLimit: true, + }, + }, + freeway, + directionName, + PresetFormItems.station, + inTunnel, + PresetFormItems.startTime, + PresetFormItems.expectedEndTime, + PresetFormItems.problemDescription, + PresetFormItems.source, + ], +} diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/index.vue index 13fd8319..1f95610d 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/index.vue @@ -1,5 +1,5 @@ @@ -72,7 +70,6 @@ export default { data: [], total: 0, searchFormList, - activeName: "-1", eventDetailDialogVisible: false, isShowAddNew: false, searchData: { @@ -92,7 +89,6 @@ export default { cardData: { ...item, state }, lastBtnColor: textColor, lastBtnText: text, - isShowLeft: this.activeName == '-1' }; }, queryData(flag) { @@ -138,12 +134,8 @@ export default { this.getData(); }, onExport() { - let url = ''; - if (this.activeName == '-1') { - url = '/business/warning/export' - } else { - url = '/dc/system/event/export?eventState=' + this.searchData.eventState; - } + let url ='/business/warning/export' + let loadingInstance = Loading.service({ fullscreen: true, background: "#00000052", @@ -177,8 +169,7 @@ export default { }, firstBtnClick(id) {//点击去确认/详情/处置记录等第一个按钮 console.log("id", id); - if (this.activeName == '-1') { - request({ + request({ url: `/perceivedEvents/warning/getWarningById`,//感知事件 method: "post", data: { id } @@ -213,36 +204,11 @@ export default { this.eventDetailDialogVisible = true; }); - } else { - request({ - url: `/dc/system/event/${id}`,//交通事件 - method: "get", - }).then(async (result) => { - if (result.code != 200) return Message.error(result?.msg); - let data = result.data; - data.stringDirection = gzDirectionMapping[data.direction] || data.direction; - data.startTime = data?.occurrenceTime || ''; - - - data.videoList = []; - data.component = "VideoMulti"; - - // const { downCamera, upCamera } = ((await getNearCameraNew(data.stakeMark))?.data || {});//新的上下游摄像头接口 - // data.downCamId = downCamera?.camId; - // data.upCamId = upCamera?.camId; - data.videoType = "flv"; - - this.detailDialogFormData = data; - - this.eventDetailDialogVisible = true; - }); - } - }, onLastBtnClick(id) { this.$router.push(`/control/event/commandDispatch?eventId=${id}`); }, - handleClose() { + handleDialogClose() { this.eventDetailDialogVisible = false; }, handleSearch(data) {