From e7f7c8b537a0d634d9eb404074dce8c8b2570140 Mon Sep 17 00:00:00 2001 From: guanj Date: Fri, 26 Sep 2025 10:59:37 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BE=AE=E8=B0=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/system-boot/file.ts | 143 +-- src/components/table/fieldRender/index.vue | 510 +++++----- src/layouts/admin/components/navMenus.vue | 1 - src/main.ts | 158 +-- .../components/photovoltaic.vue | 4 +- .../pqs/cockpit/setUp/components/popup.vue | 929 +++++++++--------- .../division/components/aListOfLoadData.vue | 7 +- .../components/completenessDetails.vue | 27 +- .../detailed/division/components/detail.vue | 10 +- .../online/yunxingzhuangtai/index.vue | 413 ++++---- .../sagGovern/businessUser/event/sags3D.vue | 534 +++++----- .../businessUser/event/toleranceCurve.vue | 686 ++++++------- .../sagGovern/businessUser/userPopup.vue | 502 +++++----- src/views/system/auth/menu/api.vue | 228 ++--- src/views/system/auth/role/popupForm.vue | 168 ++-- vite.config.ts | 110 ++- 16 files changed, 2227 insertions(+), 2203 deletions(-) diff --git a/src/api/system-boot/file.ts b/src/api/system-boot/file.ts index fc0627ba..bc13ddac 100644 --- a/src/api/system-boot/file.ts +++ b/src/api/system-boot/file.ts @@ -1,71 +1,72 @@ -import createAxios from '@/utils/request' - -const SYSTEM_PREFIX = '/system-boot' - -/** - * 上传文件 - * @param file - */ -export const uploadFile = (file: any, path: string) => { - let form = new FormData() - form.append('file', file) - form.append('path', path) - return createAxios({ - url: SYSTEM_PREFIX + '/file/upload', - method: 'POST', - headers: { - 'Content-Type': 'multipart/form-data' - }, - data: form - }) -} - -/** - * 删除文件 - */ -export const deleteFile = (filePath: string) => { - let form = new FormData() - form.append('filePath', filePath) - return createAxios({ - url: SYSTEM_PREFIX + '/file/delete', - method: 'POST', - data: form - }) -} - -/** - * 下载文件 - */ -export const downloadFile = (filePath: any) => { - // let form = new FormData() - // form.append('filePath', filePath) - return createAxios({ - url: SYSTEM_PREFIX + '/file/download', - method: 'GET', - params: filePath, - responseType: 'blob' - }) -} - -/** - * 获取文件的短期url展示 - */ -export const getFileUrl = (filePath: string) => { - let form = new FormData() - form.append('filePath', filePath) - return createAxios({ - url: SYSTEM_PREFIX + '/file/getFileUrl', - method: 'POST' - }) -} - -/** - * 根据获取文件的一个短期url及文件名 - */ -export const getFileNameAndFilePath = (query: any) => { - return createAxios({ - url: SYSTEM_PREFIX + '/file/getFileVO', - method: 'GET', - params: query - }) -} +import createAxios from '@/utils/request' + +const SYSTEM_PREFIX = '/system-boot' + +/** + * 上传文件 + * @param file + */ +export const uploadFile = (file: any, path: string) => { + let form = new FormData() + form.append('file', file) + form.append('path', path) + return createAxios({ + url: SYSTEM_PREFIX + '/file/upload', + method: 'POST', + headers: { + 'Content-Type': 'multipart/form-data' + }, + data: form + }) +} + +/** + * 删除文件 + */ +export const deleteFile = (filePath: string) => { + let form = new FormData() + form.append('filePath', filePath) + return createAxios({ + url: SYSTEM_PREFIX + '/file/delete', + method: 'POST', + data: form + }) +} + +/** + * 下载文件 + */ +export const downloadFile = (filePath: any) => { + // let form = new FormData() + // form.append('filePath', filePath) + return createAxios({ + url: SYSTEM_PREFIX + '/file/download', + method: 'GET', + params: filePath, + responseType: 'blob' + }) +} + +/** + * 获取文件的短期url展示 + */ +export const getFileUrl = (params:any) => { + let form = new FormData() + // form.append('filePath', filePath) + return createAxios({ + url: SYSTEM_PREFIX + '/file/getFileUrl', + method: 'get', + params + }) +} + +/** + * 根据获取文件的一个短期url及文件名 + */ +export const getFileNameAndFilePath = (query: any) => { + return createAxios({ + url: SYSTEM_PREFIX + '/file/getFileVO', + method: 'GET', + params: query + }) +} diff --git a/src/components/table/fieldRender/index.vue b/src/components/table/fieldRender/index.vue index caf431ee..9ba5309c 100644 --- a/src/components/table/fieldRender/index.vue +++ b/src/components/table/fieldRender/index.vue @@ -1,251 +1,259 @@ - - - - - + + + + + diff --git a/src/layouts/admin/components/navMenus.vue b/src/layouts/admin/components/navMenus.vue index f26055fb..d8836093 100644 --- a/src/layouts/admin/components/navMenus.vue +++ b/src/layouts/admin/components/navMenus.vue @@ -83,7 +83,6 @@ import { useAdminInfo } from '@/stores/adminInfo' import router from '@/router' import globalPopUp from './globalPopUp.vue' import { routePush } from '@/utils/router' -import { fullUrl } from '@/utils/common' import html2canvas from 'html2canvas' import PopupPwd from './popup/password.vue' import AdminInfo from './popup/adminInfo.vue' diff --git a/src/main.ts b/src/main.ts index 53d8dc1d..98304519 100644 --- a/src/main.ts +++ b/src/main.ts @@ -1,79 +1,79 @@ -import { createApp, reactive } from 'vue' -import App from './App.vue' -import router from './router' -import pinia from '@/stores/index' -import { registerIcons } from '@/utils/common' -import mitt from 'mitt' -import VXETable from 'vxe-table' -import XEUtils from 'xe-utils' -import 'vxe-table/lib/style.css' -import ElementPlus from 'element-plus' -import 'element-plus/dist/index.css' -import 'element-plus/theme-chalk/display.css' -import '@fortawesome/fontawesome-free/css/all.css' -import '@/styles/index.scss' -import '@/assets/font/iconfont.css' -import { ElDialog } from 'element-plus' -import BaiduMap from 'vue-baidu-map-3x' -import BaiduMapOffline from 'vue-baidu-map-offline' -import ExcelJS from 'exceljs' -import VXETablePluginExportXLSX from 'vxe-table-plugin-export-xlsx' -// 方式1:NPM 安装,注入 ExcelJS 对象 -VXETable.use(VXETablePluginExportXLSX, { - ExcelJS -}) -window.XEUtils = XEUtils - -// 初始化多语言 -import { setupI18n } from '@/plugins/vueI18n' - -// 引入 form-create -import { setupFormCreate } from '@/plugins/formCreate' - -// 创建实例 -const setupAll = async () => { - const app = createApp(App) - - //开启离线地图 - // app.use(BaiduMapOffline, { - // offline: true, - // offlineConfig: { - // imgext: '.png', - // customstyle: '', - // tiles_dir: '', - // tiles_hybrid: '', - // tiles_self: '', - // tiles_v_dir: '', - // tiles_satellite_dir: '', - // tiles_road_dir: '', - // tiles_v_road_dir: '', - // home: './plugin/offline/' - // } - // }) - app.use(BaiduMap, { - // ak: 'Yp57V71dkOPiXjiN8VdcFRsVELzlVNKK', - ak: 'RpQi6WNFZ9tseKzhdwOQsXwFsoVntnsN', - v: '3.0' - }) - - await setupI18n(app) - app.use(router) - app.use(pinia) - app.use(ElementPlus) - app.use(VXETable) - ;(app._context.components.ElDialog as typeof ElDialog).props.closeOnClickModal.default = false - registerIcons(app) // icons - - app.config.globalProperties.eventBus = mitt() - // 配置全局变量 - app.config.globalProperties.$allVariables = reactive({ - butLoading: false - }) - setupFormCreate(app) - - await router.isReady() - - app.mount('#app') -} - -setupAll() +import { createApp, reactive } from 'vue' +import App from './App.vue' +import router from './router' +import pinia from '@/stores/index' +import { registerIcons } from '@/utils/common' +import mitt from 'mitt' +import VXETable from 'vxe-table' +import XEUtils from 'xe-utils' +import 'vxe-table/lib/style.css' +import ElementPlus from 'element-plus' +import 'element-plus/dist/index.css' +import 'element-plus/theme-chalk/display.css' +import '@fortawesome/fontawesome-free/css/all.css' +import '@/styles/index.scss' +import '@/assets/font/iconfont.css' +import { ElDialog } from 'element-plus' +import BaiduMap from 'vue-baidu-map-3x' +import BaiduMapOffline from 'vue-baidu-map-offline' +import ExcelJS from 'exceljs' +import VXETablePluginExportXLSX from 'vxe-table-plugin-export-xlsx' +// 方式1:NPM 安装,注入 ExcelJS 对象 +VXETable.use(VXETablePluginExportXLSX, { + ExcelJS +}) +window.XEUtils = XEUtils + +// 初始化多语言 +import { setupI18n } from '@/plugins/vueI18n' + +// 引入 form-create +import { setupFormCreate } from '@/plugins/formCreate' + +// 创建实例 +const setupAll = async () => { + const app = createApp(App) + + //开启离线地图 + app.use(BaiduMapOffline, { + offline: true, + offlineConfig: { + imgext: '.png', + customstyle: '', + tiles_dir: '', + tiles_hybrid: '', + tiles_self: '', + tiles_v_dir: '', + tiles_satellite_dir: '', + tiles_road_dir: '', + tiles_v_road_dir: '', + home: './plugin/offline/' + } + }) + app.use(BaiduMap, { + // ak: 'Yp57V71dkOPiXjiN8VdcFRsVELzlVNKK', + ak: 'RpQi6WNFZ9tseKzhdwOQsXwFsoVntnsN', + v: '3.0' + }) + + await setupI18n(app) + app.use(router) + app.use(pinia) + app.use(ElementPlus) + app.use(VXETable) + ;(app._context.components.ElDialog as typeof ElDialog).props.closeOnClickModal.default = false + registerIcons(app) // icons + + app.config.globalProperties.eventBus = mitt() + // 配置全局变量 + app.config.globalProperties.$allVariables = reactive({ + butLoading: false + }) + setupFormCreate(app) + + await router.isReady() + + app.mount('#app') +} + +setupAll() diff --git a/src/views/pqs/bearingCapacity/evaluationList/components/photovoltaic.vue b/src/views/pqs/bearingCapacity/evaluationList/components/photovoltaic.vue index eb5723a6..1c80d1e8 100644 --- a/src/views/pqs/bearingCapacity/evaluationList/components/photovoltaic.vue +++ b/src/views/pqs/bearingCapacity/evaluationList/components/photovoltaic.vue @@ -347,12 +347,12 @@ const onSubmit = async () => { })) // 设置有功功率图表 - setEChart(1, res1.data.data, '有功功率', 'kW') + setEChart(1, res1.data.data, '有功功率', 'W') // 获取无功功率数据并设置图表 const res2 = await queryCarryCapacityQData(form) q_βminMap.value = res2.data.q_βminMap - setEChart(2, res2.data.data, '无功功率', 'kVar') + setEChart(2, res2.data.data, '无功功率', 'Var') // 获取谐波电流数据并设置图表 const res3 = await queryCarryCapacityIData(form) diff --git a/src/views/pqs/cockpit/setUp/components/popup.vue b/src/views/pqs/cockpit/setUp/components/popup.vue index 600486d1..eac422de 100644 --- a/src/views/pqs/cockpit/setUp/components/popup.vue +++ b/src/views/pqs/cockpit/setUp/components/popup.vue @@ -1,464 +1,465 @@ - - - + + + diff --git a/src/views/pqs/harmonicMonitoring/detailed/division/components/aListOfLoadData.vue b/src/views/pqs/harmonicMonitoring/detailed/division/components/aListOfLoadData.vue index defd715b..a063f538 100644 --- a/src/views/pqs/harmonicMonitoring/detailed/division/components/aListOfLoadData.vue +++ b/src/views/pqs/harmonicMonitoring/detailed/division/components/aListOfLoadData.vue @@ -47,7 +47,7 @@ import Table from '@/components/table/index.vue' import BackComponent from '@/components/icon/back/index.vue' import completenessDetails from './completenessDetails.vue' import { genFileId, ElMessage } from 'element-plus' -import { uploadUserData ,deleteUserDataByIds} from '@/api/advance-boot/division' +import { uploadUserData, deleteUserDataByIds } from '@/api/advance-boot/division' import type { UploadInstance, UploadProps, UploadRawFile } from 'element-plus' defineOptions({ name: 'division/aListOfLoadData' @@ -78,6 +78,9 @@ const tableStore = new TableStore({ title: '完整性详情', type: 'primary', icon: 'el-icon-Plus', + disabled: row => { + return row.integrity == 1 + }, render: 'basicButton', click: row => { completenessDetailsRef.value.open(row.id) @@ -129,7 +132,7 @@ const submitupload = () => { ElMessage.warning('请上传文件!') return } - ElMessage.info('上传中,请稍等...') + ElMessage.info('上传中,请稍等...') const formData = new FormData() formData.append('file', fileList.value[0].raw) loading.value = true diff --git a/src/views/pqs/harmonicMonitoring/detailed/division/components/completenessDetails.vue b/src/views/pqs/harmonicMonitoring/detailed/division/components/completenessDetails.vue index f53b8aed..f9d39087 100644 --- a/src/views/pqs/harmonicMonitoring/detailed/division/components/completenessDetails.vue +++ b/src/views/pqs/harmonicMonitoring/detailed/division/components/completenessDetails.vue @@ -1,5 +1,4 @@ - diff --git a/src/views/pqs/harmonicMonitoring/detailed/division/components/detail.vue b/src/views/pqs/harmonicMonitoring/detailed/division/components/detail.vue index 2a35edea..360bdfaa 100644 --- a/src/views/pqs/harmonicMonitoring/detailed/division/components/detail.vue +++ b/src/views/pqs/harmonicMonitoring/detailed/division/components/detail.vue @@ -5,7 +5,7 @@ - {{ query.name || '' }} + {{ query.name || '' }} @@ -21,9 +21,11 @@
diff --git a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/yunxingzhuangtai/index.vue b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/yunxingzhuangtai/index.vue index 065960d1..b69caf25 100644 --- a/src/views/pqs/harmonicMonitoring/monitoringPoint/online/yunxingzhuangtai/index.vue +++ b/src/views/pqs/harmonicMonitoring/monitoringPoint/online/yunxingzhuangtai/index.vue @@ -1,202 +1,211 @@ - - - + + + diff --git a/src/views/pqs/voltageSags/sagGovern/businessUser/event/sags3D.vue b/src/views/pqs/voltageSags/sagGovern/businessUser/event/sags3D.vue index 0a914be8..3018b6ff 100644 --- a/src/views/pqs/voltageSags/sagGovern/businessUser/event/sags3D.vue +++ b/src/views/pqs/voltageSags/sagGovern/businessUser/event/sags3D.vue @@ -1,267 +1,267 @@ - - - - + + + + diff --git a/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue b/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue index 072ee05f..7ea95bfe 100644 --- a/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue +++ b/src/views/pqs/voltageSags/sagGovern/businessUser/event/toleranceCurve.vue @@ -1,343 +1,343 @@ - - - - - + + + + + diff --git a/src/views/pqs/voltageSags/sagGovern/businessUser/userPopup.vue b/src/views/pqs/voltageSags/sagGovern/businessUser/userPopup.vue index 284df0dc..c6b49f17 100644 --- a/src/views/pqs/voltageSags/sagGovern/businessUser/userPopup.vue +++ b/src/views/pqs/voltageSags/sagGovern/businessUser/userPopup.vue @@ -1,250 +1,252 @@ - - - - + + + + diff --git a/src/views/system/auth/menu/api.vue b/src/views/system/auth/menu/api.vue index 9d2dfeb7..63d49bff 100644 --- a/src/views/system/auth/menu/api.vue +++ b/src/views/system/auth/menu/api.vue @@ -1,115 +1,115 @@ - - \ No newline at end of file diff --git a/src/views/system/auth/role/popupForm.vue b/src/views/system/auth/role/popupForm.vue index 5da9876e..ad66d533 100644 --- a/src/views/system/auth/role/popupForm.vue +++ b/src/views/system/auth/role/popupForm.vue @@ -1,84 +1,84 @@ - - + + diff --git a/vite.config.ts b/vite.config.ts index 948aa740..aa599ecc 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -1,54 +1,56 @@ -import { defineConfig } from 'vite' -import vue from '@vitejs/plugin-vue' -import vueJsx from '@vitejs/plugin-vue-jsx' -import AutoImport from 'unplugin-auto-import/vite' -import { svgBuilder } from '/@/components/icon/svg/index' - -import path from 'path' - -const nodeResolve = (dir: string): any => path.resolve(__dirname, '.', dir) -// https://vitejs.dev/config/ -export default defineConfig({ - plugins: [ - vue(), - svgBuilder('./src/assets/icons/'), - vueJsx(), - AutoImport({ - //自动引入 - imports: ['vue', 'vue-router', 'pinia'] - }) - ], - server: { - host: '0.0.0.0', - open: true, - proxy: { - '/api': { - // target: 'http://10.95.53.49:10215', //海南服务器ip - // target: 'http://10.118.135.128:10215', ///hsw - target: 'http://192.168.1.29:10215', ///hsw - // target: 'http://10.119.65.152:10215', //数据中心 - changeOrigin: true, - rewrite: path => path.replace(/^\/api/, '') //路径重写,把'/api'替换为'' - }, - '/api-docx': { - // 文件服务器地址 - target: 'http://192.168.1.22:9009', - changeOrigin: true, - rewrite: path => path.replace(/^\/api-docx/, '') - }, - '/map': { - // target: 'http://10.95.53.49:8088', //海南服务器ip - target: 'http://192.168.1.125:9009', //hsw - // target: 'http://192.168.1.125:8088', //数据中心 - changeOrigin: true - } - } - }, - resolve: { - alias: { - '/@': nodeResolve('.src'), - '@': nodeResolve('src'), - '~': nodeResolve('public') - } - } -}) +import { defineConfig } from 'vite' +import vue from '@vitejs/plugin-vue' +import vueJsx from '@vitejs/plugin-vue-jsx' +import AutoImport from 'unplugin-auto-import/vite' +import { svgBuilder } from '/@/components/icon/svg/index' + +import path from 'path' + +const nodeResolve = (dir: string): any => path.resolve(__dirname, '.', dir) +// https://vitejs.dev/config/ +export default defineConfig({ + plugins: [ + vue(), + svgBuilder('./src/assets/icons/'), + vueJsx(), + AutoImport({ + //自动引入 + imports: ['vue', 'vue-router', 'pinia'] + }) + ], + server: { + host: '0.0.0.0', + open: true, + proxy: { + '/api': { + // target: 'http://10.95.53.49:10215', //海南服务器ip + // target: 'http://10.118.135.128:10215', ///hsw + target: 'http://192.168.1.67:10215', ///hsw + // target: 'http://192.168.1.68:10215', ///hsw + // target: 'http://10.119.65.152:10215', //数据中心 + changeOrigin: true, + rewrite: path => path.replace(/^\/api/, '') //路径重写,把'/api'替换为'' + }, + '/api-docx': { + // 文件服务器地址 + target: 'http://192.168.1.68:9009', + changeOrigin: true, + rewrite: path => path.replace(/^\/api-docx/, '') + }, + '/map': { + // target: 'http://10.95.53.49:8088', //海南服务器ip + target: 'http://192.168.1.125:9009', //hsw + // target: 'http://192.168.1.125:8088', //数据中心 + changeOrigin: true + } + } + }, + resolve: { + alias: { + '/@': nodeResolve('.src'), + '@': nodeResolve('src'), + '~': nodeResolve('public') + } + } +}) + \ No newline at end of file