|
@@ -249,7 +249,8 @@ public class TempLittleArtistTrainingCampServiceImpl extends ServiceImpl<TempLit
|
|
|
//查询每日训练时长
|
|
|
param.put("startTime", startDateStr + " 00:00:00");
|
|
|
param.put("endTime", endDateStr + " 23:59:59");
|
|
|
- List<TempUserTrainingTimeDetailVo> userTrainingTimeList = baseMapper.queryUserTrainingTime(param);
|
|
|
+ param.put("campId", camp.getId());
|
|
|
+ List<TempUserTrainingTimeDetailVo> userTrainingTimeList = baseMapper.queryUserTrainingTimeV2(param);
|
|
|
//拼接数据
|
|
|
if (CollectionUtils.isNotEmpty(userTrainingTimeList)) {
|
|
|
Map<String, BigDecimal> nowTrainingTime = userTrainingTimeList.stream()
|
|
@@ -283,15 +284,14 @@ public class TempLittleArtistTrainingCampServiceImpl extends ServiceImpl<TempLit
|
|
|
//训练营详情-查询条件时间设置
|
|
|
queryUserTrainingDetailOpsParam(param);
|
|
|
Page<TempCampUserTrainingDetailVo> page = PageUtil.getPageInfo(param);
|
|
|
- page.setDesc("b.playDay");
|
|
|
- IPage<TempCampUserTrainingDetailVo> vos = baseMapper.queryUserTrainingDetail(page, param);
|
|
|
+ page.setDesc("t.playDay");
|
|
|
+ IPage<TempCampUserTrainingDetailVo> vos = baseMapper.queryUserTrainingDetailV2(page, param);
|
|
|
List<TempCampUserTrainingDetailVo> records = vos.getRecords();
|
|
|
if(CollectionUtils.isNotEmpty(records)){
|
|
|
List<Integer> studentIds = records.stream().map(e -> e.getId()).collect(Collectors.toList());
|
|
|
Map<Integer,String> subjectMap = MapUtil.convertIntegerMap(studentDao.getStudentSubjectMapList(studentIds));
|
|
|
Map<Integer,String> groupNameMap = MapUtil.convertMybatisMap(musicGroupDao.queryNormalGroupName(studentIds));
|
|
|
- List<TempCampUserTrainingSequenceVo> sequenceDays = studentDao.getStudentCloudStudySequenceDays(studentIds,
|
|
|
- param.get("startTime").toString(),param.get("endTime").toString());
|
|
|
+ List<TempCampUserTrainingSequenceVo> sequenceDays = studentDao.getStudentCloudStudySequenceDaysV2(studentIds, param.get("campId").toString());
|
|
|
Map<Integer, List<Long>> listMap = sequenceDays.stream().collect(Collectors.groupingBy(e -> e.getUserId(),
|
|
|
Collectors.collectingAndThen(Collectors.toList(),v->v.stream().map(e->e.getDayNum()).collect(Collectors.toList()))));
|
|
|
Integer standardDays = Integer.parseInt(param.get("standardDays").toString());
|
|
@@ -630,8 +630,8 @@ public class TempLittleArtistTrainingCampServiceImpl extends ServiceImpl<TempLit
|
|
|
OutputStream outputStream = response.getOutputStream();
|
|
|
HSSFWorkbook workbook = null;
|
|
|
try {
|
|
|
- String[] header = {"学员编号", "学员姓名", "学员声部", "乐团", "手机号", "群组", "打卡天数", "训练时长(分钟)", "打卡状态"};
|
|
|
- String[] body = {"id", "username", "subjectName", "musicGroupName", "phone", "imGroupName", "playDay", "playTime", "standardFlag?'达标':'未达标'"};
|
|
|
+ String[] header = {"学员编号", "学员姓名", "学员声部", "乐团", "手机号", "群组", "打卡天数","最高连续打卡", "训练时长(分钟)", "打卡状态"};
|
|
|
+ String[] body = {"id", "username", "subjectName", "musicGroupName", "phone", "imGroupName", "playDay","cloudStudySequenceDays", "playTime", "standardFlag?'达标':'未达标'"};
|
|
|
workbook = POIUtil.exportExcel(header, body, list);
|
|
|
response.setContentType("application/octet-stream");
|
|
|
response.setHeader("Content-Disposition", "attachment;filename=replacement-" + DateUtil.getDate(new Date()) + ".xls");
|