From 54517c0d5f539943990888ecf1be8c66f74be332 Mon Sep 17 00:00:00 2001 From: sjl <1716605279@qq.com> Date: Thu, 8 Jan 2026 14:50:29 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A8=B3=E6=80=81=E5=90=88=E6=A0=BC=E7=8E=87?= =?UTF-8?q?=EF=BC=8C=E7=95=B8=E5=8F=98=E7=8E=87=E8=A1=A8=E6=A0=BC=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pqs/database/case/components/drawer.vue | 34 +++++++++---------- src/views/pqs/database/standard/index.vue | 1 + .../area/onlinerate/components/charts.vue | 24 ++++++++++--- .../area/qualifiedRate/index.vue | 4 ++- 4 files changed, 39 insertions(+), 24 deletions(-) diff --git a/src/views/pqs/database/case/components/drawer.vue b/src/views/pqs/database/case/components/drawer.vue index 3ac0344c..d98cfddd 100644 --- a/src/views/pqs/database/case/components/drawer.vue +++ b/src/views/pqs/database/case/components/drawer.vue @@ -3,7 +3,7 @@
+ v-if="information" > 上传常见治理措施 @@ -15,16 +15,16 @@
- - + - - + +
@@ -45,6 +45,7 @@ import { useAdminInfo } from '@/stores/adminInfo' import { ElMessage } from 'element-plus' import { uploadFile, getFileNameAndFilePath, downloadFile } from '@/api/system-boot/file' import { addStandardCase, queryStandardCase } from '@/api/supervision-boot/database/index' +import { previewFile } from '@/utils/fileDownLoad' const adminInfo = useAdminInfo() const drawer = ref(false) const activeName = ref('2') @@ -53,17 +54,14 @@ const url = ref('') const excelOptions = ref({}) const information = adminInfo.roleCode.includes('information_info') -const VITE_FLAG = import.meta.env.VITE_NAME == 'jibei' -const open = (row: any) => { - // console.log('🚀 ~ open ~ row:', row) - // url.value = row + +const urlKey=ref('') +const open = async (row: any) => { drawer.value = true - if(VITE_FLAG){ - url.value = `/api-docx/excelreport` + row - excelOptions.value = { xls: row.split('.')[1] == 'xls' ? true : false } - }else{ + urlKey.value=row + const previewUrl = await previewFile(row); + url.value = previewUrl; - } // getFileNameAndFilePath({ filePath: row }).then(res => { // url.value = res.data.url // }) diff --git a/src/views/pqs/database/standard/index.vue b/src/views/pqs/database/standard/index.vue index b66b001c..05b1f6ab 100644 --- a/src/views/pqs/database/standard/index.vue +++ b/src/views/pqs/database/standard/index.vue @@ -88,6 +88,7 @@ const handleNodeClick = (data: any, node: any) => { if (data?.url != null && data?.url != '') { flag.value = true urlKey.value = data.url + console.log('urlKey.value',urlKey.value) setTimeout(async () => { if(VITE_FLAG){ url.value = `/api-docx/excelreport` + data.url diff --git a/src/views/pqs/harmonicMonitoring/area/onlinerate/components/charts.vue b/src/views/pqs/harmonicMonitoring/area/onlinerate/components/charts.vue index 9c25c99d..c03f4dda 100644 --- a/src/views/pqs/harmonicMonitoring/area/onlinerate/components/charts.vue +++ b/src/views/pqs/harmonicMonitoring/area/onlinerate/components/charts.vue @@ -107,7 +107,7 @@ const tableStore = new TableStore({ var tips = '' for (var i = 0; i < params.length; i++) { - if (params[i].value == 1) { + if (params[i].value == 3.14159) { tips += params[i].name + '
' tips += params[i].marker + '在线率:暂无数据' } else { @@ -143,7 +143,21 @@ const tableStore = new TableStore({ //color:function(d){return "#"+Math.floor(Math.random()*(256*256*256-1)).toString(16);} // 定制显示(按顺序) color: function (params: any) { - if (params.value >= 90) { + if (params.value == 3.14159) { + return new echarts.graphic.LinearGradient( + 0, + 1, + 0, + 0, + [ + { + offset: 1, + color: '#ccc' + } + ], + false + ) + }else if (params.value >= 90) { return new echarts.graphic.LinearGradient( 0, 1, @@ -171,7 +185,7 @@ const tableStore = new TableStore({ ], false ) - } else if (params.value <= 60 && params.value > 1) { + } else if (params.value > 0 && params.value <= 60) { return new echarts.graphic.LinearGradient( 0, 1, @@ -180,12 +194,12 @@ const tableStore = new TableStore({ [ { offset: 1, - color: '#A52a2a' + color: '#CC0100' } ], false ) - } else if (params.value > 0 && params.value <= 1) { + } else if (params.value == 0) { return new echarts.graphic.LinearGradient( 0, 1, diff --git a/src/views/pqs/harmonicMonitoring/area/qualifiedRate/index.vue b/src/views/pqs/harmonicMonitoring/area/qualifiedRate/index.vue index bcfcc7e5..3ce40832 100644 --- a/src/views/pqs/harmonicMonitoring/area/qualifiedRate/index.vue +++ b/src/views/pqs/harmonicMonitoring/area/qualifiedRate/index.vue @@ -77,7 +77,7 @@ - +
@@ -98,6 +98,7 @@ + +