|
@@ -957,6 +957,7 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
for (ClassGrade classGrade : classGradeList) {
|
|
|
classGradeUser = iClassGradeUserService.getOne(new LambdaQueryWrapper<ClassGradeUser>()
|
|
|
.eq(ClassGradeUser::getGradeId, classGrade.getGradeId())
|
|
|
+ .eq(ClassGradeUser::getChangeGrade, 0)
|
|
|
.eq(ClassGradeUser::getStatus, 1)
|
|
|
.eq(ClassGradeUser::getUserId, user.getUserId()).last("limit 1"));
|
|
|
if (Validator.isNotEmpty(classGradeUser)) {
|
|
@@ -1063,6 +1064,7 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
LambdaQueryWrapper<ClassGradeUser> lqw = Wrappers.lambdaQuery();
|
|
|
lqw.eq(ClassGradeUser::getGradeId, classGrade.getGradeId());
|
|
|
lqw.eq(ClassGradeUser::getUserId, user.getUserId());
|
|
|
+ lqw.eq(ClassGradeUser::getChangeGrade, 0);
|
|
|
lqw.eq(ClassGradeUser::getStatus, 1);
|
|
|
List<ClassGradeUser> gradeUserList = iClassGradeUserService.list(lqw);
|
|
|
for (ClassGradeUser gu : gradeUserList) {
|
|
@@ -1990,9 +1992,10 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
classPeriodStudentVo.setAllStatus(changePeriodStatus(classPeriodStudentVo.getPeriodStatus()));
|
|
|
|
|
|
// classPeriodStudentVo.setWaitRebuildNum(classPeriodUserVos.getCheat()+classPeriodUserVos.getExamCheat());
|
|
|
- if (!CollectionUtils.isEmpty(baseMapper.selectStart(classPeriodStudentVo.getUserId(), classPeriodStudentVo.getGoodsId(), classPeriodStudentVo.getGradeId(),classPeriodStudentVo.getOrderGoodsId()))) {
|
|
|
+ List<Long> timeList = baseMapper.selectStart(classPeriodStudentVo.getUserId(), classPeriodStudentVo.getGoodsId(), classPeriodStudentVo.getGradeId(),classPeriodStudentVo.getOrderGoodsId());
|
|
|
+ if (!CollectionUtils.isEmpty(timeList)) {
|
|
|
//查找开始学习时间
|
|
|
- classPeriodStudentVo.setStartTime(baseMapper.selectStart(classPeriodStudentVo.getUserId(), classPeriodStudentVo.getGoodsId(), classPeriodStudentVo.getGradeId(),classPeriodStudentVo.getOrderGoodsId()).get(0));
|
|
|
+ classPeriodStudentVo.setStartTime(timeList.get(0));
|
|
|
}
|
|
|
//取学时所有拍照最新的一张
|
|
|
String recentPhoto = userStudyRecordPhotoMapper.selectGradeRecentOnePhoto(classPeriodStudentVo.getUserId(), classPeriodStudentVo.getGradeId(),classPeriodStudentVo.getOrderGoodsId());
|
|
@@ -2898,6 +2901,11 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
ClassGrade classGrade = iClassGradeService.getOne(new LambdaQueryWrapper<ClassGrade>().eq(ClassGrade::getGradeId, copyOg.getGradeId()));
|
|
|
commonGradeName = classGrade.getClassName();
|
|
|
}
|
|
|
+ GoodsVo goodsVo = iGoodsService.queryById(bo.getGoodsId());
|
|
|
+ CourseBusinessQueryBo businessQueryBo = new CourseBusinessQueryBo();
|
|
|
+ businessQueryBo.setId(goodsVo.getBusinessId());
|
|
|
+ String fullName = iCourseBusinessService.queryFullName(businessQueryBo);
|
|
|
+
|
|
|
//查找最外层课程目录 模块 章 节
|
|
|
List<ClassPeriodVo> classPeriodVos = baseMapper.listPeriodAudit(bo);
|
|
|
classPeriodVos.addAll(baseMapper.listPeriodAuditSection(bo));
|
|
@@ -2953,7 +2961,11 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
classPeriodSectionVo.setStudyEndTime(userPeriodStatusVo.getRecordEndTime());
|
|
|
classPeriodSectionVo.setStudyStartTime(userPeriodStatusVo.getRecordStartTime());
|
|
|
if (Validator.isNotEmpty(photoList) && photoList.size() > 0) {
|
|
|
- classPeriodSectionVo.setStudyStartTime(photoList.get(0).getCreateTime());
|
|
|
+ if(fullName.contains("继续教育")&&fullName.contains("施工现场专业人员")){
|
|
|
+ classPeriodSectionVo.setStudyStartTime(userPeriodStatusVo.getRecordStartTime());
|
|
|
+ }else{
|
|
|
+ classPeriodSectionVo.setStudyStartTime(photoList.get(0).getCreateTime());
|
|
|
+ }
|
|
|
}
|
|
|
if ((startTotalTime == 0L && Validator.isNotEmpty(classPeriodSectionVo.getStudyStartTime())) || (Validator.isNotEmpty(classPeriodSectionVo.getStudyStartTime()) && (startTotalTime.longValue() > classPeriodSectionVo.getStudyStartTime().longValue()))) {
|
|
|
if(og.getSevenClassCopy()==1||moduleVo.getCommonSign()==0){
|
|
@@ -3067,10 +3079,10 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
classPeriodChapterVo.setAuditUserName(userPeriodStatusVo.getAuditUserName());
|
|
|
classPeriodChapterVo.setPeriodStatusId(userPeriodStatusVo.getId());
|
|
|
classPeriodChapterVo.setPerformance(Convert.toBigDecimal(userPeriodStatusVo.getPerformance()));
|
|
|
- if (startTotalTime == 0L || startTotalTime.longValue() > classPeriodChapterVo.getStudyStartTime().longValue()) {
|
|
|
+ if ((startTotalTime == 0L&&Validator.isNotEmpty(classPeriodChapterVo.getStudyStartTime())) || (Validator.isNotEmpty(classPeriodChapterVo.getStudyStartTime())&&startTotalTime.longValue() > classPeriodChapterVo.getStudyStartTime().longValue())) {
|
|
|
startTotalTime = classPeriodChapterVo.getStudyStartTime();
|
|
|
}
|
|
|
- if (endTotalTime == 0L || (Validator.isNotEmpty(classPeriodChapterVo.getStudyEndTime()) && endTotalTime.longValue() < classPeriodChapterVo.getStudyEndTime().longValue())) {
|
|
|
+ if ((endTotalTime == 0L&&Validator.isNotEmpty(classPeriodChapterVo.getStudyEndTime())) || (Validator.isNotEmpty(classPeriodChapterVo.getStudyEndTime()) && endTotalTime.longValue() < classPeriodChapterVo.getStudyEndTime().longValue())) {
|
|
|
endTotalTime = classPeriodChapterVo.getStudyEndTime();
|
|
|
}
|
|
|
}
|
|
@@ -3112,7 +3124,11 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
classPeriodSectionVo.setStudyEndTime(userPeriodStatusVo.getRecordEndTime());
|
|
|
classPeriodSectionVo.setStudyStartTime(userPeriodStatusVo.getRecordStartTime());
|
|
|
if (Validator.isNotEmpty(photoList) && photoList.size() > 0) {
|
|
|
- classPeriodSectionVo.setStudyStartTime(photoList.get(0).getCreateTime());
|
|
|
+ if(fullName.contains("继续教育")&&fullName.contains("施工现场专业人员")){
|
|
|
+ classPeriodSectionVo.setStudyStartTime(userPeriodStatusVo.getRecordStartTime());
|
|
|
+ }else{
|
|
|
+ classPeriodSectionVo.setStudyStartTime(photoList.get(0).getCreateTime());
|
|
|
+ }
|
|
|
}
|
|
|
if ((startTotalTime == 0L && Validator.isNotEmpty(classPeriodSectionVo.getStudyStartTime())) || (Validator.isNotEmpty(classPeriodSectionVo.getStudyStartTime()) && startTotalTime.longValue() > classPeriodSectionVo.getStudyStartTime().longValue())) {
|
|
|
if(og.getSevenClassCopy()==1||classPeriodVo.getCommonSign()==0){
|
|
@@ -3229,7 +3245,12 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
classPeriodVo.setNumList(Convert.toLong(userPeriodStatusVos.size()));
|
|
|
classPeriodVo.setStudyEndTime(userPeriodStatusVo.getRecordEndTime());
|
|
|
if (photoList.size() > 0) {
|
|
|
- classPeriodVo.setStudyStartTime(photoList.get(0).getCreateTime());
|
|
|
+ if(fullName.contains("继续教育")&&fullName.contains("施工现场专业人员")){
|
|
|
+ classPeriodVo.setStudyStartTime(userPeriodStatusVo.getRecordStartTime());
|
|
|
+ }else{
|
|
|
+ classPeriodVo.setStudyStartTime(photoList.get(0).getCreateTime());
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
if ((Validator.isNotEmpty(classPeriodVo.getStudyStartTime()) && startTotalTime == 0L) || (Validator.isNotEmpty(classPeriodVo.getStudyStartTime()) && startTotalTime.longValue() > classPeriodVo.getStudyStartTime().longValue())) {
|
|
|
startTotalTime = classPeriodVo.getStudyStartTime();
|
|
@@ -3604,6 +3625,8 @@ public class ClassGradeUserServiceImpl extends ServiceImpl<ClassGradeUserMapper,
|
|
|
}
|
|
|
|
|
|
|
|
|
+
|
|
|
+
|
|
|
/**
|
|
|
* 实体类转化成视图对象
|
|
|
*
|