更改验证码接口

This commit is contained in:
唐明明
2022-06-15 14:36:28 +08:00
parent a3221cfe18
commit e5cd4c5f41
8 changed files with 7604 additions and 7590 deletions

View File

@@ -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
clearInterval(account)
if(this.isAccount){
this.isAccount = false;
clearInterval(account)
}
},
// 共力人生
getLife(){
@@ -176,10 +178,13 @@
this.$nextTick(() => {
try{
// 计算数值
account = setInterval(() =>{
let newGlz = (Number(this.glz) + this.base_seconds)
this.glz = newGlz.toFixed(4)
}, 1000)
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,