chenxiong 3 lat temu
rodzic
commit
359bedb817
1 zmienionych plików z 8 dodań i 0 usunięć
  1. 8 0
      pages3/polyv/detail.vue

+ 8 - 0
pages3/polyv/detail.vue

@@ -306,6 +306,7 @@ export default {
 			sectionItem:null,
 			businessData:{},
 			menuIndex:[],
+			uploadLock:false, //上传图片
 			isRebuild:false, //视频是否从重修目录点击
 		};
 	},
@@ -1238,6 +1239,7 @@ export default {
 					
 					self.ossAvatarUrl = ''
 				} else {
+					this.uploadLock = false;
 					uni.showToast({
 						icon:'none',
 						title:res.data.msg
@@ -1445,6 +1447,10 @@ export default {
 			 })
 		},
 		async submit() {
+			if(this.uploadLock) {
+				return;
+			}
+			this.uploadLock = true;
 			const waitYS = await this.imageInfos();
 			this.postCoursePhotoRecord().then(res => {
 				this.photoHistoryList.push(this.photoIndex)
@@ -1452,6 +1458,7 @@ export default {
 				//恢复播放
 				
 				this.photoPopup = false;
+				this.uploadLock = false;
 				this.enableAutoRotation = true;
 				var polyvPlayerContext = this.selectComponent('#playerVideo');
 				if (polyvPlayerContext != null) {
@@ -1462,6 +1469,7 @@ export default {
 					title: '上传接口报错,请重新拍照上传' + err,
 					icon: 'none'
 				});
+				this.uploadLock = false;
 				this.openPhoto();
 			})