123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162 |
- <template>
- <view>
- <u-navbar :placeholder="true" bgColor="#fff" :autoBack="true" :border="true" title="卡券使用记录"></u-navbar>
- <!-- 卡券筛选 -->
- <view class="prize-state">
- <u-tabs @change="changeTab" :scrollable="false" :list="stateArr" lineWidth="40" lineHeight="1"
- lineColor="#D70909" :activeStyle="{
- color: '#D70909',
- transform: 'scale(1)'
- }" :inactiveStyle="{
- color: '#333',
- transform: 'scale(1)'
- }" itemStyle="padding-left: 25px; padding-right: 25px; height: 44px;">
- </u-tabs>
- </view>
- <!-- 已使用 -->
- <view class="prize-coupon">
- <view class="prize-coupon-list">
- <view class="flex prize-coupon-list-item">
- <image src="../../static/logo.png" mode=""></image>
- <view class="flex info">
- <view class="flex desc">
- <view class="title">200元代金券</view>
- <view class="txt">使用期限:2022.03.02-2022.04.01</view>
- <view class="txt">适用范围:星巴克xxx店</view>
- </view>
- <view class="flex btn">
- <view class="amt"><text>¥</text>100</view>
- </view>
- <view class="state">已使用</view>
- </view>
- </view>
- <view class="flex prize-coupon-list-item">
- <image src="../../static/logo.png" mode=""></image>
- <view class="flex info">
- <view class="flex desc">
- <view class="title">200元代金券</view>
- <view class="txt">使用期限:2022.03.02-2022.04.01</view>
- <view class="txt">适用范围:星巴克xxx店</view>
- </view>
- <view class="flex btn">
- <view class="amt"><text>¥</text>100</view>
- </view>
- <view class="state">已过期</view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- export default {
- data() {
- return {
- stateArr: [{
- name: '已使用'
- }, {
- name: '已过期',
- }],
- state: 0,
- };
- },
- methods: {
- changeTab(e) {
- if (e.index == 0) {
- this.state = 0
- } else if (e.index == 1) {
- this.state = 1
- }
- },
- changeChecked() {
- },
- }
- }
- </script>
- <style lang="scss" scoped>
- .prize-state {
- position: fixed;
- background-color: #FFFFFF;
- width: 100%;
- padding-bottom: 16rpx;
- z-index: 10;
- }
- .prize-coupon {
- margin-top: 104rpx;
- padding: 40rpx 30rpx 100rpx;
- &-list {
- &-item {
- justify-content: space-between;
- background-color: #FFFFFF;
- padding: 40rpx 20rpx;
- border-radius: 10rpx;
- margin-bottom: 40rpx;
- image {
- width: 94rpx;
- height: 132rpx;
- }
- .info {
- position: relative;
- justify-content: space-between;
- flex: 1;
- }
- .desc {
- height: 132rpx;
- flex-direction: column;
- justify-content: space-between;
- align-items: flex-start;
- padding-left: 20rpx;
- }
- .txt {
- font-size: 24rpx;
- }
- .btn {
- flex-direction: column;
- }
- .amt {
- font-size: 48rpx;
- font-weight: bold;
- line-height: 72rpx;
- }
- text {
- font-size: 24rpx;
- }
-
- .state{
- position: absolute;
- right: 50rpx;
- transform: rotate(20deg);
- -webkit-transform:rotate(20deg);
- width: 150rpx;
- height: 150rpx;
- line-height: 150rpx;
- border: #E1E1E1 4px solid;
- border-radius: 50%;
- background-color: #f9f2ef;
- text-align: center;
- color: #000000;
- opacity: .5;
- }
- }
- &-item:last-child {
- margin-bottom: 0;
- }
- }
- }
- </style>
|