feat:处理 detail-activity-tip.vue 的 type 判断
This commit is contained in:
@@ -39,14 +39,16 @@
|
|||||||
type: Array,
|
type: Array,
|
||||||
default() {
|
default() {
|
||||||
return [];
|
return [];
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
function onActivity(activity) {
|
function onActivity(activity) {
|
||||||
const type = activity.type;
|
const type = activity.type;
|
||||||
const typePath = type === 1 ? 'seckill' :
|
const typePath = type === 1 ? 'seckill' : type === 3 ? 'groupon' : undefined;
|
||||||
type === 2 ? 'TODO 拼团' : 'groupon';
|
if (!typePath) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
sheep.$router.go(`/pages/goods/${typePath}`, {
|
sheep.$router.go(`/pages/goods/${typePath}`, {
|
||||||
id: activity.id,
|
id: activity.id,
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user