This commit is contained in:
zhaohengkun 2024-10-12 11:02:16 +08:00
commit db50b79180

View File

@ -4,11 +4,15 @@
<view class="card_box"> <view class="card_box">
<view style="margin: 13px 0px;">当前积分</view> <view style="margin: 13px 0px;">当前积分</view>
<view class="r-num">{{cardBalance.points || 0}}</view> <view class="r-num">{{ cardBalance.points || 0 }}</view>
</view> </view>
<view class="tab-bs"> <view class="tab-bs">
<view class="w_box" @click="show1 = true">类型筛选 <u-icon name="arrow-down-fill"></u-icon> </view> <view class="w_box" @click="show1 = true">类型筛选
<view class="w_box" @click="show = true">全部时间 <u-icon name="arrow-down-fill"></u-icon> </view> <u-icon name="arrow-down-fill"></u-icon>
</view>
<view class="w_box" @click="show = true">全部时间
<u-icon name="arrow-down-fill"></u-icon>
</view>
</view> </view>
<view class="bai_box" v-for="(item,index) in pointsList" :key="index"> <view class="bai_box" v-for="(item,index) in pointsList" :key="index">
<view class="left-img"> <view class="left-img">
@ -17,18 +21,18 @@
</view> </view>
<view style="width: 85%;"> <view style="width: 85%;">
<view class="right-box"> <view class="right-box">
<view class="l-text">{{item.changeReason}}</view> <view class="l-text">{{ item.changeReason }}</view>
<view class="r-text" v-if="item.changeType==1">{{item.pointsChange}}</view> <view class="r-text" v-if="item.changeType==1">{{ item.pointsChange }}</view>
<view class="r-text" v-else-if="item.changeType==0">-{{item.pointsChange}}</view> <view class="r-text" v-else-if="item.changeType==0">-{{ item.pointsChange }}</view>
<view class="r-text" v-else>0</view> <view class="r-text" v-else>0</view>
</view> </view>
<view class="right-box"> <view class="right-box">
<view class="">会员积分</view> <view class="">会员积分</view>
<view class="">余额{{item.currentPoints || 0}}</view> <view class="">余额{{ item.currentPoints || 0 }}</view>
</view> </view>
<view class="right-box"> <view class="right-box">
<view class="">{{item.storeName}}</view> <view class="">{{ item.storeName }}</view>
<view class="">{{item.createTime}}</view> <view class="">{{ item.createTime }}</view>
</view> </view>
</view> </view>
</view> </view>
@ -76,14 +80,15 @@
</view> --> </view> -->
<u-datetime-picker :show="show" v-model="value1" mode="year-month" @cancel="cancel1" <u-datetime-picker :show="show" v-model="value1" mode="year-month" @cancel="cancel1"
@confirm="confirm1"></u-datetime-picker> @confirm="confirm1"></u-datetime-picker>
<u-picker :show="show1" :columns="columns" @cancel="cancel" @confirm="confirm"></u-picker> <u-picker :show="show1" :columns="columns" @cancel="cancel" keyName="label" @confirm="confirm"></u-picker>
</view> </view>
</view> </view>
</template> </template>
<script> <script>
import request from '../../utils/request' import request from '../../utils/request'
export default {
export default {
data() { data() {
return { return {
query: { query: {
@ -98,8 +103,44 @@
show1: false, show1: false,
value1: Number(new Date()), value1: Number(new Date()),
columns: [ columns: [
['全部类型', '消费有礼', '充值有礼', '积分兑换', '开卡有礼', '邀请有礼', '生日有礼', '推荐会员充值有礼', [{
'推荐会员推荐有礼', '每日签到', '大转盘抽奖', '九宫格抽奖' label: '全部类型',
value: null
}, {
label: '消费有礼',
value: ''
}, {
label: '充值有礼',
value: ''
}, {
label: '积分兑换',
value: ''
}, {
label: '开卡有礼',
value: ''
}, {
label: '邀请有礼',
value: ''
}, {
label: '生日有礼',
value: ''
}, {
label: '推荐会员充值有礼',
value: ''
},
{
label: '推荐会员推荐有礼',
value: ''
}, {
label: '每日签到',
value: ''
}, {
label: '大转盘抽奖',
value: ''
}, {
label: '九宫格抽奖',
value: ''
}
] ]
], ],
queryParams: { queryParams: {
@ -167,9 +208,9 @@
confirm(e) { confirm(e) {
this.queryParams.pageNo = 1 this.queryParams.pageNo = 1
if (e.value[0] == '全部类型') { if (e.value[0] == '全部类型') {
this.queryParams.type = "" this.queryParams.type = null
} else { } else {
this.queryParams.type = e.value[0] this.queryParams.type = e.value[0].type
} }
this.getList() this.getList()
this.show1 = false this.show1 = false
@ -196,23 +237,23 @@
this.show = false this.show = false
} }
} }
} }
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
.centenr { .centenr {
width: 100%; width: 100%;
height: 100vh; height: 100vh;
background: #F9F9F9; background: #F9F9F9;
} }
.Candywrapper { .Candywrapper {
background: #F9F9F9; background: #F9F9F9;
box-sizing: border-box; box-sizing: border-box;
padding: 10px; padding: 10px;
} }
.card_box { .card_box {
width: 100%; width: 100%;
height: 90px; height: 90px;
background: url('../../static/imgs/jf.png') no-repeat; background: url('../../static/imgs/jf.png') no-repeat;
@ -221,40 +262,40 @@
padding: 10px; padding: 10px;
color: #fff; color: #fff;
font-size: 14px; font-size: 14px;
} }
.r-size { .r-size {
width: 100%; width: 100%;
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: flex-end; justify-content: flex-end;
} }
.r-num { .r-num {
font-weight: 600; font-weight: 600;
font-size: 20px; font-size: 20px;
color: #FFFFFF; color: #FFFFFF;
} }
.tab-bs { .tab-bs {
width: 100%; width: 100%;
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
background: #fff; background: #fff;
margin: 15px auto; margin: 15px auto;
} }
.w_box { .w_box {
width: 50%; width: 50%;
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: center; justify-content: center;
box-sizing: border-box; box-sizing: border-box;
padding: 15px; padding: 15px;
} }
.bai_box { .bai_box {
width: 100%; width: 100%;
box-sizing: border-box; box-sizing: border-box;
padding: 15px 10px; padding: 15px 10px;
@ -262,37 +303,37 @@
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
} }
.left-img { .left-img {
margin-right: 10px; margin-right: 10px;
image { image {
width: 40px; width: 40px;
height: 40px; height: 40px;
} }
} }
.right-box { .right-box {
width: 100%; width: 100%;
display: flex; display: flex;
align-items: center; align-items: center;
justify-content: space-between; justify-content: space-between;
font-size: 12px; font-size: 12px;
color: #666666; color: #666666;
} }
.l-text { .l-text {
font-size: 16px; font-size: 16px;
color: #333333; color: #333333;
margin-bottom: 5px; margin-bottom: 5px;
font-weight: bold; font-weight: bold;
} }
.r-text { .r-text {
font-size: 16px; font-size: 16px;
color: #333333; color: #333333;
margin-bottom: 5px; margin-bottom: 5px;
font-weight: bold; font-weight: bold;
} }
</style> </style>