|
@@ -3,6 +3,7 @@ package com.zhongzheng.modules.grade.service.impl;
|
|
import cn.hutool.core.bean.BeanUtil;
|
|
import cn.hutool.core.bean.BeanUtil;
|
|
import cn.hutool.core.util.StrUtil;
|
|
import cn.hutool.core.util.StrUtil;
|
|
import com.zhongzheng.common.utils.DateUtils;
|
|
import com.zhongzheng.common.utils.DateUtils;
|
|
|
|
+import com.zhongzheng.modules.grade.bo.UserPeriodQueryBo;
|
|
import com.zhongzheng.modules.grade.service.IUserPeriodStatusService;
|
|
import com.zhongzheng.modules.grade.service.IUserPeriodStatusService;
|
|
import com.zhongzheng.modules.grade.vo.*;
|
|
import com.zhongzheng.modules.grade.vo.*;
|
|
import com.zhongzheng.modules.user.bo.SubjectStudyRecordQueryBo;
|
|
import com.zhongzheng.modules.user.bo.SubjectStudyRecordQueryBo;
|
|
@@ -188,15 +189,33 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
List<ClassPeriodChapterVo> classPeriodChapterVos = baseMapper.listperiodChapter(classPeriodVo.getId(), bo.getGoodsId(),classPeriodVo.getCourseId(), bo.getUserId());
|
|
List<ClassPeriodChapterVo> classPeriodChapterVos = baseMapper.listperiodChapter(classPeriodVo.getId(), bo.getGoodsId(),classPeriodVo.getCourseId(), bo.getUserId());
|
|
classPeriodChapterVos.addAll(baseMapper.listperiodExam(classPeriodVo.getId(), bo.getGoodsId(),classPeriodVo.getCourseId(), bo.getUserId()));
|
|
classPeriodChapterVos.addAll(baseMapper.listperiodExam(classPeriodVo.getId(), bo.getGoodsId(),classPeriodVo.getCourseId(), bo.getUserId()));
|
|
for (ClassPeriodChapterVo classPeriodChapterVo : classPeriodChapterVos) {
|
|
for (ClassPeriodChapterVo classPeriodChapterVo : classPeriodChapterVos) {
|
|
- List<ClassPeriodSectionVo> classPeriodSectionVos = baseMapper.listPeriodSection(classPeriodChapterVo.getId(), bo.getGoodsId(), classPeriodVo.getCourseId(), bo.getUserId());
|
|
|
|
- classPeriodChapterVo.setClassPeriodSectionList(classPeriodSectionVos);
|
|
|
|
|
|
+ if (classPeriodChapterVo.getType() == 4){
|
|
|
|
+ UserPeriodQueryBo userPeriodQueryBo = new UserPeriodQueryBo();
|
|
|
|
+ userPeriodQueryBo.setExamId(classPeriodChapterVo.getId());
|
|
|
|
+ userPeriodQueryBo.setCourseId(classPeriodChapterVo.getCourseId());
|
|
|
|
+ userPeriodQueryBo.setGoodsId(bo.getGoodsId());
|
|
|
|
+ classPeriodChapterVo.setUserPeriodStatusVos(userPeriodStatusService.selectPeriodStatus(userPeriodQueryBo));
|
|
|
|
+ }
|
|
|
|
+ if (classPeriodChapterVo.getType() == 2) {
|
|
|
|
+ List<ClassPeriodSectionVo> classPeriodSectionVos = baseMapper.listPeriodSection(classPeriodChapterVo.getId(), bo.getGoodsId(), classPeriodVo.getCourseId(), bo.getUserId());
|
|
|
|
+ for (ClassPeriodSectionVo classPeriodSectionVo : classPeriodSectionVos) {
|
|
|
|
+ UserPeriodQueryBo userPeriodQueryBo = new UserPeriodQueryBo();
|
|
|
|
+ userPeriodQueryBo.setSectionId(classPeriodSectionVo.getId());
|
|
|
|
+ userPeriodQueryBo.setCourseId(classPeriodSectionVo.getCourseId());
|
|
|
|
+ userPeriodQueryBo.setGoodsId(bo.getGoodsId());
|
|
|
|
+ userPeriodQueryBo.setChapterId(classPeriodChapterVo.getId());
|
|
|
|
+ userPeriodQueryBo.setModuleId(classPeriodVo.getId());
|
|
|
|
+ classPeriodSectionVo.setUserPeriodStatusVos(userPeriodStatusService.selectPeriodStatus(userPeriodQueryBo));
|
|
|
|
+ }
|
|
|
|
+ classPeriodChapterVo.setClassPeriodSectionList(classPeriodSectionVos);
|
|
|
|
+ }
|
|
}
|
|
}
|
|
-
|
|
|
|
classPeriodVo.setClassPeriods(classPeriodChapterVos);
|
|
classPeriodVo.setClassPeriods(classPeriodChapterVos);
|
|
}
|
|
}
|
|
if (classPeriodVo.getType() == 2){
|
|
if (classPeriodVo.getType() == 2){
|
|
List<ClassPeriodSectionVo> classPeriodSectionVos = baseMapper.listPeriodSection(classPeriodVo.getId(), bo.getGoodsId(), classPeriodVo.getCourseId(), bo.getUserId());
|
|
List<ClassPeriodSectionVo> classPeriodSectionVos = baseMapper.listPeriodSection(classPeriodVo.getId(), bo.getGoodsId(), classPeriodVo.getCourseId(), bo.getUserId());
|
|
classPeriodSectionVos.addAll(baseMapper.listPeriodSectionExam(classPeriodVo.getId(), bo.getGoodsId(), classPeriodVo.getCourseId(), bo.getUserId()));
|
|
classPeriodSectionVos.addAll(baseMapper.listPeriodSectionExam(classPeriodVo.getId(), bo.getGoodsId(), classPeriodVo.getCourseId(), bo.getUserId()));
|
|
|
|
+
|
|
classPeriodVo.setClassPeriodSectionList(classPeriodSectionVos);
|
|
classPeriodVo.setClassPeriodSectionList(classPeriodSectionVos);
|
|
}
|
|
}
|
|
}
|
|
}
|