Browse Source

感知事件检测

wangqin
zhoule 1 year ago
parent
commit
42cb14d428
  1. 6
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/dailyDisposal/index.vue
  2. 1
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/eventQuery/assets/charts3.js
  3. 42
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/eventQuery/index.vue
  4. 4
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/eventSource/index.vue
  5. 32
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/railwayDay/index.vue
  6. 2
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/typeAnalysis/index.vue
  7. 12
      ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/index.vue

6
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/dailyDisposal/index.vue

@ -140,9 +140,9 @@ export default {
context.lineWidth = 1; // 线 context.lineWidth = 1; // 线
// //
// drawRoundRect(context, 260, 50, 120, 24, 12, gr) drawRoundRect(context, 260, 50, 120, 24, 12, gr)
// drawRoundRect(context, 260, 78, 120, 24, 12, gr) drawRoundRect(context, 260, 78, 120, 24, 12, gr)
// drawRoundRect(context, 260, 106, 120, 24, 12, gr) drawRoundRect(context, 260, 106, 120, 24, 12, gr)
}); });
}); });

1
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/eventQuery/assets/charts3.js

@ -125,7 +125,6 @@ let options = {
opacity: 0.6, opacity: 0.6,
color: function (params) { color: function (params) {
var a = params.name; var a = params.name;
console.log("==========a=============", a);
if (a == "6月") { if (a == "6月") {
return new echarts.graphic.LinearGradient( return new echarts.graphic.LinearGradient(
0, 0,

42
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/eventQuery/index.vue

@ -392,17 +392,51 @@ export default {
if (res.code == 200) { if (res.code == 200) {
let data = res.data; let data = res.data;
if (this.year != "quarter") { if (this.year != "quarter") {
const maxObject = data.filter(it => it.sectionNumber > 0).reduce((prev, current) => (current.sectionNumber > prev.sectionNumber ? current : prev));
let zhs = []; let zhs = [];
let values = []; let values1 = [];
let values2 = [];
data.forEach((it) => { data.forEach((it) => {
if (it.sectionNumber > 0) { if (it.sectionNumber > 0) {
values.push(it.sectionNumber); values2.push(it.sectionNumber);
zhs.push(it.stakeMarkId); zhs.push(it.stakeMarkId);
if (maxObject && maxObject.sectionNumber == it.sectionNumber) {
values1.push({
value: it.sectionNumber,
itemStyle: {
color: {
type: 'linear',
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [{
offset: 0, color: '#01D5BC' // 0%
}, {
offset: 1, color: '#003B4E' // 100%
}],
global: false // false
},
borderRadius: 6
},
})
} else {
values1.push({
value: it.sectionNumber,
itemStyle: {
borderRadius: 6
},
})
}
} }
}) })
chart3.xAxis.data = zhs; chart3.xAxis.data = zhs;
chart3.series[0].data = values; chart3.series[0].data = values1;
chart3.series[1].data = values; chart3.series[1].data = values2;
} else { } else {
let zhs = []; let zhs = [];
let values = []; let values = [];

4
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/eventSource/index.vue

@ -91,7 +91,7 @@ export default {
} }
number.push(it.number); number.push(it.number);
// drawRoundRect(context, 241, 37 + (index * 27), 134, 20, 12, gr); drawRoundRect(context, 231, 37 + (index * 27), 138, 20, 12, gr);
}) })
let colorList = ['#006EDF', '#00FF00', '#FFC30D', '#FF8400', '#1DA7FF', '#2967EA']; let colorList = ['#006EDF', '#00FF00', '#FFC30D', '#FF8400', '#1DA7FF', '#2967EA'];
let lengData = []; let lengData = [];
@ -154,7 +154,7 @@ export default {
const context = canvas.getContext('2d'); const context = canvas.getContext('2d');
// //
let gr = context.createLinearGradient(247, 63, 450, 0); let gr = context.createLinearGradient(230, 0, 360, 0);
gr.addColorStop(1, 'rgba(92,197,255,0)'); gr.addColorStop(1, 'rgba(92,197,255,0)');
gr.addColorStop(0, 'rgba(92,197,255,0.3)'); gr.addColorStop(0, 'rgba(92,197,255,0.3)');
// drawRoundRect(context, 241, 37, 134, 20, 12, gr); // drawRoundRect(context, 241, 37, 134, 20, 12, gr);

32
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/railwayDay/index.vue

@ -41,10 +41,40 @@ export default {
if (data.length > 0) { if (data.length > 0) {
let texts = []; let texts = [];
let datas = []; let datas = [];
const maxObject = data.reduce((prev, current) => (current.number > prev.number ? current : prev));
data.forEach(it => { data.forEach(it => {
texts.push(it.sectionName); texts.push(it.sectionName);
datas.push(it.number);
if (it.number == maxObject.number) {
datas.push({
value: it.number,
itemStyle: {
color: {
type: 'linear',
x: 0,
y: 0,
x2: 0,
y2: 1,
colorStops: [{
offset: 0, color: '#0469FF' // 0%
}, {
offset: 1, color: '#699CFF' // 100%
}],
global: false // false
},
borderRadius: 6
},
});
} else {
datas.push({
value: it.number,
itemStyle: {
borderRadius: 6
},
});
}
}); });
chartsStatistics.xAxis.data = texts; chartsStatistics.xAxis.data = texts;

2
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/components/typeAnalysis/index.vue

@ -117,7 +117,7 @@ export default {
}); });
} }
drawRoundRect(context, 260, 8 + i * 28, 120, 24, 12, gr) drawRoundRect(context, 254, 8 + i * 28, 120, 24, 12, gr)
} }
chartsStatistics.legend.data = typeAnalysisData?.map(x => x.name); chartsStatistics.legend.data = typeAnalysisData?.map(x => x.name);

12
ruoyi-ui/src/views/JiHeExpressway/pages/perception/eventDetection/index.vue

@ -59,6 +59,7 @@
margin: auto; margin: auto;
margin-top: 15px; margin-top: 15px;
} }
.content { .content {
width: 98%; width: 98%;
margin: auto; margin: auto;
@ -66,13 +67,14 @@
flex: 1; flex: 1;
pointer-events: none; pointer-events: none;
margin-top: 19px; margin-top: 19px;
>div { >div {
pointer-events: auto; pointer-events: auto;
} }
.content-l { .content-l {
width: calc(100% / 4 - 25px * 3); width: calc(100% / 4 - 25px * 3);
min-width:460px; min-width: 475px;
margin-right: 15px; margin-right: 15px;
} }
@ -90,10 +92,12 @@
margin-bottom: 15px; margin-bottom: 15px;
} }
} }
.content-r { .content-r {
width: 49.4%; width: 49.4%;
} }
} }
.foot { .foot {
width: 98%; width: 98%;
margin: auto; margin: auto;
@ -102,6 +106,7 @@
flex: 1; flex: 1;
pointer-events: none; pointer-events: none;
margin-top: 0px; margin-top: 0px;
>div { >div {
pointer-events: auto; pointer-events: auto;
} }
@ -114,13 +119,14 @@
.foot-l { .foot-l {
width: 726px; width: 726px;
} }
.foot-m { .foot-m {
width: 613px; width: 613px;
} }
.foot-r { .foot-r {
width: 493px; width: 493px;
} }
} }
} }</style>
</style>
Loading…
Cancel
Save