8.28修改文字
This commit is contained in:
@@ -255,7 +255,7 @@ Component({
|
||||
},
|
||||
goReport(event){
|
||||
const url=event.currentTarget.dataset.url;
|
||||
const randfile = new Date().getTime() + '检测报告';
|
||||
const randfile = new Date().getTime() + '检测报告';
|
||||
const newPath = `${wx.env.USER_DATA_PATH}/${randfile}`;
|
||||
wx.downloadFile({
|
||||
// 示例 url,并非真实存在
|
||||
@@ -264,12 +264,27 @@ Component({
|
||||
success: function (res) {
|
||||
//const filePath = res.tempFilePath
|
||||
wx.openDocument({
|
||||
fileType:"pdf",
|
||||
showMenu:true,
|
||||
filePath: newPath,
|
||||
success: function (res) {
|
||||
console.log('打开文档成功')
|
||||
},
|
||||
fail:function(error){
|
||||
wx.showToast({
|
||||
title:res,
|
||||
icon:"none"
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
fail:function(error){
|
||||
wx.showToast({
|
||||
title:error,
|
||||
icon:"none"
|
||||
})
|
||||
}
|
||||
|
||||
})
|
||||
},
|
||||
goSick(event){
|
||||
|
||||
Reference in New Issue
Block a user