Browse Source

新增了推广页面

v1
longjieli 5 months ago
parent
commit
c71e04697a
3 changed files with 133 additions and 10 deletions
  1. +7
    -0
      pages.json
  2. +15
    -10
      pages/center/center.vue
  3. +111
    -0
      pages/promotion/promotion.vue

+ 7
- 0
pages.json View File

@ -29,6 +29,13 @@
"style": { "style": {
"navigationBarTitleText": "婚庆服务" "navigationBarTitleText": "婚庆服务"
} }
},
{
"path" : "pages/promotion/promotion",
"style" :
{
"navigationBarTitleText" : ""
}
} }
], ],
"globalStyle": { "globalStyle": {


+ 15
- 10
pages/center/center.vue View File

@ -23,17 +23,13 @@
</view> --> </view> -->
<view class="topBox"> <view class="topBox">
<view class="users"> <view class="users">
<view class="u-top"
@click="$utils.navigateTo('/login/wxUserInfo')"
v-if="userInfo.appletOpenid">
<view class="u-top" @click="$utils.navigateTo('/login/wxUserInfo')" v-if="userInfo.appletOpenid">
<image class="img" :src="userInfo.headImage" mode="widthFix"></image> <image class="img" :src="userInfo.headImage" mode="widthFix"></image>
<view class="tit"> <view class="tit">
{{ userInfo.nickName }} {{ userInfo.nickName }}
</view> </view>
</view> </view>
<view class="u-top"
v-else
@click="$utils.navigateTo('/login/login')">
<view class="u-top" v-else @click="$utils.navigateTo('/login/login')">
<image class="img" <image class="img"
src="https://img2.baidu.com/it/u=2953585264,744730101&fm=253&fmt=auto&app=138&f=JPEG?w=360&h=360" src="https://img2.baidu.com/it/u=2953585264,744730101&fm=253&fmt=auto&app=138&f=JPEG?w=360&h=360"
mode="widthFix"></image> mode="widthFix"></image>
@ -46,6 +42,8 @@
<view class="listBox"> <view class="listBox">
<view class="lists"> <view class="lists">
<uni-section @click="toPromotion" title="推广" type="line" titleFontSize="34rpx"
style="border-radius: 10rpx;"></uni-section>
<uni-section title="我的订单" type="line" titleFontSize="34rpx" <uni-section title="我的订单" type="line" titleFontSize="34rpx"
style="border-radius: 10rpx;"></uni-section> style="border-radius: 10rpx;"></uni-section>
<view class="order-list"> <view class="order-list">
@ -89,7 +87,7 @@
pageSize: 10 pageSize: 10
}, },
orderList: [], orderList: [],
total : 0
total: 0
} }
}, },
onShow() { onShow() {
@ -100,7 +98,7 @@
}, },
// //
onReachBottom() { onReachBottom() {
if(this.queryParams.pageSize < this.total){
if (this.queryParams.pageSize < this.total) {
this.queryParams.pageSize += 10 this.queryParams.pageSize += 10
this.getOrderList() this.getOrderList()
} }
@ -113,6 +111,13 @@
this.total = res.result.total this.total = res.result.total
}) })
}, },
//广
toPromotion(){
uni.navigateTo({
url: '/pages/promotion/promotion'
})
}
} }
} }
</script> </script>
@ -243,8 +248,8 @@
align-items: center; align-items: center;
margin-top: 20rpx; margin-top: 20rpx;
} }
.oldPrice{
.oldPrice {
margin-left: 10rpx; margin-left: 10rpx;
color: #757575; color: #757575;
text-decoration: line-through; text-decoration: line-through;


+ 111
- 0
pages/promotion/promotion.vue View File

@ -0,0 +1,111 @@
<template>
<view class="promotion">
<uni-nav-bar dark :fixed="true" background-color="#00aaff" :border="false" status-bar title="推广" />
<view class="promotion-card">
<view class="user-info">
<!-- <image :src="userInfo.headImage" mode=""></image> -->
<image class="image" src="../../static/logo.png" mode="widthFix"></image>
<!-- <view class="user-name">{{ userInfo.nickName }}</view> -->
<view class="user-name">湖南第一深情</view>
</view>
<view class="invitation-code-img">
<image class="image" src="../../static/logo.png" mode="widthFix"></image>
</view>
<view class="invitation-code">邀请码: sjflshf</view>
</view>
<view class="btns">
<view class="btn">保存海报</view>
<view class="btn">立即邀请</view>
</view>
</view>
</template>
<script>
import {
mapState
} from 'vuex'
export default {
name: 'Promotion',
computed: {
...mapState(['userInfo']),
},
data() {
return {
}
},
methods: {
}
}
</script>
<style lang="scss" scoped>
.promotion {
.promotion-card {
width: 90%;
margin: 100rpx auto 0rpx auto;
box-shadow: 0rpx 0rpx 15rpx rgba(0, 0, 0, .2);
border-radius: 15rpx;
padding: 40rpx 30rpx;
box-sizing: border-box;
.user-info {
display: flex;
align-items: center;
.image {
width: 80rpx;
height: 80rpx;
border-radius: 50%;
margin-right: 10rpx;
}
.user-name {
font-size: 30rpx;
}
}
.invitation-code-img {
display: flex;
align-items: center;
justify-content: center;
margin: 100rpx 0rpx;
.image {
width: 30%;
border-radius: 50%;
}
}
.invitation-code {
text-align: center;
color: #818181;
font-size: 28rpx;
}
}
.btns {
position: fixed;
left: 0;
bottom: 0;
width: 100%;
height: 90rpx;
display: flex;
background: #00aaff;
color: white;
font-size: 28rpx;
.btn {
width: 50%;
display: flex;
align-items: center;
justify-content: center;
&:nth-child(2) {
background: orange;
}
}
}
}
</style>

Loading…
Cancel
Save