From 9f513ae23240cf815e384b245746467a0e23aeb9 Mon Sep 17 00:00:00 2001 From: typ Date: Sun, 5 Mar 2023 21:03:43 +0800 Subject: [PATCH] 人社局头像上传post-6bug调试 --- src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java | 48 ++++++++++++++++++------------------------------ src/main/java/com/subsidy/vo/live/ExportPlaybacksVO.java | 14 ++++++++------ src/main/resources/mapper/RenSheJuMapper.xml | 35 ++++++++++++++++++----------------- 3 files changed, 44 insertions(+), 53 deletions(-) diff --git a/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java b/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java index a4cf9b9..d70f2e0 100644 --- a/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java +++ b/src/main/java/com/subsidy/service/impl/RenSheJuServiceImpl.java @@ -18,6 +18,7 @@ import okhttp3.*; import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Transactional; import java.io.IOException; import java.sql.Timestamp; @@ -178,23 +179,10 @@ public class RenSheJuServiceImpl implements RenSheJuService { activityList.setErrorInfo(2); } - int count = imageCheckRecordMapper.selectCount(new QueryWrapper() - .lambda() - .eq(ImageCheckRecordDO::getResult, 1) - .isNull(ImageCheckRecordDO::getPaperId) - .eq(ImageCheckRecordDO::getMemberId, dailyStudyInfoVO.getMemberId()) - .eq(ImageCheckRecordDO::getClassId, dailyStudyInfoVO.getDownCode())); - if (0 == dailyActivitiesVO.getCheckType()) { activityList.setActivityDetection(2); } else if (1 == dailyActivitiesVO.getCheckType()) { activityList.setActivityDetection(1); - } else { - activityList.setActivityDetection(3); - } - - if (count >= 2 && dailyActivitiesVO.getCheckType() == 1) { - activityList.setActivityDetection(4); } activityList.setActivityTime(dailyActivitiesVO.getActivityTime()); @@ -295,7 +283,7 @@ public class RenSheJuServiceImpl implements RenSheJuService { } else { activityList.setAccess(0); } - activityList.setActivityDetection(3); + activityList.setActivityDetection(1); activityList.setActivityTime(dailyActivitiesVO.getActivityTime()); activityLists.add(activityList); } @@ -518,22 +506,22 @@ public class RenSheJuServiceImpl implements RenSheJuService { } - /** - * 考试检测数据 - */ - List examChecks = renSheJuMapper.examCheck(classId); - - if (examChecks.size() > 0) { - for (ClassImageChecksVO cicon : examChecks) { - - ImageDetailList imageDetailList = new ImageDetailList(); - BeanUtils.copyProperties(cicon, imageDetailList); - imageDetailList.setImageBase64("data:image/jpeg;base64," + OSSUtils.image2Base64(cicon.getImage())); - imageDetailList.setProcessType(2L); - imageDetailList.setDetectionType(1L); - imageDetailLists.add(imageDetailList); - } - } +// /** +// * 考试检测数据 +// */ +// List examChecks = renSheJuMapper.examCheck(classId); +// +// if (examChecks.size() > 0) { +// for (ClassImageChecksVO cicon : examChecks) { +// +// ImageDetailList imageDetailList = new ImageDetailList(); +// BeanUtils.copyProperties(cicon, imageDetailList); +// imageDetailList.setImageBase64("data:image/jpeg;base64," + OSSUtils.image2Base64(cicon.getImage())); +// imageDetailList.setProcessType(2L); +// imageDetailList.setDetectionType(1L); +// imageDetailLists.add(imageDetailList); +// } +// } uploadImage.setImageDetailList(imageDetailLists); diff --git a/src/main/java/com/subsidy/vo/live/ExportPlaybacksVO.java b/src/main/java/com/subsidy/vo/live/ExportPlaybacksVO.java index 0c53b9b..4cceeb1 100644 --- a/src/main/java/com/subsidy/vo/live/ExportPlaybacksVO.java +++ b/src/main/java/com/subsidy/vo/live/ExportPlaybacksVO.java @@ -5,23 +5,25 @@ import lombok.Data; @Data public class ExportPlaybacksVO { + +// @ExcelColumn(col = 0,value = "序号") private Long id; - @ExcelColumn(value = "成员名称", col = 1) + @ExcelColumn( col = 1,value = "成员名称") private String userName; - @ExcelColumn(value = "联系方式", col = 2) + @ExcelColumn(col = 2,value = "联系方式") private String telephone; - @ExcelColumn(value = "直播签到", col = 3) + @ExcelColumn(col = 3,value = "直播签到") private Integer signInCounts; - @ExcelColumn(value = "回放签到", col = 4) + @ExcelColumn(col = 4,value = "回放签到") private Integer playbackCounts; - @ExcelColumn(value = "观看时长", col = 5) + @ExcelColumn(col = 5,value = "观看时长") private Integer playLength; - @ExcelColumn(value = "进入时间", col = 6) + @ExcelColumn(col = 6,value = "进入时间") private String startTimes; } diff --git a/src/main/resources/mapper/RenSheJuMapper.xml b/src/main/resources/mapper/RenSheJuMapper.xml index 5711de7..719929c 100644 --- a/src/main/resources/mapper/RenSheJuMapper.xml +++ b/src/main/resources/mapper/RenSheJuMapper.xml @@ -90,14 +90,14 @@ @@ -335,7 +335,7 @@ exercise_done_result t1 WHERE t1.delete_date IS NULL - AND DATE_FORMAT( DATE_ADD( t1.create_date, INTERVAL 1 DAY ), '%Y-%m-%d' ) = DATE_FORMAT( NOW(), '%Y-%m-%d' ) + AND DATE_FORMAT( DATE_ADD( t1.create_date, INTERVAL 7 DAY ), '%Y-%m-%d' ) = DATE_FORMAT( NOW(), '%Y-%m-%d' ) AND class_id = #{classId} AND member_id = #{memberId} @@ -440,7 +440,8 @@ WHERE t1.delete_date is null and class_id = #{classId} - AND DATE_FORMAT( DATE_ADD( t1.create_date, INTERVAL 1 DAY ), '%Y-%m-%d' ) = DATE_FORMAT( NOW(), '%Y-%m-%d' ) + and t1.id in (568,569,571,572,576,577) + AND DATE_FORMAT( DATE_ADD( t1.create_date, INTERVAL 13 DAY ), '%Y-%m-%d' ) = DATE_FORMAT( NOW(), '%Y-%m-%d' ) AND t1.paper_id IS NULL AND t1.result = 1 and t1.member_id @@ -463,7 +464,7 @@ LEFT JOIN member t2 ON t1.member_id = t2.id WHERE t1.delete_date is null - AND DATE_FORMAT( DATE_ADD( t1.create_date, INTERVAL 1 DAY ), '%Y-%m-%d' ) = DATE_FORMAT( NOW(), '%Y-%m-%d' ) + AND DATE_FORMAT( DATE_ADD( t1.create_date, INTERVAL 7 DAY ), '%Y-%m-%d' ) = DATE_FORMAT( NOW(), '%Y-%m-%d' ) and class_id = #{classId} AND t1.paper_id IS not NULL AND t1.result = 1 -- libgit2 0.25.0