瀏覽代碼

fix 下载文件

he2802 3 年之前
父節點
當前提交
9181bbe210
共有 1 個文件被更改,包括 8 次插入0 次删除
  1. 8 0
      pages2/verify/input2.vue

+ 8 - 0
pages2/verify/input2.vue

@@ -111,8 +111,16 @@ export default {
 					url: this.$method.splitImgHost(res.data.msg),
 					success: result => {
 						if (result.statusCode === 200) {
+							const filePath = result.tempFilePath
 							console.log(this.$method.splitImgHost(res.data.msg));
 							this.$method.showToast('下载成功');
+							uni.openDocument({
+							    filePath: filePath,
+							    fileType:'doc',
+							    showMenu:true,
+							    success: function (res) {
+							    }
+							  })
 						}
 					}
 				});