Browse Source

修复学生登录

ting.yin 8 years ago
parent
commit
8ec900674d

+ 3 - 1
core-api/src/main/java/cn/com/qmth/examcloud/service/core/service/StudentService.java

@@ -180,7 +180,9 @@ public class StudentService {
             throw new RuntimeException("该用户被禁用");
             throw new RuntimeException("该用户被禁用");
         }else {
         }else {
             String token = AccessCtrlUtil.buildToken();
             String token = AccessCtrlUtil.buildToken();
-            userService.createAccessUser(token, student.getUser(), student.getId());
+        	userService.initUserLogin(student.getUser());
+        	userService.createAccessUser(token,student.getUser(),student.getId());
+        	userService.createUserLogin(token,student.getUser());
             UserInfo userInfo = userService.getUserInfo(student.getUser(), token);
             UserInfo userInfo = userService.getUserInfo(student.getUser(), token);
             userInfo.setStudentId(student.getId());
             userInfo.setStudentId(student.getId());
             userInfo.setIdentityNumber(student.getIdentityNumber());
             userInfo.setIdentityNumber(student.getIdentityNumber());