shortPlay-mini/pages/my/inviteFriend/inviteFriend.vue

141 lines
2.7 KiB
Vue

<template>
<view class="p-20">
<view class="box">
<view class="flex flex-col justify-center items-center income">
<view>我的收入()</view>
<view class="number">0.00</view>
</view>
<view class="flex flex-row three-row">
<view class="flex-1 flex flex-col justify-center items-center">
<text>邀请人数</text>
<text>0</text>
</view>
<view class="flex-1 flex flex-col justify-center items-center">
<text>本月收入</text>
<text>0</text>
</view>
<view class="flex-1 flex flex-col justify-center items-center">
<text>上月收入</text>
<text>0</text>
</view>
</view>
<view class="range">
<u-cell title="邀请规则" isLink></u-cell>
</view>
</view>
<view style="padding: 40upx 20upx;">
<u-button shape="circle" type="primary">去邀请</u-button>
</view>
<view>
<u-tabs style="padding: 20upx 0;" :scrollable="false" :list="tabs" lineColor="#007aff" :activeStyle="{
color: '#303133',
fontWeight: 'bold'
}" :inactiveStyle="{
color: '#606266',
transform: 'scale(1)'
}" itemStyle="height: 34px; padding-bottom: 10upx;" @change="change">
</u-tabs>
</view>
<view class="content">
<view class="table" v-if="currentIndex === 0">
<view class="table-line flex flex-row">
<view>ID</view>
<view>昵称</view>
<view>手机号码</view>
<view>注册时间</view>
</view>
<view class="table-line flex flex-row">
<view>1</view>
<view>张三</view>
<view>13547478909</view>
<view>2020-10-01</view>
</view>
</view>
<view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
tabs: [{
name: '邀请记录'
}, {
name: '收入记录'
}],
currentIndex: 0
}
},
methods: {
change(e) {
this.currentIndex = e.index
}
}
}
</script>
<style lang="scss">
.box {
border-radius: 20upx;
background-color: #fff;
color: #7a797a;
font-size: 30upx;
overflow: hidden;
.income {
padding: 40upx;
}
.number {
color: #363636;
font-size: 45upx;
font-weight: bold;
}
.range {
border-top: 1upx solid #f6f6f6;
}
.three-row {
padding-bottom: 20upx;
}
}
.table{
padding-top: 20upx;
}
.table-line {
width: calc(100vw - 40upx);
color: #a6a6a6;
font-size: 28upx;
background-color: #fff;
padding: 10upx;
box-sizing: border-box;
view {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
&:first-child {
width: 13%;
}
&:nth-child(2) {
width: 25%;
}
&:nth-child(3) {
width: 37%;
}
&:nth-child(4) {
width: 25%;
}
}
}
::v-deep .box .u-cell:last-child {
.u-line {
display: none !important;
}
}
</style>