wangguoyu пре 21 часа
родитељ
комит
63f6cf9204
2 измењених фајлова са 3 додато и 9 уклоњено
  1. 2 8
      components/sharePopUp/index.vue
  2. 1 1
      pages/admin/haibao/haibaoInfo.vue

+ 2 - 8
components/sharePopUp/index.vue

@@ -84,7 +84,7 @@
 	// 选择分享方式
 	const select = (scene) => {
 		//emit('select', scene)
-
+		console.log('props.currentPageprops.currentPageprops.currentPage',props.currentPage);
 		try {
 			if (props.currentPage == 'haibao') {
 				shareToWeChatHaibao(scene)
@@ -138,6 +138,7 @@
 	}
 	// 分享针对海报
 	const shareToWeChatHaibao = (scene) => {
+		console.log('12311');
 		uni.downloadFile({
 			url: props.image, // 你的网络图片地址
 			success: (downloadRes) => {
@@ -173,13 +174,6 @@
 				console.log('分享配置:', shareConfig)
 				uni.share(shareConfig)
 			}
-		}).fail(() => {
-			// 其他错误
-			uni.showToast({
-				title: '海报分享失败,请检测网络状态',
-				icon: 'none',
-				duration: 3000
-			})
 		})
 	}
 

+ 1 - 1
pages/admin/haibao/haibaoInfo.vue

@@ -21,7 +21,7 @@
 			<view v-else class="loading-text">暂无数据</view>
 		</view>
 	</view>
-	<share-popup ref="sharePopupRef" title="海报" :image="haibaoImage" :currentPage="haibao" type="2" @success="onShareSuccess" />
+	<share-popup ref="sharePopupRef" title="海报" :image="haibaoImage" :currentPage="'haibao'" type="2" @success="onShareSuccess" />
 </template>
 
 <script setup>