新增分享,找回密码,实名认证,签约
This commit is contained in:
@@ -13,7 +13,6 @@ Page({
|
||||
shareSee : false, //分享弹出
|
||||
inviteText : '', //邀请码
|
||||
inviteCode : '', //二维码
|
||||
|
||||
//海报
|
||||
canvas : ''
|
||||
},
|
||||
@@ -38,7 +37,7 @@ Page({
|
||||
*/
|
||||
onShow() {
|
||||
// 小程序码
|
||||
// this.ShareInfo();
|
||||
this.ShareInfo();
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -46,7 +45,7 @@ Page({
|
||||
*/
|
||||
ShareInfo() {
|
||||
wx.$api.user.miniShare({
|
||||
url: '/pages/mall/index'
|
||||
url: 'pages/mall/index'
|
||||
}).then(res => {
|
||||
this.setData({
|
||||
inviteCode: res.data.qrcode
|
||||
@@ -151,9 +150,7 @@ Page({
|
||||
|
||||
// 返回上一页
|
||||
returnGo() {
|
||||
wx.navigateBack({
|
||||
delta: 1
|
||||
})
|
||||
wx.navigateBack()
|
||||
},
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
|
||||
<!-- header -->
|
||||
<view class="navigation {{isFixedTop > 0 ? 'active' : ''}}" style="padding-top:{{barHeight}}px;">
|
||||
<image bindtap="returnGo" class="navigation-arrow" src="{{isFixedTop > 0 ? '/static/icons/arrowBlack.png' : '/static/icons/arrowWrite.png'}}"></image>
|
||||
</view>
|
||||
|
||||
<!-- 二维码海报 -->
|
||||
<view class="code">
|
||||
<image src="https://cdn.douhuofalv.com/images/2023/08/11/cd8093d6ab1a248e5154be48b0ddcaac.jpg" class="code-back"></image>
|
||||
<view class="code-cont">
|
||||
@@ -20,16 +23,18 @@
|
||||
<canvas type="2d" style="width: 375px; height: 800px;" id="coverCanvas" class="canvas-img" />
|
||||
|
||||
<!-- 分享弹出 -->
|
||||
<view class="sharePop {{shareSee ? 'active' : ''}}">
|
||||
<view class="shareCont">
|
||||
<button class="shareCont-label codeShare-button" open-type="share" hover-class="none">
|
||||
<image src="https://cdn.shuiganying.com/images/2023/03/28/f8b773edc2fe6db8e45f96773b9a8dc4.png"></image>
|
||||
微信好友
|
||||
</button>
|
||||
<view class="shareCont-label" bindtap="onCanvas">
|
||||
<image src="https://cdn.shuiganying.com/images/2023/03/28/cfe0efbb53eaf7911ea5211923859c65.png"></image>
|
||||
保存二维码
|
||||
<view class="sharePop-lay {{shareSee ? 'active' : ''}}">
|
||||
<view class="sharePop">
|
||||
<view class="shareCont">
|
||||
<button class="shareCont-label codeShare-button" open-type="share" hover-class="none">
|
||||
<image src="https://cdn.shuiganying.com/images/2023/03/28/f8b773edc2fe6db8e45f96773b9a8dc4.png"></image>
|
||||
微信好友
|
||||
</button>
|
||||
<view class="shareCont-label" bindtap="onCanvas">
|
||||
<image src="https://cdn.shuiganying.com/images/2023/03/28/cfe0efbb53eaf7911ea5211923859c65.png"></image>
|
||||
保存二维码
|
||||
</view>
|
||||
</view>
|
||||
<view class="shareCancel" bindtap="shareTap">取消</view>
|
||||
</view>
|
||||
<view class="shareCancel" bindtap="shareTap">取消</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -1,148 +1,31 @@
|
||||
/* 返回上一页 */
|
||||
.navigation{
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 99;
|
||||
width: 100%;
|
||||
height: 90rpx;
|
||||
background-color: transparent;
|
||||
transition: .2s;
|
||||
}
|
||||
.navigation{ position: fixed; top: 0; left: 0; z-index: 9; width: 100%; height: 90rpx; background-color: transparent; transition: .2s; }
|
||||
.navigation.active { background-color: transparent; }
|
||||
.navigation-arrow { width: 44rpx; height: 44rpx; margin: 20rpx 15rpx 0 20rpx; }
|
||||
|
||||
.navigation.active {
|
||||
background-color: transparent;
|
||||
}
|
||||
/* 二维码海报 */
|
||||
.code { width: 100vw; height: 100vh; position: relative; }
|
||||
.code-back { position: absolute; left: 0; top: 0; width: 100%; height: 100%; }
|
||||
.code-cont { width: 400rpx; position: absolute; z-index: 9; text-align: center; left: calc(50% - 200rpx); bottom: 8vh; }
|
||||
.code-img{ margin: 0 auto 20rpx; overflow: hidden; width: 260rpx; height: 260rpx; border: 4rpx solid #ff4f64; background-color: #ffffff; padding: 10rpx; box-sizing: border-box; border-radius: 50%; }
|
||||
.code-img image { width: 100%; }
|
||||
.code-text { color: #ffffff; font-size: 30rpx; }
|
||||
|
||||
.navigation-arrow {
|
||||
width: 44rpx;
|
||||
height: 44rpx;
|
||||
margin: 20rpx 15rpx 0 20rpx;
|
||||
/* 海报分享 */
|
||||
.code-share { position: absolute; right: 0; bottom: 15%; background: linear-gradient(to right, #fffafb, #ffd4dd); width: 50rpx; text-align: center; border-radius: 26rpx 0 0 26rpx; padding: 30rpx 10rpx 30rpx 15rpx; box-shadow: 0 0 0 6rpx rgba(249, 96, 116, .8); z-index: 9;
|
||||
}
|
||||
.code-share-name { writing-mode:vertical-rl; font-size: 30rpx; padding-left: 4rpx; color: #da2b54; }
|
||||
.code-share image { width: 36rpx; height: 36rpx; margin-bottom: 5rpx; }
|
||||
|
||||
|
||||
/* 二维码 */
|
||||
.code {
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.code-back {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.code-cont {
|
||||
width: 400rpx;
|
||||
position: absolute;
|
||||
z-index: 9;
|
||||
text-align: center;
|
||||
left: calc(50% - 200rpx);
|
||||
bottom: 5%;
|
||||
}
|
||||
|
||||
.code-img{
|
||||
margin: 0 auto 20rpx;
|
||||
overflow: hidden;
|
||||
width: 260rpx;
|
||||
height: 260rpx;
|
||||
border: 4rpx solid #ff4f64;
|
||||
background-color: #ffffff;
|
||||
padding: 10rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.code-img image {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.code-text {
|
||||
color: #ffffff;
|
||||
font-size: 32rpx;
|
||||
}
|
||||
|
||||
.code-share {
|
||||
position: absolute;
|
||||
z-index: 10;
|
||||
right: 0;
|
||||
bottom: 15%;
|
||||
background: linear-gradient(to right, #fffafb, #ffd4dd);
|
||||
width: 50rpx;
|
||||
text-align: center;
|
||||
border-radius: 26rpx 0 0 26rpx;
|
||||
padding: 30rpx 10rpx 30rpx 15rpx;
|
||||
box-shadow: 0 0 0 6rpx rgba(249, 96, 116, .8);
|
||||
}
|
||||
|
||||
.code-share-name {
|
||||
writing-mode:vertical-rl;
|
||||
font-size: 30rpx;
|
||||
padding-left: 4rpx;
|
||||
color: #da2b54;
|
||||
}
|
||||
|
||||
.code-share image {
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
margin-bottom: 5rpx;
|
||||
}
|
||||
|
||||
.sharePop {
|
||||
position: fixed;
|
||||
width: 100%;
|
||||
z-index: 99;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
background-color: #ffffff;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.sharePop.active {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.shareCont-label image {
|
||||
width: 60rpx;
|
||||
height: 60rpx;
|
||||
display: block;
|
||||
margin: 0 auto 10rpx;
|
||||
}
|
||||
|
||||
.shareCancel {
|
||||
border-top: 2rpx solid #ebebeb;
|
||||
color: #000000;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
line-height: 100rpx;
|
||||
}
|
||||
|
||||
.shareCont{
|
||||
display: flex;
|
||||
padding: 30rpx 0;
|
||||
}
|
||||
|
||||
.shareCont-label {
|
||||
color: #000000;
|
||||
flex: 2;
|
||||
text-align: center;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
|
||||
.codeShare-button {
|
||||
background-color: transparent;
|
||||
padding: 0;
|
||||
font-weight: normal;
|
||||
}
|
||||
/* 弹出层 */
|
||||
.sharePop-lay{ background: rgba(0, 0, 0, .5); position: fixed; top: 0; left: 0; right: 0; height: 100vh; width: 100vw; z-index: 9; display: none; }
|
||||
.sharePop-lay.active{ display: block; }
|
||||
.sharePop { position: fixed; width: 100%; z-index: 99; left: 0; bottom: 0; background-color: #ffffff; }
|
||||
.shareCont-label image { width: 60rpx; height: 60rpx; display: block; margin: 0 auto 10rpx; }
|
||||
.shareCancel { border-top: 2rpx solid #ebebeb; color: #000000; width: 100%; text-align: center; line-height: 100rpx; }
|
||||
.shareCont{ display: flex; padding: 30rpx 0; }
|
||||
.shareCont-label { color: #000000; flex: 2; text-align: center; font-size: 28rpx; }
|
||||
.codeShare-button { background-color: transparent; padding: 0; font-weight: normal; }
|
||||
|
||||
/* canvas */
|
||||
.canvas-img {
|
||||
position: fixed;
|
||||
left: 0%;
|
||||
/* left: -10000%; */
|
||||
top: 0;
|
||||
z-index: 99;
|
||||
}
|
||||
.canvas-img { position: fixed; left: 0%; left: -100%; top: 0; z-index: -1; }
|
||||
@@ -8,15 +8,10 @@ Page({
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
userLogin: false,
|
||||
userData: '', // 用户信息
|
||||
userLogin : false,
|
||||
userData : '',
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad(options) {},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
@@ -31,7 +26,8 @@ Page({
|
||||
return
|
||||
}
|
||||
this.setData({
|
||||
userLogin: false
|
||||
userLogin: false,
|
||||
userData : ''
|
||||
})
|
||||
},
|
||||
|
||||
@@ -43,16 +39,31 @@ Page({
|
||||
this.setData({
|
||||
userData: res.data
|
||||
})
|
||||
console.log(res)
|
||||
}).catch(err => {})
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
* 处理未登录时的转跳
|
||||
*/
|
||||
userNav(e){
|
||||
let pageUrl = e.currentTarget.dataset.url
|
||||
if(wx.getStorageSync("token") != ''){
|
||||
if(e.currentTarget.dataset.type && e.currentTarget.dataset.type == 'needSign' && this.data.userData.need_sign){
|
||||
wx.showModal({
|
||||
title : '提示',
|
||||
content : '您还未完成实名认证与签约成为VIP用户,无法获得邀请码',
|
||||
cancelText : '稍后完成',
|
||||
confirmText : '立即完善',
|
||||
confirmColor : '#da2b54',
|
||||
complete : res => {
|
||||
if (res.confirm) {
|
||||
wx.navigateTo({
|
||||
url: '/pages/idcard/idcard'
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
return
|
||||
}
|
||||
wx.navigateTo({
|
||||
url: pageUrl
|
||||
})
|
||||
@@ -62,5 +73,16 @@ Page({
|
||||
url: "/pages/login/index"
|
||||
})
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 购买产品
|
||||
*/
|
||||
onBuy(e){
|
||||
let { id } = e.currentTarget.dataset
|
||||
if(id){
|
||||
wx.navigateTo({
|
||||
url: '/pages/mall/details/details?id=' + id,
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
@@ -51,10 +51,6 @@
|
||||
<image class="order-icon" src="/static/imgs/order_04.png" mode="widthFix"></image>
|
||||
<view class="order-label">已签收</view>
|
||||
</view>
|
||||
<!-- <view class="order-item">
|
||||
<image class="order-icon" src="/static/imgs/order_05.png" mode="widthFix"></image>
|
||||
<view class="order-label">售后</view>
|
||||
</view> -->
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
@@ -67,15 +63,15 @@
|
||||
<image class="tool-icon" src="/static/imgs/tool_05.png" mode="widthFix"></image>
|
||||
<view class="order-label">我的账户</view>
|
||||
</view>
|
||||
<view class="order-item" bindtap="userNav" data-url="/pages/bankCard/index">
|
||||
<!-- <view class="order-item" bindtap="userNav" data-url="/pages/bankCard/index">
|
||||
<image class="tool-icon" src="/static/imgs/tool_08.png" mode="widthFix"></image>
|
||||
<view class="order-label">我的银行卡</view>
|
||||
</view>
|
||||
</view> -->
|
||||
<view class="order-item" bindtap="userNav" data-url="/pages/user/team/index">
|
||||
<image class="tool-icon" src="/static/imgs/tool_06.png" mode="widthFix"></image>
|
||||
<view class="order-label">我的团队</view>
|
||||
</view>
|
||||
<view class="order-item" bindtap="userNav" data-url="/pages/user/code/code">
|
||||
<view class="order-item" bindtap="userNav" data-url="/pages/user/code/code" data-type="needSign">
|
||||
<image class="tool-icon" src="/static/imgs/tool_07.png" mode="widthFix"></image>
|
||||
<view class="order-label">邀请码</view>
|
||||
</view>
|
||||
@@ -83,9 +79,9 @@
|
||||
<image class="tool-icon" src="/static/imgs/tool_01.png" mode="widthFix"></image>
|
||||
<view class="order-label">我的地址</view>
|
||||
</view>
|
||||
<view class="order-item" bindtap="userNav" data-url="/pages/user/setup/setup">
|
||||
<view class="order-item" bindtap="userNav" data-url="/pages/idcard/idcard">
|
||||
<image class="tool-icon" src="/static/imgs/tool_02.png" mode="widthFix"></image>
|
||||
<view class="order-label">意见反馈</view>
|
||||
<view class="order-label">实名认证</view>
|
||||
</view>
|
||||
<navigator hover-class="none" class="order-item" url="/pages/user/about/about">
|
||||
<image class="tool-icon" src="/static/imgs/tool_03.png" mode="widthFix"></image>
|
||||
@@ -105,7 +101,7 @@
|
||||
<view class="goods-title-name"><text class="goods-title-left"></text>为你推荐<text class="goods-title-right"></text></view>
|
||||
</view>
|
||||
<view class="goodsList">
|
||||
<view class="goodsItem" wx:for="{{userData.goods}}" wx:key="goods">
|
||||
<view class="goodsItem" wx:for="{{userData.goods}}" wx:key="goods" bind:tap="onBuy" data-id="{{item.goods_id}}">
|
||||
<view class="goodsItem-img">
|
||||
<image mode="aspectFill" src="{{item.cover}}"></image>
|
||||
</view>
|
||||
|
||||
@@ -91,11 +91,12 @@ page {
|
||||
}
|
||||
|
||||
.order-icon {
|
||||
width: 56rpx;
|
||||
width: 52rpx;
|
||||
}
|
||||
|
||||
.order-label {
|
||||
font-size: 26rpx;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.order--number {
|
||||
@@ -120,8 +121,7 @@ page {
|
||||
}
|
||||
|
||||
.tool-icon {
|
||||
width: 62rpx;
|
||||
margin-bottom: 10rpx;
|
||||
width: 52rpx;
|
||||
}
|
||||
|
||||
/* 推荐 */
|
||||
@@ -230,7 +230,7 @@ page {
|
||||
|
||||
.goodsItem-price {
|
||||
flex: 1;
|
||||
color: #ff1122;
|
||||
color: #da2b54;
|
||||
font-size: 32rpx;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
@@ -147,7 +147,7 @@ page {
|
||||
padding: 0 !important;
|
||||
background-color: transparent;
|
||||
font-weight: normal !important;
|
||||
color: #6c78f8;
|
||||
color: #da2b54;
|
||||
}
|
||||
|
||||
.publicPop-btn-go {
|
||||
|
||||
@@ -123,6 +123,7 @@ page {
|
||||
padding: 120rpx 0;
|
||||
color: #6d6d6d;
|
||||
font-size: 28rpx;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
|
||||
.pages-no image {
|
||||
|
||||
Reference in New Issue
Block a user