From c3fb43d145a6ea5979334bd86be02fae49fa2956 Mon Sep 17 00:00:00 2001
From: 周宾 <2802492122@qq.com>
Date: 星期四, 18 十二月 2025 18:01:58 +0800
Subject: [PATCH] 海川开心-巡检任务列表增加日期字段

---
 src/pages/inspectionUpload/index.vue |   25 ++++++++++++++++++-------
 1 files changed, 18 insertions(+), 7 deletions(-)

diff --git a/src/pages/inspectionUpload/index.vue b/src/pages/inspectionUpload/index.vue
index caf3783..4320a6e 100644
--- a/src/pages/inspectionUpload/index.vue
+++ b/src/pages/inspectionUpload/index.vue
@@ -58,6 +58,10 @@
               <text class="detail-label">鎵ц浜�</text>
               <text class="detail-value">{{ item.inspector }}</text>
             </view>
+			<view class="detail-item">
+			  <text class="detail-label">浠诲姟涓嬪彂鏃ユ湡</text>
+			  <text class="detail-value">{{ item.dateStr }}</text>
+			</view>
           </view>
         </view>
       </view>
@@ -702,10 +706,8 @@
 
 // 鑾峰彇褰撳墠鍒嗙被鐨勬枃浠跺垪琛�
 const getCurrentFiles = () => {
-	console.log('currentUploadType',currentUploadType.value)
   switch (currentUploadType.value) {
     case 'before':
-	console.log('beforeModelValue',beforeModelValue.value)
       return beforeModelValue.value
     case 'after':
       return afterModelValue.value
@@ -817,7 +819,6 @@
     infoData.value.storageBlobDTO = arr;
     // 娣诲姞寮傚父鐘舵�佷俊鎭�
     infoData.value.hasException = hasException.value;
-    
     const result = await uploadInspectionTask({...infoData.value});
     
     // 妫�鏌ユ彁浜ょ粨鏋�
@@ -940,7 +941,19 @@
 const getAttachmentsByType = (typeValue) => {
   return attachmentList.value.filter(file => file.type === typeValue) || []
 }
-
+// 鑾峰彇type鍊�
+const getTabType = () => {
+	switch (currentUploadType.value) {
+	  case 'before':
+	    return 0
+	  case 'after':
+	    return 1
+	  case 'issue':
+	    return 2
+	  default:
+	    return 0
+	}
+}
 // 鑾峰彇褰撳墠鏌ョ湅绫诲瀷鐨勯檮浠�
 const getCurrentViewAttachments = () => {
   switch (currentViewType.value) {
@@ -1299,13 +1312,12 @@
     filePath: filePath,
     name: 'files',
     formData: {
-      type: uploadStatusType.value || 0
+      type: getTabType() || 0
     },
     header: {
       'Authorization': `Bearer ${token}`
     }
   };
-  console.log('uploadParams',uploadParams)
   const uploadTask = uni.uploadFile({
     ...uploadParams,
     success: (res) => {
@@ -1385,7 +1397,6 @@
 
 // 涓婁紶鎴愬姛鍥炶皟
 const handleUploadSuccess = (res, file) => {
-	console.log(res,file)
   if (res.code === 200 && res.data && Array.isArray(res.data) && res.data.length > 0) {
     const uploadedFile = res.data[0];
     

--
Gitblit v1.9.3