会员相关更新、商品列表更新

This commit is contained in:
GaoHao
2024-08-16 18:09:09 +08:00
26 changed files with 1891 additions and 2186 deletions

View File

@@ -1,180 +0,0 @@
<template>
<!-- 账单明细 -->
<view>
<view class="bild">
<view class="bildLeft">
<text>我的余额</text>
<view>{{info.amount}}</view>
</view>
<view class="bildRight">
<text>我的积分</text>
<view>{{info.levelConsume}}</view>
</view>
</view>
<view class="navTop">
<view @click="clickEvent(1)" :class="[active==1?'fonts':'']">
余额明细
<view :class="[active==1?'xian':'']" style="left: 36rpx;"> </view>
</view>
<view @click="clickEvent(2)" :class="[active==2?'fonts':'']">
积分明细
<view :class="[active==2?'xian':'']" style="left: 36rpx;"> </view>
</view>
</view>
<view class="listStyle" v-for="(item,i) in list" :key="i">
<!-- <image :src="require('')" style="width: 76rpx;height: 76rpx;float: left;" mode=""></image> -->
<view class="listrigth">
<view>{{item.biz_name}}</view>
<view :class="[item.type == '+'?'colorStyle':'']">{{item.type}}{{item.amount}}
</view>
</view>
<view class="listrigth2">
<view>{{$u.timeFormat(item.create_time, 'yyyy-mm-dd hh:MM:ss')}}</view>
<view>余额:{{item.balance}}</view>
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
active: 1,
list: [],
form: {
page: 1,
pageSize: 10,
memberId: null
},
info: null
}
},
onLoad(e) {
this.info = e
this.form.memberId = e.memberId
this.getlist()
},
onReachBottom() {
this.getlist()
},
methods: {
// 检测是否包含In
checkIn(str) {
let reg = RegExp(/In/)
return str.match(reg)
},
async getlist() {
if (this.active == 1) {
let res = await this.api.queryMemberAccount(this.form)
if (res.code == 0) {
if (this.form.page == 1) {
this.list = res.data.list
} else {
this.form.page++
this.list.push(res.data.list)
}
}
} else {
this.list = []
}
},
clickEvent(i) {
this.active = i
this.getlist()
}
}
}
</script>
<style scoped lang="less">
.bild {
height: 320rpx;
background-image: url('https://czg-qr-order.oss-cn-beijing.aliyuncs.com/drder/czmxbg.png');
background-size: 750rpx 320rpx;
display: flex;
justify-content: space-around;
align-items: center;
.bildLeft,
.bildRight {
font-weight: 400;
font-size: 32rpx;
>view,
>text {
text-align: center;
color: #333;
}
>view {
margin-top: 34rpx;
font-weight: bold;
}
}
}
.navTop {
display: flex;
justify-content: space-around;
align-items: center;
color: #333;
margin-top: -60rpx;
padding: 0 120rpx;
.fonts {
font-size: 34rpx;
}
>view {
position: relative;
.xian {
width: 58rpx;
height: 6rpx;
background: #FFAA62;
border-radius: 2rpx 2rpx 2rpx 2rpx;
position: absolute;
bottom: -16rpx;
}
}
}
.listStyle {
padding: 28rpx;
padding-top: 50rpx;
width: 100%;
.listrigth,
.listrigth2 {
display: flex;
justify-content: space-between;
align-items: center;
// padding-left: 32rpx;
}
.listrigth {
.colorStyle {
color: #FF7127;
}
>view {
font-weight: bold;
font-size: 32rpx;
color: #333333;
}
}
.listrigth2 {
margin-top: 6rpx;
>view {
font-weight: 500;
font-size: 24rpx;
color: #666666;
}
}
}
</style>

View File

