From fdd3687e392462822226fd4e0ffc20c92a1caaba Mon Sep 17 00:00:00 2001
From: zhangwencui <1064582902@qq.com>
Date: 星期一, 02 十一月 2026 16:08:30 +0800
Subject: [PATCH] refactor(app): 移除页面附件上传功能

---
 src/pages/crm/customer/detail.vue |   33 +--------------------------------
 1 files changed, 1 insertions(+), 32 deletions(-)

diff --git a/src/pages/crm/customer/detail.vue b/src/pages/crm/customer/detail.vue
index aa23080..5ebc095 100644
--- a/src/pages/crm/customer/detail.vue
+++ b/src/pages/crm/customer/detail.vue
@@ -395,36 +395,8 @@
       },
     });
   }
-  async function chooseFile() {
-    if (!state.accessToken || uploading.value) return;
-    uni.chooseFile({
-      count: 10 - follow.blobIds.length,
-      success: async result => {
-        uploading.value = true;
-        try {
-          for (const file of result.tempFiles || []) {
-            if (!file.path) continue;
-            const attachment = await uploadCrmFile(state.accessToken!, file.path);
-            follow.blobIds.push(attachment.id);
-            follow.attachments.push(attachment);
-          }
-        } catch (error) {
-          uni.showToast({
-            title: error instanceof Error ? error.message : "闄勪欢涓婁紶澶辫触",
-            icon: "none",
-          });
-        } finally {
-          uploading.value = false;
-        }
-      },
-    });
-  }
   function removeImage(index: number) {
     follow.picUrls.splice(index, 1);
-  }
-  function removeFile(index: number) {
-    follow.blobIds.splice(index, 1);
-    follow.attachments.splice(index, 1);
   }
   async function saveFollow() {
     if (
@@ -614,10 +586,7 @@
                        @click="uni.previewImage({urls:follow.picUrls,current:url})" /><text @click="removeImage(index)">脳</text>
               </view>
             </view>
-            <view class="upload-head"><text>闄勪欢</text><text @click="chooseFile">涓婁紶闄勪欢</text></view>
-            <view v-for="(file,index) in follow.attachments"
-                  :key="file.id"
-                  class="file"><text>{{file.name||`闄勪欢 #${file.id}`}}</text><text @click="removeFile(index)">鍒犻櫎</text></view><button class="primary"
+            <button class="primary"
                     :loading="saving||uploading"
                     @click="saveFollow">淇濆瓨璺熻繘</button>
           </view>

--
Gitblit v1.9.3