mirror of
https://gitee.com/beijing_hongye_huicheng/lilishop-uniapp.git
synced 2025-12-17 16:05:53 +08:00
修改购物车为空时显示图标,新增虚拟商品退款判断,修改个人中心背景图
This commit is contained in:
@@ -156,9 +156,7 @@ export default {
|
||||
this.routers = options;
|
||||
},
|
||||
watch: {
|
||||
showFlag(val) {
|
||||
|
||||
},
|
||||
showFlag(val) {},
|
||||
},
|
||||
onShow() {
|
||||
this.goodsList = [];
|
||||
@@ -172,27 +170,34 @@ export default {
|
||||
},
|
||||
|
||||
async handleLink(goods) {
|
||||
uni.showToast({
|
||||
title: "请请按住保存图片",
|
||||
duration: 2000,
|
||||
icon: "none",
|
||||
});
|
||||
let page = `pages/product/goods`;
|
||||
let scene = `${goods.skuId},${goods.id},${this.routers.id}`;
|
||||
let result = await getMpCode({ page, scene });
|
||||
if(result.data.success){
|
||||
let callback = result.data.result;
|
||||
this.res.container.title = `${goods.goodsName}`;
|
||||
this.res.bottom.code = `data:image/png;base64,${callback}`;
|
||||
this.res.bottom.price = this.$options.filters.unitPrice(goods.price, "¥");
|
||||
this.res.bottom.desc = `${goods.goodsName}`;
|
||||
this.res.bottom.img = `${goods.thumbnail}`;
|
||||
if (result.data.success) {
|
||||
let callback = result.data.result;
|
||||
this.res.container.title = `${goods.goodsName}`;
|
||||
this.res.bottom.code = `data:image/png;base64,${callback}`;
|
||||
this.res.bottom.price = this.$options.filters.unitPrice(
|
||||
goods.price,
|
||||
"¥"
|
||||
);
|
||||
this.res.bottom.desc = `${goods.goodsName}`;
|
||||
this.res.bottom.img = `${goods.thumbnail}`;
|
||||
|
||||
if (this.showFlag) {
|
||||
this.$refs.drawCanvas.init();
|
||||
}
|
||||
this.showFlag = true;
|
||||
}
|
||||
else{
|
||||
if (this.showFlag) {
|
||||
this.$refs.drawCanvas.init();
|
||||
}
|
||||
this.showFlag = true;
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: `制作二维码失败!请稍后重试`,
|
||||
duration: 2000,
|
||||
icon:"none"
|
||||
icon: "none",
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user