|
|
@ -8,10 +8,7 @@ import com.ibeetl.admin.core.entity.CoreUser;
|
|
|
|
import com.ibeetl.admin.core.util.enums.DelFlagEnum;
|
|
|
|
import com.ibeetl.admin.core.util.enums.DelFlagEnum;
|
|
|
|
import com.ibeetl.jlw.dao.*;
|
|
|
|
import com.ibeetl.jlw.dao.*;
|
|
|
|
import com.ibeetl.jlw.entity.*;
|
|
|
|
import com.ibeetl.jlw.entity.*;
|
|
|
|
import com.ibeetl.jlw.enums.ChatLogSendTypeEnum;
|
|
|
|
import com.ibeetl.jlw.enums.*;
|
|
|
|
import com.ibeetl.jlw.enums.GlobalPushStatusEnum;
|
|
|
|
|
|
|
|
import com.ibeetl.jlw.enums.ResourcesQuestionSnapshotFromTypeEnum;
|
|
|
|
|
|
|
|
import com.ibeetl.jlw.enums.SignInTypeEnum;
|
|
|
|
|
|
|
|
import com.ibeetl.jlw.web.query.*;
|
|
|
|
import com.ibeetl.jlw.web.query.*;
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
import org.beetl.sql.core.query.LambdaQuery;
|
|
|
|
import org.beetl.sql.core.query.LambdaQuery;
|
|
|
@ -28,48 +25,79 @@ import static com.ibeetl.jlw.enums.ResourcesQuestionSnapshotFromTypeEnum.HOMEWOR
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* 统计分析service
|
|
|
|
* 统计分析service
|
|
|
|
|
|
|
|
*
|
|
|
|
* @Version 0.0.1
|
|
|
|
* @Version 0.0.1
|
|
|
|
* @Author 许良彤
|
|
|
|
* @Author 许良彤
|
|
|
|
* @Date 2022/10/7 12:25
|
|
|
|
* @Date 2022/10/7 12:25
|
|
|
|
*
|
|
|
|
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
@Service
|
|
|
|
@Service
|
|
|
|
public class StatisticalAnalysisService {
|
|
|
|
public class StatisticalAnalysisService {
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired private StatisticalAnalysisDao statisticalAnalysisDao;
|
|
|
|
|
|
|
|
@Autowired private TeacherOpenCourseMergeSchoolClassService teacherOpenCourseMergeSchoolClassService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseMergeStudentService teacherOpenCourseMergeStudentService;
|
|
|
|
private TeacherOpenCourseMergeSchoolClassService teacherOpenCourseMergeSchoolClassService;
|
|
|
|
@Autowired private TeacherOpenCourseNoticeService teacherOpenCourseNoticeService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private StudentService studentService;
|
|
|
|
private TeacherOpenCourseMergeStudentService teacherOpenCourseMergeStudentService;
|
|
|
|
@Autowired private TeacherService teacherService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private CourseInfoService courseInfoService;
|
|
|
|
private TeacherOpenCourseNoticeService teacherOpenCourseNoticeService;
|
|
|
|
@Autowired private ResourcesApplicationService resourcesApplicationService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private UniversitiesCollegesDao universitiesCollegesDao;
|
|
|
|
private StudentService studentService;
|
|
|
|
@Autowired private SysLogDao sysLogDao;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private UniversitiesCollegesService universitiesCollegesService;
|
|
|
|
private TeacherService teacherService;
|
|
|
|
@Autowired private CoreUserDao coreUserDao;
|
|
|
|
|
|
|
|
@Autowired private ResourcesTrainingDao resourcesTrainingService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private ResourcesInfoService resourcesInfoService;
|
|
|
|
private ResourcesApplicationService resourcesApplicationService;
|
|
|
|
@Autowired private ResourcesQuestionService resourcesQuestionService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseStudentSigninLogService teacherOpenCourseStudentSigninLogService;
|
|
|
|
private UniversitiesCollegesDao universitiesCollegesDao;
|
|
|
|
@Autowired private TeacherOpenCourseQuestionSettingService teacherOpenCourseQuestionSettingService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseMergeCourseInfoService teacherOpenCourseMergeCourseInfoService;
|
|
|
|
private SysLogDao sysLogDao;
|
|
|
|
@Autowired private TeacherOpenCourseQuestionLogService teacherOpenCourseQuestionLogService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseHandsOnService teacherOpenCourseHandsOnService;
|
|
|
|
private UniversitiesCollegesService universitiesCollegesService;
|
|
|
|
@Autowired private TeacherOpenCourseHandsOnSimulationTasksService teacherOpenCourseHandsOnSimulationTasksService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private HandsOnAchievementService handsOnAchievementService;
|
|
|
|
private CoreUserDao coreUserDao;
|
|
|
|
@Autowired private TeacherOpenCourseChatLogService teacherOpenCourseChatLogService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseDao teacherOpenCourseService;
|
|
|
|
private ResourcesTrainingDao resourcesTrainingService;
|
|
|
|
@Autowired private TeacherOpenCourseQuestionSettingDao teacherOpenCourseQuestionSettingDao;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private HandsOnDao handsOnService;
|
|
|
|
private ResourcesInfoService resourcesInfoService;
|
|
|
|
@Autowired private ResourcesCompetitionDao resourcesCompetitionService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseScoreDashboardDao teacherOpenCourseScoreDashboardDao;
|
|
|
|
private ResourcesQuestionService resourcesQuestionService;
|
|
|
|
@Autowired private QuestionLogSummaryDao questionLogSummaryDao;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private TeacherOpenCourseQuestionLogDao teacherOpenCourseQuestionLogDao;
|
|
|
|
private TeacherOpenCourseStudentSigninLogService teacherOpenCourseStudentSigninLogService;
|
|
|
|
@Autowired private ResourcesQuestionSnapshotService resourcesQuestionSnapshotService;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private ResourcesQuestionSnapshotDao resourcesQuestionSnapshotDao;
|
|
|
|
private TeacherOpenCourseQuestionSettingService teacherOpenCourseQuestionSettingService;
|
|
|
|
@Autowired private UniversitiesCollegesJurisdictionExperimentalSystemDao universitiesCollegesJurisdictionExperimentalSystemDao;
|
|
|
|
@Autowired
|
|
|
|
@Autowired private UniversitiesCollegesJurisdictionCurriculumResourcesService universitiesCollegesJurisdictionCurriculumResourcesService;
|
|
|
|
private TeacherOpenCourseMergeCourseInfoService teacherOpenCourseMergeCourseInfoService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseQuestionLogService teacherOpenCourseQuestionLogService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseHandsOnService teacherOpenCourseHandsOnService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseHandsOnSimulationTasksService teacherOpenCourseHandsOnSimulationTasksService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private HandsOnAchievementService handsOnAchievementService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseChatLogService teacherOpenCourseChatLogService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseDao teacherOpenCourseService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseQuestionSettingDao teacherOpenCourseQuestionSettingDao;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private HandsOnDao handsOnService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private ResourcesCompetitionDao resourcesCompetitionService;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseScoreDashboardDao teacherOpenCourseScoreDashboardDao;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private UniversitiesCollegesJurisdictionExperimentalSystemDao universitiesCollegesJurisdictionExperimentalSystemDao;
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private UniversitiesCollegesJurisdictionCurriculumResourcesService universitiesCollegesJurisdictionCurriculumResourcesService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseMergeResourcesInfoService teacherOpenCourseMergeResourcesInfoService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private TeacherOpenCourseMergeResourcesQuestionService teacherOpenCourseMergeResourcesQuestionService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static final String PATTERN = "(?<=\"code\":\\[\").*?(?=\"\\],)";
|
|
|
|
private static final String PATTERN = "(?<=\"code\":\\[\").*?(?=\"\\],)";
|
|
|
@ -77,6 +105,7 @@ public class StatisticalAnalysisService {
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* 统计分析
|
|
|
|
* 统计分析
|
|
|
|
|
|
|
|
*
|
|
|
|
* @param
|
|
|
|
* @param
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public Map<String, Object> detail(Long teacherOpenCourseId, Date stime, Date etime) {
|
|
|
|
public Map<String, Object> detail(Long teacherOpenCourseId, Date stime, Date etime) {
|
|
|
@ -232,6 +261,7 @@ public class StatisticalAnalysisService {
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
|
* 首页
|
|
|
|
* 首页
|
|
|
|
|
|
|
|
*
|
|
|
|
* @param
|
|
|
|
* @param
|
|
|
|
* @return
|
|
|
|
* @return
|
|
|
|
*/
|
|
|
|
*/
|
|
|
@ -261,24 +291,37 @@ public class StatisticalAnalysisService {
|
|
|
|
List<TeacherOpenCourseMergeStudent> studentList = teacherOpenCourseMergeStudentService.getValuesByQueryNotWithPermission(studentQuery);
|
|
|
|
List<TeacherOpenCourseMergeStudent> studentList = teacherOpenCourseMergeStudentService.getValuesByQueryNotWithPermission(studentQuery);
|
|
|
|
data.put("studentNum", studentList.size());
|
|
|
|
data.put("studentNum", studentList.size());
|
|
|
|
//课件
|
|
|
|
//课件
|
|
|
|
|
|
|
|
TeacherOpenCourseMergeResourcesInfoQuery teacherOpenCourseMergeResourcesInfoQuery = new TeacherOpenCourseMergeResourcesInfoQuery();
|
|
|
|
|
|
|
|
teacherOpenCourseMergeResourcesInfoQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
|
|
|
|
teacherOpenCourseMergeResourcesInfoQuery.setResourcesInfoStatus(GlobalUpStatusEnum.UP);
|
|
|
|
|
|
|
|
List<TeacherOpenCourseMergeResourcesInfo> resourcesInfoList = teacherOpenCourseMergeResourcesInfoService.getValuesByQueryNotWithPermission(teacherOpenCourseMergeResourcesInfoQuery);
|
|
|
|
|
|
|
|
data.put("coursewareNum", resourcesInfoList.size());
|
|
|
|
|
|
|
|
|
|
|
|
TeacherOpenCourseMergeCourseInfoQuery courseInfoQuery = new TeacherOpenCourseMergeCourseInfoQuery();
|
|
|
|
TeacherOpenCourseMergeCourseInfoQuery courseInfoQuery = new TeacherOpenCourseMergeCourseInfoQuery();
|
|
|
|
courseInfoQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
courseInfoQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
courseInfoQuery.setCourseInfoStatus(1);
|
|
|
|
courseInfoQuery.setCourseInfoStatus(1);
|
|
|
|
List<TeacherOpenCourseMergeCourseInfo> courseInfos = teacherOpenCourseMergeCourseInfoService.getValuesByQueryNotWithPermission(courseInfoQuery);
|
|
|
|
List<TeacherOpenCourseMergeCourseInfo> courseInfos = teacherOpenCourseMergeCourseInfoService.getValuesByQueryNotWithPermission(courseInfoQuery);
|
|
|
|
data.put("coursewareNum", courseInfos.size());
|
|
|
|
|
|
|
|
//视频
|
|
|
|
//视频
|
|
|
|
List<TeacherOpenCourseMergeCourseInfo> videoCount = courseInfos.stream().filter(v -> v.getCourseVideoId() != null).collect(Collectors.toList());
|
|
|
|
List<TeacherOpenCourseMergeCourseInfo> videoCount = courseInfos.stream().filter(v -> v.getCourseVideoId() != null).collect(Collectors.toList());
|
|
|
|
data.put("videoNum", videoCount.size());
|
|
|
|
data.put("videoNum", videoCount.size());
|
|
|
|
|
|
|
|
|
|
|
|
//题目
|
|
|
|
//题目
|
|
|
|
//习题总数
|
|
|
|
//习题总数
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
TeacherOpenCourseMergeResourcesQuestionQuery teacherOpenCourseMergeResourcesQuestionQuery = new TeacherOpenCourseMergeResourcesQuestionQuery();
|
|
|
|
|
|
|
|
teacherOpenCourseMergeResourcesQuestionQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
|
|
|
|
teacherOpenCourseMergeResourcesQuestionQuery.setQuestionStatus(1);
|
|
|
|
|
|
|
|
List<TeacherOpenCourseMergeResourcesQuestion> questionList = teacherOpenCourseMergeResourcesQuestionService.getValuesByQueryNotWithPermission(teacherOpenCourseMergeResourcesQuestionQuery);
|
|
|
|
|
|
|
|
data.put("subjectNum", questionList.size());
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
TeacherOpenCourseQuestionSettingQuery teacherOpenCourseQuestionSettingQuery = new TeacherOpenCourseQuestionSettingQuery();
|
|
|
|
TeacherOpenCourseQuestionSettingQuery teacherOpenCourseQuestionSettingQuery = new TeacherOpenCourseQuestionSettingQuery();
|
|
|
|
teacherOpenCourseQuestionSettingQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
teacherOpenCourseQuestionSettingQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
teacherOpenCourseQuestionSettingQuery.setTeacherOpenCourseQuestionSettingPushStatus(GlobalPushStatusEnum.PUSH);
|
|
|
|
teacherOpenCourseQuestionSettingQuery.setTeacherOpenCourseQuestionSettingPushStatus(GlobalPushStatusEnum.PUSH);
|
|
|
|
teacherOpenCourseQuestionSettingQuery.setTeacherOpenCourseQuestionSettingStatus(1);
|
|
|
|
teacherOpenCourseQuestionSettingQuery.setTeacherOpenCourseQuestionSettingStatus(1);
|
|
|
|
|
|
|
|
|
|
|
|
List<TeacherOpenCourseQuestionSettingPure> courseQuestionSettings = teacherOpenCourseQuestionSettingDao.getValuesByQueryNotWithPermission2(teacherOpenCourseQuestionSettingQuery);
|
|
|
|
List<TeacherOpenCourseQuestionSettingPure> courseQuestionSettings = teacherOpenCourseQuestionSettingDao.getValuesByQueryNotWithPermission2(teacherOpenCourseQuestionSettingQuery);
|
|
|
|
List<TeacherOpenCourseQuestionSettingPure> collect1 = courseQuestionSettings.stream().filter(v -> v.getTeacherOpenCourseQuestionSettingType().equals(ResourcesQuestionSnapshotFromTypeEnum.CHAPTER_EXERCISE)).collect(Collectors.toList());
|
|
|
|
//List<TeacherOpenCourseQuestionSettingPure> collect1 = courseQuestionSettings.stream().filter(v -> v.getTeacherOpenCourseQuestionSettingType().equals(ResourcesQuestionSnapshotFromTypeEnum.CHAPTER_EXERCISE)).collect(Collectors.toList());
|
|
|
|
data.put("subjectNum", collect1.size());
|
|
|
|
|
|
|
|
//案例
|
|
|
|
//案例
|
|
|
|
TeacherOpenCourseHandsOnQuery teacherOpenCourseHandsOnQuery = new TeacherOpenCourseHandsOnQuery();
|
|
|
|
TeacherOpenCourseHandsOnQuery teacherOpenCourseHandsOnQuery = new TeacherOpenCourseHandsOnQuery();
|
|
|
|
teacherOpenCourseHandsOnQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|
teacherOpenCourseHandsOnQuery.setTeacherOpenCourseId(teacherOpenCourseId);
|
|
|
|