xwz999
xwz999
  • 发布:2020-10-27 15:38
  • 更新:2020-10-27 15:38
  • 阅读:668

canvasToTempFilePath在小程序中不走回调

分类:HBuilderX

context.draw(false,function(){
//将生成好的图片保存到本地
uni.canvasToTempFilePath({
canvasId: 'mycanvas',
width: 740,
success: function(res) {
var tempFilePath = res.tempFilePath;
console.log(res)
that.imagePath = tempFilePath
that.poster_hidden = false
},
fail: function(res) {
console.log(res)
},
complete: (complete) => {
console.log('complete:',JSON.stringify(complete))
}
},that);
});

2020-10-27 15:38 负责人:无 分享
已邀请:

该问题目前已经被锁定, 无法添加新回复