瀏覽代碼

Merge branch 'feature_20260330_拜访连拍速度优化' into uat(dev)

zhujindu 15 小時之前
父節點
當前提交
29e06c765b
共有 1 個文件被更改,包括 3 次插入2 次删除
  1. 3 2
      src/views/deviceWithin/taskPhotoTaking.vue

+ 3 - 2
src/views/deviceWithin/taskPhotoTaking.vue

@@ -294,7 +294,7 @@ export default {
         this.taskPhotoRecognitionResult = item.taskPhotoRecognitionResult;
         this.taskPhotoRecognitionResult = item.taskPhotoRecognitionResult;
       });
       });
     },
     },
-    async onSubmit() {
+    onSubmit() {
       this.toastLoading(0, '提交中,请稍候...', true);
       this.toastLoading(0, '提交中,请稍候...', true);
       const taskPhoto = this.$refs.taskPhoto && this.$refs.taskPhoto[0];
       const taskPhoto = this.$refs.taskPhoto && this.$refs.taskPhoto[0];
       let formData = {
       let formData = {
@@ -317,14 +317,15 @@ export default {
       };
       };
       if (this.userInfo.photoMethod == '1') {
       if (this.userInfo.photoMethod == '1') {
         formData.mediaInfos = [];
         formData.mediaInfos = [];
+        this.addCollection(formData);
       } else {
       } else {
         this.mediaInfos = [];
         this.mediaInfos = [];
         this.syncUpload(taskPhoto.imgArr, () => {
         this.syncUpload(taskPhoto.imgArr, () => {
           this.toastLoading().clear();
           this.toastLoading().clear();
           formData.mediaInfos = this.mediaInfos;
           formData.mediaInfos = this.mediaInfos;
+          this.addCollection(formData);
         });
         });
       }
       }
-      await this.addCollection(formData);
     },
     },
     syncUpload(imgArr, callback) {
     syncUpload(imgArr, callback) {
       if (!imgArr.length) {
       if (!imgArr.length) {