Browse Source

修改部分问题

wangqin
王钦 12 months ago
parent
commit
b7dc324c3b
  1. 2
      ruoyi-ui/src/views/JiHeExpressway/components/Dialog/index.vue
  2. 3
      ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg
  3. 3
      ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processed24.svg
  4. 3
      ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processing21.svg
  5. 3
      ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/toBeConfirmed23.svg
  6. 2
      ruoyi-ui/src/views/JiHeExpressway/components/Video/Video.vue
  7. 3
      ruoyi-ui/src/views/JiHeExpressway/components/Video/index.vue
  8. 6
      ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/MeteorologicalDetection/components/DeviceControlDialog.vue
  9. 58
      ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/RoadNetworkFacilities/data.js
  10. 17
      ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/RoadNetworkFacilities/index.vue
  11. 1
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/CrowdnessIndicatorRankings/index.vue
  12. 4
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DispatchLiaison/index.vue
  13. 43
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/DialogVisible/index.vue
  14. 4
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/index.vue
  15. 465
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/data.js
  16. 71
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/index.vue
  17. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/images/congestion.svg
  18. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/TrafficControl/components/AddControlEventInfoDialog/data.js
  19. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/index.vue
  20. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/control/event/event/FormEvent/data.js
  21. 521
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/eventPlanDialog/index.vue
  22. 336
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/formTable/index.vue
  23. 321
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/index.vue
  24. 381
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/qbbDialog/index.vue
  25. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/FormEvent/data.js
  26. 42
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/index.vue

2
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;
}

3
ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/confirmed22.svg

