问题模块 | 框架类型 | 问题类型 | 操作系统 | 工具版本 |
---|---|---|---|---|
开发者工具 | 小程序 | Bug | Windows | 1.02.1904090 |
- 当前 Bug 的表现(可附上截图)
打印出来的tempFilePath是有后缀名的呀。
- 预期表现:有和tempFilePath一样的路径名。
另外,savefile就是不支持自定义文件名的是吗?
- 复现路径
- 提供一个最简复现 Demo
wx.downloadFile({
url: app.request_url + data.data + "&a=.pptx",
success: function (res) {
console.log(res.tempFilePath)
var filePath = res.tempFilePath;
wx.saveFile({
tempFilePath: filePath,
success: function (res) {
var savedFilePath = res.savedFilePath
console.log(savedFilePath)
},
file:function(res){
console.log(res)
}
})