Showing
3 changed files
with
21 additions
and
1 deletions
@@ -140,6 +140,11 @@ function sendMessageValidate() { | @@ -140,6 +140,11 @@ function sendMessageValidate() { | ||
140 | captcha.show(); | 140 | captcha.show(); |
141 | } | 141 | } |
142 | 142 | ||
143 | + if (data.code === captcha.errorCode) { | ||
144 | + captcha.showTip(data.message); | ||
145 | + return; | ||
146 | + } | ||
147 | + | ||
143 | alert(data.message); // eslint-disable-line | 148 | alert(data.message); // eslint-disable-line |
144 | }); | 149 | }); |
145 | }); | 150 | }); |
@@ -251,6 +251,15 @@ function sendMessageValidate() { | @@ -251,6 +251,15 @@ function sendMessageValidate() { | ||
251 | verifyCode: captcha2.getResults() | 251 | verifyCode: captcha2.getResults() |
252 | } | 252 | } |
253 | }).then(function(data) { | 253 | }).then(function(data) { |
254 | + if (data.data && data.data.needCaptcha) { | ||
255 | + showCaptchaImg(); | ||
256 | + } | ||
257 | + | ||
258 | + if (data.code === captcha2.errorCode) { | ||
259 | + captcha2.showTip(data.message); | ||
260 | + return; | ||
261 | + } | ||
262 | + | ||
254 | if (data.code !== 200) { | 263 | if (data.code !== 200) { |
255 | alert(data.message); // eslint-disable-line | 264 | alert(data.message); // eslint-disable-line |
256 | } else { | 265 | } else { |
@@ -354,7 +363,7 @@ function nextStep() { | @@ -354,7 +363,7 @@ function nextStep() { | ||
354 | success: function(data) { | 363 | success: function(data) { |
355 | var winHeight = $(window).height(); | 364 | var winHeight = $(window).height(); |
356 | 365 | ||
357 | - if (data.code !== 200 && data.data && data.data.needCaptcha) { | 366 | + if (data.data && data.data.needCaptcha) { |
358 | showCaptchaImg(); | 367 | showCaptchaImg(); |
359 | } | 368 | } |
360 | 369 |
@@ -59,6 +59,11 @@ function sendMessageValidate() { | @@ -59,6 +59,11 @@ function sendMessageValidate() { | ||
59 | captcha.show(); | 59 | captcha.show(); |
60 | } | 60 | } |
61 | 61 | ||
62 | + if (data.code === captcha.errorCode) { | ||
63 | + captcha.showTip(data.message); | ||
64 | + return; | ||
65 | + } | ||
66 | + | ||
62 | if (data.code !== 200) { | 67 | if (data.code !== 200) { |
63 | alert(data.message); // eslint-disable-line | 68 | alert(data.message); // eslint-disable-line |
64 | } | 69 | } |
@@ -122,6 +127,7 @@ function actionConfirm() { | @@ -122,6 +127,7 @@ function actionConfirm() { | ||
122 | function init() { | 127 | function init() { |
123 | sendMessageValidate(); | 128 | sendMessageValidate(); |
124 | actionConfirm(); | 129 | actionConfirm(); |
130 | + circleTime(); | ||
125 | } | 131 | } |
126 | 132 | ||
127 | init(); | 133 | init(); |
-
Please register or login to post a comment