From 0b41710b70c992893591a5b23f68c0a65a7b415e Mon Sep 17 00:00:00 2001 From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com> Date: Mon, 14 Apr 2025 11:37:37 +0800 Subject: [PATCH] =?UTF-8?q?=E8=87=AA=E6=B5=8B=E4=BF=AE=E5=A4=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .env.development | 2 +- src/hooks/useCommon.js | 5 +- src/main.js | 4 +- .../components/photo-recent.vue | 97 +++++++++++++++++-- .../components/photo-total.vue | 8 +- src/pages/comprehensiveQuery/index.vue | 9 +- .../components/addAndEditForm.vue | 19 +++- .../coordinatePhotos/upload-record/index.vue | 36 +++++-- .../components/addAndEditForm.vue | 17 +++- .../importantMatters/upload-record/index.vue | 22 +++-- src/pages/login/index.vue | 4 +- .../components/addAndEditForm.vue | 18 +++- .../qualityInspection/upload-record/index.vue | 14 ++- .../components/addAndEditForm.vue | 19 +++- .../safetyMeasure/upload-record/index.vue | 23 +++-- .../components/addAndEditForm.vue | 32 +++++- .../safetyViolations/upload-record/index.vue | 16 ++- src/services/comprehensiveQuery.js | 12 +++ src/stores/modules/common.js | 2 +- src/utils/encrypt.js | 3 +- src/utils/env.js | 26 ----- 21 files changed, 301 insertions(+), 87 deletions(-) delete mode 100644 src/utils/env.js diff --git a/.env.development b/.env.development index 468692c..b661567 100644 --- a/.env.development +++ b/.env.development @@ -1 +1 @@ -VITE_API_BASE_URL = /api +VITE_API_BASE_URL = http://192.168.0.14:11997 diff --git a/src/hooks/useCommon.js b/src/hooks/useCommon.js index e80bb6c..b84e9dc 100644 --- a/src/hooks/useCommon.js +++ b/src/hooks/useCommon.js @@ -1,7 +1,8 @@ -import { useCommonStore } from '@/stores/index' -const commonStore = useCommonStore() +import { useCommonStore } from '@/stores' + export function useCommon() { + const commonStore = useCommonStore() // 获取项目数据(自动处理缓存) const getProjectList = async () => { return await commonStore.getProjectList() diff --git a/src/main.js b/src/main.js index 60e57d1..2ba088d 100644 --- a/src/main.js +++ b/src/main.js @@ -1,11 +1,11 @@ import { createSSRApp } from 'vue' +import App from './App.vue' import pinia from './stores/index' import uviewPlus from 'uview-plus' -import App from './App.vue' export function createApp() { const app = createSSRApp(App) - app.use(pinia) app.use(uviewPlus) + app.use(pinia) return { app, } diff --git a/src/pages/comprehensiveQuery/components/photo-recent.vue b/src/pages/comprehensiveQuery/components/photo-recent.vue index 23b87ef..135ecb3 100644 --- a/src/pages/comprehensiveQuery/components/photo-recent.vue +++ b/src/pages/comprehensiveQuery/components/photo-recent.vue @@ -17,7 +17,8 @@ width="100%" height="120" :src="icon.imgUrl" - @tap="onHandleImage(icon.imgUrl)" + mode="aspectFit" + @tap="onHandleImage(icon)" /> {{ icon.uploadTime }} @@ -42,7 +43,7 @@ - + 原图下载 水印下载 @@ -64,13 +65,24 @@