|
|
@@ -2,7 +2,7 @@ package com.seecoder.dataanalysis.analysis.impl;
|
|
|
|
|
|
import cn.seecoder.bok.common.vo.QuestionVO;
|
|
|
import com.seecoder.dataanalysis.analysis.EvalDataAnalysisService;
|
|
|
-import com.seecoder.dataanalysis.analysis.RecommandService;
|
|
|
+import com.seecoder.dataanalysis.analysis.RecommendService;
|
|
|
import com.seecoder.dataanalysis.data.dao.competency.CompetencyTreeDao;
|
|
|
import com.seecoder.dataanalysis.data.entity.competency.CompetencyTree;
|
|
|
import com.seecoder.dataanalysis.data.entity.competency.KSDScore;
|
|
|
@@ -13,7 +13,7 @@ import org.springframework.stereotype.Service;
|
|
|
import java.util.*;
|
|
|
|
|
|
@Service
|
|
|
-public class RecommandServiceImpl implements RecommandService {
|
|
|
+public class RecommendServiceImpl implements RecommendService {
|
|
|
//默认推荐的题目数量
|
|
|
public static final int QUESTION_NUM = 30;
|
|
|
|
|
|
@@ -25,7 +25,7 @@ public class RecommandServiceImpl implements RecommandService {
|
|
|
private CompetencyTreeDao competencyTreeDao;
|
|
|
|
|
|
@Override
|
|
|
- public List<QuestionVO> getRecommandById(int userId){
|
|
|
+ public List<String> getRecommendById(int userId){
|
|
|
Random random = new Random();
|
|
|
//获取学生的做题情况
|
|
|
Map<String,Double> errorQuestions = evalDataAnalysisService.getStudentErrorQuestions(userId);
|
|
|
@@ -167,13 +167,11 @@ public class RecommandServiceImpl implements RecommandService {
|
|
|
undos.remove(undos.get(r));
|
|
|
}
|
|
|
|
|
|
- for(String s : total){
|
|
|
- System.out.println(s);
|
|
|
- }
|
|
|
- System.out.println(total.size());
|
|
|
-
|
|
|
- List<QuestionVO> res = new ArrayList<>();
|
|
|
+// for(String s : total){
|
|
|
+// System.out.println(s);
|
|
|
+// }
|
|
|
+// System.out.println(total.size());
|
|
|
|
|
|
- return res;
|
|
|
+ return total;
|
|
|
}
|
|
|
}
|