From 25743ef4cfb9da0be8d3e488c93f5429ffd02f8a Mon Sep 17 00:00:00 2001
From: 44323 <443237572@qq.com>
Date: 星期二, 21 五月 2024 14:21:25 +0800
Subject: [PATCH] Merge branch 'master' of http://120.76.84.145:10101/gitblit/r/java/DolphinEnglish

---
 ruoyi-service/ruoyi-study/src/main/java/com/ruoyi/study/controller/TStudyController.java |   40 ++++++++++++++++++++++++++++++++++------
 1 files changed, 34 insertions(+), 6 deletions(-)

diff --git a/ruoyi-service/ruoyi-study/src/main/java/com/ruoyi/study/controller/TStudyController.java b/ruoyi-service/ruoyi-study/src/main/java/com/ruoyi/study/controller/TStudyController.java
index c5b45a1..3a3babb 100644
--- a/ruoyi-service/ruoyi-study/src/main/java/com/ruoyi/study/controller/TStudyController.java
+++ b/ruoyi-service/ruoyi-study/src/main/java/com/ruoyi/study/controller/TStudyController.java
@@ -116,9 +116,8 @@
     public R<PageInfo<TSubject>> subjectList(@RequestBody ChoiceSubject query) {
         PageInfo<TSubject> res = new PageInfo<>(query.getPageNumber(), query.getPageSize());
         QueryWrapper<TSubject> wrapper = new QueryWrapper<>();
-
-        if (StringUtils.hasLength(query.getName())) {
-            wrapper.like("name", query.getName());
+        if (StringUtils.hasLength(query.getName())){
+            wrapper.like("name",query.getName());
         }
         if (StringUtils.hasLength(query.getEnglish())) {
             wrapper.like("english", query.getEnglish());
@@ -354,14 +353,43 @@
         List<TStudy> count = studyService.list(new QueryWrapper<TStudy>()
                 .eq("type", 1));
         studyListVO.setWeeks(count.size());
+
         // todo 补充开始学习人数
         studyListVO.setCount(0);
+        studyListVO.setName("听");
         // 查询听类型有多少周目
         res.add(studyListVO);
         // 后续类型 不在1.0功能中
-        for (int i = 1; i <= 6; i++) {
-            res.add(new StudyListVO(0, 0));
-        }
+        StudyListVO studyListVO1 = new StudyListVO();
+        studyListVO1.setWeeks(0);
+        studyListVO1.setCount(0);
+        studyListVO1.setName("说");
+        res.add(studyListVO1);
+        StudyListVO studyListVO2 = new StudyListVO();
+        studyListVO2.setWeeks(0);
+        studyListVO2.setCount(0);
+        studyListVO2.setName("认读");
+        res.add(studyListVO2);
+        StudyListVO studyListVO3 = new StudyListVO();
+        studyListVO3.setWeeks(0);
+        studyListVO3.setCount(0);
+        studyListVO3.setName("阅读");
+        res.add(studyListVO3);
+        StudyListVO studyListVO4 = new StudyListVO();
+        studyListVO4.setWeeks(0);
+        studyListVO4.setCount(0);
+        studyListVO4.setName("练习");
+        res.add(studyListVO4);
+        StudyListVO studyListVO5 = new StudyListVO();
+        studyListVO5.setWeeks(0);
+        studyListVO5.setCount(0);
+        studyListVO5.setName("智能互动问答");
+        res.add(studyListVO5);
+        StudyListVO studyListVO6 = new StudyListVO();
+        studyListVO6.setWeeks(0);
+        studyListVO6.setCount(0);
+        studyListVO6.setName("智能识别");
+        res.add(studyListVO6);
         return R.ok(res);
     }
 

--
Gitblit v1.7.1