From 2ada40a20dac58616ffb808603627a11a8197cf4 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期三, 10 七月 2024 11:25:09 +0800
Subject: [PATCH] 密码过期处理定时任务完善

---
 src/main/java/com/ycl/jxkg/service/impl/HomeServiceImpl.java |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/main/java/com/ycl/jxkg/service/impl/HomeServiceImpl.java b/src/main/java/com/ycl/jxkg/service/impl/HomeServiceImpl.java
index b61702f..ffa07ac 100644
--- a/src/main/java/com/ycl/jxkg/service/impl/HomeServiceImpl.java
+++ b/src/main/java/com/ycl/jxkg/service/impl/HomeServiceImpl.java
@@ -61,11 +61,13 @@
         //瀛︿範璁板綍
         StudyRecord studyRecord = studyRecordMapper.getByStudentId(userId);
         if (studyRecord != null) {
+            Long studyTime = studyRecord.getStudyTime();
+            BigDecimal studyTimeVo = new BigDecimal(studyTime).divide(new BigDecimal(3600), 1, RoundingMode.HALF_UP);
             vo.setLastTime(studyRecord.getLastTime());
-            vo.setStudyTime(studyRecord.getStudyTime());
+            vo.setStudyTime(studyTimeVo);
             vo.setMeetCount(studyRecord.getMeetCount());
         }else {
-            vo.setStudyTime(0L);
+            vo.setStudyTime(BigDecimal.ZERO);
             vo.setMeetCount(0);
         }
         //骞冲潎鍒�

--
Gitblit v1.8.0