|
|
<template>
|
|
|
<div style="height: 100%;">
|
|
|
<div class="coupon-page">
|
|
|
<ClassicTabs ref="tabs" v-model="selectLabel" :data="tabLabels" :filterId.sync="selectFilterId"></ClassicTabs>
|
|
|
|
|
|
<div class="tab-slide-container">
|
|
|
<Slide
|
|
|
ref="slide"
|
|
|
:loop="false"
|
|
|
:auto-play="false"
|
|
|
:show-dots="false"
|
|
|
:initial-index="initialIndex"
|
|
|
:options="slideOptions"
|
|
|
@scroll="scroll"
|
|
|
@change="changePage"
|
|
|
>
|
|
|
<SlideItem style="background-color: #f0f0f0;">
|
|
|
<ExchangeBox v-model="inputCouponCode" @click="onSubmitCode"></ExchangeBox>
|
|
|
|
|
|
<ScrollView class="scroll-view1" ref="notuse" :data="getNotUseList" :options="scrollOptions" v-if="getNotUseList.length" :reach-bottom="reachBottom">
|
|
|
<CouponItem :item="item" v-for="(item, index) in getNotUseList" :key="index + '' + item.coupon_id"></CouponItem>
|
|
|
</ScrollView>
|
|
|
<Empty v-else></Empty>
|
|
|
</SlideItem>
|
|
|
|
|
|
<SlideItem style="background-color: #f0f0f0;">
|
|
|
<ScrollView class="scroll-view2" ref="use" :data="getUseList" :options="scrollOptions" v-if="getUseList.length" :reach-bottom="reachBottom">
|
|
|
<CouponItem :item="item" v-for="(item, index) in getUseList" :key="index + '' + item.coupon_id"></CouponItem>
|
|
|
</ScrollView>
|
|
|
<Empty v-else></Empty>
|
|
|
</SlideItem>
|
|
|
|
|
|
<SlideItem style="background-color: #f0f0f0;">
|
|
|
<ScrollView class="scroll-view2" ref="overtime" :data="getOvertimeList" :options="scrollOptions" v-if="getOvertimeList.length" :reach-bottom="reachBottom">
|
|
|
<CouponItem :item="item" v-for="(item, index) in getOvertimeList" :key="index + '' + item.coupon_id"></CouponItem>
|
|
|
</ScrollView>
|
|
|
<Empty v-else></Empty>
|
|
|
</SlideItem>
|
|
|
</Slide>
|
|
|
</div>
|
|
|
<Slide
|
|
|
class="slide-box"
|
|
|
ref="slide"
|
|
|
:loop="false"
|
|
|
:auto-play="false"
|
|
|
:show-dots="false"
|
|
|
:initial-index="initialIndex"
|
|
|
:options="slideOptions"
|
|
|
@scroll="scroll"
|
|
|
@change="changePage"
|
|
|
>
|
|
|
<SlideItem class="slide-item">
|
|
|
<ExchangeBox class="" v-model="inputCouponCode" @click="onSubmitCode"></ExchangeBox>
|
|
|
<ScrollView class="scroll-view" ref="notuse" :data="getNotUseList" :options="scrollOptions" v-if="getNotUseList.length" :reach-bottom="reachBottom">
|
|
|
<CouponItem :item="item" v-for="(item, index) in getNotUseList" :key="index + '' + item.coupon_id"></CouponItem>
|
|
|
</ScrollView>
|
|
|
<Empty v-else></Empty>
|
|
|
</SlideItem>
|
|
|
|
|
|
<SlideItem class="slide-item">
|
|
|
<ScrollView class="scroll-view" ref="use" :data="getUseList" :options="scrollOptions" v-if="getUseList.length" :reach-bottom="reachBottom">
|
|
|
<CouponItem :item="item" v-for="(item, index) in getUseList" :key="index + '' + item.coupon_id"></CouponItem>
|
|
|
</ScrollView>
|
|
|
<Empty v-else></Empty>
|
|
|
</SlideItem>
|
|
|
|
|
|
<SlideItem class="slide-item">
|
|
|
<ScrollView class="scroll-view" ref="overtime" :data="getOvertimeList" :options="scrollOptions" v-if="getOvertimeList.length" :reach-bottom="reachBottom">
|
|
|
<CouponItem :item="item" v-for="(item, index) in getOvertimeList" :key="index + '' + item.coupon_id"></CouponItem>
|
|
|
</ScrollView>
|
|
|
<Empty v-else></Empty>
|
|
|
</SlideItem>
|
|
|
</Slide>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
...
|
...
|
@@ -189,19 +186,31 @@ export default { |
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
|
.page-wrapper {
|
|
|
height: calc(100% - 90px);
|
|
|
}
|
|
|
.coupon-page {
|
|
|
width: 100%;
|
|
|
height: 100%;
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
|
}
|
|
|
|
|
|
.tab-slide-container {
|
|
|
height: 100%;
|
|
|
}
|
|
|
.slide-box {
|
|
|
flex: 1;
|
|
|
}
|
|
|
|
|
|
.scroll-view1 {
|
|
|
height: calc(100% - 270px);
|
|
|
}
|
|
|
.page-wrapper {
|
|
|
height: calc(100% - 90px);
|
|
|
}
|
|
|
|
|
|
.slide-item {
|
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
|
|
|
|
.scroll-view2 {
|
|
|
height: calc(100% - 180px);
|
|
|
.scroll-view {
|
|
|
flex: 1;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
.tab-slide-container {
|
|
|
height: 100%;
|
|
|
}
|
|
|
</style> |
...
|
...
|
|