Commit 61e576c7 authored by 董建华's avatar 董建华

增加一些注释

parent aa052074
......@@ -91,14 +91,21 @@ public class CaptchaFiniteValidateAdvisor {
return JsonResult.buildErrorStateResult("用户名或密码不正确", null);
}
if (countErrorByPhone > Constants.Image_Need_Count) {
/**
* 输入密码错误超过一定次数限制登陆
*/
if (countErrorByPhone > Constants.PASSWORD_ERROR_LOCK_COUNT) {
String lock_key = Constants.PASSWORD_LOCK_PRE.concat(phoneNo);
Long expire = redisTemplate.opsForValue().getOperations().getExpire(lock_key);
if (expire != null && expire > 0L) {
/**
* 查看锁的剩余时间不存在说明已经解锁
*/
if (null != expire && expire > 0L) {
/**
* 获取到的时间是秒 转化为分 大概转一下吧不要太精确
*/
expire = expire > 60L ? expire / 60 : 1L;
return JsonResult.buildErrorStateResult(String.format(ALERT_TEMP, expire ), null);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment