...
|
...
|
@@ -289,33 +289,41 @@ |
|
|
mui.toast("请输入正确的手机号");
|
|
|
unstock();
|
|
|
}else{
|
|
|
|
|
|
const TIME_COUNT = 60;
|
|
|
app.show = false;
|
|
|
if (!app.timer) {
|
|
|
app.count = TIME_COUNT;
|
|
|
app.count = TIME_COUNT;
|
|
|
|
|
|
var header = {
|
|
|
"XX-Device-Type": getDevice(),
|
|
|
'XX-Token': getToken()
|
|
|
};
|
|
|
var post = {
|
|
|
tel: app.tel
|
|
|
};
|
|
|
getRequest('post', 'home/index/loginBySMS', post, header).then(function (res) {
|
|
|
// alert(JSON.stringify(res))
|
|
|
// alert(res.data.msg)
|
|
|
mui.toast(res.data.msg);
|
|
|
unstock()
|
|
|
app.timer = setInterval(function () {
|
|
|
if (app.count > 0 && app.count <= TIME_COUNT) {
|
|
|
app.count--;
|
|
|
} else {
|
|
|
app.show = true;
|
|
|
clearInterval(this.timer);
|
|
|
app.timer = null;
|
|
|
}
|
|
|
}, 1000)
|
|
|
if (!app.timer) {
|
|
|
app.timer = setInterval(function () {
|
|
|
if (app.count > 0 && app.count <= TIME_COUNT) {
|
|
|
app.count--;
|
|
|
} else {
|
|
|
app.show = true;
|
|
|
clearInterval(this.timer);
|
|
|
app.timer = null;
|
|
|
}
|
|
|
}, 1000)
|
|
|
}
|
|
|
// alert(JSON.stringify(res))
|
|
|
// alert(res.data.msg)
|
|
|
|
|
|
|
|
|
})
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
},
|
|
|
|
...
|
...
|
@@ -323,7 +331,7 @@ |
|
|
reg_fir: function () {
|
|
|
var header = {
|
|
|
"XX-Device-Type": getDevice(),
|
|
|
'XX-Token': getToken()
|
|
|
// 'XX-Token': getToken()
|
|
|
};
|
|
|
var post = {
|
|
|
tel: app.tel,
|
...
|
...
|
|