feat:173版本
This commit is contained in:
@@ -1,13 +1,18 @@
|
||||
<template>
|
||||
<view class="register_warp">
|
||||
<view class="header_">
|
||||
<view style="margin-top: 10rpx">
|
||||
<up-image src="/static/common/left.png" width="18" height="20" bgColor="#f1f6ff00" @click="jumpMine" />
|
||||
<!-- 顶部固定导航栏 -->
|
||||
<view class="navbar-sticky-wrapper" :style="mpWarpStyle">
|
||||
<view class="custom-navbar" :style="mpHeaderStyle">
|
||||
<view class="back_btn" @click="jumpMine">
|
||||
<up-image src="/static/common/left.png" width="18" height="20" bgColor="#f1f6ff00" />
|
||||
</view>
|
||||
<view class="nav-title">绑定手机号</view>
|
||||
<view class="nav-right"></view>
|
||||
</view>
|
||||
<view class="title_">绑定手机号</view>
|
||||
<view></view>
|
||||
</view>
|
||||
|
||||
<view class="register_content">
|
||||
|
||||
<view class="register_ifo_warp">
|
||||
<view class="register_info_item">
|
||||
<up-input placeholder="请输入手机号" border="surround" v-model="form.mobile" :customStyle="inputCss"></up-input>
|
||||
@@ -46,6 +51,8 @@
|
||||
</up-checkbox>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<up-toast ref="uToastRef"></up-toast>
|
||||
<u-modal :show="tipsShow" title="提示" showCancelButton @cancel="onCancel" @confirm="onConfirm">
|
||||
<view class="slot-content">
|
||||
@@ -71,6 +78,8 @@ import {
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
mpWarpStyle: {},
|
||||
mpHeaderStyle: {},
|
||||
form: {
|
||||
mobile: null,
|
||||
smsCode: null, // 验证码
|
||||
@@ -94,6 +103,7 @@ export default {
|
||||
},
|
||||
|
||||
onLoad(option) {
|
||||
this.initMPHeader();
|
||||
this.form.token = option.token;
|
||||
this.type = option.type;
|
||||
console.log("-----1", option, this.form.token, this.type);
|
||||
@@ -102,7 +112,9 @@ export default {
|
||||
submit() {
|
||||
if (!this.isPolicy) {
|
||||
this.tipsShow = true;
|
||||
return;
|
||||
}
|
||||
this.registerFun();
|
||||
},
|
||||
onCancel() {
|
||||
this.tipsShow = false;
|
||||
@@ -112,9 +124,54 @@ export default {
|
||||
this.isPolicy = true;
|
||||
this.registerFun();
|
||||
},
|
||||
initMPHeader() {
|
||||
try {
|
||||
const systemInfo = uni.getSystemInfoSync();
|
||||
const statusBarHeight = systemInfo.statusBarHeight || 0;
|
||||
|
||||
// #ifdef MP-WEIXIN || MP
|
||||
const menuButton = uni.getMenuButtonBoundingClientRect();
|
||||
if (menuButton && menuButton.top && menuButton.top > 0) {
|
||||
const menuButtonHeight = menuButton.height || 32;
|
||||
const menuButtonTop = menuButton.top;
|
||||
const menuButtonLeft = menuButton.left;
|
||||
const windowWidth = systemInfo.windowWidth;
|
||||
|
||||
this.mpWarpStyle = {
|
||||
paddingTop: `${menuButtonTop}px`
|
||||
};
|
||||
|
||||
this.mpHeaderStyle = {
|
||||
height: `${menuButtonHeight}px`,
|
||||
paddingRight: `${windowWidth - menuButtonLeft + 10}px`,
|
||||
display: 'flex',
|
||||
alignItems: 'center'
|
||||
};
|
||||
return;
|
||||
}
|
||||
// #endif
|
||||
|
||||
// APP-PLUS 或 H5 或 无胶囊环境
|
||||
this.mpWarpStyle = {
|
||||
paddingTop: `${statusBarHeight}px`
|
||||
};
|
||||
|
||||
this.mpHeaderStyle = {
|
||||
height: '88rpx',
|
||||
display: 'flex',
|
||||
alignItems: 'center'
|
||||
};
|
||||
} catch (e) {
|
||||
console.error("initMPHeader error:", e);
|
||||
}
|
||||
},
|
||||
jumpMine() {
|
||||
uni.reLaunch({
|
||||
url: "/pages/login_package/login/login",
|
||||
uni.navigateBack({
|
||||
fail: () => {
|
||||
uni.redirectTo({
|
||||
url: "/pages/login_package/login/login",
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
// 用户协议
|
||||
@@ -237,21 +294,53 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.header_ {
|
||||
.register_warp {
|
||||
min-height: 100vh;
|
||||
box-sizing: border-box;
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.navbar-sticky-wrapper {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 100;
|
||||
background-color: #ffffff;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.custom-navbar {
|
||||
height: 88rpx;
|
||||
background-color: #ffffff;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
padding: calc(24rpx + env(safe-area-inset-bottom)) 30rpx 0 30rpx;
|
||||
justify-content: space-between;
|
||||
padding: 0 24rpx;
|
||||
position: relative;
|
||||
box-sizing: border-box;
|
||||
|
||||
.title_ {
|
||||
font-weight: bold;
|
||||
font-size: 36rpx;
|
||||
margin-left: 20rpx;
|
||||
.back_btn {
|
||||
width: 60rpx;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.nav-title {
|
||||
font-size: 34rpx;
|
||||
font-weight: 600;
|
||||
color: #1A1A1A;
|
||||
text-align: center;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.nav-right {
|
||||
width: 60rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.register_warp {
|
||||
height: calc(100vh - 280rpx);
|
||||
padding: 40rpx;
|
||||
.register_content {
|
||||
padding: 0 40rpx;
|
||||
}
|
||||
|
||||
.register_title_warp {
|
||||
|
||||
Reference in New Issue
Block a user