feat:优化

This commit is contained in:
2026-07-23 20:11:26 +08:00
parent 6042342641
commit 1a493b4faf
2 changed files with 66 additions and 36 deletions
@@ -1331,8 +1331,8 @@ export default {
};
console.log("selectTempl", selectTempl);
if (this.isShowCart == 1 || this.isCoupon || isBy) {
console.log("活动类型params---秦星星", params, this.isCoupon);
if (this.isShowCart == 1 || this.isCoupon) {
console.log("活动类型params---秦星星", params, this.isCoupon, this.isShowCart == 1);
params["specsId"] = selectTempl;
let url = "";
if (this.activedType == "seckill") {
@@ -1356,6 +1356,8 @@ export default {
this.specificationShow = false;
}
console.log("活动类型params---秦星星--1", url);
uni.navigateTo({
url: url
});
@@ -1363,12 +1365,20 @@ export default {
}
const resp = await addGoods(params);
if (resp && resp.bizcode === 100) {
this.specificationShow = false;
uni.showToast({
title: "成功加入购物车",
icon: "success", // 可选 success/loading/none
duration: 2000, // 持续时长,单位ms
});
if (isBy) {
uni.navigateTo({
url: `/pages/order_package/order_submit/order_submit?ids=${resp.data}&address=${this.selectAddress?.id}`,
});
} else {
this.specificationShow = false;
uni.showToast({
title: "成功加入购物车",
icon: "success", // 可选 success/loading/none
duration: 2000, // 持续时长,单位ms
});
}
}
},
// 跳转到分享页面