|
@@ -11,6 +11,7 @@ import com.qmth.boot.core.fss.store.FileStore;
|
|
|
import com.qmth.exam.reserve.bean.Constants;
|
|
|
import com.qmth.exam.reserve.bean.applytask.CurrentApplyTaskVO;
|
|
|
import com.qmth.exam.reserve.bean.login.LoginUser;
|
|
|
+import com.qmth.exam.reserve.bean.org.OrgInfo;
|
|
|
import com.qmth.exam.reserve.bean.stdapply.CategoryVO;
|
|
|
import com.qmth.exam.reserve.bean.student.StudentInfo;
|
|
|
import com.qmth.exam.reserve.bean.student.StudentReq;
|
|
@@ -18,6 +19,7 @@ import com.qmth.exam.reserve.bean.student.StudentVO;
|
|
|
import com.qmth.exam.reserve.bean.student.WechatBindReq;
|
|
|
import com.qmth.exam.reserve.cache.impl.ApplyTaskCacheService;
|
|
|
import com.qmth.exam.reserve.cache.impl.CategoryCacheService;
|
|
|
+import com.qmth.exam.reserve.cache.impl.OrgCacheService;
|
|
|
import com.qmth.exam.reserve.config.SysProperty;
|
|
|
import com.qmth.exam.reserve.dao.StudentDao;
|
|
|
import com.qmth.exam.reserve.entity.ApplyTaskEntity;
|
|
@@ -85,6 +87,9 @@ public class StudentServiceImpl extends ServiceImpl<StudentDao, StudentEntity> i
|
|
|
@Autowired
|
|
|
private StudentCourseService studentCourseService;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private OrgCacheService orgCacheService;
|
|
|
+
|
|
|
@Override
|
|
|
public StudentEntity findByStudentCode(Long applyTaskId, String studentCode) {
|
|
|
if (StringUtils.isEmpty(studentCode)) {
|
|
@@ -205,9 +210,10 @@ public class StudentServiceImpl extends ServiceImpl<StudentDao, StudentEntity> i
|
|
|
|
|
|
@Override
|
|
|
public PageResult<StudentVO> pageStudent(StudentReq req) {
|
|
|
- if(req.getTaskId() == null) {
|
|
|
- CurrentApplyTaskVO curApplyTask = applyTaskCacheService.currentApplyTask(null);
|
|
|
- if(curApplyTask == null) {
|
|
|
+ if (req.getTaskId() == null) {
|
|
|
+ OrgInfo org = orgCacheService.currentOrg();
|
|
|
+ CurrentApplyTaskVO curApplyTask = applyTaskCacheService.currentApplyTask(org.getOrgId());
|
|
|
+ if (curApplyTask == null) {
|
|
|
return new PageResult<>();
|
|
|
} else {
|
|
|
req.setTaskId(curApplyTask.getTaskId());
|
|
@@ -319,8 +325,8 @@ public class StudentServiceImpl extends ServiceImpl<StudentDao, StudentEntity> i
|
|
|
if (file.getSize() > Constants.FILE_SIZE_LIMIT) {
|
|
|
throw new StatusException("上传的考生照片大小不能超过5M");
|
|
|
}
|
|
|
-
|
|
|
- CurrentApplyTaskVO curApplyTask = applyTaskCacheService.currentApplyTask(null);
|
|
|
+ OrgInfo org = orgCacheService.currentOrg();
|
|
|
+ CurrentApplyTaskVO curApplyTask = applyTaskCacheService.currentApplyTask(org.getOrgId());
|
|
|
if (curApplyTask == null) {
|
|
|
throw new StatusException("未开启预约任务,无法导入");
|
|
|
}
|