|
@@ -9,10 +9,7 @@ import com.ym.mec.biz.dal.enums.YesOrNoEnum;
|
|
|
import com.ym.mec.biz.dal.page.ExtraExercilseQueryInfo;
|
|
|
import com.ym.mec.biz.dal.page.ExtraExercilseReplyQueryInfo;
|
|
|
import com.ym.mec.biz.dal.page.StudentCourseHomeWorkQueryInfo;
|
|
|
-import com.ym.mec.biz.service.ExtracurricularExercisesReplyService;
|
|
|
-import com.ym.mec.biz.service.StudentServeService;
|
|
|
-import com.ym.mec.biz.service.SysConfigService;
|
|
|
-import com.ym.mec.biz.service.SysMessageService;
|
|
|
+import com.ym.mec.biz.service.*;
|
|
|
import com.ym.mec.common.dal.BaseDAO;
|
|
|
import com.ym.mec.common.exception.BizException;
|
|
|
import com.ym.mec.common.page.PageInfo;
|
|
@@ -21,7 +18,6 @@ import com.ym.mec.common.tenant.TenantContextHolder;
|
|
|
import com.ym.mec.thirdparty.message.MessageSenderPluginContext;
|
|
|
import com.ym.mec.util.collection.MapUtil;
|
|
|
import com.ym.mec.util.date.DateUtil;
|
|
|
-
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
@@ -43,10 +39,10 @@ public class ExtracurricularExercisesReplyServiceImpl extends BaseServiceImpl<Lo
|
|
|
@Autowired
|
|
|
private ExtracurricularExercisesDao extracurricularExercisesDao;
|
|
|
@Autowired
|
|
|
- private CourseScheduleStatisticsDao courseScheduleStatisticsDao;
|
|
|
- @Autowired
|
|
|
private StudentExtracurricularExercisesSituationDao studentExtracurricularExercisesSituationDao;
|
|
|
@Autowired
|
|
|
+ private StudentExtracurricularExercisesSituationService studentExtracurricularExercisesSituationService;
|
|
|
+ @Autowired
|
|
|
private SysMessageService sysMessageService;
|
|
|
@Autowired
|
|
|
private TeacherDao teacherDao;
|
|
@@ -314,7 +310,7 @@ public class ExtracurricularExercisesReplyServiceImpl extends BaseServiceImpl<Lo
|
|
|
results.add(studentExtracurricularExercisesSituation);
|
|
|
}
|
|
|
|
|
|
- studentExtracurricularExercisesSituationDao.deleteByMonday(monDayDate.toString(),null);
|
|
|
+ studentExtracurricularExercisesSituationService.deleteByMonday(monDayDate.toString(),null);
|
|
|
|
|
|
BigDecimal currentPage=BigDecimal.ONE,
|
|
|
pageSize=new BigDecimal(10000),
|
|
@@ -322,7 +318,7 @@ public class ExtracurricularExercisesReplyServiceImpl extends BaseServiceImpl<Lo
|
|
|
totalPage=total.divide(pageSize, BigDecimal.ROUND_UP);
|
|
|
while (currentPage.compareTo(totalPage)<=0){
|
|
|
List<StudentExtracurricularExercisesSituation> rows=results.stream().skip(pageSize.multiply(currentPage.subtract(BigDecimal.ONE)).longValue()).limit(pageSize.longValue()).collect(Collectors.toList());
|
|
|
- studentExtracurricularExercisesSituationDao.batchInsert(rows);
|
|
|
+ studentExtracurricularExercisesSituationService.batchInsert(rows);
|
|
|
currentPage=currentPage.add(BigDecimal.ONE);
|
|
|
}
|
|
|
}
|
|
@@ -341,24 +337,4 @@ public class ExtracurricularExercisesReplyServiceImpl extends BaseServiceImpl<Lo
|
|
|
pageInfo.setRows(dataList);
|
|
|
return pageInfo;
|
|
|
}
|
|
|
-
|
|
|
- @Override
|
|
|
- @Transactional(rollbackFor = Exception.class)
|
|
|
- public void batchInsert(List<StudentExtracurricularExercisesSituation> situations) {
|
|
|
- if (CollectionUtils.isEmpty(situations)){
|
|
|
- return;
|
|
|
- }
|
|
|
- studentExtracurricularExercisesSituationDao.batchInsert(situations);
|
|
|
- List<String> collect = situations.stream().map(e -> e.getCourseIds()).filter(e -> StringUtils.isNotEmpty(e)).collect(Collectors.toList());
|
|
|
- if(!CollectionUtils.isEmpty(collect)){
|
|
|
- //更新课程服务指标
|
|
|
- courseScheduleStatisticsDao.updateCourseService(collect,1);
|
|
|
- }
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- @Transactional(rollbackFor = Exception.class)
|
|
|
- public void delWaitByCourseId(List<Long> courseIdList) {
|
|
|
- courseScheduleStatisticsDao.delWaitByCourseId();
|
|
|
- }
|
|
|
}
|