Merge branch 'feature/mall_product' of http://117.33.142.185:3000/zenghuapei/cyywl_server into feature/mall_product

pull/2/head
TianYu 2023-05-22 14:30:00 +08:00
commit 336aef34b6
6 changed files with 58 additions and 32 deletions

View File

@ -198,12 +198,12 @@
<style scoped lang="scss"> <style scoped lang="scss">
.payment { .payment {
position: fixed; position: fixed;
bottom: 4%; bottom: 0;
left: 0; left: 0;
width: 100%; width: 100%;
border-radius: 16rpx 16rpx 0 0; border-radius: 16rpx 16rpx 0 0;
background-color: #fff; background-color: #fff;
padding-bottom: 100rpx; padding-bottom: 4%;
z-index: 99; z-index: 99;
transition: all 0.3s cubic-bezier(0.25, 0.5, 0.5, 0.9); transition: all 0.3s cubic-bezier(0.25, 0.5, 0.5, 0.9);
transform: translate3d(0, 100%, 0); transform: translate3d(0, 100%, 0);

View File

@ -101,17 +101,26 @@
}, },
async onLoad() { async onLoad() {
const res = await memberGradeInfo() uni.showLoading({
if(res.data.some((item) => !!parseInt(item.isExist))){ title: '加载中',
uni.setTabBarItem({ mask: true
index: 2, });
pagePath: '/pages/member_equity/index' try{
}) const res = await memberGradeInfo()
uni.switchTab({ if(res.data.some((item) => !!!parseInt(item.isExist))){
url:'/pages/member_equity/index' console.log(123123)
}) uni.setTabBarItem({
index: 0,
pagePath: '/pages/member_equity/index'
})
uni.switchTab({
url:'/pages/member_equity/index'
})
}
this.memberData = res.data
} finally{
uni.hideLoading();
} }
this.memberData = res.data
}, },
methods: { methods: {
@ -217,14 +226,14 @@
background-size: cover; background-size: cover;
background-repeat: no-repeat; background-repeat: no-repeat;
background-attachment: fixed; background-attachment: fixed;
.u-nav-slot{ .u-nav-slot{
::v-deep .u-popup__content{ ::v-deep .u-popup__content{
padding-bottom: 20% !important; padding-bottom: 20% !important;
} }
} }
.phone-money { .phone-money {
width: 604rpx; width: 604rpx;

View File

@ -11,8 +11,8 @@
</view> </view>
<view class="member-right"> <view class="member-right">
<image src='../../static/images/vipStar.png'></image> <image src='../../static/images/vipStar.png'></image>
<text>会员等级3</text> <text>会员等级{{vipData.findIndex((item) => item == memberDetail.grade) +1}}</text>
<button>立即续</button> <button @click="handleRenew"></button>
</view> </view>
</view> </view>
<view class="box-equity"> <view class="box-equity">
@ -20,7 +20,7 @@
<text class="equity-member">我的会员权益</text> <text class="equity-member">我的会员权益</text>
<text class="equity-look">查看权益></text> <text class="equity-look">查看权益></text>
</view> </view>
<view class="equity-item" v-for="(item,index) in 2" :key="index"> <view class="equity-item" v-for="(item,index) in 3" :key="index">
<view class="equity-grade"> <view class="equity-grade">
<image src='../../static/images/member240.png'></image> <image src='../../static/images/member240.png'></image>
<text>办理日期2021.12.30</text> <text>办理日期2021.12.30</text>
@ -79,6 +79,7 @@
fontSize:'28' fontSize:'28'
}, },
], ],
vipData:['普通会员','中级会员','高级会员'],
show: false, show: false,
memberDetail:{} memberDetail:{}
}; };
@ -89,6 +90,11 @@
this.memberDetail = res.data this.memberDetail = res.data
}, },
methods: { methods: {
handleRenew(){
uni.navigateTo({
url:'/pages/member_renew/index'
})
},
handleSelect(value){ handleSelect(value){
switch (value.name){ switch (value.name){
case "购买记录": case "购买记录":
@ -97,7 +103,6 @@
}) })
break; break;
case "为他人充值": case "为他人充值":
console.log(123)
uni.navigateTo({ uni.navigateTo({
url:'/pages/member_others/index' url:'/pages/member_others/index'
}) })
@ -106,20 +111,13 @@
break; break;
} }
}, },
submit() {
this.$refs.uForm.validate().then(res => {
uni.$u.toast('校验通过')
}).catch(errors => {
uni.$u.toast('校验失败')
})
}
} }
}; };
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.box { .box {
margin-bottom: 30%;
margin-top: 10%; margin-top: 10%;
background: #fff; background: #fff;
height: 100vh; height: 100vh;

View File

@ -114,8 +114,16 @@
}; };
}, },
async onLoad() { async onLoad() {
const res = await memberGradeInfo() uni.showLoading({
this.memberData = res.data title: '加载中',
mask: true
});
try{
const res = await memberGradeInfo()
this.memberData = res.data
} finally{
uni.hideLoading();
}
}, },
methods: { methods: {
handleMember(value, index) { handleMember(value, index) {
@ -151,7 +159,7 @@
}) })
} }
}).catch(errors => { }).catch(errors => {
uni.$u.toast('校验失败') uni.$u.toast('请检查手机号输入')
}) })
}, },
/** /**
@ -222,6 +230,10 @@
background: #fff; background: #fff;
} }
} }
::v-deep .u-form-item__body__right__message{
margin-top: 10rpx;
color: #fff;
}
.phone-money { .phone-money {
width: 604rpx; width: 604rpx;

View File

@ -95,9 +95,16 @@ import store from '@/store/index';
}; };
}, },
async onLoad() { async onLoad() {
uni.showLoading({
title: '加载中',
mask: true
});
try{
const res = await memberGradeInfo() const res = await memberGradeInfo()
this.memberData = res.data this.memberData = res.data
this.form.userPhone = store.state.app.userInfo.mobile this.form.userPhone = store.state.app.userInfo.mobile } finally{
uni.hideLoading();
}
}, },
methods: { methods: {
handleMember(value,index){ handleMember(value,index){

View File

@ -205,7 +205,7 @@
// href = window.location.href.split('/pages')[0]; // href = window.location.href.split('/pages')[0];
console.log('uid', that.uid) console.log('uid', that.uid)
const baseUrl = 'http://yuxy.perrymake.com'; const baseUrl = 'http://yuxy.perrymake.com';
const url =`${baseUrl}/pages/index/index?redirectUrl=${baseUrl}&tenantId=${that.tenantId}&spreadId=${that.uid}` const url =`${baseUrl}/pages/member_application/index?redirectUrl=${baseUrl}&tenantId=${that.tenantId}&spreadId=${that.uid}`
console.log('url', url) console.log('url', url)
uQRCode.make({ uQRCode.make({
canvasId: 'qrcode', canvasId: 'qrcode',