Browse Source

[优化] 商品详情页生成海报

threedate
邓平艺 4 years ago
parent
commit
d3fb0a647a
  1. 4
      pages/goodsDetail/index.vue

4
pages/goodsDetail/index.vue

@ -311,6 +311,7 @@
context.draw(); context.draw();
// //
setTimeout(function() { setTimeout(function() {
wx.hideToast();
wx.canvasToTempFilePath({ wx.canvasToTempFilePath({
canvasId: 'mycanvas', canvasId: 'mycanvas',
success: function(res) { success: function(res) {
@ -354,12 +355,12 @@
}, },
formSubmit() { formSubmit() {
var that = this; var that = this;
that.$u.throttle(() => {
wx.showToast({ wx.showToast({
title: '生成海报中...', title: '生成海报中...',
icon: 'loading', icon: 'loading',
duration: 1000 duration: 1000
}); });
wx.hideToast()
console.log(that.onceCode) console.log(that.onceCode)
console.log(that.backgroundImg) console.log(that.backgroundImg)
if(that.onceCode) { if(that.onceCode) {
@ -370,6 +371,7 @@
// else if(!that.backgroundImg){ // else if(!that.backgroundImg){
// this.$msg('!') // this.$msg('!')
// } // }
}, 500);
}, },
// //
getGoodsDetail() { getGoodsDetail() {

Loading…
Cancel
Save