|
@@ -5,7 +5,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
import com.google.gson.Gson;
|
|
import com.google.gson.Gson;
|
|
import com.qmth.themis.business.cache.bean.ExamCourseCacheBean;
|
|
import com.qmth.themis.business.cache.bean.ExamCourseCacheBean;
|
|
import com.qmth.themis.business.constant.SystemConstant;
|
|
import com.qmth.themis.business.constant.SystemConstant;
|
|
-import com.qmth.themis.business.dao.*;
|
|
|
|
|
|
+import com.qmth.themis.business.dao.TEExamCourseMapper;
|
|
import com.qmth.themis.business.dto.ExamStudentImportDto;
|
|
import com.qmth.themis.business.dto.ExamStudentImportDto;
|
|
import com.qmth.themis.business.dto.RoomCodeImportDto;
|
|
import com.qmth.themis.business.dto.RoomCodeImportDto;
|
|
import com.qmth.themis.business.entity.*;
|
|
import com.qmth.themis.business.entity.*;
|
|
@@ -54,23 +54,11 @@ public class TempleteLogicServiceImpl implements TempleteLogicService {
|
|
@Resource
|
|
@Resource
|
|
TEExamCourseService teExamCourseService;
|
|
TEExamCourseService teExamCourseService;
|
|
|
|
|
|
- @Resource
|
|
|
|
- TEStudentMapper teStudentMapper;
|
|
|
|
-
|
|
|
|
- @Resource
|
|
|
|
- TEExamStudentMapper teExamStudentMapper;
|
|
|
|
-
|
|
|
|
- @Resource
|
|
|
|
- TBExamInvigilateUserMapper tbExamInvigilateUserMapper;
|
|
|
|
-
|
|
|
|
@Resource
|
|
@Resource
|
|
TEExamCourseMapper teExamCourseMapper;
|
|
TEExamCourseMapper teExamCourseMapper;
|
|
|
|
|
|
@Resource
|
|
@Resource
|
|
- TBUserMapper tbUserMapper;
|
|
|
|
-
|
|
|
|
- @Resource
|
|
|
|
- TBUserRoleMapper tbUserRoleMapper;
|
|
|
|
|
|
+ TBUserRoleService tbUserRoleService;
|
|
|
|
|
|
/**
|
|
/**
|
|
* 考生导入逻辑
|
|
* 考生导入逻辑
|
|
@@ -204,10 +192,10 @@ public class TempleteLogicServiceImpl implements TempleteLogicService {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (!CollectionUtils.isEmpty(teStudentList)) {
|
|
if (!CollectionUtils.isEmpty(teStudentList)) {
|
|
- teStudentMapper.insertOrUpdateBath(teStudentList);
|
|
|
|
|
|
+ teStudentService.saveOrUpdateBatch(teStudentList);
|
|
}
|
|
}
|
|
if (!CollectionUtils.isEmpty(teExamStudentList)) {
|
|
if (!CollectionUtils.isEmpty(teExamStudentList)) {
|
|
- teExamStudentMapper.insertOrUpdateBath(teExamStudentList);
|
|
|
|
|
|
+ teExamStudentService.saveOrUpdateBatch(teExamStudentList);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
map.put("line", line);
|
|
map.put("line", line);
|
|
@@ -219,13 +207,12 @@ public class TempleteLogicServiceImpl implements TempleteLogicService {
|
|
if (Objects.isNull(tbExamInvigilateUserMap) || (Objects.nonNull(tbExamInvigilateUserMap) && Objects.isNull(tbExamInvigilateUserMap.get(s)))) {
|
|
if (Objects.isNull(tbExamInvigilateUserMap) || (Objects.nonNull(tbExamInvigilateUserMap) && Objects.isNull(tbExamInvigilateUserMap.get(s)))) {
|
|
String[] strs = s.split(":");
|
|
String[] strs = s.split(":");
|
|
TBExamInvigilateUser tbExamInvigilateUser = new TBExamInvigilateUser(Long.parseLong(strs[0]), orgId, strs[1], strs[2]);
|
|
TBExamInvigilateUser tbExamInvigilateUser = new TBExamInvigilateUser(Long.parseLong(strs[0]), orgId, strs[1], strs[2]);
|
|
-// tbExamInvigilateUserService.save(tbExamInvigilateUser);
|
|
|
|
tbExamInvigilateUserList.add(tbExamInvigilateUser);
|
|
tbExamInvigilateUserList.add(tbExamInvigilateUser);
|
|
count.getAndIncrement();
|
|
count.getAndIncrement();
|
|
}
|
|
}
|
|
});
|
|
});
|
|
if (!CollectionUtils.isEmpty(tbExamInvigilateUserList)) {
|
|
if (!CollectionUtils.isEmpty(tbExamInvigilateUserList)) {
|
|
- tbExamInvigilateUserMapper.insertOrUpdateBath(tbExamInvigilateUserList);
|
|
|
|
|
|
+ tbExamInvigilateUserService.saveOrUpdateBatch(tbExamInvigilateUserList);
|
|
}
|
|
}
|
|
if (count.get() > 0) {
|
|
if (count.get() > 0) {
|
|
txtList.add(DateUtil.format(new Date(), Constants.DEFAULT_DATE_PATTERN) + "->创建了" + count + "条考场数据");
|
|
txtList.add(DateUtil.format(new Date(), Constants.DEFAULT_DATE_PATTERN) + "->创建了" + count + "条考场数据");
|
|
@@ -297,13 +284,13 @@ public class TempleteLogicServiceImpl implements TempleteLogicService {
|
|
tbExamInvigilateUserService.remove(wrapper);
|
|
tbExamInvigilateUserService.remove(wrapper);
|
|
|
|
|
|
if (!CollectionUtils.isEmpty(tbUserList)) {
|
|
if (!CollectionUtils.isEmpty(tbUserList)) {
|
|
- tbUserMapper.insertOrUpdateBath(tbUserList);
|
|
|
|
|
|
+ tbUserService.saveOrUpdateBatch(tbUserList);
|
|
}
|
|
}
|
|
if (!CollectionUtils.isEmpty(tbUserRoleList)) {
|
|
if (!CollectionUtils.isEmpty(tbUserRoleList)) {
|
|
- tbUserRoleMapper.insertOrUpdateBath(tbUserRoleList);
|
|
|
|
|
|
+ tbUserRoleService.saveOrUpdateBatch(tbUserRoleList);
|
|
}
|
|
}
|
|
if (!CollectionUtils.isEmpty(tbExamInvigilateUserList)) {
|
|
if (!CollectionUtils.isEmpty(tbExamInvigilateUserList)) {
|
|
- tbExamInvigilateUserMapper.insertOrUpdateBath(tbExamInvigilateUserList);
|
|
|
|
|
|
+ tbExamInvigilateUserService.saveOrUpdateBatch(tbExamInvigilateUserList);
|
|
}
|
|
}
|
|
map.put("line", line);
|
|
map.put("line", line);
|
|
return map;
|
|
return map;
|