@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 27.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 70 67" style="enable-background:new 0 0 70 67;" xml:space="preserve">
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="69" height="67" viewBox="0 0 69 67" fill="none" xml:space="preserve">
<style type="text/css">
.st0{fill:url(#Rectangle_3543_00000027573242941979377840000008498132700452433310_);}
.st1{fill:url(#Rectangle_3545_00000108306831714505799710000016481210161124509350_);}

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

3
ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processed24.svg

@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 27.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 69 67" style="enable-background:new 0 0 69 67;" xml:space="preserve">
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="69" height="67" viewBox="0 0 69 67" fill="none" xml:space="preserve">
<style type="text/css">
.st0{fill:url(#Rectangle_3543_00000135670463380124271900000010923522838896704945_);}
.st1{fill:url(#Rectangle_3545_00000149381956171071755920000000984320330230580101_);}

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

3
ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/processing21.svg

@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 27.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 68 67" style="enable-background:new 0 0 68 67;" xml:space="preserve">
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="69" height="67" viewBox="0 0 69 67" fill="none" xml:space="preserve">
<style type="text/css">
.st0{fill:url(#Rectangle_3543_00000053538272738649842960000009181435203724315524_);}
.st1{fill:url(#Rectangle_3545_00000042731925473050420680000005354543093107188619_);}

Before

Width:  |  Height:  |  Size: 2.1 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

3
ruoyi-ui/src/views/JiHeExpressway/components/RoadStateCard/images/toBeConfirmed23.svg

@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 27.0.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 71 67" style="enable-background:new 0 0 71 67;" xml:space="preserve">
<svg version="1.1" id="图层_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="69" height="67" viewBox="0 0 69 67" fill="none" xml:space="preserve">
<style type="text/css">
.st0{fill:url(#Rectangle_3543_00000051376741410994204160000013762924089411596164_);}
.st1{fill:url(#Rectangle_3545_00000044885868572866352330000017989187333113817249_);}

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

2
ruoyi-ui/src/views/JiHeExpressway/components/Video/Video.vue

@ -33,7 +33,7 @@ export default {
default: 'flv'
},
rangeIndex: {
default: 0
type: [String,Number],
}
},
watch: {

3
ruoyi-ui/src/views/JiHeExpressway/components/Video/index.vue

@ -49,8 +49,7 @@ export default {
default: 'flv'
},
rangeIndex: {
type: Number,
default: 0
type: [String,Number]
},
showHeader: {
type: Boolean,

6
ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/MeteorologicalDetection/components/DeviceControlDialog.vue

@ -103,15 +103,15 @@ export default {
qsData.rows.forEach(item => {
if (lastPath == 'deviceHour') {
times.push(item.date);
datas.push(this.btnType == 1 ? item.temperature : item.visibility)
} else if (lastPath == 'deviceDay') {
times.push(new Date(item.date).format('dd'));
datas.push(this.btnType == 1 ? item.avgTemperature : item.avgVisibility)
} else if (lastPath == 'deviceYears') {
times.push(new Date(item.month).format('MM'));
datas.push(this.btnType == 1 ? item.avgTemperature : item.avgVisibility)
}
datas.push(this.btnType == 1 ? item.temperature : item.visibility)
})
// console.log('datas',datas)
if (lastPath == 'deviceHour') {
lineChartOption.xAxis.name = '时'

58
ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/RoadNetworkFacilities/data.js

@ -419,19 +419,9 @@ export const tabList = {
labelWidth: "70px",
list: [
{
label: "道路编码",
key: "roadCode",
gridColumn: "3",
},
{
label: "道路名称",
key: "roadName",
gridColumn: "3",
},
{
label: "变坡点桩号",
key: "stakeMark1",
gridColumn: "3",
label:"名称",
key: "crossingType",
gridColumn: "3"
},
{
label: "方向",
@ -439,13 +429,8 @@ export const tabList = {
gridColumn: "3",
},
{
label: "起点桩号",
key: "startPileNumber",
gridColumn: "3",
},
{
label: "终点桩号",
key: "endPileNumber",
label: "桩号",
key: "end_mark",
gridColumn: "3",
},
{
@ -458,31 +443,40 @@ export const tabList = {
key: "latitude",
gridColumn: "3",
},
],
},
{
label: "直坡段长",
key: "segmentLength",
gridColumn: "3",
name: "边坡测点数据",
key: "second",
labelWidth: "70px",
list: [
{
label:"醒目编号",
key: "pro_code",
gridColumn: "3"
},
{
label: "横坡",
key: "lateralSlope",
label: "标段编号",
key: "con_code",
gridColumn: "3",
},
{
label: "竖曲线半径",
key: "verticalCurveRadius",
label: "项目单位工程编号",
key: "unit_code",
gridColumn: "3",
},
{
label: "纵坡",
key: "longitudinalSlope",
label: "测点编号",
key: "meaPointnum",
gridColumn: "3",
},
{
label: "管养单位",
key: "managementAndMaintenanceUnit",
gridColumn: "6",
label: "测点名称",
key: "meaPointName",
gridColumn: "3",
},
],
},
],

17
ruoyi-ui/src/views/JiHeExpressway/pages/Home/components/Dialogs/RoadNetworkFacilities/index.vue

@ -5,7 +5,6 @@
<Video class="video-stream" :pileNum="dialogData.stakeMark" rangeIndex="upCamera" :showHeader="false" />
<!-- <Video class="video-stream" :pileNum="dialogData.stakeMark" /> -->
</div>
<div class="SolarEnergy">
<ElTabs v-model="activeName" class="tabs">
<ElTabPane v-for="item in formList" :key="item.key" :label="item.name" :name="item.key">
@ -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)

1
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`);

4
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) => {});
},

43
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";
@ -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);
}

4
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/DisposalProcess/index.vue

@ -133,12 +133,12 @@
</div>
</Card>
<DialogVisible
v-if="dialogVisible !== null"
:visible="dialogVisible"
@update:value="handleClose"
@update:type="handleUpdate"
:eventId="eventId"
/>
<!-- :data="dispatchList" -->
</div>
</template>
@ -181,7 +181,7 @@ export default {
return {
provideDetail: {},
dialogType: "",
dialogVisible: false,
dialogVisible: null,
eventId: "",
test: null,
testRadio: "input",

465
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,31 +73,101 @@ 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 = [
const isCongestionAhead = {
label: "前方是否拥堵:",
key: "dcEventAccident.congestionAhead",
type: "RadioGroup",
options: {
activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)",
options: [
{
key: "TrafficAccident",
label: "交通事故",
formConfig: {
list: [
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: "dcEventAccident.reporterName",
key: "dcEventVehicleAccident.reporterName",
},
{
...PresetFormItems.callPolicePersonPhone,
key: "dcEventAccident.reporterPhoneNumber",
key: "dcEventVehicleAccident.reporterPhoneNumber",
},
PresetFormItems.trafficAccidentType,
PresetFormItems.vehicleMalfunctionType,
PresetFormItems.eventLevel,
{
...PresetFormItems.locationMode,
key: "dcEventAccident.locationType",
key: "dcEventVehicleAccident.locationType",
},
PresetFormItems.freeway,
freeway,
{
label: "服务区:",
key: "dcEventAccident.facilityId",
key: "dcEventVehicleAccident.facilityId",
type: "select",
isAlone: false,
required: true,
@ -85,7 +180,7 @@ export const tabConfigList = [
],
},
visible: (data) => {
if (data?.dcEventAccident?.locationType == 2) {
if (data?.dcEventVehicleAccident?.locationType == 2) {
return true;
}
return false;
@ -93,14 +188,14 @@ export const tabConfigList = [
},
{
label: "地点:",
key: "dcEventAccident.location",
key: "dcEventVehicleAccident.location",
isAlone: false,
required: true,
options: {
placeholder: "服务区地点",
},
visible: (data) => {
if (data?.dcEventAccident?.locationType == 2) {
if (data?.dcEventVehicleAccident?.locationType == 2) {
return true;
}
return false;
@ -108,7 +203,7 @@ export const tabConfigList = [
},
{
label: "立交桥:",
key: "dcEventAccident.facilityId",
key: "dcEventVehicleAccident.facilityId",
type: "select",
isAlone: false,
required: true,
@ -121,7 +216,7 @@ export const tabConfigList = [
],
},
visible: (data) => {
if (data?.dcEventAccident?.locationType == 3) {
if (data?.dcEventVehicleAccident?.locationType == 3) {
return true;
}
return false;
@ -143,22 +238,22 @@ export const tabConfigList = [
);
console.log("zd", zd);
formList.forEach((it) => {
if (it.key == "dcEventAccident.rampId") {
console.log("it", it);
if (it.key == "dcEventVehicleAccident.rampId") {
// console.log("it", it);
it.options.options = zd;
}
});
})
.catch((err) => {
console.log("err", err);
Message.error("查询失败3", err);
Message.error("查询失败2", err);
});
},
},
},
{
label: "匝道:",
key: "dcEventAccident.rampId",
key: "dcEventVehicleAccident.rampId",
type: "select",
isAlone: false,
required: true,
@ -166,7 +261,7 @@ export const tabConfigList = [
options: [],
},
visible: (data) => {
if (data?.dcEventAccident?.locationType == 3) {
if (data?.dcEventVehicleAccident?.locationType == 3) {
return true;
}
return false;
@ -174,7 +269,7 @@ export const tabConfigList = [
},
{
label: "收费站:",
key: "dcEventAccident.facilityId",
key: "dcEventVehicleAccident.facilityId",
type: "select",
isAlone: false,
required: true,
@ -187,7 +282,7 @@ export const tabConfigList = [
],
},
visible: (data) => {
if (data?.dcEventAccident?.locationType == 4) {
if (data?.dcEventVehicleAccident?.locationType == 4) {
return true;
}
return false;
@ -195,7 +290,7 @@ export const tabConfigList = [
},
{
label: "地点:",
key: "dcEventAccident.location",
key: "dcEventVehicleAccident.location",
type: "select",
isAlone: false,
required: true,
@ -204,83 +299,73 @@ export const tabConfigList = [
options: locationSelect,
},
visible: (data) => {
if (data?.dcEventAccident?.locationType == 4) {
if (data?.dcEventVehicleAccident?.locationType == 4) {
return true;
}
return false;
},
},
PresetFormItems.direction,
PresetFormItems.station,
directionName,
{ ...PresetFormItems.station,
visible: (data) => {
if (data.dcEventVehicleAccident && data.dcEventVehicleAccident.locationType != 1) {
return false;
}
return true;
},
},
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.pressure,
key: "dcEventVehicleAccident.trafficJam",
},
{
...PresetFormItems.trafficPolicePhone,
key: "dcEventAccident.policeContact",
...PresetFormItems.weatherCondition,
key: "dcEventVehicleAccident.weatherCondition",
},
{
...PresetFormItems.wreckerCalls,
key: "dcEventAccident.towingServiceContact",
...isCongestionAhead,
key: "dcEventVehicleAccident.congestionAhead",
},
{
...PresetFormItems.isCongestionAhead,
key: "dcEventAccident.congestionAhead",
...isForkRoad,
key: "dcEventVehicleAccident.atIntersection",
},
{
...PresetFormItems.isForkRoad,
key: "dcEventAccident.atIntersection",
...isCurveRoad,
key: "dcEventVehicleAccident.onCurve",
},
{ ...PresetFormItems.isCurveRoad, key: "dcEventAccident.onCurve" },
{ ...PresetFormItems.isInTunnel, key: "dcEventAccident.inTunnel" },
{ ...PresetFormItems.spillName, key: "dcEventAccident.spillageItem" },
{
...PresetFormItems.ownerPhone,
key: "dcEventAccident.vehicleOwnerPhone",
...inTunnel,
key: "dcEventVehicleAccident.inTunnel",
},
PresetFormItems.laneOccupancy,
PresetFormItems.vehicleCondition("dcEventAccident"),
PresetFormItems.casualties("dcEventAccident"),
PresetFormItems.vehicleCondition("dcEventVehicleAccident"),
PresetFormItems.casualties("dcEventVehicleAccident"),
PresetFormItems.eventTitle,
PresetFormItems.eventDesc,
PresetFormItems.source,
],
},
},
{
key: "VehicleFault",
label: "车辆故障",
formConfig: {
formOptions: {},
list: [
交通事故: [
{
...PresetFormItems.callPolicePersonName,
key: "dcEventVehicleAccident.reporterName",
key: "dcEventAccident.reporterName",
},
{
...PresetFormItems.callPolicePersonPhone,
key: "dcEventVehicleAccident.reporterPhoneNumber",
key: "dcEventAccident.reporterPhoneNumber",
},
PresetFormItems.vehicleMalfunctionType,
PresetFormItems.trafficAccidentType,
PresetFormItems.eventLevel,
{
...PresetFormItems.locationMode,
key: "dcEventVehicleAccident.locationType",
key: "dcEventAccident.locationType",
},
PresetFormItems.freeway,
freeway,
{
label: "服务区:",
key: "dcEventVehicleAccident.facilityId",
key: "dcEventAccident.facilityId",
type: "select",
isAlone: false,
required: true,
@ -293,7 +378,7 @@ export const tabConfigList = [
],
},
visible: (data) => {
if (data?.dcEventVehicleAccident?.locationType == 2) {
if (data?.dcEventAccident?.locationType == 2) {
return true;
}
return false;
@ -301,14 +386,14 @@ export const tabConfigList = [
},
{
label: "地点:",
key: "dcEventVehicleAccident.location",
key: "dcEventAccident.location",
isAlone: false,
required: true,
options: {
placeholder: "服务区地点",
},
visible: (data) => {
if (data?.dcEventVehicleAccident?.locationType == 2) {
if (data?.dcEventAccident?.locationType == 2) {
return true;
}
return false;
@ -316,7 +401,7 @@ export const tabConfigList = [
},
{
label: "立交桥:",
key: "dcEventVehicleAccident.facilityId",
key: "dcEventAccident.facilityId",
type: "select",
isAlone: false,
required: true,
@ -329,7 +414,7 @@ export const tabConfigList = [
],
},
visible: (data) => {
if (data?.dcEventVehicleAccident?.locationType == 3) {
if (data?.dcEventAccident?.locationType == 3) {
return true;
}
return false;
@ -351,22 +436,22 @@ export const tabConfigList = [
);
console.log("zd", zd);
formList.forEach((it) => {
if (it.key == "dcEventVehicleAccident.rampId") {
// console.log("it", it);
if (it.key == "dcEventAccident.rampId") {
console.log("it", it);
it.options.options = zd;
}
});
})
.catch((err) => {
console.log("err", err);
Message.error("查询失败2", err);
Message.error("查询失败3", err);
});
},
},
},
{
label: "匝道:",
key: "dcEventVehicleAccident.rampId",
key: "dcEventAccident.rampId",
type: "select",
isAlone: false,
required: true,
@ -374,7 +459,7 @@ export const tabConfigList = [
options: [],
},
visible: (data) => {
if (data?.dcEventVehicleAccident?.locationType == 3) {
if (data?.dcEventAccident?.locationType == 3) {
return true;
}
return false;
@ -382,7 +467,7 @@ export const tabConfigList = [
},
{
label: "收费站:",
key: "dcEventVehicleAccident.facilityId",
key: "dcEventAccident.facilityId",
type: "select",
isAlone: false,
required: true,
@ -395,7 +480,7 @@ export const tabConfigList = [
],
},
visible: (data) => {
if (data?.dcEventVehicleAccident?.locationType == 4) {
if (data?.dcEventAccident?.locationType == 4) {
return true;
}
return false;
@ -403,7 +488,7 @@ export const tabConfigList = [
},
{
label: "地点:",
key: "dcEventVehicleAccident.location",
key: "dcEventAccident.location",
type: "select",
isAlone: false,
required: true,
@ -412,64 +497,58 @@ export const tabConfigList = [
options: locationSelect,
},
visible: (data) => {
if (data?.dcEventVehicleAccident?.locationType == 4) {
if (data?.dcEventAccident?.locationType == 4) {
return true;
}
return false;
},
},
PresetFormItems.direction,
{ ...PresetFormItems.station,
visible: (data) => {
if (data.dcEventVehicleAccident && data.dcEventVehicleAccident.locationType != 1) {
return false;
}
return true;
},
},
directionName,
PresetFormItems.station,
PresetFormItems.eventHappenTime,
PresetFormItems.aEstimatedReleaseTime,
{ ...PresetFormItems.pressure, key: "dcEventAccident.trafficJam" },
{
...PresetFormItems.pressure,
key: "dcEventVehicleAccident.trafficJam",
...PresetFormItems.weatherCondition,
key: "dcEventAccident.weatherCondition",
},
{ ...PresetFormItems.effect, key: "dcEventAccident.impactLevel" },
{ ...PresetFormItems.isArrives, key: "dcEventAccident.isReverseCargo" },
{
...PresetFormItems.weatherCondition,
key: "dcEventVehicleAccident.weatherCondition",
...PresetFormItems.isMaintenanceAccident,
key: "dcEventAccident.isMaintenance",
},
{
...PresetFormItems.isCongestionAhead,
key: "dcEventVehicleAccident.congestionAhead",
...PresetFormItems.trafficPolicePhone,
key: "dcEventAccident.policeContact",
},
{
...PresetFormItems.isForkRoad,
key: "dcEventVehicleAccident.atIntersection",
...PresetFormItems.wreckerCalls,
key: "dcEventAccident.towingServiceContact",
},
{
...PresetFormItems.isCurveRoad,
key: "dcEventVehicleAccident.onCurve",
...isCongestionAhead,
key: "dcEventAccident.congestionAhead",
},
{
...PresetFormItems.isInTunnel,
key: "dcEventVehicleAccident.inTunnel",
...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("dcEventVehicleAccident"),
PresetFormItems.casualties("dcEventVehicleAccident"),
PresetFormItems.vehicleCondition("dcEventAccident"),
PresetFormItems.casualties("dcEventAccident"),
PresetFormItems.eventTitle,
PresetFormItems.eventDesc,
PresetFormItems.source,
],
},
},
{
key: "TrafficControl",
label: "交通管制",
formConfig: {
formOptions: {
column: 2,
},
list: [
交通管制: [
{
label: "管制设施:",
key: "eventSubclass",
@ -546,7 +625,7 @@ export const tabConfigList = [
if (value == "3-2") {
facilityType = 1;
} else if (value == "3-3") {
facilityType = 3;
facilityType = 4;
} else if (value == "3-4") {
facilityType = 6;
}
@ -588,11 +667,11 @@ export const tabConfigList = [
activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)",
options: [
{
key: "1",
key: 1,
label: "封闭",
},
{
key: "2",
key: 2,
label: "限行",
},
],
@ -705,27 +784,27 @@ export const tabConfigList = [
activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)",
options: [
{
key: "1",
key: 1,
label: "车流量大",
},
{
key: "2",
key: 2,
label: "交通事故",
},
{
key: "3",
key: 3,
label: "恶劣天气",
},
{
key: "4",
key: 4,
label: "施工",
},
{
key: "5",
key: 5,
label: "警备任务",
},
{
key: "6",
key: 6,
label: "其他",
},
],
@ -786,7 +865,7 @@ export const tabConfigList = [
},
},
},
PresetFormItems.isInTunnel,
inTunnel,
{
label: "原因类型:",
key: "dcEventTrafficControl.causeType",
@ -804,8 +883,8 @@ export const tabConfigList = [
return false;
},
},
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
PresetFormItems.emptyLine,
{
label: "出入口:",
@ -818,11 +897,11 @@ export const tabConfigList = [
activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)",
options: [
{
key: "1",
key: 1,
label: "出口",
},
{
key: "2",
key: 2,
label: "入口",
},
],
@ -1093,14 +1172,7 @@ export const tabConfigList = [
PresetFormItems.remark,
PresetFormItems.source,
],
},
},
{
key: "TrafficCongestion",
label: "交通拥堵",
formConfig: {
formOptions: {},
list: [
交通拥堵: [
{
label: "拥堵类型:",
key: "eventSubclass",
@ -1257,7 +1329,7 @@ export const tabConfigList = [
return false;
},
},
{ ...PresetFormItems.isInTunnel, isAlone: true },
{ ...inTunnel, isAlone: true },
{
label: "高速公路:",
required: true,
@ -1587,37 +1659,19 @@ export const tabConfigList = [
PresetFormItems.remark,
PresetFormItems.source,
],
},
},
{
key: "IllegalOnRoad",
label: "非法上路",
formConfig: {
formOptions: {
column: 2,
},
list: [
非法上路:[
PresetFormItems.illegalTriggeringType,
PresetFormItems.additionalNotes,
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
PresetFormItems.station,
PresetFormItems.isInTunnel,
inTunnel,
PresetFormItems.startTime,
PresetFormItems.expectedEndTime,
PresetFormItems.problemDescription,
PresetFormItems.source,
],
},
},
{
key: "BarricadesCleared",
label: "路障清除",
formConfig: {
formOptions: {
column: 2,
},
list: [
路障清除: [
{
label: "障碍物类型:",
key: "eventSubclass",
@ -1652,25 +1706,16 @@ export const tabConfigList = [
},
},
PresetFormItems.additionalNotes,
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
PresetFormItems.station,
PresetFormItems.isInTunnel,
inTunnel,
PresetFormItems.startTime,
PresetFormItems.expectedEndTime,
PresetFormItems.problemDescription,
PresetFormItems.source,
],
},
},
{
key: "Construction",
label: "施工建设",
formConfig: {
formOptions: {
column: 2,
},
list: [
施工建设: [
{
label: "施工类型:",
key: "key0123",
@ -1838,7 +1883,7 @@ export const tabConfigList = [
],
},
},
PresetFormItems.isInTunnel,
inTunnel,
{
//地点类型
...PresetFormItems.locationType,
@ -1913,8 +1958,8 @@ export const tabConfigList = [
return false;
},
},
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
{
...PresetFormItems.station,
visible: (data) => {
@ -2141,16 +2186,7 @@ export const tabConfigList = [
PresetFormItems.remark,
PresetFormItems.source,
],
},
},
{
key: "ServiceAreaAbnormal",
label: "服务区异常",
formConfig: {
formOptions: {
column: 2,
},
list: [
服务区异常: [
{
label: "异常分类:",
key: "eventSubclass",
@ -2176,8 +2212,8 @@ export const tabConfigList = [
],
},
},
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
{
label: "服务区:",
key: "dcEventServiceArea.facilityId",
@ -2256,16 +2292,7 @@ export const tabConfigList = [
PresetFormItems.remark,
PresetFormItems.source,
],
},
},
{
key: "HiddenDangersEquipment",
label: "设施设备隐患",
formConfig: {
formOptions: {
column: 2,
},
list: [
设施设备隐患: [
{
label: "类型:",
key: "eventSubclass",
@ -2316,25 +2343,16 @@ export const tabConfigList = [
},
required: true,
},
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
PresetFormItems.station,
PresetFormItems.isInTunnel,
inTunnel,
PresetFormItems.startTime,
PresetFormItems.expectedEndTime,
PresetFormItems.problemDescription,
PresetFormItems.source,
],
},
},
{
key: "AbnormalWeather",
label: "异常天气",
formConfig: {
formOptions: {
column: 2,
},
list: [
异常天气: [
{
label: "异常天气:",
key: "eventSubclass",
@ -2474,8 +2492,8 @@ export const tabConfigList = [
key: "dcEventAbnormalWeather.weatherSituation",
},
PresetFormItems.additionalNotes,
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
PresetFormItems.startEndStation,
{
label: "紧急级别:",
@ -2495,22 +2513,13 @@ export const tabConfigList = [
],
},
},
PresetFormItems.isInTunnel,
inTunnel,
PresetFormItems.startTime,
PresetFormItems.expectedEndTime,
PresetFormItems.problemDescription,
PresetFormItems.source,
],
},
},
{
key: "OtherEvents",
label: "其他事件",
formConfig: {
formOptions: {
column: 2,
},
list: [
其他事件: [
{
label: "事件说明:",
key: "eventSourceTips",
@ -2523,16 +2532,14 @@ export const tabConfigList = [
showWordLimit: true,
},
},
PresetFormItems.freeway,
PresetFormItems.direction,
freeway,
directionName,
PresetFormItems.station,
PresetFormItems.isInTunnel,
inTunnel,
PresetFormItems.startTime,
PresetFormItems.expectedEndTime,
PresetFormItems.problemDescription,
PresetFormItems.source,
],
},
},
];
}

71
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/components/EditEventInformationDialog/index.vue

@ -1,5 +1,5 @@
<template>
<Dialog v-model="modelVisible" title="修改事件信息" width="1100px" top="10%">
<Dialog v-model="modelVisible" title="修改事件信息" width="1100px" top="5%">
<div class="EditEventInformationDialog">
<Form
class="form"
@ -24,7 +24,7 @@ import Dialog from "@screen/components/Dialog/index";
import Form from "@screen/components/FormConfig";
import Button from "@screen/components/Buttons/Button.vue";
import request from "@/utils/request";
import { tabConfigList } from "./data.js";
import { configList } from "./data.js";
import { Message } from "element-ui";
import { provideMixin } from "./../../../../mixin";
@ -65,7 +65,6 @@ export default {
return this.visible;
},
set(val) {
console.log("val", val);
this.$emit("close", val);
},
},
@ -78,56 +77,28 @@ export default {
method: "get",
});
console.log('-----',infoData)
if (infoData.code != 200) return Message.error(infoData?.msg);
this.resultEventData = { ...infoData.data };
let info = infoData.data;
if (typeof info.stakeMark == "string") {
let numbers = info.stakeMark.match(/\d+/g).map(Number);
// console.log('numbers', numbers);
let numbers = info.stakeMark.match(/\d+/g).map(String);
info.stakeMark = numbers;
}
if (typeof info.lang == "string") {
info.lang = info.lang.split(",");
}
if(info.eventSource){
info.eventSource = info.eventSource.toString()
}
if(info.dcEventVehicleAccident && info.dcEventVehicleAccident.weatherCondition){
info.dcEventVehicleAccident.weatherCondition = info.dcEventVehicleAccident.weatherCondition.toString()
}
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`,
@ -149,14 +120,7 @@ export default {
Message.error("查询失败6", err);
}),
]);
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);
}
@ -164,10 +128,10 @@ export default {
},
onSubmit() {
this.$refs.FormConfigRef.validate().then((formData) => {
this.submitting = true;
let eventType = this.resultEventData.eventType;
formData.eventType = eventType;
if (
(eventType == 1 || eventType == 2) &&
Array.isArray(formData.lang)
@ -189,7 +153,7 @@ export default {
let endStakeMark = formData.endStakeMark;
let strMark =
endStakeMark && endStakeMark.length > 0
? "K" + endStakeMark[0] + "+" + endStakeMark[1]
? "K" + endStakeMark[0].padStart(3,'0') + "+" + endStakeMark[1]
: "";
if (eventType == 4) {
formData.dcEventTrafficCongestion.endStakeMark = strMark;
@ -210,10 +174,9 @@ export default {
// ...formData,
// id: this.resultEventData.id,
// eventState: this.resultEventData.eventState,
// stakeMark: (stakeMark && stakeMark[0] != null) ? ((stakeMark && stakeMark.length > 0) ? ('K' + stakeMark[0] + '+' + stakeMark[1]) : '') : '',
// stakeMark: (stakeMark && stakeMark[0] != null) ? ((stakeMark && stakeMark.length > 0) ? ('K' + stakeMark[0].padStart(3,'0') + '+' + stakeMark[1]) : '') : '',
// })
// this.submitting = false;
// return;
request({
url: `/dc/system/event`,
@ -250,11 +213,10 @@ export default {
<style lang="scss" scoped>
.EditEventInformationDialog {
gap: 9px;
width: 1050px;
height: 850px;
width: 100%;
height: 700px;
display: flex;
flex-direction: column;
.form {
flex: 1;
overflow-y: auto;
@ -264,6 +226,7 @@ export default {
display: flex;
justify-content: end;
gap: 15px;
margin-top: 9px;
}
}
</style>

2
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/EventInformation/images/congestion.svg

@ -1,3 +1,3 @@
<svg width="18" height="18" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="Vector" d="M9 0C4.02945 0 0 4.02942 0 9C0 13.9706 4.02945 18 9 18C13.9706 18 18 13.9706 18 9C18 4.02944 13.9707 0 9 0ZM13.9486 6.84275L8.15496 12.7718C7.88844 13.0446 7.45606 13.0446 7.18957 12.7718L4.05145 9.56015C3.78475 9.28735 3.78475 8.84498 4.05145 8.5721C4.31795 8.2992 4.75035 8.2992 5.01684 8.5721L7.67229 11.2896L12.983 5.85462C13.2497 5.58174 13.6821 5.58174 13.9486 5.85462C14.2153 6.12747 14.2153 6.56987 13.9486 6.84275H13.9486Z" fill="#FF5F5F"/>
<path id="Subtract" fill-rule="evenodd" clip-rule="evenodd" d="M9 18C13.9706 18 18 13.9706 18 9C18 4.02944 13.9706 0 9 0C4.02944 0 0 4.02944 0 9C0 13.9706 4.02944 18 9 18ZM13.5184 4.429C13.782 4.67715 13.7889 5.09389 13.5337 5.35067L9.90677 8.99979L13.5341 12.6493C13.7894 12.9061 13.7824 13.3229 13.5188 13.571C13.2651 13.8098 12.8674 13.8032 12.6218 13.5561L9 9.9121L5.37816 13.5561C5.13256 13.8032 4.73487 13.8098 4.48119 13.571C4.21758 13.3229 4.21065 12.9061 4.46586 12.6493L8.09323 8.99979L4.46628 5.35067C4.21107 5.09389 4.218 4.67715 4.48161 4.429C4.73529 4.19021 5.13298 4.19682 5.37857 4.44392L9 8.08748L12.6214 4.44392C12.867 4.19682 13.2647 4.19021 13.5184 4.429Z" fill="#FF5F5F"/>
</svg>

Before

Width:  |  Height:  |  Size: 574 B

After

Width:  |  Height:  |  Size: 797 B

2
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/Cards/TrafficControl/components/AddControlEventInfoDialog/data.js

@ -91,7 +91,7 @@ export const tabConfigList = [
if (value == "3-2") {
facilityType = 1;
} else if (value == "3-3") {
facilityType = 3;
facilityType = 4;
} else if (value == "3-4") {
facilityType = 6;
}

2
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/commandDispatch/index.vue

@ -83,7 +83,7 @@ export default {
})
.then((result) => {
if (result.code != 200) return;
console.log(result,'###########')
this.provideData.detail = result.data;
console.log("这里是事件详情", this.provideData.detail);
if (

2
ruoyi-ui/src/views/JiHeExpressway/pages/control/event/event/FormEvent/data.js

@ -546,7 +546,7 @@ export const tabConfigList = [
if (value == "3-2") {
facilityType = 1;
} else if (value == "3-3") {
facilityType = 3;
facilityType = 4;
} else if (value == "3-4") {
facilityType = 6;
}

521
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/eventPlanDialog/index.vue

@ -1,521 +0,0 @@
<template>
<Dialog v-model="modelVisible" :title="title" width="880px">
<div class="EventAddPlanDialog">
<div class="first">
<el-radio-group v-model="planName" @input="changeRadio">
<el-radio-button
v-for="item in info"
:key="item.id"
:label="item.planName"
></el-radio-button>
</el-radio-group>
</div>
<div class="second">
<el-row>
<el-col :span="2">
<div class="text">联动设备:</div>
</el-col>
<el-col :span="22">
<FormTable
ref="secondFormTable"
:tableData="secondFormData"
:type="1"
></FormTable>
</el-col>
</el-row>
</div>
<div class="third">
<el-row>
<el-col :span="2">
<div class="text">恢复操作:</div>
</el-col>
<el-col :span="22">
<FormTable
ref="thirdFormTable"
:tableData="thirdFormData"
:type="2"
></FormTable>
</el-col>
</el-row>
</div>
</div>
<template #footer>
<!-- <Button v-if="isDisBtn" style="padding:0 24px; pointer-events: none; background-color: #C9C9C9;"
@click.native="handleRestore" :loading="submitting">强制恢复</Button> -->
<Button
style="padding: 0 24px"
@click.native="handleSubmit(2)"
:loading="submitting"
>强制恢复</Button
>
<Button
style="padding: 0 24px"
@click.native="handleSubmit(1)"
:loading="submitting"
>确认</Button
>
<Button
style="background: #c9c9c9; padding: 0 24px"
@click.native="(modelVisible = false), (submitting = false)"
>取消</Button
>
</template>
</Dialog>
</template>
<script>
import Dialog from "@screen/components/Dialog/index";
import FormTable from "../formTable/index.vue";
import Button from "@screen/components/Buttons/Button.vue";
import request from "@/utils/request";
import { Message } from "element-ui";
import { throttle } from "lodash";
export default {
name: "eventPlanDialog",
components: {
Dialog,
Button,
FormTable,
},
model: {
prop: "visible",
event: "close",
},
provide() {
return {
loadData: throttle(this.loadData, 1000),
getAutomatic: this.getTemplateAutomatic,
getOriginal: this.getBoardOriginal,
};
},
props: {
visible: Boolean,
activeName: String,
info: {
type: Array,
default: () => [],
},
eventFormData: {
type: Object,
default: () => {},
},
},
data() {
return {
title: "事件确认",
isDisBtn: true,
dialogType: 1,
planId: 0,
planInfo: {},
submitting: false,
secondFormData: [
{
deviceType: 1,
searchRule: 1,
qbb: "",
},
],
thirdFormData: [
{
deviceType: 1,
searchRule: 1,
qbb: "",
},
],
planName: "",
automaticInfo: {},
dcExecuteAction: [],
deviceData: [],
automaticData: {},
boardOriginalData: {},
eventOptions: [
{
value: 1,
label: "异常天气",
},
{
value: 2,
label: "交通事故",
},
{
value: 3,
label: "非法上路",
},
{
value: 4,
label: "车辆故障",
},
{
value: 5,
label: "交通拥堵",
},
{
value: 6,
label: "交通管制",
},
{
value: 7,
label: "服务区异常",
},
{
value: 8,
label: "施工建设",
},
{
value: 9,
label: "路障清除",
},
],
mechanismOptions: [
{
value: 1,
label: "雨",
},
{
value: 2,
label: "雪",
},
{
value: 3,
label: "雾",
},
{
value: 4,
label: "大风",
},
{
value: 5,
label: "低温寒潮",
},
{
value: 6,
label: "路面积雪",
},
{
value: 7,
label: "路面结冰",
},
{
value: 8,
label: "路面积水",
},
{
value: 9,
label: "其他",
},
],
conditionOptions: [
// {
// value: 1,
// label: '(>)'
// },
{
value: 1,
label: "小于(<)",
},
],
};
},
mounted() {},
computed: {
modelVisible: {
get() {
if (this.visible) {
if (this.info.length > 0) {
this.planName = this.info[0]?.planName || "";
this.planInfo = this.info[0];
this.initData(this.info[0]);
}
}
return this.visible;
},
set(val) {
this.$emit("close", val);
},
},
},
methods: {
initData(data) {
console.log("data", data);
if (!data) return;
// this.planId = data.id;
let dcExecuteAction = data.dcExecuteAction;
let secondFormData = [];
let thirdFormData = [];
dcExecuteAction.forEach((it) => {
let action = { ...it };
if (it.otherConfig) {
let config = JSON.parse(it.otherConfig);
let qbb = "";
if (config.id) {
qbb = config.content;
config = { dcInfoBoardTemplate: config };
}
// if (config.state) {
// config.gzms = config.state
// }
action = { ...it, ...config, qbb: qbb };
}
if (it.deviceList) {
action.deviceList = it.deviceList
.split(",")
.map((str) => Number(str));
}
if (it.actionType == 1) {
secondFormData.push(action);
} else if (it.actionType == 2) {
thirdFormData.push({
...action,
qbb: "默认恢复该情报板上次常态化信息",
});
}
});
this.secondFormData = secondFormData;
this.thirdFormData = thirdFormData;
},
async loadData() {
if (this.deviceData.length <= 0) {
let result = await request({
url: `business/device/query?deviceType=2`,
method: "get",
});
if (result.code != 200) return Message.error(result?.msg);
// console.log('123');
this.deviceData = result.data;
// return result.data;
}
return this.deviceData;
},
async getTemplateAutomatic() {
let url = "";
let data = {};
let otherConfig = {};
let plan = this.info.find((it) => it.planName == this.planName);
console.log("plan", plan);
let action = plan.dcExecuteAction.find(
(it) => it.actionType == 1 && it.deviceType == 2
);
if (action) {
otherConfig = JSON.parse(action.otherConfig);
if (this.activeName == "-1") {
//
url = "/business/plans/warning/confirm";
data = {
dcInfoBoardTemplate: otherConfig,
dcWarning: this.eventFormData,
};
} else {
//
url = "/business/plans/event/automatic";
data = {
dcInfoBoardTemplate: otherConfig,
dcEvent: this.eventFormData,
};
}
const result = await request({
url: url,
method: "post",
data: data,
});
if (result.code != 200) return Message.error(result?.msg);
this.automaticData = result.data;
} else {
console.log("没有情报板,不调用接口");
this.automaticData = {};
}
return this.automaticData;
},
async getBoardOriginal() {
let url = "";
let data = {};
let plan = this.info.find((it) => it.planName == this.planName);
console.log("plan1", plan);
let action = plan.dcExecuteAction.find(
(it) => it.actionType == 1 && it.deviceType == 2
);
if (action) {
if (this.activeName == "-1") {
//
url = "/business/plans/warning/board/confirm";
data = {
dcEmergencyPlans: {
...plan,
executeAction: action,
},
dcWarning: this.eventFormData,
};
} else {
//
url = "/business/plans/event/board/confirm";
data = {
dcEmergencyPlans: {
...plan,
executeAction: action,
},
dcEvent: this.eventFormData,
};
}
const result = await request({
url: url,
method: "post",
data: data,
});
if (result.code != 200) return Message.error(result?.msg);
this.boardOriginalData = result.data;
} else {
console.log("没有情报板,不调用接口");
this.boardOriginalData = {};
}
return this.boardOriginalData;
},
changeRadio(value) {
let plan = this.info.find((it) => it.planName == value);
this.planInfo = plan;
this.initData(plan);
},
formatData(it, value = 1) {
let data = { ...it, actionType: value, emergencyPlansId: id };
if (
it.deviceList &&
typeof it.deviceList !== "string" &&
it.deviceList.length > 0
) {
data.deviceList = it.deviceList.join(",");
} else {
data.deviceList = "";
}
if (it.content) {
data.otherConfig = JSON.stringify({ content: it.content });
}
if (it.controlModel) {
let other = {
controlModel: it.controlModel,
controlModelName: inducerModeDic[it.controlModel],
state: it.state,
name: inducerWorkTypeDic[it.state],
};
if (it.time && it?.time[0]) {
other = {
controlModel: it.controlModel,
controlModelName: inducerModeDic[it.controlModel],
state: it.state,
name: inducerWorkTypeDic[it.state],
startTime: it.time[0],
endTime: it.time[1],
};
}
data.otherConfig = JSON.stringify(other);
}
if (it.gzms) {
data.otherConfig = JSON.stringify({
state: it.gzms,
name: gzmsMap[it.gzms],
operationDuration: it.operationDuration,
});
}
return data;
},
handleSubmit(value = 1) {
// this.submitting = false;
let plan = { ...this.planInfo };
let actions = plan.dcExecuteAction.filter((it) => it.actionType == value);
plan.dcExecuteAction = actions;
let reqData = {
operationType: value, //1- 2-
dcEmergencyPlans: plan,
dcEvent: this.eventFormData,
};
let url = "";
if (this.activeName == "-1") {
//
url = "/business/plans/warning/confirm";
reqData = { ...reqData, dcWarning: { ...reqData.dcEvent } };
} else {
//
url = "/business/plans/event/confirm";
}
console.log("reqData", reqData);
// return;
request({
url: url,
method: "post",
data: reqData,
})
.then((result) => {
if (result.code != 200) return Message.error(result?.msg);
Message.success("提交成功");
this.$emit("close", false);
setTimeout(() => {
this.$emit("reInitData", true);
}, 100);
})
.catch(() => {
Message.error("提交失败");
})
.finally(() => {
this.submitting = false;
});
},
handleRestore() {},
},
};
</script>
<style lang="scss" scoped>
.fade-enter-active,
.fade-leave-active {
transition: opacity 0.24s;
}
.fade-enter,
.fade-leave-to {
opacity: 0;
}
.EventAddPlanDialog {
gap: 9px;
width: 1280px;
height: 310px;
display: flex;
flex-direction: column;
.first,
.second,
.third {
padding: 5px 10px 8px;
background-color: #296887;
margin-bottom: 15px;
.text {
margin-top: 12px;
}
}
.form {
flex: 1;
overflow-y: auto;
}
.footer {
display: flex;
justify-content: end;
gap: 15px;
}
// .disabledBtn {
// height: 24px;
// border-radius: 48px;
// background: #C9C9C9;
// padding: 0 24px;
// color: white !important;
// display: flex;
// align-items: center;
// justify-content: center;
// }
}
</style>

336
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/formTable/index.vue

@ -1,336 +0,0 @@
<template>
<div class="EventDetail">
<Table :data="tableData" :show-header="false">
<ElTableColumn prop="deviceType" width="160">
<template slot-scope="scope">
<el-select v-model="scope.row.deviceType" placeholder="请选择设备类型" @change="changeDeviceType">
<el-option v-for="item in deviceOptions" :key="item.value" :label="item.label"
:value="item.value">
</el-option>
</el-select>
</template>
</ElTableColumn>
<ElTableColumn prop="searchRule" width="230">
<template slot-scope="scope">
<div class="plhx">
<el-select v-model="scope.row.searchRule" placeholder="检索规则条件">
<el-option v-for="item in zyOptions" :key="item.value" :label="item.label"
:value="item.value">
</el-option>
</el-select>
<el-input-number v-if="scope.row.searchRule == 2 || scope.row.searchRule == 3"
v-model="scope.row.number" :min="0" :max="9999" style="width: 130px;"></el-input-number>
<p v-if="scope.row.searchRule == 2 || scope.row.searchRule == 3"></p>
<el-input-number v-if="scope.row.searchRule == 4" v-model="scope.row.number" :min="0"
:max="9999" style="width: 130px;"></el-input-number>
<p v-if="scope.row.searchRule == 4" style="width: 56px;">公里</p>
</div>
</template>
</ElTableColumn>
<ElTableColumn prop="deviceList" width="400">
<template slot-scope="scope">
<div class="mjs">
<el-select v-if="scope.row.searchRule == 1" v-model="scope.row.deviceList" placeholder="请选择设备"
multiple collapse-tags>
<el-option v-for="item in sbOptions" :key="item.id" :label="item.deviceName"
:value="item.id">
</el-option>
</el-select>
<!-- 情报板 -->
<el-input @click.native="clickQbb(scope.$index)" v-if="scope.row.deviceType == 2"
placeholder="请选择" v-model="scope.row.qbb" readonly>
<i slot="suffix" class="el-input__icon el-icon-search"></i>
</el-input>
<el-select v-if="scope.row.deviceType == 10" v-model="scope.row.gzms" placeholder="工作模式">
<el-option v-for="item in gzmsOptions" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select>
<el-input-number v-if="scope.row.deviceType == 10" placeholder="时长(分钟)"
v-model="scope.row.operationDuration" :min="0" :max="999"></el-input-number>
<el-select v-if="scope.row.deviceType == 12" v-model="scope.row.controlModel"
placeholder="请选择模式">
<el-option label="手动模式" value="00"></el-option>
<el-option label="自动模式" value="01"></el-option>
<el-option label="万年历" value="02"></el-option>
</el-select>
<el-time-picker v-if="scope.row.controlModel == '01' && scope.row.deviceType == 12"
v-model="scope.row.time" is-range style="" range-separator="-" placeholder="选择时间"
value-format="HH:mm" format="HH:mm">
</el-time-picker>
<el-select v-if="scope.row.deviceType == 12" v-model="scope.row.state" placeholder="工作状态">
<el-option v-for="item in gzztOptions" :key="item.value" :label="item.label"
:value="item.value"></el-option>
</el-select>
<el-input v-if="scope.row.deviceType == 5" v-model="scope.row.content"
placeholder="请输入发布内容"></el-input>
</div>
</template>
</ElTableColumn>
<ElTableColumn label="操作" width="100">
<template slot-scope="scope">
<ElButton class="elButton" icon="el-icon-plus" plain size="mini"
@click.native="onAdd(scope.row.id)" />
<ElButton class="elButton" icon="el-icon-delete" plain size="mini"
@click.native="onDel(scope.$index)" />
</template>
</ElTableColumn>
</Table>
<!-- 情报板弹窗 -->
<QbbDialog :visible="isShowDialog" :info="qbbData" :type="type" @close="onCloseDialog"
@dialogSubmit="dialogSubmit" />
</div>
</template>
<script>
import Table from '@screen/components/Table.vue';
import Button from '@screen/components/Buttons/Button.vue';
import request from "@/utils/request";
import QbbDialog from "../qbbDialog/index.vue";
import { Message } from 'element-ui'
import { planDeviceOptions } from "@screen/utils/enum.js";
export default {
name: 'formTable',
components: {
Button,
Table,
QbbDialog
},
// model: {
// prop: 'visible',
// event: 'update:value'
// },
inject: ['loadData'],
props: {
eventType: Number,
type: Number,
tableData: {
type: Array,
default: () => [{
deviceType: 1,
searchRule: 1,
qbb: ''
}]
}
},
data() {
return {
// tableData: [
// {
// deviceType: 1,
// searchRule: 1,
// qbb: ''
// }
// ],
isShowDialog: false,
deviceOptions: planDeviceOptions,
zyOptions: [
{
value: 1,
label: '指定设备资源'
},
{
value: 2,
label: '事发上游最近'
},
{
value: 3,
label: '事发下游最近'
},
{
value: 4,
label: '最近公里数'
},
],
gzztOptions: [
{
value: "01",
label: "常亮"
},
{
value: "02",
label: "流水"
},
{
value: "03",
label: "闪烁"
},
{
value: "04",
label: "关闭",
}
],
gzmsOptions: [
{
value: "SETMD0",
label: "激光关闭"
},
{
value: "SETMD1",
label: "常亮模式"
},
{
value: "SETMD2",
label: "间隔100ms闪烁模式"
},
{
value: "SETMD3",
label: "间隔200ms闪烁模式",
},
{
value: "SETMD4",
label: "间隔500ms闪烁模式",
},
{
value: "SETMD5",
label: "2次闪烁模式"
},
{
value: "SETMD6",
label: "SOS模式"
},
{
value: "SETMD7",
label: "自定义模式1",
},
{
value: "SETMD8",
label: "自定义模式2",
},
{
value: "SETMD9",
label: "自定义模式3",
}
],
qbbData: {},
sbOptions: [],
deviceType: 1,
index: 1
}
},
async created() {
let loadData = await this.loadData(1);
// console.log('aa',loadData)
this.sbOptions = loadData;
},
methods: {
initData() {
// request({
// url: `business/device/query?deviceType=2`,
// method: "get",
// }).then((result) => {
// if (result.code != 200) return Message.error(result?.msg);
// this.sbOptions = result.data;
// }).catch(() => {
// Message.error("");
// })
},
async changeDeviceType(value) {
this.deviceType = value;
console.log('value', value)
this.sbOptions = await this.loadData(value);
},
onAdd(id) {
this.tableData.push({
deviceType: 1,
searchRule: 1,
qbb: ''
})
},
onDel(index) {
if (this.tableData.length <= 1) {
return Message.warning('最后一项不可删除!');
}
this.tableData.splice(index, 1)
},
clickQbb(index) {
this.index = index;
// this.qbbData = this.tableData[index].dcInfoBoardTemplate;
console.log('this.type', this.type)
this.isShowDialog = true;
},
onCloseDialog() {
this.isShowDialog = false;
},
dialogSubmit(data) {
this.tableData[this.index].qbb = data.content;
this.tableData[this.index].otherConfig = JSON.stringify(data);
}
}
}
</script>
<style lang="scss" scoped>
.EventDetail {
display: flex;
gap: 9px;
width: 100%;
// height: 768px;
min-height: 50px;
margin-top: 5px;
flex-direction: column;
::v-deep {
.el-table .el-table__cell {
padding: 0 5px;
}
}
.mjs {
display: flex;
>div {
margin-right: 10px;
}
}
.ms {
width: 160px;
}
.plhx {
display: flex;
}
::v-deep {
.el-tag.el-tag--info {
max-width: 100px;
}
.el-range-editor--medium .el-range__icon,
.el-range-editor--medium .el-range__close-icon {
display: none;
}
}
}
.elButton {
background: #2ba8c3;
border-radius: 2px 2px 2px 2px;
color: #FFFFFF;
}
.elButton:hover,
.elButton:focus {
background: #2ba8c3;
border-radius: 2px 2px 2px 2px;
border-color: #FFFFFF;
color: #FFFFFF;
}
</style>

321
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/index.vue

@ -1,88 +1,51 @@
<template>
<Dialog v-model="modelVisible" title="事件详情" width="890px" top="11%">
<div class="EventDetail" :style="{
height: activeName == '-1' || activeName == '0' ? '380px' : '698px',
}">
<div class="EventDetail" style="height:380px">
<Form ref="FormConfigRef" :formList="formList" :dFormData="formData" label-width="100px" />
<div class="video-pic" :style="{
height: formData.component === 'VideoMulti' ? '242px' : undefined,
}">
<component :is="formData.component" v-if="activeName != '-1'" style="height: 100%; width: 380px"
:showHeader="false" :url="formData.videoList && formData.videoList.length > 0
? formData.videoList[0]
: ''
" :camId="formData.upCamId" :pileNum="formData.stakeMark" rangeIndex="upCamera" :videoType="formData.videoType" />
<component :is="formData.component" v-if="activeName != '-1'" style="height: 100%; width: 380px"
<component :is="formData.component" style="height: 100%; width: 380px"
:showHeader="false" :url="formData.videoList && formData.videoList.length > 0
? formData.videoList[1]
: ''
" :camId="formData.downCamId" :pileNum="formData.stakeMark" rangeIndex="downCamera"
:videoType="formData.videoType" />
<Carousel v-if="activeName == '-1'" style="flex: 1" :videos="formData.videoList" :pictures="[]" />
<Carousel v-if="activeName == '-1'" style="flex: 1" :pictures="formData.pictures" :videos="[]" />
<Carousel style="flex: 1" :videos="formData.videoList" :pictures="[]" />
<Carousel style="flex: 1" :pictures="formData.pictures" :videos="[]" />
</div>
<!-- <div>{{ formData.videoList[0] }}</div> -->
<TimeLine1 v-if="activeName == '1' || activeName == '2'" :data="timeLine1List" />
<TimeLine2 v-if="activeName == '1' || activeName == '2'" :data="timeLine2List" style="flex: 1" />
</div>
<!-- 确认弹窗 -->
<EventPlanDialog :visible="isShowDialog" :info="info" :eventFormData="formData" :activeName="activeName"
@reInitData="() => {
this.$emit('update:value', false);
this.$emit('queryData', true);
}
" @close="onCloseAddNew" />
<template #footer>
<Button v-if="activeName == '-1' || activeName == '0'" style="padding: 0 24px"
@click.native="onDelete">误报</Button>
<Button :style="{ backgroundColor: '#C9C9C9', padding: '0 24px' }"
@click.native="modelVisible = false">取消</Button>
<Button v-if="activeName == '-1' || activeName == '0'" style="padding: 0 24px"
@click.native="onSubmit">确认</Button>
<Button :style="{ padding: '0 24px' }"
@click.native="modelVisible = false">关闭</Button>
</template>
</Dialog>
</template>
<script>
import Dialog from "@screen/components/Dialog/index";
import TimeLine1 from "@screen/components/TimeLine/TimeLine1/index";
import TimeLine2 from "@screen/components/TimeLine/TimeLine2/index";
import Form from "@screen/components/FormConfig";
import { _formList } from "./data";
// import { timeLine2List } from "@screen/pages/control/event/commandDispatch/Cards/DisposalProcess/data.js"
import Video from "@screen/components/Video";
import VideoMulti from "@screen/components/VideoMulti";
import Carousel from "./Carousel/index.vue";
import EventPlanDialog from "./eventPlanDialog/index.vue";
import Button from "@screen/components/Buttons/Button.vue";
import request from "@/utils/request";
import { Message } from "element-ui";
var moment = require("moment");
import {
getProcessNode,
getProcessList,
postProcess,
postCompleteEvent,
postNoSkipClear,
} from "@/api/commandDispatch";
export default {
name: "EventDetail",
components: {
Dialog,
Form,
TimeLine1,
TimeLine2,
Video,
VideoMulti,
Carousel,
Button,
EventPlanDialog,
},
model: {
prop: "visible",
@ -90,7 +53,7 @@ export default {
},
props: {
visible: Boolean,
activeName: String,
formData: {
type: Object,
default: () => { },
@ -101,289 +64,21 @@ export default {
formList:[..._formList],
isShowDialog: false,
info: [],
timeLine1List: [
{
time: "",
label: "",
isActive: false,
},
],
timeLine2List: [
{
time: "",
name: "",
desc: "",
posts: "",
direction: "left",
},
],
};
},
computed: {
modelVisible: {
get() {
if (this.visible) {
this.getProcess();
}
return this.visible;
},
set(val) {
console.log(111)
this.formList = [..._formList]
this.$emit("update:value", val);
},
},
},
methods: {
getProcess() {
if (this.activeName == "-1" || this.activeName == "0") {
this.timeLine1List = [];
this.timeLine2List = [];
return;
}
let directionFlg = true;
getProcessList(this.formData.id).then((rows) => {
console.log('rows', rows)
// if (result.code != 200) return Message.error(result?.msg);
// const rows = result.rows;
this.timeLine1List = [];
this.timeLine2List = [];
this.formData?.processConfigList.forEach((it) => {
const process = rows.find((row) => it.nodeNode == row.processId && row.processType === 1);
if (process) {
this.timeLine1List.push({
time: moment(process.operationTime || new Date()).format("HH:mm"),
label: it.processNode,
isActive: true,
});
directionFlg = !directionFlg;
} else {
this.timeLine1List.push({
time: "",
label: it.processNode,
isActive: false,
});
}
});
rows.forEach(item =>{
this.timeLine2List.push({
time: moment(item.operationTime || new Date()).format(
"yyyy-MM-DD HH:mm:ss"
),
name: item.operatorName,
desc: item.context,
source: item.source,
posts: "",
direction: item.source == 1 ? "right" : "left",
});
})
});
},
getProcessNode() {
return request({
url:
`/dc/system/event/getProcessNode/${this.formData.id}`,
method: "GET",
})
.then((result) => {
if (result.code != 200) return [];
// this.timeLine1List = result.data.map((item) => {
// return {
// time: item.operationTime,
// label: item.processNode,
// isActive: item.status == 1 ? true : false,
// };
// });
// this.options = result.data.filter((item) => {
// item.status == 0;
// return item;
// });
})
.catch((err) => []);
},
onCloseAddNew() {
this.isShowDialog = false;
},
onDelete() {
if(this.formList[this.formList.length-1].key !== 'relieveReason' ){
this.formList.push({
label: "解除类型:",
key: "relieveType",
type: "RadioGroup",
isAlone: true,
required: true,
options: {
activeColor: "linear-gradient(180deg, #37E7FF 0%, #009BCC 100%)",
options: [
{
key: "1",
label: "误报解除",
},
{
key: "2",
label: "事件已结束",
},
{
key: "3",
label: "无需处理事件",
},
{
key: "4",
label: "其它",
}
],
},
})
this.formList.push({
label: "解除原因:", //
key: "relieveReason", //
isAlone: true, //
type: "input", //(el-input el-) input
options: { //elementformItem
type: "textarea",
autosize: true,
maxlength: 200,
autosize: { minRows: 3, maxRows: 3 },
showWordLimit: true,
}
})
} else {
this.$refs.FormConfigRef.validate()
.then((result) => {
request({
url: `/business/warning/falseAlarm`,
method: "post",
data: {
id: this.formData.id,
relieveType: result.relieveType,
relieveReason: result.relieveReason
},
}).then((result) => {
if (result.code == 200) Message.success("成功!");
else Message.error(result?.msg);
this.modelVisible = false;
this.$emit("queryData", true);
//
this.$root.$emit('delete-event');
});
})
.catch((err) => {
});
}
// 2024-05-18
// if (this.formData.id) {
// this.$confirm("", "", {
// confirmButtonText: "",
// cancelButtonText: "",
// type: "warning",
// }).then(() => {
// if (this.activeName == "-1") {
// request({
// url: `/business/warning/delete`,
// method: "post",
// data: { id: this.formData.id },
// }).then((result) => {
// if (result.code == 200) Message.success("");
// else Message.error(result?.msg);
// this.modelVisible = false;
// this.$emit("queryData", true);
// //
// this.$root.$emit('delete-event');
// });
// } else {
// request({
// url: `dc/system/event/${this.formData.id}`,
// method: "delete",
// }).then((result) => {
// if (result.code == 200) Message.success("");
// else Message.error(result?.msg);
// this.modelVisible = false;
// this.$emit("queryData", true);
// //
// this.$root.$emit('delete-event');
// });
// }
// });
// }
},
onSubmit() {
// let url = "/business/plans/list/warning/type";
// if (this.activeName == "-1") {
// url = "/business/plans/list/warning/type";
// } else {
// url = "/business/plans/list/event/type";
// }
// request({
// url: url,
// method: "post",
// data: this.formData,
// }).then((result) => {
// if (result.code != 200) return Message.error(result?.msg);
// this.info = result.data;
// this.isShowDialog = true;
// });
let reData = {
id: this.formData.id,
stakeMark: this.formData.stakeMark,
direction: this.formData.direction == '济南方向' ? 3 : 1,
warningType: this.formData.warningType,
warningSource: this.formData.warningSource,
deptId: this.formData.deptId,
warningTime: this.formData.warningTime,
warningLevel: this.formData.warningLevel,
warningSubclass: this.formData.warningSubclass,
warningTitle: this.formData.warningTitle,
lane: this.formData.lane,
remark: this.formData.remark,
}
if (this.activeName == '-1') {
request({
url: '/business/warning/updateWarningConvert',
method: "post",
data: reData,
}).then((result) => {
if (result.code != 200) return Message.error(result?.msg);
else Message.success("成功!");
this.modelVisible = false;
this.$emit("queryData", true);
});
} else if (this.activeName == '0') {
request({
url: `/dc/system/event/dcEventState/${this.formData.id}/1`,
method: "put",
data: reData,
}).then((result) => {
if (result.code != 200) return Message.error(result?.msg);
else Message.success("成功!");
this.modelVisible = false;
this.$emit("queryData", true);
});
} else {
let eventId = this.formData.id;
this.modelVisible = false;
setTimeout(() => {
this.$router.push(`/control/event/commandDispatch?eventId=${eventId}`);
// this.$router.push(`/control/event/commandDispatch`);
})
}
},
reInitData() {
console.log("reInitData");
this.$emit("update:value", false);
this.$emit("queryData", true);
},
},
};
</script>

381
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/EventDetailDialog/qbbDialog/index.vue

@ -1,381 +0,0 @@
<template>
<div>
<Dialog v-model="modelVisible" title="情报板确认">
<div v-if="type == 1" class="EventAddPlanDialog">
<h4>预案内容</h4>
<dev class="listBox disPid">
<div class="tplItem">
<BoardTplPreview class="boardPreview" boardWH="1400*200" :tpl="automaticData"></BoardTplPreview>
<div class="infoBtnBox infoBtnBoxSm">
<p class="btn">
<el-radio v-model="radio1" :label="1" @input="changeRadio(automaticData)" />
</p>
<!-- <p @click="____onEditTemplate(automaticData)" class="btn btnEdit" /> -->
</div>
</div>
</dev>
<h4>自动生成</h4>
<dev class="listBox disPid">
<div class="tplItem">
<BoardTplPreview class="boardPreview" boardWH="1400*200" :tpl="automaticData"></BoardTplPreview>
<div class="infoBtnBox infoBtnBoxSm">
<p class="btn">
<el-radio v-model="radio1" :label="2" @input="changeRadio(automaticData)" />
</p>
<!-- <p @click="____onEditTemplate(automaticData)" class="btn btnEdit" /> -->
</div>
</div>
</dev>
<h4>情报板模版</h4>
<vuescroll :ops="scrollOptions" class="listBox">
<div v-for="(item) in templateAvailable" :key="item.dictValue">
<h5>{{ item.dictLabel }}</h5>
<div v-for="(itm, indx) in item.list" :key="indx" class="tplItem">
<BoardTplPreview class="boardPreview" boardWH="1400*200" :tpl="itm"></BoardTplPreview>
<div class="infoBtnBox infoBtnBoxSm">
<!-- <p class="btn">
<el-radio v-model="radio1" :label="itm.id" @input="changeRadio(itm)" />
</p> -->
<p @click="____onEditTemplate(itm)" class="btn btnEdit" />
</div>
</div>
</div>
</vuescroll>
</div>
<div v-if="type == 2" class="EventAddPlanDialog">
<div v-for="(item, index) in Object.keys(originalData)" :key="index">
<h4>{{ item }}</h4>
<dev class="listBox disPid">
<div v-for="(it, idx) in originalData[item]" :key="idx" class="tplItem">
<BoardTplPreview class="boardPreview" boardWH="1400*200" :tpl="it"></BoardTplPreview>
</div>
</dev>
</div>
</div>
<template #footer v-if="type == 1">
<Button style="background: #C9C9C9;padding:0 24px;"
@click.native="modelVisible = false, submitting = false">取消</Button>
<Button style="padding:0 24px;" @click.native="handleSubmit" :loading="submitting">确认</Button>
</template>
</Dialog>
<BoardInfoEditor @afterSubmit="____onEditSubmit" :mode="editDialog.mode" :type="editDialog.type"
:visible.sync="editDialog.visible" :screenSize="selectedSize" :tpl="editDialog.tpl"></BoardInfoEditor>
</div>
</template>
<script>
import vuescroll from "vuescroll";
import scrollOptions from "@/common/scrollbar.js";
import BoardTplPreview from "@screen/components/infoBoard/BoardTplPreview.vue";
import BoardInfoEditor from "@screen/components/infoBoard/BoardInfoEditor";
import Dialog from "@screen/components/Dialog/index";
import Button from '@screen/components/Buttons/Button.vue';
import { getTemplateList } from "@/api/board/template";
export default {
name: 'qbbDialog',
components: {
Dialog,
Button,
vuescroll,
BoardTplPreview,
BoardInfoEditor
},
model: {
prop: 'visible',
event: 'close'
},
inject: ['getAutomatic', 'getOriginal'],
props: {
visible: Boolean,
type: {
type: Number,
default: 1
},
info: {
type: Object,
default: () => { }
}
},
data() {
return {
submitting: false,
selectedSize: "",
scrollOptions,
templateAvailable: null,
tplCategory: [],
templateAll: [],
radio1: '',
itmData: {},
automaticData: {},
originalData: {},
editDialog: {
mode: "",
type: "",
visible: false,
tpl: {},
},
}
},
mounted() {
if (this.type == 1) {
this.initData();
} else if (this.type == 2) {
this.getBoardOriginal();
}
},
computed: {
modelVisible: {
get() {
// if (this.visible2) {
// if (this.info && this.info.id) {
// this.radio1 = Number(this.info.id);
// }
// console.log('123', this.getTemplateAutomatic());
// }
return this.visible;
},
set(val) {
this.$emit('close', val)
}
},
},
methods: {
initData() {
if (this.tplCategory.length && this.templateAll.length) {
this.____setAvailableTemplate();
} else {
Promise.all([
this.____getTemplateCategory(),
this.____getAllTemplate(),
]).then((res) => {
this.____setAvailableTemplate();
});
this.getTemplateAutomatic();
}
},
//
____getTemplateCategory() {
return this.getDicts("iot_template_category").then((res) => {
this.tplCategory = res.data;
});
},
//
____getAllTemplate() {
return getTemplateList().then((res) => {
this.templateAll = res.data;
});
},
//
____setAvailableTemplate() {
this.templateAvailable = [];
this.tplCategory.forEach((item, index) => {
let arr = this.templateAll["" + index];
if (arr.length > 0) {
let temp = [];
arr.forEach((tpl) => {
if (tpl.screenSize) {
temp.push(tpl);
}
});
if (temp.length > 0) {
this.templateAvailable.push({
...item,
list: temp,
});
}
}
});
},
____onEditTemplate(tpl) {
this.editDialog = {
visible: true,
mode: "edit",
type: "template",
tpl,
};
},
//
____onEditSubmit(para) {
this.editDialog.tpl = {};
this.editDialog.visible = false;
if (para.type == "device") {
if (para.mode == "edit") {
this.selectedBdMsg[this.boardItemEdtingIndex] = para.data;
} else {
this.selectedBdMsg.push(_.cloneDeep(para.data));
}
} else if (para.mode == "toDevice") {
this.selectedBdMsg.push(_.cloneDeep(para.data));
} else {
this.____refreshPageData(para);
}
},
____refreshPageData(para) {
if (para.type == "template") {
this.____getAllTemplate().then((res) => {
this.____setAvailableTemplate();
});
} else {
}
},
async getTemplateAutomatic() {
let data = await this.getAutomatic();
console.log('dataaaa', data);
this.automaticData = data;
},
async getBoardOriginal() {
let data = await this.getOriginal();
console.log('datbbbbb', data);
this.originalData = data;
},
changeRadio(data) {
this.itmData = data;
},
handleSubmit() {
this.modelVisible = false;
this.$emit('dialogSubmit', this.itmData);
}
}
}
</script>
<style lang="scss" scoped>
.listBox {
padding: 20px;
.tplItem {
margin-right: 14px;
display: flex;
align-items: stretch;
padding-bottom: 10px;
.boardPreview {
border: 1px solid rgba(61, 232, 255, 0.5);
// width: 560px;
// height:80px;
flex: 1;
}
.infoBtnBox {
&.infoBtnBoxSm {
width: 60px;
}
width: 110px;
height: 80px;
display: flex;
margin-left: 10px;
/* // border: solid 1px #05afe3; */
border: 1px solid rgba(61, 232, 255, 0.5);
display: flex;
justify-content: space-around;
align-items: center;
.btn {
background-repeat: no-repeat;
background-size: 100% 100%;
width: 15px;
height: 30px;
&.btnApply {
background-image: url(~@/assets/jihe/images/button/toLeft.svg);
}
&.btnEdit {
background-image: url(~@/assets/jihe/images/button/edit.svg);
}
&.btnDelete {
background-image: url(~@/assets/jihe/images/button/delete.svg);
}
}
i {
font-size: 24px;
color: #666;
padding-left: 4px;
cursor: pointer;
caret-color: rgba(0, 0, 0, 0);
user-select: none;
}
i:hover {
color: #05afe3;
}
.disabledClass {
pointer-events: none;
cursor: auto !important;
color: #ccc;
}
}
}
.controlBox {
margin-top: 10px;
margin-bottom: 10px;
display: flex;
justify-content: center;
}
.el-collapse {
max-height: 100% !important;
overflow: auto;
border-bottom: none;
border-top: none;
padding: 0 0.5vw;
}
}
.disPid {
padding: 0 20px !important;
}
.fade-enter-active,
.fade-leave-active {
transition: opacity .24s;
}
.fade-enter,
.fade-leave-to {
opacity: 0;
}
.EventAddPlanDialog {
gap: 9px;
width: 650px;
height: 700px;
display: flex;
flex-direction: column;
h4 {
margin: 0 0 5px 0;
}
::v-deep {
.el-radio__label {
display: none;
}
}
.form {
flex: 1;
overflow-y: auto;
}
.footer {
display: flex;
justify-content: end;
gap: 15px;
}
}
</style>

2
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/FormEvent/data.js

@ -546,7 +546,7 @@ export const tabConfigList = [
if (value == "3-2") {
facilityType = 1;
} else if (value == "3-3") {
facilityType = 3;
facilityType = 4;
} else if (value == "3-4") {
facilityType = 6;
}

42
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventAnalysis/index.vue

@ -36,9 +36,7 @@
</div>
<!-- "详情"弹出框 -->
<!-- <EventDetailDialog :visible="eventDetailDialogVisible" :formData="detailDialogFormData" :activeName="activeName"
@update:value="handleClose" @queryData="queryData" />
-->
<EventDetailDialog @update:value="handleDialogClose" :visible="eventDetailDialogVisible" :formData="detailDialogFormData" />
</div>
</template>
@ -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,7 +169,6 @@ export default {
},
firstBtnClick(id) {////
console.log("id", id);
if (this.activeName == '-1') {
request({
url: `/perceivedEvents/warning/getWarningById`,//
method: "post",
@ -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) {

Loading…
Cancel
Save