Commit eabe050f authored by Xuguangxing's avatar Xuguangxing

Merge branch 'feat/group-buy' of git.quantgroup.cn:ui/group-buy-ui into feat/group-buy

parents 1aa3f3e1 c4acff51
......@@ -76,8 +76,6 @@ import localStorage from '@/service/localStorage.service';
import goodsCheckMixin from '@/mixins/goodsCheck.mixin';
import { setAppTitleColor, EventBus, firstGroupShare } from '@/service/utils.service';
import { saTrackEvent } from '@/service/sa.service';
// import { isNull } from '@/service/validation.service';
// let topicIndex;
export default {
// eslint-disable-next-line vue/name-property-casing
name: 'groupBuyList',
......@@ -121,15 +119,6 @@ export default {
return +new Date(endTime || 0);
}
},
watch: {
// $route(to) {
// if (to.name !== 'groupBuyList') {
// this.setTitleColor();
// return;
// }
// this.setTitleColor(this.goodsTemp.bgcolor);
// }
},
created() {
this.showLoops = true;
this.reload = true;
......@@ -137,12 +126,6 @@ export default {
beforeDestroy() {
this.setTitleColor();
},
// deactivated() {
// this.showLoops = false;
// },
// activated() {
// this.showLoops = true;
// },
beforeRouteEnter(to, from, next) {
const { activityId } = to.query;
if (!activityId || isNaN(activityId)) {
......@@ -153,17 +136,6 @@ export default {
return;
} else {
getActivityList(to.query, next);
// if (isNull(topicIndex)) {
// getActivityList(to.query, next);
// } else {
// if (localStorage.get('activityId') !== +activityId) {
// getActivityList(to.query, next);
// return;
// }
// next(vm => {
// store.commit('CHANGE_TITLE', vm.goodsTemp.title || '活动页');
// });
// }
}
},
methods: {
......@@ -319,33 +291,6 @@ async function getActivityList(urlQuery, next) {
// t.endTime = '2021-09-23 19:17:20';
t = await computedTemplate(t);
t.groupBuyUserInfoList = (t.groupBuyUserInfoList || []).reverse();
// t.groupBuyUserInfoList = [
// {
// name: '皱眉',
// avatar:
// 'https://img.lkbang.net/avator/0c8c1cfeb1cfdfffd77ac74af83377a17812a3585027-OKt5j9_fw658.jpeg'
// },
// {
// name: '空白人生',
// avatar:
// 'https://img.lkbang.net/avator/e684de0d4db0fcd3a04945ff7ed394abb678ce577dba5-VJbncW_fw658.jpeg'
// },
// {
// name: '逅黄昏',
// avatar:
// 'https://img.lkbang.net/avator/900b3be08740dbe4e38f7c3b7a73b613538a2f2edac3-yXzWfB_fw658.jpeg'
// },
// {
// name: '桑过后正年轻',
// avatar:
// 'https://img.lkbang.net/avator/7ca48321827385f386d0317a40d3f6201f442fddf99a-xXvv37_fw658.jpeg'
// },
// {
// name: '年少就是不服输',
// avatar:
// 'https://img.lkbang.net/avator/e33db7b617e42367d888e3821e1acd89b4b20319cb42-esiOS3_fw658.jpeg'
// }
// ];
store.commit('CHANGE_TITLE', t.title || '活动页');
nextFns(vm => {
// topicIndex = 0;
......
<template>
<div>
<div class="pay-result">
<div v-if="isSuccess" class="card">
<div class="info">
<cr-image
......@@ -18,11 +18,21 @@
拼团成功即可退款0元拿,拼团失败立即退款
</p>
<div class="actions">
<cr-button shape="circle" type="default" @click="goPage(1)">我的拼团</cr-button>
<cr-button shape="circle" class="actions__back" :plain="true" type="primary" @click="share"
<cr-button shape="circle" class="actions__share" type="primary" @click="share"
>邀请好友</cr-button
>
</div>
<div class="actions">
<cr-button shape="circle" type="default" @click="goGroupList">返回活动列表</cr-button>
<cr-button
shape="circle"
class="actions__back"
:plain="true"
type="primary"
@click="goPage(1)"
>查看我的拼团</cr-button
>
</div>
</div>
<div v-else class="card">
<div class="info">
......@@ -135,6 +145,10 @@ export default {
this.shareInfo = res;
firstGroupShare(res, 3);
},
goGroupList() {
const { activityId } = this.shareInfo;
this.$router.push(`/groupBuy/list?activityId=${activityId}`);
},
goPage(type) {
if (type == 1) {
this.$router.replace({ path: '/orderList/0' });
......@@ -170,25 +184,31 @@ export default {
};
</script>
<style lang="less" scoped>
.pay-result {
height: 100%;
}
.card {
margin: @padding-sm;
// margin: @padding-sm;
height: 100%;
background-color: @white;
border-radius: @border-radius-sm;
// border-radius: @border-radius-sm;
padding: 28px @padding-sm @padding-sm @padding-sm;
box-sizing: border-box;
.info {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
&__image {
width: 100px;
height: 100px;
margin: @padding-xl 0;
}
&__text {
.text-16;
margin-left: @padding-md;
// margin-left: @padding-md;
}
&__desc {
......@@ -200,6 +220,7 @@ export default {
margin-top: @padding-xs;
}
&__free {
text-align: center;
.text-13;
margin-top: @padding-xs;
color: @font-color-light;
......@@ -209,7 +230,7 @@ export default {
.tips {
.text-12;
text-align: center;
margin-top: @padding-lg;
margin-top: @padding-xs;
color: @font-color-light;
}
......@@ -231,7 +252,11 @@ export default {
button {
// flex: 1;
.text-16;
width: 161px;
width: 170px;
line-height: normal;
}
&__share {
width: 100% !important;
}
}
.info_button {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment