From 0487f168855129aaf8083b08e62ee6b8f8637c84 Mon Sep 17 00:00:00 2001 From: loveflow <5269966+loveflow@user.noreply.gitee.com> Date: Wed, 3 Apr 2024 22:40:46 +0800 Subject: [PATCH] update --- .../enterpriseTopic/dangerTransport/index.js | 6 ++-- src/loveflow/components/echart/bar/four.vue | 6 ++-- src/loveflow/mixins/tableListMixins.js | 5 ++-- .../enterpriseTopic/components/tableWrap.vue | 10 +++++++ .../dangerTransport/carDetail.vue | 30 +++++++++++++++++-- .../enterpriseTopic/dangerTransport/index.vue | 22 +++++++------- .../enterpriseTopic/inSecurity/ycTable.vue | 11 ++++--- src/views/enterpriseTopic/listGoods/index.vue | 30 +++++++++++++++---- .../personSafety/flowPerson.vue | 3 ++ .../enterpriseTopic/personSafety/screen.vue | 4 +-- .../personSafety/workPerson.vue | 3 ++ src/views/enterpriseTopic/roadSafety/dpie.vue | 16 ++++++---- .../enterpriseTopic/roadSafety/index.vue | 29 ++++++++++-------- .../enterpriseTopic/roadSafety/qyzgTable.vue | 25 +++++++++------- .../enterpriseTopic/roadSafety/ytTable.vue | 17 ++++++----- 15 files changed, 150 insertions(+), 67 deletions(-) diff --git a/src/api/enterpriseTopic/dangerTransport/index.js b/src/api/enterpriseTopic/dangerTransport/index.js index 867262b..b65974d 100644 --- a/src/api/enterpriseTopic/dangerTransport/index.js +++ b/src/api/enterpriseTopic/dangerTransport/index.js @@ -1,9 +1,10 @@ import request from "@/utils/request"; //车辆详情 -export function vehicledetail() { +export function vehicledetail(params) { return request({ url: "/special/vehicle/vehicledetail", method: "post", + params, }); } //车辆的违规信息统计 @@ -21,9 +22,10 @@ export function violations() { }); } //获取统计数 -export function nums() { +export function nums(params) { return request({ url: "/special/vehicle/nums", method: "get", + params, }); } diff --git a/src/loveflow/components/echart/bar/four.vue b/src/loveflow/components/echart/bar/four.vue index 1b381d3..e3786f4 100644 --- a/src/loveflow/components/echart/bar/four.vue +++ b/src/loveflow/components/echart/bar/four.vue @@ -65,7 +65,7 @@ export default { }, }, yAxis: { - name:"单位:吨", + name: "单位:吨", type: "value", splitLine: { show: true, @@ -86,7 +86,7 @@ export default { type: "bar", barWidth: 20, color: this.chartObj.color[0][0], - data: this.chartObj.yData1, + data: this.chartObj.yData[0], label: { show: false, position: "top", @@ -131,7 +131,7 @@ export default { type: "bar", barWidth: 20, color: this.chartObj.color[1][0], - data: this.chartObj.yData2, + data: this.chartObj.yData[1], label: { show: false, position: "top", diff --git a/src/loveflow/mixins/tableListMixins.js b/src/loveflow/mixins/tableListMixins.js index 2de7cde..1340838 100644 --- a/src/loveflow/mixins/tableListMixins.js +++ b/src/loveflow/mixins/tableListMixins.js @@ -53,8 +53,9 @@ export const tableListMixins = { this.dataSource = []; return; } - this.dataSource = res.data || []; - if (res.total) { + this.dataSource = (res && res.data) || []; + + if (res && res.total) { this.ipagination.total = res.total; } else { this.ipagination.total = 0; diff --git a/src/views/enterpriseTopic/components/tableWrap.vue b/src/views/enterpriseTopic/components/tableWrap.vue index 0b7985f..b1f8d98 100644 --- a/src/views/enterpriseTopic/components/tableWrap.vue +++ b/src/views/enterpriseTopic/components/tableWrap.vue @@ -39,6 +39,12 @@ export default { return ""; }, }, + param: { + type: Object, + default: () => { + return {}; + }, + }, }, data() { return { @@ -50,6 +56,10 @@ export default { }, created() { this.url.list = this.dataUrl; + if (!this.url.list) { + return; + } + this.queryParam = { ...this.param }; this.ipagination.pageSize = 10000; this.ipagination.pageSizes = []; this.ipagination.layout = "total, prev, pager, next"; diff --git a/src/views/enterpriseTopic/dangerTransport/carDetail.vue b/src/views/enterpriseTopic/dangerTransport/carDetail.vue index 8f85146..5b73793 100644 --- a/src/views/enterpriseTopic/dangerTransport/carDetail.vue +++ b/src/views/enterpriseTopic/dangerTransport/carDetail.vue @@ -4,7 +4,14 @@