Commit 21b11d36 authored by 赵啸非's avatar 赵啸非

修复部分sqlXml生成缺陷

parent d9dd1f13
......@@ -65,7 +65,7 @@ public class LoginController extends BaseCRUDJsonController<UserService, UserFor
JSONObject ret = new JSONObject();
String loginName = loginForm.getLoginName();
String password = loginForm.getPassword();
// String securityCode = loginForm.getSecurityCode();
String securityCode = loginForm.getSecurityCode();
String ip = super.getRequestIP(request);
if (StringUtils.isEmpty(loginName) || StringUtils.isEmpty(password)) {
ret.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
......@@ -74,14 +74,14 @@ public class LoginController extends BaseCRUDJsonController<UserService, UserFor
}
UserEntity userEntity = null;
try {
// loginForm.validate();
// boolean result = validCodeService.doCheckImageValidCode(request.getSession().getId(), ip, securityCode);
// if (!result) {
// recordSysLog(request, userEntity, "登录验证码不正确或已过期!");
// ret.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
// ret.put(KEY_RESULT_MSG, "登录验证码不正确或已过期!");
// return ret.toJSONString();
// }
loginForm.validate();
boolean result = validCodeService.doCheckImageValidCode(request.getSession().getId(), ip, securityCode);
if (!result) {
recordSysLog(request, userEntity, "登录验证码不正确或已过期!");
ret.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
ret.put(KEY_RESULT_MSG, "登录验证码不正确或已过期!");
return ret.toJSONString();
}
userEntity = userService.doLogin(loginName, password, ip);
userEntity.setLastLoginAddress(ip);
// saveCurrUser(request, response, userEntity);
......
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