@@ -21,17 +21,22 @@
<view :class="[active==2?'xian':'']" style="left: 36rpx;"> </view>
</view>
</view>
<view class="listStyle" v-for="(item,i) in list" :key="i">
<!-- <image :src="require('')" style="width: 76rpx;height: 76rpx;float: left;" mode=""></image> -->
<view class="listrigth">
<view>{{item.biz_name}}</view>
<view :class="[item.type == '+'?'colorStyle':'']">{{item.type}}{{item.amount}}
<view class="listStyle " v-for="(item,i) in list" :key="i">
<image class="head_img" :src="item.head_img?item.head_img:'https://czg-qr-order.oss-cn-beijing.aliyuncs.com/menber/head_default.png'" style="width: 76rpx;height: 76rpx;float: left;" mode=""></image>
<view class="flex-start">
<view class="listStyle_left">
<view class="listrigth">
<view>{{item.biz_name}}</view>
<view :class="[item.type == '+'?'colorStyle':'']">{{item.type}}{{item.amount}}
</view>
</view>
</view>
<view class="listrigth2">
<view>{{$u.timeFormat(item.create_time, 'yyyy-mm-dd hh:MM:ss')}}</view>
<view>余额:{{item.balance}}</view>
</view>
</view>
<view class="listrigth2">
<view>{{$u.timeFormat(item.create_time, 'yyyy-mm-dd hh:MM:ss')}}</view>
<view>余额:{{item.balance}}</view>
</view>
</view>
</view>
@@ -150,7 +155,9 @@
.listrigth,
.listrigth2 {
width: 100%;
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: center;
// padding-left: 32rpx;
@@ -167,9 +174,17 @@
color: #333333;
}
}
.listStyle_left{
width: 100%;
display: flex;
align-items: center;
}
.head_img{
border-radius: 50%;
margin-right: 32rpx;
}
.listrigth2 {
margin-top: 6rpx;
margin-top: 16rpx;
>view {
font-weight: 500;

View File

@@ -1,169 +0,0 @@
<template>
<view class="towcontentitem">
<view class="towcontentitemone flex-start">
<image class="towcontentitemoneimage" :src="userInfo.logo" mode="aspectFill"></image>
<view class="towcontentitemonetext flex-colum-start">
<text class="towcontentitemonetextone">{{userInfo.shopName || '暂无昵称'}}</text>
</view>
</view>
<view class="towcontentitemthere flex-start">
余额<text class="towcontentitemtheretext">{{userInfo.amount || '0.00'}}</text>
</view>
<view class="towcontentitemtow flex-between">
<text class="towcontentitemtowetext">VIP{{userInfo.code || '无'}}</text>
</view>
<view class="towcontentitevip">
VIP{{userInfo.isVip||''}}
</view>
<image src="https://czg-qr-order.oss-cn-beijing.aliyuncs.com/drder/erweima.png" class="imgStyle" mode=""
@click="clickEvent"></image>
</view>
</template>
<script>
export default {
props: ['userInfo'],
data() {
return {}
},
mounted() {
console.log(this.userInfo, '调试1113')
},
methods: {
clickEvent() {
if (this.userInfo.amount) {
uni.navigateTo({
url: '/pages/pay_code/pay_code?shopInfo=' + JSON.stringify(this.userInfo)
})
}
}
}
}
</script>
<style lang="scss" scoped>
.towcontentitem {
width: 100%;
position: relative;
padding: 32rpx;
border-radius: 12rpx;
background: linear-gradient(126deg, #FFFBF2 0%, #F2D093 100%);
border-radius: 12rpx 12rpx 12rpx 12rpx;
&::after {
position: absolute;
bottom: 0;
right: 68rpx;
content: '';
display: inline-block;
width: 240rpx;
height: 232rpx;
background: url(https://czg-qr-order.oss-cn-beijing.aliyuncs.com/member.png) no-repeat;
background-size: 100% 100%;
}
.towcontentitemimage {
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
border-radius: 12rpx;
z-index: 5;
}
.towcontentitemone {
width: 100%;
position: relative;
z-index: 9;
.towcontentitemoneimage {
width: 76rpx;
height: 76rpx;
border-radius: 50%;
}
.towcontentitemonetext {
height: 76rpx;
margin-left: 16rpx;
.towcontentitemonetextone {
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: 500;
font-size: 36rpx;
color: #333333;
}
.towcontentitemonetexttow {
font-size: 24rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #422A07;
}
}
}
.towcontentitemprogressa {
padding: 8rpx 44rpx;
z-index: 10;
position: relative;
margin-top: 54rpx;
}
.towcontentitemtow {
margin-top: 84rpx;
z-index: 10;
font-size: 24rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #422A07;
}
.towcontentitevip {
position: absolute;
right: 0;
top: 0;
width: 92rpx;
height: 40rpx;
font-size: 20rpx;
background: #F4C380;
border-radius: 0rpx 12rpx 0rpx 12rpx;
text-align: center;
line-height: 40rpx;
color: #fff;
font-family: Source Han Sans CN-Medium;
font-weight: Medium;
}
.towcontentitemthere {
margin-left: 92rpx;
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: Medium;
font-size: 24rpx;
color: #333333;
display: flex;
align-items: center;
.towcontentitemtheretext {
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: bold;
font-size: 36rpx;
color: #333333;
}
}
}
.imgStyle {
width: 54rpx;
height: 52rpx;
position: absolute;
right: 50rpx;
bottom: 30rpx;
// border: 2px solid #fff;
z-index: 666;
}
</style>

View File

@@ -161,7 +161,7 @@
encryptedData: d.detail.encryptedData,
iv: d.detail.iv,
})
this.phonetitle = res.data
this.telephone = res.data
}
})
}
@@ -205,7 +205,14 @@
birthDay: this.birthDay
})
if ( res.code == 0 ) {
this.$emit('getRegisterMember', false)
let res = await this.api.loginwxuserInfo({
userId: uni.cache.get('userInfo').id
})
if (res.code == 0) {
uni.cache.set('userInfo', res.data);
}
}
}
@@ -240,6 +247,8 @@
.reg-head-img{
width: 120rpx;
height: 120rpx;
border-radius: 50%;
padding: 0;
position: relative;
}
.reg-head-edit{

View File

@@ -1,332 +0,0 @@
<template>
<view class="content">
<card :userInfo="userInfo"></card>
<view class="therecontent">
<input type="number" v-model="amount" placeholder="自定义金额">
</view>
<view class="fourcontent flex-start">
<view class="fourcontentlnage" v-for="(item,index) in listdata" :key="index">
<view class="flex-colum" :class="index == inputshow?'fourcontentitems':'fourcontentitem'"
@click="clickinput(item,index)">
<text>{{item.minNum}}</text>
<text style="margin-top: 10rpx;">{{item.minNum}}{{item.handselNum}}</text>
</view>
</view>
</view>
<view class="fivecontent" @tap="$u.debounce(userbalancerechangesub, 500)">
立即充值
</view>
</view>
</template>
<script>
import card from './components/card.vue'
export default {
components: {
card
},
data() {
return {
inputshow: 0,
listdata: [],
amount: '',
userInfo: {},
shopId: ''
}
},
onLoad(e) {
this.shopId = e.shopId
if (e.type == 'list') { //从列表进来的
this.paygetShopByMember(e.shopId)
} else {
this.paygetShopByMember(e.shopId)
}
this.paygetActive(e.shopId) //列表
},
methods: {
async paygetShopByMember(w) {
let res = await this.api.paygetShopByMember({
page: 1,
pageSize: 10,
userId: uni.cache.get('userInfo').id,
shopId: this.shopId
})
this.userInfo = res.data.list[0]
},
async paygetActive() {
let res = await this.api.paygetActive({
shopId: this.shopId,
page: 1,
pageSize: 10
})
try {
this.listdata = res.data.list
this.amount = res.data.list[0].minNum
} catch (e) {
//TODO handle the exception
}
},
async userbalancerechangesub() {
if (this.amount == null || this.amount == '') {
uni.showToast({
title: '金额不能为空',
icon: 'none'
});
return false;
}
if (this.amount <= 0) {
uni.showToast({
title: '金额必须大于0',
icon: 'none'
});
return false;
}
let res = await this.api.paymemeberIn({
shopId: this.shopId, // 判断显示哪家的作品,
amount: this.amount // 判断显示哪家的作品,
})
if (res.code == 0) {
uni.showLoading({
title: '加载中',
mask: true
})
// #ifdef MP-WEIXIN
uni.requestPayment({
provider: 'wxpay', //支付类型-固定值
partnerid: res.data.appId, // 微信支付商户号
timeStamp: res.data.timeStamp, // 时间戳(单位:秒)
nonceStr: res.data.nonceStr, // 随机字符串
package: res.data.package, // 固定值
signType: res.data.signType, //固定值
paySign: res.data.paySign, //签名
success: (res) => {
uni.showToast({
title: "支付成功"
})
uni.hideLoading()
setTimeout(res => {
uni.navigateBack()
}, 500)
},
fail: (res) => {
uni.hideLoading()
}
});
uni.hideLoading()
// #endif
}
},
clickinput(a, b) {
console.log(a, b)
this.inputshow = b
this.amount = a.minNum
},
}
}
</script>
<style lang="scss">
page {
background: #F9F9F9;
}
.content {
padding: 0 28rpx;
.towcontentitem {
width: 100%;
position: relative;
padding: 32rpx;
border-radius: 12rpx;
background: linear-gradient(126deg, #FFFBF2 0%, #F2D093 100%);
border-radius: 12rpx 12rpx 12rpx 12rpx;
&::after {
position: absolute;
bottom: 0;
right: 68rpx;
content: '';
display: inline-block;
width: 240rpx;
height: 232rpx;
background: url(https://czg-qr-order.oss-cn-beijing.aliyuncs.com/member.png) no-repeat;
background-size: 100% 100%;
}
.towcontentitemimage {
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
border-radius: 12rpx;
z-index: 5;
}
.towcontentitemone {
width: 100%;
position: relative;
z-index: 9;
.towcontentitemoneimage {
width: 76rpx;
height: 76rpx;
border-radius: 50%;
}
.towcontentitemonetext {
height: 76rpx;
margin-left: 16rpx;
.towcontentitemonetextone {
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: 500;
font-size: 36rpx;
color: #333333;
}
.towcontentitemonetexttow {
font-size: 24rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #422A07;
}
}
}
.towcontentitemprogressa {
padding: 8rpx 44rpx;
z-index: 10;
position: relative;
margin-top: 54rpx;
}
.towcontentitemtow {
margin-top: 84rpx;
z-index: 10;
font-size: 24rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #422A07;
}
.towcontentitevip {
position: absolute;
right: 0;
top: 0;
width: 92rpx;
height: 40rpx;
font-size: 20rpx;
background: #F4C380;
border-radius: 0rpx 12rpx 0rpx 12rpx;
text-align: center;
line-height: 40rpx;
color: #fff;
font-family: Source Han Sans CN-Medium;
font-weight: Medium;
}
.towcontentitemthere {
margin-left: 92rpx;
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: Medium;
font-size: 24rpx;
color: #333333;
.towcontentitemtheretext {
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: bold;
font-size: 36rpx;
color: #333333;
}
}
}
.therecontent {
margin-top: 32rpx;
position: relative;
padding: 22rpx 32rpx;
width: 100%;
background: #FFFFFF;
border-radius: 8rpx;
input {
padding-left: 30rpx;
text-align: right;
font-size: 28rpx;
font-family: Source Han Sans CN-Medium, Source Han Sans CN;
font-weight: 500;
color: #666666;
}
}
.therecontent::after {
position: absolute;
top: 50%;
left: 32rpx;
transform: translateY(-50%);
content: '¥';
display: inline-block;
width: 28rpx;
height: 40rpx;
font-size: 28rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #333333;
}
.fourcontent {
.fourcontentlnage {
width: 33.33%;
.fourcontentitem {
margin: 24rpx 10rpx;
padding: 16rpx 0;
text-align: center;
background: #FFFFFF;
border-radius: 8rpx;
// border: 1rpx solid #333333;
font-size: 28rpx;
font-family: Roboto-Medium, Roboto;
font-weight: 500;
color: #333333;
}
.fourcontentitems {
margin: 24rpx 10rpx;
padding: 16rpx 0;
text-align: center;
border-radius: 8rpx;
background: #F1CB66;
border-radius: 8rpx 8rpx 8rpx 8rpx;
border: 2rpx solid #F1CB66;
font-size: 28rpx;
font-family: Roboto-Medium, Roboto;
font-weight: 500;
color: #FFFFFF;
}
}
}
.fivecontent {
position: relative;
bottom: 44rpx;
margin-top: 62rpx;
padding: 20rpx 0;
text-align: center;
width: 100%;
font-size: 36rpx;
font-family: PingFang SC-Bold, PingFang SC;
font-weight: bold;
color: #FFFFFF;
border-radius: 8rpx;
background: #F1CB66;
}
}
</style>

View File

@@ -70,11 +70,14 @@
<view class="rechargeBox">
<view class="agreement">
<u-checkbox-group>
<u-checkbox shape="circle" activeColor="#E3AD7F" @change="radioChange" size="30"></u-checkbox>
<u-checkbox shape="circle" activeColor="#E3AD7F" @change="radioChange" size="30">
<view style="width: 100rpx;height: 100rpx;"></view>
</u-checkbox>
</u-checkbox-group>
<text>已同意</text>
<text class="agreement_text" @click="Privacy(1)">用户储值协议</text>
<text class="agreement_text" @click="Privacy(3)">用户授权协议</text>
<text class="agreement_text" @click="viewProtocol">用户隐私协议</text>
<!-- <text class="agreement_text" @click="viewProtocol">用户储值协议</text> -->
<!-- <text class="agreement_text" @click="viewProtocol">用户授权协议</text> -->
</view>
<view class="recharge" @tap="$u.debounce(userbalancerechangesub, 500)">立即充值</view>
</view>
@@ -116,9 +119,9 @@
this.shopId = this.getQueryString(decodeURIComponent(e.q), 'shopId')
this.tokenShow = false;
// 等待登录结果返回
if (!uni.cache.get('token')) {
await this.$onLaunched;
}
// if (!uni.cache.get('token')) {
// await this.$onLaunched;
// }
this.init();
} else{
this.shopId = e.shopId;
@@ -173,25 +176,16 @@
uni.pro.navigateTo(item.url, this.userInfo)
},
async Privacy(e) {
if (e == 1) {
//用户协议
let res = await this.api.agreementgetAgreementOne({
discern: 0
});
uni.pro.navigateTo('my/about/agreement', {
discern: 0,
list: res.data.content
});
} else {
let res3 = await this.api.agreementgetAgreementOne({
discern: 3
});
uni.pro.navigateTo('my/about/agreement', {
discern: 3,
list: res3.data.content
});
}
/**
* 查看协议
*/
viewProtocol (){
wx.openPrivacyContract({
success: () => {}, // 打开成功
fail: () => {}, // 打开失败
complete: () => {}
})
},
/**
@@ -216,18 +210,26 @@
* 拉起地图
*/
openLocation () {
console.log('123');
uni.openLocation({
latitude: Number(this.userInfo.lat), // 目的地的纬度,浮点数,范围为-90~90
longitude: Number(this.userInfo.lng), // 目的地的经度,浮点数,范围为-180~180
latitude: Number(this.usershopUserinfo.lat), // 目的地的纬度,浮点数,范围为-90~90
longitude: Number(this.usershopUserinfo.lng), // 目的地的经度,浮点数,范围为-180~180
scale: 18, // 缩放比例范围5~18
name: this.userInfo.shopName, // 位置名
address: this.userInfo.address, // 地址的详细说明
name: this.usershopUserinfo.shopName, // 位置名
address: this.usershopUserinfo.address, // 地址的详细说明
success() {
console.log('导航启动成功');
},
fail(error) {
console.log('导航启动失败', error);
if ( error.errMsg == "openLocation:fail invalid_coordinate") {
uni.showToast({
title: "门店经纬度无效",
icon: 'none'
});
}
}
});
},
@@ -278,6 +280,13 @@
* 充值
*/
async userbalancerechangesub() {
if (!this.isProtocol) {
uni.showToast({
title: '请勾选协议',
icon: 'none'
});
return false;
}
if (this.amount == null || this.amount == '') {
uni.showToast({
title: '金额不能为空',
@@ -317,9 +326,7 @@
uni.hideLoading()
let pages = getCurrentPages()
if ( pages.length > 1) {
setTimeout(res => {
uni.navigateBack()
}, 500)
this.paygetShopByMember()
} else {
setTimeout(res => {
uni.switchTab({

View File

@@ -40,17 +40,24 @@
size: 10, //页容量
status: 'loadmore',
},
userId: uni.cache.get('userInfo').id
userId: uni.cache.get('userInfo').id,
type: null,
}
},
onLoad(e) {
console.log(e)
if ( e.type ) {
this.type = e.type;
}
},
onShow() {
this.list = []
this.form = {
page: 1, //页数
size: 10, //页容量
status: 'loadmore',
},
this.paygetShopByMember()
page: 1, //页数
size: 10, //页容量
status: 'loadmore',
},
this.paygetShopByMember()
},
onReachBottom() {
this.paygetShopByMember()
@@ -86,9 +93,21 @@
}
},
eeInfo(item) {
uni.pro.navigateTo('member/memberdetails', {
shopId_id: item.shopId
})
if ( this.type && this.type == 'user_payCode') {
uni.navigateTo({
url: '/pages/pay_code/pay_code?shopInfo=' + JSON.stringify(item)
})
} else if ( this.type && this.type == 'user_recharge') {
uni.pro.navigateTo('member/index', {
shopId: item.shopId,
type: 'index',
})
} else {
uni.pro.navigateTo('member/memberdetails', {
shopId_id: item.shopId
})
}
},
}
}

View File

@@ -1,304 +0,0 @@
<template>
<!-- 会员详情 -->
<view class="content">
<card :userInfo="userInfo"></card>
<view class="memberdetailsStyle">
<text>会员详情</text>
<view @click="goUrl('member/billDetails')">
<text>账单明细</text>
<uni-icons type="right" style="color: #333;" size="20"></uni-icons>
</view>
<view @click="goUrlinfo('member/index')">
<text>会员充值</text>
<uni-icons type="right" style="color: #333;" size="20"></uni-icons>
</view>
</view>
</view>
</template>
<script>
import card from './components/card.vue'
export default {
components: {
card
},
data() {
return {
shopId_id: null,
inputshow: 0,
memberlist: {},
listdata: [],
amount: '',
userInfo: {},
}
},
onLoad(e) {
console.log(e)
this.shopId_id = e.shopId_id
},
onShow() {
this.paygetShopByMember(this.shopId_id)
},
methods: {
async paygetShopByMember(w) {
let res = await this.api.paygetShopByMember({
page: 1,
pageSize: 10,
userId: uni.cache.get('userInfo').id,
shopId: w
})
this.userInfo = res.data.list[0]
},
clickinput(a, b) {
console.log(a, b)
this.inputshow = b
this.amount = a.minNum
},
goUrl(url) {
uni.pro.navigateTo(url, this.userInfo)
},
goUrlinfo(url) {
uni.pro.navigateTo(url, {
shopId: this.shopId_id,
type: 'list'
})
}
}
}
</script>
<style lang="scss">
page {
background: #F9F9F9;
}
.content {
padding: 0 28rpx;
.towcontentitem {
width: 100%;
position: relative;
padding: 32rpx;
border-radius: 12rpx;
background: linear-gradient(126deg, #FFFBF2 0%, #F2D093 100%);
border-radius: 12rpx 12rpx 12rpx 12rpx;
&::after {
position: absolute;
bottom: 0;
right: 68rpx;
content: '';
display: inline-block;
width: 240rpx;
height: 232rpx;
background: url(https://czg-qr-order.oss-cn-beijing.aliyuncs.com/member.png) no-repeat;
background-size: 100% 100%;
}
.towcontentitemimage {
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
border-radius: 12rpx;
z-index: 5;
}
.towcontentitemone {
width: 100%;
position: relative;
z-index: 9;
.towcontentitemoneimage {
width: 76rpx;
height: 76rpx;
border-radius: 50%;
}
.towcontentitemonetext {
height: 76rpx;
margin-left: 16rpx;
.towcontentitemonetextone {
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: 500;
font-size: 36rpx;
color: #333333;
}
.towcontentitemonetexttow {
font-size: 24rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #422A07;
}
}
}
.towcontentitemprogressa {
padding: 8rpx 44rpx;
z-index: 10;
position: relative;
margin-top: 54rpx;
}
.towcontentitemtow {
margin-top: 84rpx;
z-index: 10;
font-size: 24rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #422A07;
}
.towcontentitevip {
position: absolute;
right: 0;
top: 0;
width: 92rpx;
height: 40rpx;
font-size: 20rpx;
background: #F4C380;
border-radius: 0rpx 12rpx 0rpx 12rpx;
text-align: center;
line-height: 40rpx;
color: #fff;
font-family: Source Han Sans CN-Medium;
font-weight: Medium;
}
.towcontentitemthere {
margin-left: 92rpx;
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: Medium;
font-size: 24rpx;
color: #333333;
.towcontentitemtheretext {
font-family: Source Han Sans CN, Source Han Sans CN;
font-weight: bold;
font-size: 36rpx;
color: #333333;
}
}
}
.therecontent {
margin-top: 32rpx;
position: relative;
padding: 22rpx 32rpx;
width: 100%;
background: #FFFFFF;
border-radius: 8rpx;
input {
padding-left: 30rpx;
text-align: right;
font-size: 28rpx;
font-family: Source Han Sans CN-Medium, Source Han Sans CN;
font-weight: 500;
color: #666666;
}
}
.therecontent::after {
position: absolute;
top: 50%;
left: 32rpx;
transform: translateY(-50%);
content: '¥';
display: inline-block;
width: 28rpx;
height: 40rpx;
font-size: 28rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #333333;
}
.fourcontent {
.fourcontentlnage {
width: 33.33%;
.fourcontentitem {
margin: 24rpx 10rpx;
padding: 16rpx 0;
text-align: center;
background: #FFFFFF;
border-radius: 8rpx;
border: 1rpx solid #333333;
font-size: 28rpx;
font-family: Roboto-Medium, Roboto;
font-weight: 500;
color: #333333;
}
.fourcontentitems {
margin: 24rpx 10rpx;
padding: 16rpx 0;
text-align: center;
border-radius: 8rpx;
background: #F1CB66;
border-radius: 8rpx 8rpx 8rpx 8rpx;
border: 2rpx solid #F1CB66;
font-size: 28rpx;
font-family: Roboto-Medium, Roboto;
font-weight: 500;
color: #FFFFFF;
}
}
}
.fivecontent {
position: relative;
bottom: 44rpx;
margin-top: 62rpx;
padding: 20rpx 0;
text-align: center;
width: 100%;
font-size: 36rpx;
font-family: PingFang SC-Bold, PingFang SC;
font-weight: bold;
color: #FFFFFF;
border-radius: 8rpx;
background: #F1CB66;
}
// 会员详情
.memberdetailsStyle {
margin-top: 32rpx;
border-radius: 24rpx 24rpx 24rpx 24rpx;
background-color: #fff;
padding: 32rpx;
height: 252rpx;
display: flex;
justify-content: space-between;
flex-direction: column;
>text {
font-weight: bold;
font-size: 32rpx;
color: #333333;
}
>view {
font-weight: 400;
font-size: 28rpx;
color: #333333;
display: flex;
justify-content: space-between;
align-items: center;
}
}
}
</style>

View File

@@ -23,13 +23,13 @@
<view class="card_cen_right" v-if="userInfo.isVip != 0">查看特权</view>
</view>
<view class="card_bom" v-if="userInfo.isVip != 0">
<view class="card_bom_item">
<view class="card_bom_item" @click="itemClick(1)">
<text>{{userInfo.amount || '0.00'}}</text><text>储值</text>
</view>
<view class="card_bom_item">
<text>0</text><text>积分</text>
</view>
<view class="card_bom_item">
<view class="card_bom_item" @click="itemClick(3)">
<text>0</text><text>优惠券</text>
</view>
<view class="card_bom_item">
@@ -93,39 +93,53 @@
list: ['鸿运当头',"财运亨通","时来运转","否极泰来","花逢时发"],
index: 0,
text: ""
}
},
usershopUserinfo:{},
}
},
onLoad(e) {
this.shopId_id = e.shopId_id
},
onShow() {
this.paygetShopByMember()
this.init();
},
methods: {
/**
* 获取会员卡信息
* 获取店铺信息
*/
async paygetShopByMember() {
let res = await this.api.paygetShopByMember({
page: 1,
pageSize: 10,
userId: uni.cache.get('userInfo').id,
shopId: this.shopId_id
async init() {
let res = await this.api.shopUserInfo({
"shopId": this.shopId_id,
"userId": uni.cache.get('userInfo').id,
})
this.userInfo = res.data.list[0];
if (res.code == 0) {
this.userInfo = res.data
}
if ( this.userInfo.isVip == 0 ) {
this.memberOpen = true;
return;
}
},
itemClick ( type ) {
if ( type == 1) {
uni.pro.navigateTo('member/index', {
shopId: this.userInfo.shopId,
type: 'index',
})
} else if ( type == 3 ) {
uni.pro.navigateTo('user/coupon')
}
},
/**
* 注册会员卡
* @param {Object} e
*/
getRegisterMember (e) {
this.memberOpen = e;
this.paygetShopByMember()
this.init()
},
clickEvent() {

View File

@@ -7,7 +7,7 @@
</view>
<view class="box_item flex-between" style="position:relative;">
<text class="top_box_one_text"></text>
<input type="number" v-model="form.checkCode" placeholder="请输入验证码" style="padding-right: 140rpx;" />
<input type="number" v-model="form.checkCode" placeholder="请输入验证码" style="padding-right: 140rpx;color: #333" />
<view class="top_box_one_texts">
<view v-if="showText == true" class="yzm" @click="CodeRegister">{{ Recapture }}</view>
<view v-else style="color: #ccc; background-color: #f9f9f9; border-radius:16px; padding: 10rpx;">
@@ -28,7 +28,7 @@
</view>
<view class="flex-colum">
<view class="Box_bottom" @click="userInfosavePayPassword">确定</view>
<view class="Box_bottom" :class="(form.checkCode!=''&&form.password!=''&&form.payPassword!='')?'active':''" @click="userInfosavePayPassword">确定</view>
</view>
</view>
</template>
@@ -52,8 +52,13 @@
Recapture: '获取验证码'
};
},
onLoad() {
onLoad(e) {
// if ( e.shopUserInfo ) {
// this.shopUserInfo = JSON.parse(e.shopUserInfo);
// this.isPwd = this.shopUserInfo.isPwd;
// this.mobile = this.shopUserInfo.telephone.slice(0, 3)+'****'+this.shopUserInfo.telephone.slice(7);
// this.form.mobile = this.shopUserInfo.telephone;
// }
},
methods: {
@@ -62,7 +67,7 @@
// post 手机验证码
phone: this.form.mobile
});
if (res) {
if (res.code == 0) {
uni.showToast({
title: '验证码获取成功',
icon: 'none'
@@ -150,9 +155,10 @@
icon: 'none'
});
}
// 获取用户信息
this.loginwxuserInfo()
setTimeout(() => {
// 获取用户信息
this.loginwxuserInfo()
uni.navigateBack();
}, 1000);
}
@@ -196,7 +202,7 @@
font-size: 28rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
font-weight: 400;
color: #999999;
color: #333;
}
@@ -238,7 +244,7 @@
width: 100%;
height: 96rpx;
line-height: 96rpx;
background: #999;
background-color: #999;
border-radius: 48rpx;
font-size: 32rpx;
font-family: Source Han Sans CN-Regular, Source Han Sans CN;
@@ -246,6 +252,9 @@
color: #ffffff;
text-align: center;
}
.Box_bottom.active{
background-color: #E3AD7F;
}
}
}
</style>