|
@@ -167,6 +167,8 @@ $(function(){
|
|
|
$('.mf .ipt_email').val({{.T.s_myemail}})
|
|
|
$('.correct-icon').show()
|
|
|
freesubmit();
|
|
|
+ }else{
|
|
|
+ $('.mf .ipt_email').val('')
|
|
|
}
|
|
|
if ({{.T.phone_num}}!=""&&{{.T.phone_num}}!=null){
|
|
|
isfreesubmit[1] = 'true';
|
|
@@ -419,24 +421,10 @@ $(function(){
|
|
|
if(res.errCode == 1){
|
|
|
$('.correct-icon').hide()
|
|
|
}else if(res.errCode == 2) {
|
|
|
+ countdown()
|
|
|
$('.correct-icon').hide()
|
|
|
}else if(res.errCode == 3) {
|
|
|
- $('.sendEmail').hide()
|
|
|
- setTimeout(() => {
|
|
|
- $('.timedown').show()
|
|
|
- }, 100);
|
|
|
- var time=300;
|
|
|
- setTime=setInterval(function(){
|
|
|
- if(time<=0){
|
|
|
- $('.timedown').hide()
|
|
|
- $('.sendEmail').show()
|
|
|
- time=299
|
|
|
- clearInterval(setTime);
|
|
|
- return;
|
|
|
- }
|
|
|
- time--;
|
|
|
- $(".timedown").text(time+'s');
|
|
|
- },1000);
|
|
|
+ countdown()
|
|
|
$('.correct-icon').hide()
|
|
|
}else if(res.errCode == 4) {
|
|
|
$('.email_code').slideUp();
|
|
@@ -444,22 +432,7 @@ $(function(){
|
|
|
freesubmit();
|
|
|
$('.correct-icon').hide()
|
|
|
}else if(res.errCode == 5) {
|
|
|
- $('.sendEmail').hide()
|
|
|
- setTimeout(() => {
|
|
|
- $('.timedown').show()
|
|
|
- }, 100);
|
|
|
- var time=300;
|
|
|
- setTime=setInterval(function(){
|
|
|
- if(time<=0){
|
|
|
- $('.timedown').hide()
|
|
|
- $('.sendEmail').show()
|
|
|
- time=299
|
|
|
- clearInterval(setTime);
|
|
|
- return;
|
|
|
- }
|
|
|
- time--;
|
|
|
- $(".timedown").text(time+'s');
|
|
|
- },1000);
|
|
|
+ countdown()
|
|
|
}else{
|
|
|
// weui.toast('发送失败', 1500);
|
|
|
}
|
|
@@ -472,6 +445,28 @@ $(function(){
|
|
|
|
|
|
})
|
|
|
})
|
|
|
+
|
|
|
+
|
|
|
+// 倒计时
|
|
|
+function countdown() {
|
|
|
+ $('.sendEmail').hide()
|
|
|
+ setTimeout(() => {
|
|
|
+ $('.timedown').show()
|
|
|
+ }, 100);
|
|
|
+ var time=300;
|
|
|
+ setTime=setInterval(function(){
|
|
|
+ if(time<=0){
|
|
|
+ $('.timedown').hide()
|
|
|
+ $('.sendEmail').show()
|
|
|
+ time=299
|
|
|
+ clearInterval(setTime);
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ time--;
|
|
|
+ $(".timedown").text(time+'s');
|
|
|
+ },1000);
|
|
|
+}
|
|
|
+
|
|
|
// 验证手机号格式
|
|
|
function isPoneAvailable($poneInput) {
|
|
|
var myreg=/^[1][3,4,5,7,8][0-9]{9}$/;
|