From c3572ed890da6cbb8066fef191101de4b945f429 Mon Sep 17 00:00:00 2001 From: zhangzhang <1747194829@qq.com> Date: Tue, 20 Feb 2024 11:14:45 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=94=B9=E6=94=B6=E8=B4=B9=E7=AB=99?= =?UTF-8?q?=E5=88=86=E6=9E=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../StatsDialogVisible/index.vue | 816 +++++++++++------- .../components/auditAnalytics/index.vue | 137 +-- .../channelAnalytics/assets/charts.js | 1 + .../eventTypeAnalysis/assets/charts.js | 1 + 4 files changed, 576 insertions(+), 379 deletions(-) diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/StatsDialogVisible/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/StatsDialogVisible/index.vue index 001d3809..33a33126 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/StatsDialogVisible/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/StatsDialogVisible/index.vue @@ -1,393 +1,551 @@ \ No newline at end of file + diff --git a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/index.vue b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/index.vue index bfd838ec..8949a01d 100644 --- a/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/index.vue +++ b/ruoyi-ui/src/views/JiHeExpressway/pages/control/event/governanceAnalysis/components/auditAnalytics/index.vue @@ -1,5 +1,5 @@ @@ -51,42 +62,50 @@ import WgtTitle from "@screen/pages/perception/widgets/title"; import ButtonGradient from "@screen/components/Buttons/ButtonGradient.vue"; import * as echarts from "echarts"; import chartsStatistics from "./assets/charts"; -import { tollStationAnalysis } from "@/api/event/governanceAnalysis" -import StatsDialogVisible from "./StatsDialogVisible/index.vue" +import { tollStationAnalysis } from "@/api/event/governanceAnalysis"; +import StatsDialogVisible from "./StatsDialogVisible/index.vue"; import icon from "./assets/icon.svg"; export default { - name: 'RailWayDay', + name: "RailWayDay", components: { WgtTitle, ButtonGradient, - StatsDialogVisible + StatsDialogVisible, }, data() { return { statsDialogVisible: false, tollBoothsData: [], maxRestrictionNum: null, - maxCloseNum: null - } + maxCloseNum: null, + }; }, - created() { - - }, + created() {}, methods: { handleStats() { - this.statsDialogVisible = true + this.statsDialogVisible = true; }, handleClose() { - this.statsDialogVisible = false + this.statsDialogVisible = false; }, getTollStationAnalysis() { return tollStationAnalysis().then((response) => { - this.tollBoothsData = response.data - this.maxRestrictionNum = Math.max.apply(Math, this.tollBoothsData.map(item => { return item.trafficRestriction })) - this.maxCloseNum = Math.max.apply(Math, this.tollBoothsData.map(item => { return item.trafficRestriction })) - console.log("response", this.maxRestrictionNum, this.maxCloseNum) + this.tollBoothsData = response.data; + this.maxRestrictionNum = Math.max.apply( + Math, + this.tollBoothsData.map((item) => { + return item.trafficRestriction; + }) + ); + this.maxCloseNum = Math.max.apply( + Math, + this.tollBoothsData.map((item) => { + return item.trafficRestriction; + }) + ); + console.log("response", this.maxRestrictionNum, this.maxCloseNum); // let facilityName = [] // let trafficRestriction = [] // let trafficClose = [] @@ -109,20 +128,18 @@ export default { // chartsStatistics.yAxis[0].data = facilityName; // chartsStatistics.series[0].data = trafficClose; // chartsStatistics.series[1].data = trafficRestriction; - - }) - } + }); + }, }, async mounted() { - await this.getTollStationAnalysis() + await this.getTollStationAnalysis(); // const myChart = echarts.init(document.getElementById('auditAnalytics')); // myChart.setOption(chartsStatistics); - }, -} +}; -