From c2701247a0d5305e305c326c166ab978a7966bcb Mon Sep 17 00:00:00 2001
From: ZN <zhang_12370@163.com>
Date: 星期一, 30 三月 2026 15:59:20 +0800
Subject: [PATCH] 设备巡检的图片上传功能添加
---
src/pages/inspectionUpload/index.vue | 21 +++++++++++++++++++--
1 files changed, 19 insertions(+), 2 deletions(-)
diff --git a/src/pages/inspectionUpload/index.vue b/src/pages/inspectionUpload/index.vue
index dd076b0..0a3fc94 100644
--- a/src/pages/inspectionUpload/index.vue
+++ b/src/pages/inspectionUpload/index.vue
@@ -27,6 +27,17 @@
}">
鎵爜涓婁紶
</u-button>
+ <u-button type="primary"
+ size="small"
+ @click.stop="startUploadForTask(item)"
+ :customStyle="{
+ borderRadius: '15px',
+ height: '30px',
+ fontSize: '12px',
+ marginRight: '8px'
+ }">
+ 鍥剧墖涓婁紶
+ </u-button>
<u-button type="success"
size="small"
@click.stop="viewAttachments(item)"
@@ -408,7 +419,7 @@
// 璁$畻涓婁紶URL
const uploadFileUrl = computed(() => {
- const baseUrl = "http://114.132.189.42:9030";
+ const baseUrl = config.baseUrl;
return baseUrl + uploadConfig.action;
});
@@ -855,6 +866,12 @@
}
};
+ // 鍥剧墖涓婁紶(鍙�夋嫨鍥剧墖涓婁紶鎴栬�呮槸鐩告満鎷嶇収)
+ const startUploadForTask = async (task, type) => {
+ // 鐩存帴鎵撳紑涓婁紶寮圭獥
+ openUploadDialog(task);
+ };
+
// 鏌ョ湅闄勪欢
const viewAttachments = async task => {
try {
@@ -971,7 +988,7 @@
};
// 鏂囦欢璁块棶鍩虹鍩燂紙鍚庣瑕佹眰鍓嶇紑锛�
- const filePreviewBase = "http://114.132.189.42:9098";
+ const filePreviewBase = config.fileUrl;
// 灏嗗悗绔繑鍥炵殑鏂囦欢鍦板潃瑙勮寖鎴愬彲璁块棶URL
// 鍏煎鍦烘櫙锛�
--
Gitblit v1.9.3