You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
yanzong_qianduan/pages/news3/JoinDistribution.vue

322 lines
7.0 KiB

10 months ago
<template>
<view>
9 months ago
<view class="status-box"></view>
<view style="width:100%;position: fixed;top:var(--status-bar-height);z-index:99">
10 months ago
<view class="navBarContent">
9 months ago
<u-icon name="arrow-left" @click="goBack()" style="position: absolute;top:50%;left:50rpx;transform: translateY(-50%);" color="#000" size="24"></u-icon>
10 months ago
<text>加入分销</text>
</view>
</view>
10 months ago
<image :src="$picUrl+'/static/news3/walletBg.png'" mode="widthFix" class="bgImg"></image>
10 months ago
<view class="userInfo">
10 months ago
<image :src="$picUrl+'/static/news3/join.png'" mode="widthFix"></image>
10 months ago
<view class="userContent">
<view v-if="user">
<image src="{{user.avatar_url?'/static/news3/walletBg.png':'/static/news3/walletBg.png'}}" mode="aspectFill" class="avatar"></image>
</view>
10 months ago
<view class="user">
<view class="userTop">
<text class="name">{{ user.nick_name||'' }}</text>
10 months ago
<view class="flag">
分销商
</view>
</view>
<view class="userBottom">
9 months ago
<text>加入时间{{dealer.update_time}}</text>
<view class="tixian" @click="$navTo('pages/dealer/withdraw/apply')">
10 months ago
提现
</view>
</view>
</view>
</view>
</view>
<view class="yongjinContent">
<view class="item">
<text class="num">
9 months ago
<!-- {{ setting.words.index.words.money.value }} -->
{{ dealer.money }}
10 months ago
</text>
<text class="text">已提现佣金</text>
</view>
<view class="item">
<text class="num">
9 months ago
<!-- {{ setting.words.index.words.freeze_money.value }} -->
{{ dealer.freeze_money }}
10 months ago
</text>
<text class="text">未结算佣金</text>
</view>
</view>
<view class="gridContent">
<view class="gridItem">
10 months ago
<image :src="$picUrl+'/static/news3/fx1.png'" mode="widthFix"></image>
10 months ago
<text>分销佣金</text>
</view>
9 months ago
<view class="gridItem" @click="$navTo('pages/dealer/order')">
10 months ago
<image :src="$picUrl+'/static/news3/fx2.png'" mode="widthFix"></image>
10 months ago
<text>分销订单</text>
</view>
9 months ago
<view class="gridItem" @click="$navTo('pages/dealer/withdraw/list')">
10 months ago
<image :src="$picUrl+'/static/news3/fx3.png'" mode="widthFix"></image>
10 months ago
<text>提现明细</text>
</view>
9 months ago
<view class="gridItem" @click="$navTo('pages/dealer/team')">
10 months ago
<image :src="$picUrl+'/static/news3/fx4.png'" mode="widthFix"></image>
10 months ago
<text>我的团队</text>
</view>
9 months ago
<view class="gridItem" @click="$navTo('pages/dealer/poster')">
10 months ago
<image :src="$picUrl+'/static/news3/fx5.png'" mode="widthFix"></image>
10 months ago
<text>推广二维码</text>
</view>
</view>
</view>
</template>
<script>
9 months ago
import AvatarImage from '@/components/avatar-image'
import * as Api from '@/api/dealer'
10 months ago
export default {
data() {
return {
9 months ago
// 正在加载
isLoading: true,
// 当前用户信息
user: {},
9 months ago
// 当前是否为分销商
isDealer: false,
// 当前分销商信息
dealer: {},
9 months ago
// 推荐人昵称
refereeName: undefined,
// 分销设置
setting: {
background: undefined,
words: undefined
}
10 months ago
};
},
9 months ago
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.getCenter()
},
10 months ago
methods:{
/**
* 售后点击
*/
9 months ago
goBack(){
uni.navigateBack({ // 调用uni-app提供的跳转API
delta: 1 // 表示返回上一个页面,若为0则表示不进行任何操作
});
},
// 获取分销商中心数据
getCenter() {
const app = this
app.isLoading = true
Api.center()
.then(result => {
// api数据赋值
const data = result.data
app.isDealer = data.isDealer
app.user = data.user||{};
9 months ago
app.dealer = data.dealer
app.refereeName = data.refereeName
app.setting = data.setting
// 设置当前页面标题
app.setPageTitle()
app.isLoading = false
})
},
10 months ago
onApplyAftersales(){
uni.navigateTo({
9 months ago
url: '/pages/dealer/poster',
10 months ago
})
9 months ago
},
// 设置当前页面标题
setPageTitle() {
uni.setNavigationBarTitle({
title: this.setting.words.index.title.value
})
10 months ago
}
}
}
</script>
<style scoped lang="scss">
page{
background-color: #F7F8FA;
min-height: 100%;
padding-bottom: 140upx;
padding-top:200upx;
}
9 months ago
.status-box{
height: var(--status-bar-height);
}
10 months ago
.bgImg{
width:100%;
height:auto;
position:absolute;
top:0;
left:0;
9 months ago
z-index:-1;
10 months ago
}
.navBarContent{
height:88upx;
line-height: 88upx;
text-align: center;
position: relative;
text{
font-size: 32upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #000;
}
}
.userInfo{
position: relative;
z-index:3;
9 months ago
margin:130upx 30upx 0;
10 months ago
image{
width:100%;
height:auto;
}
.userContent{
position: absolute;
top:0;
left:0;
width:100%;
height:100%;
display: flex;
padding:52upx 30upx;
display: flex;
align-items: center;
justify-content: space-between;
.avatar{
width:114upx;
height:114upx;
}
.user{
margin-left:30upx;
flex:1;
.userTop{
display: flex;
align-items: center;
.name{
font-size: 36upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #785B45;
margin-right:20upx;
}
.flag{
height: 42upx;
background: rgba(255,255,255,0.71);
border-radius: 31px 31px 31px 31px;
opacity: 1;
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #785B45;
line-height: 42upx;
text-align: center;
padding:0 20upx;
}
}
.userBottom{
display: flex;
align-items: center;
justify-content: space-between;
margin-top:26upx;
text{
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #785B45;
}
.tixian{
padding:12upx 36upx;
background: linear-gradient(180deg, #AF8D72 0%, #7D5C45 100%);
border-radius: 29px 29px 29px 29px;
opacity: 1;
font-size: 24upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #FFFFFF;
}
}
}
}
}
.yongjinContent{
background: #FFFFFF;
border-radius: 6px 6px 6px 6px;
opacity: 1;
padding:42upx 0;
display: flex;
align-items: center;
justify-content: space-around;
margin:20upx 30upx;
.item{
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
.num{
font-size: 40upx;
font-family: PingFang SC, PingFang SC;
font-weight: 500;
color: #414141;
}
.text{
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #616161;
margin-top:10upx;
}
}
}
.gridContent{
display: flex;
background-color: #fff;
flex-wrap: wrap;
margin:0upx 30upx;
padding:20upx 0;
.gridItem{
width:33%;
margin:30upx 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
image{
height:auto;
width:50upx;
}
text{
font-size: 28upx;
font-family: PingFang SC, PingFang SC;
font-weight: 400;
color: #616161;
margin-top:16upx;
}
}
}
</style>