更改验证码接口
This commit is contained in:
@@ -17,6 +17,15 @@ const smsAuth = (data) =>{
|
||||
})
|
||||
}
|
||||
|
||||
// 获取带有邀请码可填写的邀请码接口
|
||||
const getInvitationSms = (data) =>{
|
||||
return request({
|
||||
url: "user/auth/new_verify",
|
||||
method: 'POST',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 获取验证码
|
||||
const getSms = (data) =>{
|
||||
return request({
|
||||
@@ -51,6 +60,7 @@ const secretService = (name) =>{
|
||||
|
||||
export {
|
||||
smsAuth,
|
||||
getInvitationSms,
|
||||
getSms,
|
||||
userFigure,
|
||||
createUser,
|
||||
|
||||
@@ -13,8 +13,8 @@
|
||||
<input v-model="code" type="number" maxlength="4" placeholder="输入验证码">
|
||||
<button :disabled="getSms" size="mini" @click="getPhoneCode()">{{sendCode}}</button>
|
||||
</view>
|
||||
<view class="auth-input">
|
||||
<input v-model="parentId" placeholder="输入邀请码">
|
||||
<view class="auth-input" v-if="isShowParent">
|
||||
<input v-model="parentId" placeholder="输入邀请码,选填">
|
||||
</view>
|
||||
<view class="auth-button">
|
||||
<button @click="login('code')">登录</button>
|
||||
@@ -32,16 +32,17 @@
|
||||
<script>
|
||||
import {
|
||||
smsAuth,
|
||||
getSms
|
||||
getInvitationSms
|
||||
} from '@/apis/interfaces/auth.js'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
phone : '',
|
||||
code : '',
|
||||
parentId: '',
|
||||
parentId : '',
|
||||
getSms : false,
|
||||
sendCode: '获取验证码'
|
||||
sendCode : '获取验证码',
|
||||
isShowParent: false
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
@@ -56,13 +57,14 @@
|
||||
})
|
||||
let outTime;
|
||||
let smsTime = 60;
|
||||
getSms({
|
||||
getInvitationSms({
|
||||
mobileNo: this.phone,
|
||||
}).then(res => {
|
||||
uni.showToast({
|
||||
title: res,
|
||||
title: res.message,
|
||||
icon: "none",
|
||||
});
|
||||
this.isShowParent = res.is_show_parent
|
||||
this.getSms = true;
|
||||
this.sendCode = smsTime + 's后重新获取';
|
||||
outTime = setInterval(() => {
|
||||
|
||||
@@ -11,8 +11,9 @@
|
||||
</view>
|
||||
<view class="capacity-block">
|
||||
<view class="capacity-block-title">
|
||||
<view class="title">成员产率({{group.effect}}/{{group.count}})<text>{{group.capacity}}GLF/h</text></view>
|
||||
<view class="more" @click="onInvitation">邀请更多好友</view>
|
||||
<view class="title">成员产率({{group.effect}}/{{group.count}})<text</text></view>
|
||||
<view class="capacity-block-glf">{{group.capacity}}GLF/h</view>
|
||||
<!-- <view class="more" @click="onInvitation">邀请更多好友</view> -->
|
||||
</view>
|
||||
<view class="capacity-block-table">
|
||||
<view class="header">
|
||||
@@ -36,7 +37,7 @@
|
||||
<view class="flex-item">{{partner.vip_text}}</view>
|
||||
</view>
|
||||
<view class="flex">
|
||||
<view class="flex-item">{{partner.novip}}人在线(会员)</view>
|
||||
<view class="flex-item">{{partner.novip}}人在线(普通用户)</view>
|
||||
<view class="flex-item">{{partner.novip_text}}</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -104,9 +104,7 @@
|
||||
|
||||
<script>
|
||||
import { life, sign } from '@/apis/interfaces/life.js'
|
||||
|
||||
var account;
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@@ -132,6 +130,7 @@
|
||||
base_seconds: 0,
|
||||
timeData : {},
|
||||
isSign : false,
|
||||
isAccount : false,
|
||||
};
|
||||
},
|
||||
onShow() {
|
||||
@@ -145,7 +144,10 @@
|
||||
// 倒计时结束
|
||||
TimeFinish(){
|
||||
this.isSign = false
|
||||
if(this.isAccount){
|
||||
this.isAccount = false;
|
||||
clearInterval(account)
|
||||
}
|
||||
},
|
||||
// 共力人生
|
||||
getLife(){
|
||||
@@ -176,10 +178,13 @@
|
||||
this.$nextTick(() => {
|
||||
try{
|
||||
// 计算数值
|
||||
if(!this.isAccount){
|
||||
this.isAccount = true;
|
||||
account = setInterval(() =>{
|
||||
let newGlz = (Number(this.glz) + this.base_seconds)
|
||||
this.glz = newGlz.toFixed(4)
|
||||
}, 1000)
|
||||
}
|
||||
// 签到开始倒计时
|
||||
this.$refs.countDown.start();
|
||||
}catch(e){
|
||||
@@ -232,6 +237,7 @@
|
||||
try{
|
||||
clearInterval(account)
|
||||
this.$refs.countDown.pause();
|
||||
this.isAccount = false;
|
||||
}catch(err){
|
||||
uni.showToast({
|
||||
title: err,
|
||||
|
||||
4
unpackage/dist/build/app-plus/app-service.js
vendored
4
unpackage/dist/build/app-plus/app-service.js
vendored
File diff suppressed because one or more lines are too long
2
unpackage/dist/build/app-plus/app-view.js
vendored
2
unpackage/dist/build/app-plus/app-view.js
vendored
File diff suppressed because one or more lines are too long
13173
unpackage/dist/dev/app-plus/app-service.js
vendored
13173
unpackage/dist/dev/app-plus/app-service.js
vendored
File diff suppressed because one or more lines are too long
1918
unpackage/dist/dev/app-plus/app-view.js
vendored
1918
unpackage/dist/dev/app-plus/app-view.js
vendored
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user