Browse Source

页面:订单详情一系列页面的添加/设置支付密码等页面优化 接口:所有活动列表/我的活动列表/报名活动/活动列表详情(接口待优化)/发现首页列表(接口待优化)

master
Enzo 4 years ago
parent
commit
e35af4ea75
  1. 31
      App.vue
  2. 25
      components/lf-payPassword/lf-payPassword.vue
  3. 7
      pages.json
  4. 31
      pages/aboutpay/confirmcash.vue
  5. 212
      pages/discover/discover.vue
  6. 51
      pages/index/activity/confirm.vue
  7. 81
      pages/index/activity/detail.vue
  8. 108
      pages/index/activity/hot.vue
  9. 10
      pages/order/cashier/cashier.vue
  10. 297
      pages/order/newdetail/carrybyself.vue
  11. 189
      pages/order/newdetail/newdetail.vue
  12. 47
      pages/user/member/service.vue
  13. 2
      pages/user/my/center.vue
  14. 112
      pages/user/my/myEventRegistrationList.vue
  15. 57
      pages/user/my/myregister.vue

31
App.vue

@ -110,4 +110,35 @@ view {
uni-page-head {
display: none;
}
// loading
.loading-more {
align-items: center;
justify-content: center;
padding-top: 10px;
padding-bottom: 10px;
text-align: center;
font-size: 28rpx;
color: #999;
}
.loading-more-text::before {
content: '';
width: 20px;
height: 20px;
display: inline-block;
vertical-align: middle;
-webkit-animation: weuiLoading 1s steps(12, end) infinite;
animation: weuiLoading 1s steps(12, end) infinite;
background-repeat: no-repeat;
background-image: url("data:image/svg+xml;charset=utf8, %3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' viewBox='0 0 100 100'%3E%3Cpath fill='none' d='M0 0h100v100H0z'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23E9E9E9' rx='5' ry='5' transform='translate(0 -30)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23989697' rx='5' ry='5' transform='rotate(30 105.98 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%239B999A' rx='5' ry='5' transform='rotate(60 75.98 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23A3A1A2' rx='5' ry='5' transform='rotate(90 65 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23ABA9AA' rx='5' ry='5' transform='rotate(120 58.66 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23B2B2B2' rx='5' ry='5' transform='rotate(150 54.02 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23BAB8B9' rx='5' ry='5' transform='rotate(180 50 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23C2C0C1' rx='5' ry='5' transform='rotate(-150 45.98 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23CBCBCB' rx='5' ry='5' transform='rotate(-120 41.34 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23D2D2D2' rx='5' ry='5' transform='rotate(-90 35 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23DADADA' rx='5' ry='5' transform='rotate(-60 24.02 65)'/%3E%3Crect width='7' height='20' x='46.5' y='40' fill='%23E2E2E2' rx='5' ry='5' transform='rotate(-30 -5.98 65)'/%3E%3C/svg%3E");
background-size: 100%;
}
@keyframes weuiLoading {
0% {
transform: rotate3d(0, 0, 1, 0deg);
}
100% {
transform: rotate3d(0, 0, 1, 360deg);
}
}
</style>

25
components/lf-payPassword/lf-payPassword.vue

@ -5,26 +5,47 @@
<view class="password">
<lf-jp-coded :width="686" @inputVal="inputVal"></lf-jp-coded>
</view>
<view class="lf-flex lf-m-t-45 lf-row-center">
<view class="lf-font-24 lf-m-r-10" style="color:#FF9D9D">
剩余支付时间
</view>
<countdown-timer :time="time" :autoStart="true" @finish="dateFinish">
<template v-slot="{minute, second}">
<!-- <view>{{minute}}:{{second}}</view> -->
<view class="lf-flex">
<view class="lf-font-24" style="color:#FF9D9D">{{ minute >= 10 ? minute : "0" + minute }}</view>
<view class="lf-font-24" style="color:#FF9D9D">:</view>
<view class="lf-font-24" style="color:#FF9D9D">{{ second >= 10 ? second : "0" + second }}</view>
</view>
</template>
</countdown-timer>
</view>
</view>
<button class="btn" hover-class="lf-opacity" @click="comfirm">确认</button>
</view>
</template>
<script>
import countdownTimer from '@/components/countdown-timer/countdown-timer';
import lfJpCoded from '@/components/lf-jpCoded/lf-jpCoded.vue'
export default {
components: {
lfJpCoded
lfJpCoded,
countdownTimer
},
data(){
return {
code: ''
code: '',
time: new Date('2021/09/8 14:15:00').getTime() - new Date('2021/09/8 14:10:00').getTime()
}
},
created(){
},
methods: {
dateFinish(){
console.log("倒计时结束");
},
inputVal(event){
this.code = event;
},

7
pages.json

@ -344,6 +344,13 @@
"navigationStyle": "custom"
}
},
{
"path" : "pages/order/newdetail/carrybyself",
"style" : {
"navigationBarTitleText": "订单详情",
"navigationStyle": "custom"
}
},
{
"path" : "pages/order/newdetail/newdetail",
"style" : {

31
pages/aboutpay/confirmcash.vue

@ -7,6 +7,21 @@
请核对支付金额
</view>
<view style="font-size: 72rpx;color: #15716E;">¥478.50</view>
<view class="lf-flex">
<view class="lf-font-24 lf-m-r-10" style="color:#FF9D9D">
剩余支付时间
</view>
<countdown-timer :time="time" :autoStart="true" @finish="dateFinish">
<template v-slot="{minute, second}">
<!-- <view>{{minute}}:{{second}}</view> -->
<view class="lf-flex">
<view class="lf-font-24" style="color:#FF9D9D">{{ minute >= 10 ? minute : "0" + minute }}</view>
<view class="lf-font-24" style="color:#FF9D9D">:</view>
<view class="lf-font-24" style="color:#FF9D9D">{{ second >= 10 ? second : "0" + second }}</view>
</view>
</template>
</countdown-timer>
</view>
<view>
<button class="confirmcash-btn">确认</button>
</view>
@ -16,6 +31,22 @@
</template>
<script>
import countdownTimer from '@/components/countdown-timer/countdown-timer';
export default {
data() {
return {
time: new Date('2021/09/8 14:15:00').getTime() - new Date('2021/09/8 14:10:00').getTime()
}
},
components: {
countdownTimer
},
methods: {
dateFinish(){
console.log("倒计时结束");
},
}
}
</script>
<style>

212
pages/discover/discover.vue

@ -2,9 +2,13 @@
<view>
<lf-nav :spreadOut="true" title="发现"></lf-nav>
<view>
<u-tabs :list="tab_list" active-color="#15716E" inactive-color='#777777' :is-scroll="true" :current="current" @change="tabChange"></u-tabs>
<u-tabs :list="tab_list" active-color="#15716E" inactive-color='#777777' :is-scroll="true" :current="tab_current" @change="tabChange"></u-tabs>
</view>
<view v-for="i of 6">
<swiper :style="{height: autoHeight}" :current="tab_current" @change="swiperChange">
<swiper-item v-for="(tab, tabIndex) in tab_list" :key="tabIndex">
<scroll-view :style="{height: autoHeight}" :scroll-y="true" :refresher-enabled="true" :refresher-triggered="isRefresher"
@scrolltolower="onScrolltolower" @refresherrefresh="onRefresherrefresh">
<view v-for="(item,index) of tab.list">
<view class="lf-p-32">
<view class="lf-flex" @click="$url('/pages/user/my/my')">
<view class="tag-father">
@ -13,37 +17,47 @@
</view>
<view class="lf-flex-column lf-m-l-20">
<view class="lf-font-32 lf-color-black lf-font-bold">最新FUEJFEI</view>
<view class="lf-font-24 lf-color-777 lf-m-t-15">08-28 18:39</view>
<view class="lf-font-24 lf-color-777 lf-m-t-15">{{item.created_at}}</view>
</view>
</view>
<view class="lf-font-28 lf-color-333 lf-m-t-20" @click="$url('/pages/discover/discoverdetails')">
在售商品在售商品在售商品在售商品在售商品在售商品在售商品在售
{{item.content}}
</view>
<view class="lf-flex-wrap lf-m-t-20">
<image v-for="item in 9" class="qzone-img" src="https://hainan.lanzulive.com/storage/images/v2-deb89623e0ee2a2dad34bcded6dfd1ed_1440w.png" mode="aspectFill"></image>
<image v-for="(picture,index) in item.attachs" class="qzone-img" :src="picture.url" mode="aspectFill"></image>
</view>
<view class="lf-m-t-30 lf-row-between lf-p-l-50 lf-p-r-50">
<view class="lf-row-center">
<text class="lf-iconfont icon-shoucang"></text>
<text class="lf-font-24 lf-color-777 lf-m-l-10">379</text>
<text class="lf-font-24 lf-color-777 lf-m-l-10">{{item.likes_count}}</text>
</view>
<view class="lf-row-center">
<text class="lf-iconfont icon-fabu"></text>
<text class="lf-font-24 lf-color-777 lf-m-l-10">3579</text>
<text class="lf-font-24 lf-color-777 lf-m-l-10">{{item.view_count}}</text>
</view>
<view class="lf-row-center">
<text class="lf-iconfont icon-fenxiang"></text>
<text class="lf-font-24 lf-color-777 lf-m-l-10">63</text>
<text class="lf-font-24 lf-color-777 lf-m-l-10">{{item.comments_count}}</text>
</view>
</view>
</view>
<self-line/>
</view>
<!-- 空数据的情况 -->
<view class="loading-more">
<text v-if="tab.list.length"
:class="{'loading-more-text': tab.loadingClass}">{{ tab.loadingText }}</text>
<lf-nocontent v-else></lf-nocontent>
</view>
<view class="fixed-right">
<view class="fixed-btn" hover-class="lf-opacity" @click="$url('/pages/discover/publish')">
<text class="lf-iconfont icon-fabu lf-font-50"></text>
</view>
</view>
<view style="height: 30rpx;"></view>
</scroll-view>
</swiper-item>
</swiper>
<lf-tabbar></lf-tabbar>
</view>
</template>
@ -55,19 +69,189 @@
lfTabbar
},
data() {
let _public = {
page: 1,
isPage: true,
loadingClass: true,
loadingText: '正在加载中'
}
return {
tab_list: [
{name: '最新',id: 1},
{name: '最热',id: 2},
{name: '已关注',id: 3}
{name: '最新',type: 'created_at',list:[]},
{name: '最热',type: 'view_count',list:[]},
{name: '已关注',type: 'view_count',list:[]}
],
current: 0,
tab_current: 0,
scrollH: 0,
nav_height: 0,
isRefresher: true,
pageSize: 10
}
},
computed: {
autoHeight(){
return `calc(${this.scrollH}px - ${this.nav_height}px - 86rpx)`;
}
},
onLoad(){
let info = uni.getSystemInfoSync();
this.scrollH = info.screenHeight;
this.getHotActivity()
},
methods: {
tabChange(index){
this.current = index;
getMyAttention() {
let tab_item = this.tab_list[this.tab_current];
this.$http
.get({
api: 'api/discover/follow',
header: {
Authorization: this.$cookieStorage.get('user_token')
},
})
.then(res => {
console.log(res)
if (res.data.code == 200) {
if (res.data.status) {
let isPage = res.data.next_page_url == null?false:true;
tab_item.isPage = isPage;
if(!isPage) {
tab_item.loadingClass = false;
tab_item.loadingText = '没有更多数据啦~';
}
if(options.type == 'pageRefresh') {
uni.stopPullDownRefresh();
}else if(options.type == 'scrollRefresh') {
this.isRefresher = false;
}
if(tab_item.page == 1) {
tab_item.list = res.data.data.data;
}else {
tab_item.list.push(...res.data.data.data);
}
console.log('发现列表',tab_item.list)
} else {
wx.showModal({
content: res.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
},
//
onScrolltolower(){
let tab_item = this.tab_list[this.tab_current];
if(tab_item.isPage){
tab_item.page = tab_item.page + 1;
this.getHotActivity();
}
},
//
refreshFn(options){
let tab_item = this.tab_list[this.tab_current];
tab_item.page = 1;
tab_item.isPage = true;
tab_item.loadingClass = true;
tab_item.list = []
tab_item.loadingText = '正在加载中';
this.getHotActivity(options);
},
// scroll-view
onRefresherrefresh(){
this.isRefresher = true;
this.refreshFn({type: 'scrollRefresh'});
},
tabChange(event){
this.tab_current = event;
if(this.tab_current == 2) {
this.getMyAttention();
console.log('执行关注列表');
}else {
this.getHotActivity();
}
},
swiperChange(event){
this.tab_current = event.detail.current;
if (event.detail.source == '') return; //
if(this.tab_current == 2) {
this.getMyAttention();
console.log('执行关注列表');
}else {
this.getHotActivity();
}
},
getHotActivity(options = {}) {
let discover_type;
let tab_item = this.tab_list[this.tab_current];
if(this.tab_current == 0) {
discover_type = 'created_at';
}else {
discover_type = 'view_count';
}
this.$http
.get({
api: 'api/discover',
page: tab_item.page,
page_size: this.pageSize,
data:{
order: discover_type
}
})
.then(res => {
if (res.data.code == 200) {
if (res.data.status) {
let isPage = res.data.next_page_url == null?false:true;
tab_item.isPage = isPage;
if(!isPage) {
tab_item.loadingClass = false;
tab_item.loadingText = '没有更多数据啦~';
}
if(options.type == 'pageRefresh') {
uni.stopPullDownRefresh();
}else if(options.type == 'scrollRefresh') {
this.isRefresher = false;
}
if(tab_item.page == 1) {
tab_item.list = res.data.data.data;
}else {
tab_item.list.push(...res.data.data.data);
}
console.log('数组列表',tab_item.list)
} else {
wx.showModal({
content: res.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
}
}
}
</script>

51
pages/index/activity/confirm.vue

@ -21,18 +21,63 @@
data(){
return {
name: '',
phone: ''
phone: '',
activity_id: 0
}
},
onLoad(){
onLoad(e){
this.activity_id = e.activity_id;
console.log('接受的id',this.activity_id)
},
methods: {
confirm(){
if(!this.name || !this.phone) return this.$msg('请将信息补充完整');
this.$http
.post({
api: 'api/activity/apply',
data: {
activity_id: this.activity_id,
name: this.name,
phone: this.phone
},
header: {
Authorization: this.$cookieStorage.get('user_token')
},
})
.then(res => {
if (res.data.code == 200) {
if (res.data.status) {
this.$msg('报名成功').then(() => {
this.$toBack();
})
} else {
wx.showModal({
content: res.data.message || '人数爆满,请稍后重试!',
showCancel: false,
success: (res) => {
this.$toBack();
}
});
}
} else {
wx.showModal({
content: res.data.message || '人数爆满,请稍后重试!',
showCancel: false,
success: (res) => {
this.$toBack();
}
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
}
}
}

81
pages/index/activity/detail.vue

@ -2,37 +2,38 @@
<view>
<lf-nav title="活动详情" :showIcon="true"></lf-nav>
<view class="content">
<view class="title">海蓝之谜美颜会 9月15日场10:30</view>
<view class="level2-title">会员尊享美颜会</view>
<view class="title">{{activity_details.name}}</view>
<view class="level2-title">
{{activity_details.username}}
</view>
<view class="level3-title">
<text>活动时间</text>
<text class="color1">2021年9月15日 10:30-12:00</text>
<text class="color1">{{activity_details.time_start}}</text>
</view>
<view class="level3-title">
<text>报名时间</text>
<text class="color2">即日起-9月12日24:00</text>
<text class="color2">{{activity_details.apply_start}}</text>
</view>
<view class="level3-title">
<view class="level3-title lf-flex">
<text>活动内容</text>
<text class="color2">美白课堂+现场DIY甜橙茶</text>
<rich-text :nodes="activity_details.content" v-if="activity_details.content"></rich-text>
</view>
<view class="level3-title">
<text>活动人数</text>
<text class="color2">5</text>
<text class="color2">{{activity_details.member_count}}</text>
</view>
<view class="level3-title">
<text>活动报名</text>
<text class="color1">免费</text>
<text class="color1" v-if="activity_details.price == 0">免费</text>
<text class="color1" v-else>{{activity_details.price}}</text>
</view>
<view class="level3-title">
<view class="level3-title lf-flex">
<view>活动规则</view>
<view class="color2">
<view>1金卡及以上会员可免费报名参加每个ID仅可报名一场活动以每个第一次报名场次为准超出报名次数不予审核通过</view>
<view>2报名成功后店铺会在活动前一天联系您报名的手机号</view>
<view>3如有疑问请致电海蓝之谜店铺联系电话0315-743843474</view>
<view>{{activity_details.rule}}</view>
</view>
</view>
<button class="btn"
<button v-if="enter_type==0" class="btn"
hover-class="lf-opacity"
:disabled="is_end"
:class="{'lf-opacity': is_end}"
@ -46,16 +47,62 @@
export default {
data(){
return {
is_end: false // false
is_end: false ,// false
activity_id: 0,
activity_details: '',
enter_type: 0
}
},
onLoad(){
onLoad(e){
this.activity_id = e.activity_id;
this.enter_type = e.enter_type;
if(e.is_end == 0) {
this.is_end = false;
}else {
this.is_end = true;
}
console.log('传来的type',this.is_end);
this.getActivityDetails();
},
methods: {
getActivityDetails() {
this.$http
.get({
api: 'api/activity/detail',
data: {
activity_id: this.activity_id
}
})
.then(res => {
if (res.data.code == 200) {
if (res.data.status) {
this.activity_details = res.data.data;
console.log('活动详情',this.activity_details);
} else {
wx.showModal({
content: res.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
},
submit(){
if(this.is_end) return;
this.$url('/pages/index/activity/confirm');
this.$url('/pages/index/activity/confirm?activity_id='+this.activity_id);
}
}
}

108
pages/index/activity/hot.vue

@ -5,18 +5,25 @@
<u-tabs :list="tab_list" active-color="#15716E" inactive-color='#777777' :is-scroll="true" :current="tab_current" @change="tabChange"></u-tabs>
</view>
<swiper :style="{height: autoHeight}" :current="tab_current" @change="swiperChange">
<swiper-item v-for="(item, index) in tab_list" :key="index">
<scroll-view :style="{height: autoHeight}" :scroll-y="true">
<swiper-item v-for="(tab, tabIndex) in tab_list" :key="tabIndex">
<scroll-view :style="{height: autoHeight}" :scroll-y="true" :refresher-enabled="true" :refresher-triggered="isRefresher"
@scrolltolower="onScrolltolower" @refresherrefresh="onRefresherrefresh">
<view class="scroll-content">
<view class="card" v-for="(item, index) in 3" :key="index" @click="$url('/pages/index/activity/detail')">
<view class="card" v-for="(item, index) in tab.list" :key="index" @click="goDetails(item.id)">
<view class="cover">
<image class="img"></image>
<image class="img" :src="item.image" mode="aspectFill"></image>
</view>
<view class="info">
<view class="title">海蓝之谜美颜会 9月15日场10:30</view>
<view class="date">2021.09.01-2021.09.15</view>
<view class="title">{{item.name}}</view>
<view class="date">{{item.time_start}}-{{item.time_end}}</view>
</view>
</view>
<!-- 空数据的情况 -->
<view class="loading-more">
<text v-if="tab.list.length"
:class="{'loading-more-text': tab.loadingClass}">{{ tab.loadingText }}</text>
<lf-nocontent v-else></lf-nocontent>
</view>
</view>
<view style="height: 30rpx;"></view>
</scroll-view>
@ -46,7 +53,8 @@
..._public
}],
scrollH: 0,
nav_height: 0
nav_height: 0,
isRefresher: true
}
},
computed: {
@ -57,13 +65,99 @@
onLoad(){
let info = uni.getSystemInfoSync();
this.scrollH = info.screenHeight;
this.getHotActivity()
},
methods: {
goDetails(id) {
console.log('当前tabcurrent',this.tab_current)
if(this.tab_current == 0) {
this.$url('/pages/index/activity/detail?enter_type=0&is_end=0&activity_id='+id)
}else {
this.$url('/pages/index/activity/detail?enter_type=0&is_end=1&activity_id='+id)
}
},
//
onScrolltolower(){
let tab_item = this.tab_list[this.tab_current];
if(tab_item.isPage){
tab_item.page = tab_item.page + 1;
this.getHotActivity();
}
},
//
refreshFn(options){
let tab_item = this.tab_list[this.tab_current];
tab_item.page = 1;
tab_item.isPage = true;
tab_item.loadingClass = true;
tab_item.list = []
tab_item.loadingText = '正在加载中';
this.getHotActivity(options);
},
// scroll-view
onRefresherrefresh(){
this.isRefresher = true;
this.refreshFn({type: 'scrollRefresh'});
},
tabChange(event){
this.tab_current = event;
this.getHotActivity();
},
swiperChange(event){
this.tab_current = event.detail.current;
if (event.detail.source == '') return; //
this.getHotActivity();
},
getHotActivity(options = {}) {
this.$http
.get({
api: 'api/activity',
data:{
is_expired: this.tab_current+1
}
})
.then(res => {
let tab_item = this.tab_list[this.tab_current];
if (res.data.code == 200) {
if (res.data.status) {
let isPage = res.data.next_page_url == null?false:true;
tab_item.isPage = isPage;
if(!isPage) {
tab_item.loadingClass = false;
tab_item.loadingText = '没有更多数据啦~';
}
if(options.type == 'pageRefresh') {
uni.stopPullDownRefresh();
}else if(options.type == 'scrollRefresh') {
this.isRefresher = false;
}
if(tab_item.page == 1) {
tab_item.list = res.data.data.data;
}else {
tab_item.list.push(...res.data.data.data);
}
console.log('数组列表',tab_item.list)
} else {
wx.showModal({
content: res.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
}
}
}

10
pages/order/cashier/cashier.vue

@ -35,6 +35,7 @@
</view>
</view>
<view class="fixed-btn" hover-class="lf-opacity" @click="confirm">立即支付</view>
<view class="fixed-agreement">购买须知</view>
</view>
</template>
@ -120,6 +121,15 @@
}
}
.fixed-agreement {
position: fixed;
bottom: 5vh;
font-size: 28rpx;
color: #15716E;
left: calc(50% - 84rpx);
width: 168rpx;
}
.fixed-btn{
position: fixed;
bottom: 10vh;

297
pages/order/newdetail/carrybyself.vue

@ -0,0 +1,297 @@
<template>
<view>
<lf-nav title="订单详情" :showIcon="true"></lf-nav>
<view class="tips">
<view class="lf-font-24 lf-color-white">剩余支付时间</view>
<view>
<countdown-timer :time="time" :autoStart="true" @finish="dateFinish">
<template v-slot="{minute, second}">
<!-- <view>{{minute}}:{{second}}</view> -->
<view class="lf-flex">
<view class="lf-font-24 lf-color-white">{{ minute >= 10 ? minute : "0" + minute }}</view>
<view class="lf-font-24 lf-color-white">:</view>
<view class="lf-font-24 lf-color-white">{{ second >= 10 ? second : "0" + second }}</view>
</view>
</template>
</countdown-timer>
</view>
</view>
<view class="card" v-if="type == 'default'" style="margin-top: 0;">
<view class="lf-font-28">
<text class="lf-color-222 lf-font-bold">王小二</text>
<text class="lf-color-777 lf-m-l-20">18284385380</text>
</view>
<view class="lf-font-28 lf-color-333 lf-m-t-20">
<text>广西壮族自治区-南宁市-青秀区-民族大道民族大道民族大道民族大道民族大道民族大道15号</text>
</view>
</view>
<view class="card goods">
<view>
<text class="lf-iconfont icon-Group- lf-font-30"></text>
<text class="shop-name">精品超市</text>
<text class="lf-iconfont icon-xiangyou lf-font-24"></text>
</view>
<view class="lf-flex lf-m-t-20">
<image class="goods-img"></image>
<view class="info">
<view class="lf-font-26 lf-color-333 lf-line-1">爱他美较大婴儿配方奶粉较大配方奶粉较2段 </view>
<view class="lf-font-24 lf-color-777">500g</view>
<view class="lf-row-between" style="line-height: 1;">
<text class="price">¥385</text>
<text class="lf-font-28 lf-color-777">x 2</text>
</view>
</view>
</view>
</view>
<view class="card" v-if="type == 'point'">
<view class="lf-row-between lf-font-28">
<text class="lf-color-777">积分数量</text>
<text class="lf-color-222">385</text>
</view>
</view>
<view class="lf-bg-white lf-m-t-20 lf-p-b-30 lf-row-center lf-flex-column">
<view class="qrcode">
<lf-qrcode :options="qrc"></lf-qrcode>
</view>
<view class="lf-font-28" style="color:#15716E" v-if="true">待提货</view>
<view class="lf-font-28 lf-color-777" v-else>已取货</view>
</view>
<view class="card" v-if="type == 'default'">
<view class="lf-row-between lf-font-28">
<text class="lf-color-777">优惠券</text>
<text style="color: #F63434;">-¥20</text>
</view>
<view class="lf-row-between lf-m-t-30 lf-font-28">
<text class="lf-color-777">订单总价</text>
<text class="lf-color-222">¥375</text>
</view>
</view>
<view class="card">
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">订单编号</text>
<text class="lf-color-222">75894375395739345</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">创建时间</text>
<text class="lf-color-222">2021-09-07 10:21:38</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">留言</text>
<text class="lf-color-222">暂无留言</text>
</view>
<!-- 待自提 -->
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">支付方式</text>
<text class="lf-color-222">余额支付</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">收货方式</text>
<text class="lf-color-222">自提</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">支付时间</text>
<text class="lf-color-222">2021-09-07 10:21:38</text>
</view>
</view>
<view style="height: 120rpx;margin-top: 20rpx;"></view>
<!-- 待付款 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center" style="color:#F63434">
待付款
</view>
<view class="lf-flex">
<view class="btn-cancel lf-m-r-20">
取消订单
</view>
<view class="btn-atonce">
立即付款
</view>
</view>
</view>
<!-- 待自提 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center lf-color-black">
待自提
</view>
<view class="lf-flex">
<view style="width: 220rpx;"></view>
<view style="width: 220rpx;"></view>
</view>
</view>
<!-- 已完成 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center" style="color: #22A19F;">
已完成
</view>
<view class="lf-flex">
<view style="width: 220rpx;"></view>
<view style="width: 220rpx;"></view>
</view>
</view>
</view>
</template>
<script>
import countdownTimer from '@/components/countdown-timer/countdown-timer';
import lfQrcode from '@/components/lf-code/lf-qrcode.vue';
export default {
data(){
return {
type: 'default' ,// point, default
time: new Date('2021/09/8 14:15:00').getTime() - new Date('2021/09/8 14:10:00').getTime(),
qrc: {
code: "https://weixin.qq.com/g/AwYAAHO3aO4zlasEij6bLsk4hlZd5XNFkkBmqyS55mLPFxmn5c9PaI1omqLhd24fABCD23333",
size: 300, //
level: 4, // 04
bgColor: '#FFFFFF', //
// border: {
// color: ['#8A2387', '#F27121'], //
// lineWidth: 3, //
// },
// img: '/static/logo.png', //
// iconSize: 40, //
color: '#000000', //
}
}
},
components: {
countdownTimer,
lfQrcode
},
onLoad(options){
this.type = options.type || this.type;
},
methods: {
dateFinish(){
console.log("倒计时结束");
},
}
}
</script>
<style>
page{
background-color: #F8F8F8;
}
</style>
<style lang="scss" scoped="scoped">
.qrcode{
display: flex;
justify-content: center;
margin-top: 30rpx;
}
.tips-waitconfirm {
width: 100%;
height: 113rpx;
background: #15716E;
display: flex;
justify-content: space-between;
padding: 0 32rpx;
align-items: center;
}
.waitconfirm-tag {
width: 136rpx;
height: 53rpx;
border-radius: 27rpx;
border: 2rpx solid #FFFFFF;
font-size: 24rpx;
color: white;
display: flex;
justify-content: center;
align-items: center;
}
.btn-cancel {
width: 220rpx;
height: 90rpx;
border-radius: 45rpx;
border: 2rpx solid #999999;
color: #777;
font-size: 28rpx;
display: flex;
justify-content: center;
align-items: center;
}
.btn-confirm {
width: 220rpx;
height: 90rpx;
border-radius: 45rpx;
background-color: #15716E;
color: #fff;
font-size: 28rpx;
display: flex;
justify-content: center;
align-items: center;
}
.btn-atonce {
width: 220rpx;
height: 90rpx;
border-radius: 45rpx;
background-color: #F63434;
color: #fff;
font-size: 28rpx;
display: flex;
justify-content: center;
align-items: center;
}
.order-btn {
width: 100%;
height: 120rpx;
background: #FFFFFF;
display: flex;
justify-content: space-between;
padding: 0 32rpx;
position: fixed;
bottom: 0;
}
.tips {
display: flex;
background-color: #F63434;
height: 64rpx;
width: 100%;
justify-content: center;
align-items: center;
}
.card{
height: max-content;
width: 750rpx;
padding: 30rpx 32rpx;
background-color: #FFFFFF;
&:nth-child(n+2){
margin-top: 20rpx;
}
}
.goods{
.shop-name{
font-size: 28rpx;
color: #222222;
font-weight: bold;
margin: 0 15rpx;
}
.goods-img{
width: 130rpx;
height: 130rpx;
border-radius: 4rpx;
margin-right: 15rpx;
background-color: #EEEEEE;
}
.info{
width: 540rpx;
height: 130rpx;
display: flex;
flex-direction: column;
justify-content: space-around;
.price{
font-size: 32rpx;
color: #F63434;
font-weight: bold;
}
}
.order-num{
font-size: 24rpx;
color: #999999;
display: flex;
justify-content: space-between;
margin-top: 28rpx;
}
}
</style>

189
pages/order/newdetail/newdetail.vue

@ -1,7 +1,33 @@
<template>
<view>
<lf-nav title="订单详情" :showIcon="true"></lf-nav>
<view class="card" v-if="type == 'default'">
<view class="tips">
<view class="lf-font-24 lf-color-white">剩余支付时间</view>
<view>
<countdown-timer :time="time" :autoStart="true" @finish="dateFinish">
<template v-slot="{minute, second}">
<!-- <view>{{minute}}:{{second}}</view> -->
<view class="lf-flex">
<view class="lf-font-24 lf-color-white">{{ minute >= 10 ? minute : "0" + minute }}</view>
<view class="lf-font-24 lf-color-white">:</view>
<view class="lf-font-24 lf-color-white">{{ second >= 10 ? second : "0" + second }}</view>
</view>
</template>
</countdown-timer>
</view>
</view>
<!-- 待收货 -->
<view class="tips-waitconfirm">
<view class="lf-flex-column">
<view class="lf-font-28 lf-color-white">运输中</view>
<view class="lf-font-24 lf-color-white" v-if="true">广州转运中心公司 已发出下一站南宁转运中心</view>
<view class="lf-font-24 lf-color-white" v-else>[自提柜]已签收签收人凭取货码签收</view>
</view>
<view class="waitconfirm-tag">
查看详情
</view>
</view>
<view class="card" v-if="type == 'default'" style="margin-top: 0;">
<view class="lf-font-28">
<text class="lf-color-222 lf-font-bold">王小二</text>
<text class="lf-color-777 lf-m-l-20">18284385380</text>
@ -36,18 +62,25 @@
</view>
<view class="card" v-if="type == 'default'">
<view class="lf-row-between lf-font-28">
<text class="lf-color-777">订单总价</text>
<text class="lf-color-222">¥385</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">优惠券</text>
<text style="color: #F63434;">-¥20</text>
</view>
<view class="lf-row-between lf-m-t-30 lf-font-28">
<text class="lf-color-777">运费</text>
<text class="lf-color-222">+¥10</text>
</view>
<view class="lf-row-between lf-m-t-30 lf-font-28">
<text class="lf-color-777">订单总价</text>
<text class="lf-color-222">¥375</text>
</view>
</view>
<view class="card">
<view class="lf-row-between lf-font-28">
<text class="lf-color-777">商品订单编号</text>
<text>
<text class="lf-color-222">75894375395739345</text>
<text class="lf-font-28 lf-m-l-20" style="color: #22A19F;">复制</text>
</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">订单编号</text>
@ -57,26 +90,97 @@
<text class="lf-color-777">创建时间</text>
<text class="lf-color-222">2021-09-07 10:21:38</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">留言</text>
<text class="lf-color-222">暂无留言</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30" v-if="type == 'point'">
<text class="lf-color-777">兑换状态</text>
<text class="lf-color-222">兑换成功</text>
</view>
<!-- 待发货 -->
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">支付方式</text>
<text class="lf-color-222">余额支付</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">收货方式</text>
<text class="lf-color-222">邮寄</text>
</view>
<view class="lf-row-between lf-font-28 lf-m-t-30">
<text class="lf-color-777">支付时间</text>
<text class="lf-color-222">2021-09-07 10:21:38</text>
</view>
</view>
<view style="height: 120rpx;margin-top: 20rpx;"></view>
<!-- 待付款 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center" style="color:#F63434">
待付款
</view>
<view class="lf-flex">
<view class="btn-cancel lf-m-r-20">
取消订单
</view>
<view class="btn-atonce">
立即付款
</view>
</view>
</view>
<!-- 待发货 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center lf-color-777">
待发货
</view>
<view class="lf-flex">
<view style="width: 220rpx;"></view>
<view style="width: 220rpx;"></view>
</view>
</view>
<!-- 待收货 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center lf-color-black">
待收货
</view>
<view class="lf-flex">
<view style="width: 220rpx;"></view>
<view class="btn-confirm">
确认收货
</view>
</view>
</view>
<!-- 已完成 -->
<view class="order-btn">
<view class="lf-font-28 lf-row-center" style="color: #22A19F;">
已完成
</view>
<view class="lf-flex">
<view style="width: 220rpx;"></view>
<view style="width: 220rpx;"></view>
</view>
</view>
</view>
</template>
<script>
import countdownTimer from '@/components/countdown-timer/countdown-timer';
export default {
data(){
return {
type: 'default' // point, default
type: 'default' ,// point, default
time: new Date('2021/09/8 14:15:00').getTime() - new Date('2021/09/8 14:10:00').getTime()
}
},
components: {
countdownTimer
},
onLoad(options){
this.type = options.type || this.type;
},
methods: {
dateFinish(){
console.log("倒计时结束");
},
}
}
</script>
@ -87,6 +191,77 @@
}
</style>
<style lang="scss" scoped="scoped">
.tips-waitconfirm {
width: 100%;
height: 113rpx;
background: #15716E;
display: flex;
justify-content: space-between;
padding: 0 32rpx;
align-items: center;
}
.waitconfirm-tag {
width: 136rpx;
height: 53rpx;
border-radius: 27rpx;
border: 2rpx solid #FFFFFF;
font-size: 24rpx;
color: white;
display: flex;
justify-content: center;
align-items: center;
}
.btn-cancel {
width: 220rpx;
height: 90rpx;
border-radius: 45rpx;
border: 2rpx solid #999999;
color: #777;
font-size: 28rpx;
display: flex;
justify-content: center;
align-items: center;
}
.btn-confirm {
width: 220rpx;
height: 90rpx;
border-radius: 45rpx;
background-color: #15716E;
color: #fff;
font-size: 28rpx;
display: flex;
justify-content: center;
align-items: center;
}
.btn-atonce {
width: 220rpx;
height: 90rpx;
border-radius: 45rpx;
background-color: #F63434;
color: #fff;
font-size: 28rpx;
display: flex;
justify-content: center;
align-items: center;
}
.order-btn {
width: 100%;
height: 120rpx;
background: #FFFFFF;
display: flex;
justify-content: space-between;
padding: 0 32rpx;
position: fixed;
bottom: 0;
}
.tips {
display: flex;
background-color: #F63434;
height: 64rpx;
width: 100%;
justify-content: center;
align-items: center;
}
.card{
height: max-content;
width: 750rpx;

47
pages/user/member/service.vue

@ -6,15 +6,15 @@
<image mode="aspectFill" src="https://picsum.photos/seed/picsum/200/300"></image>
</view>
<view class="main">
<view class="item" v-for="(item, index) in 9" :key="index">
<image class="img"></image>
<view class="title">会员饮品</view>
<view class="desc">每月免费赠饮</view>
<view class="item" v-for="(item, index) in serviceList" :key="index">
<image class="img" :src="item.image" mode="aspectFill"></image>
<view class="title">{{item.name}}</view>
<view class="desc">{{item.remark}}</view>
</view>
</view>
<view style="height: 120rpx;"></view>
<view class="fixed">
<!-- <view class="btn1" hover-class="lf-opacity" @click="$url('/pages/user/my/chatonline')">在线客服</view> -->
<view class="btn1 lf-m-r-25" hover-class="lf-opacity" @click="$url('/pages/user/my/chatonline')">在线客服</view>
<view class="btn2" hover-class="lf-opacity">拨打客服电话</view>
</view>
</view>
@ -25,14 +25,45 @@
export default {
data(){
return {
serviceList: []
}
},
onLoad(){
this.getService()
},
methods: {
getService() {
this.$http
.get({
api: 'api/service'
})
.then(res => {
if (res.data.code == 200) {
if (res.data.status) {
this.serviceList = res.data.data
console.log('数组列表',this.serviceList)
} else {
wx.showModal({
content: res.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
}
}
}
</script>

2
pages/user/my/center.vue

@ -37,7 +37,7 @@
</view>
<view class="center-card">
<view class="lf-p-30 lf-row-between lf-w-100" @click="$url('/pages/user/member/quanyi')">
<view class="lf-p-30 lf-row-between lf-w-100" @click="$url('/pages/user/member/service')">
<view class="lf-flex-column">
<view class="lf-font-bold" style="color: #15716E;">
<text class="lf-font-48">VIP</text>

112
pages/user/my/myEventRegistrationList.vue

@ -5,19 +5,26 @@
<u-tabs :list="tab_list" active-color="#15716E" inactive-color='#777777' :is-scroll="true" :current="tab_current" @change="tabChange"></u-tabs>
</view>
<swiper :style="{height: autoHeight}" :current="tab_current" @change="swiperChange">
<swiper-item v-for="(item, index) in tab_list" :key="index">
<scroll-view :style="{height: autoHeight}" :scroll-y="true">
<swiper-item v-for="(tab, tabIndex) in tab_list" :key="tabIndex">
<scroll-view :style="{height: autoHeight}" :scroll-y="true" :refresher-enabled="true" :refresher-triggered="isRefresher"
@scrolltolower="onScrolltolower" @refresherrefresh="onRefresherrefresh">
<view class="scroll-content">
<view class="card" v-for="(item, index) in 3" :key="index">
<view class="card" v-for="(item, index) in tab.list" :key="index" @click="$url('/pages/user/my/myregister?activity_id='+item.activity_id)">
<view class="cover">
<image class="img"></image>
<view class="label" :class="'theme-'+ (index+1)">待参加</view>
<image class="img" :src="item.activity.image"></image>
<view class="label" :class="'theme-'+ (index+1)">{{item.state}}</view>
</view>
<view class="info">
<view class="title">海蓝之谜美颜会 9月15日场10:30</view>
<view class="date">2021.09.01-2021.09.15</view>
<view class="title">{{item.name}}</view>
<view class="date">{{item.created_at}}</view>
</view>
</view>
<!-- 空数据的情况 -->
<view class="loading-more">
<text v-if="tab.list.length"
:class="{'loading-more-text': tab.loadingClass}">{{ tab.loadingText }}</text>
<lf-nocontent v-else></lf-nocontent>
</view>
</view>
<view style="height: 30rpx;"></view>
</scroll-view>
@ -39,23 +46,29 @@
tab_current: 0,
tab_list: [{
name: '全部',
state: '',
list: [],
..._public
},{
name: '待参加',
state: '待使用',
list: [],
..._public
},{
name: '已参加',
state: '已使用',
list: [],
..._public
},{
name: '已过期',
state: '已过期',
list: [],
..._public
}],
scrollH: 0,
nav_height: 0
nav_height: 0,
isRefresher: true,
pageSize: 10
}
},
computed: {
@ -66,13 +79,96 @@
onLoad(){
let info = uni.getSystemInfoSync();
this.scrollH = info.screenHeight;
this.getMyActivity()
},
methods: {
//
onScrolltolower(){
let tab_item = this.tab_list[this.tab_current];
if(tab_item.isPage){
tab_item.page = tab_item.page + 1;
this.getMyActivity();
}
},
//
refreshFn(options){
let tab_item = this.tab_list[this.tab_current];
tab_item.page = 1;
tab_item.isPage = true;
tab_item.loadingClass = true;
tab_item.list = []
tab_item.loadingText = '正在加载中';
this.getMyActivity(options);
},
// scroll-view
onRefresherrefresh(){
this.isRefresher = true;
this.refreshFn({type: 'scrollRefresh'});
},
tabChange(event){
this.tab_current = event;
this.getMyActivity();
},
swiperChange(event){
this.tab_current = event.detail.current;
if (event.detail.source == '') return; //
this.getMyActivity();
},
getMyActivity(options = {}) {
let tab_item = this.tab_list[this.tab_current];
this.$http
.get({
api: 'api/activity/my',
data:{
state: tab_item.state,
page: tab_item.page,
page_size: this.pageSize
},
header: {
Authorization: `Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImp0aSI6IjczYTViNTA1NDNlYmNmMjFkNmZiMGJlNzc0NmJmMDE4MDc3MTRkY2Y1MjBiMjM3MGQyZDAyYzQxMTlmMDU4ZTkwMTUxNDQwOTk4MjJhODFhIn0.eyJhdWQiOiIzIiwianRpIjoiNzNhNWI1MDU0M2ViY2YyMWQ2ZmIwYmU3NzQ2YmYwMTgwNzcxNGRjZjUyMGIyMzcwZDJkMDJjNDExOWYwNThlOTAxNTE0NDA5OTgyMmE4MWEiLCJpYXQiOjE2MzExNjk1MDIsIm5iZiI6MTYzMTE2OTUwMiwiZXhwIjoxNjYyNzA1NTAyLCJzdWIiOiIxIiwic2NvcGVzIjpbXX0.p0YoIC_bhOxIOugYxDQTOFIK9t2ORiHQq9H6JWzdByBJKWkFDBisKaXZJvzn1HdU5cjNQnHaBfWpG1Ed15cQlB2LdpXxxc38iaaGW2J6WhlLhVkehloii-TtlZTOeqNrpAHbSe5DRrmm_L07Llm9wr1T1A6pP3MhzdHiZ9d6748j3_cJjK4CJUl3WfYRTaozLFlI00OCW4zzGfgivSighjSFyhqMoHnQ2iSoeWdcJnYpXzXQdc5AXvXOt6eIIa7o2F6Ma1tUseTYVijEVfngdfd21JI1eH6tHrSqUItkQHAart9o74dJn9micI3WrN5yEBXgzemqWkQGV4QzFHLyd3wk-XvP1s2GhCeWlJZOQADzgzhLoxzFUbgM5xULWHp3yfpePGISlM4ZpBwTHcqQt1i_UkNX_zCxa3RYQbZFDfWW0-UPbvHw40t5BY6X7nTPMhPjPGnnPq18jyYBrWBbC9vBWs2o2IHAe5VlkHtmy_v5fymFJLfFzS784Nxp2qPJFWxI7IfrpNckHxohhs5LoieQivw2MyU2shFOUjgwe0xQgyg6UBg5PwNknGTTmzYdavCM4BiQ7moqOuoI15ccIEmc_uMiuLVEfDPlzejP9PQv6mj6IlkJ8HSu4KZU-LxKmtLnGeEwMjVAZBIhsOwzMkaMF1nZ70pgv2YYwBQyVVs`
},
})
.then(res => {
if (res.data.code == 200) {
if (res.data.status) {
let isPage = res.data.next_page_url == null?false:true;
tab_item.isPage = isPage;
if(!isPage) {
tab_item.loadingClass = false;
tab_item.loadingText = '没有更多数据啦~';
}
if(options.type == 'pageRefresh') {
uni.stopPullDownRefresh();
}else if(options.type == 'scrollRefresh') {
this.isRefresher = false;
}
if(tab_item.page == 1) {
tab_item.list = res.data.data.data;
}else {
tab_item.list.push(...res.data.data.data);
}
console.log('数组列表',tab_item.list)
} else {
wx.showModal({
content: res.data.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: res.data.message || '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
}
}
}

57
pages/user/my/myregister.vue

@ -6,16 +6,16 @@
<view class="margin-auto">
<view class="register-card">
<view class="lf-flex lf-p-l-40 register-content">
<image class="register-head" src="https://hainan.lanzulive.com/storage/images/v2-deb89623e0ee2a2dad34bcded6dfd1ed_1440w.png" mode="aspectFill"></image>
<image class="register-head" :src="activity_details.image" mode="aspectFill"></image>
<view class="lf-color-black lf-m-l-21 lf-font-32">
LA MER海蓝之谜
{{activity_details.name}}
</view>
</view>
<view class="lf-p-l-40" style="position: relative;top: 160rpx;">
<view class="lf-font-36 lf-color-black lf-font-bold ">海蓝之谜美颜会</view>
<view class="lf-font-36 lf-color-black lf-font-bold ">{{activity_details.content}}</view>
<view class="lf-m-t-30">
<view class="lf-m-t-20">
<text class="lf-color-777 lf-font-28">活动时间</text><text class="lf-font-28 lf-color-black lf-m-l-10">2021.09.01-2021.09.15</text>
<text class="lf-color-777 lf-font-28">活动时间</text><text class="lf-font-28 lf-color-black lf-m-l-10">{{activity_details.apply_start}}-{{activity_details.apply_end}}</text>
</view>
<view class="lf-m-t-20">
<text class="lf-color-777 lf-font-28">活动地点</text><text class="lf-font-28 lf-color-black lf-m-l-10">海蓝之谜专卖店</text>
@ -24,7 +24,9 @@
<text class="lf-color-777 lf-font-28">报名时间</text><text class="lf-font-28 lf-color-black lf-m-l-10">2021.09.02 18:37:57</text>
</view>
<view class="lf-m-t-20">
<text class="lf-color-777 lf-font-28">报名费用</text><text class="lf-font-28 lf-color-black lf-m-l-10">免费</text>
<text class="lf-color-777 lf-font-28">报名费用</text>
<text class="lf-font-28 lf-color-black lf-m-l-10" v-if="activity_details.price == 0">免费</text>
<text class="lf-font-28 lf-color-black lf-m-l-10" v-else>{{activity_details.price}}</text>
</view>
<view style="margin-top: 60rpx;display: flex;justify-content: center;">
<view class="lf-flex-column">
@ -77,9 +79,52 @@
color: '#000000', //
}
},
activity_id: 0,
activity_details: ''
}
},
components: {lfQrcode}
components: {lfQrcode},
onLoad(e) {
this.activity_id = e.activity_id;
this.getMyActivetiDetails();
},
methods: {
getMyActivetiDetails() {
this.$http
.get({
api: 'api/activity/detail',
data: {
activity_id: this.activity_id
}
})
.then(res => {
if (res.data.code == 200) {
if (res.data.status) {
this.activity_details = res.data.data;
console.log('活动详情',this.activity_details);
} else {
wx.showModal({
content: res.message || '请下拉页面刷新重试',
showCancel: false
});
}
} else {
wx.showModal({
content: '请下拉页面刷新重试',
showCancel: false
});
}
wx.hideLoading();
})
.catch(() => {
wx.hideLoading();
wx.showModal({
content: '请求失败',
showCancel: false
});
});
}
}
}
</script>

Loading…
Cancel
Save