You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

110 lines
3.7 KiB
Java

3 years ago
package com.ibeetl.jlw.dao;
import cn.hutool.core.util.ObjectUtil;
3 years ago
import com.ibeetl.jlw.entity.CourseInfo;
import com.ibeetl.jlw.entity.Student;
import com.ibeetl.jlw.entity.StudentExtendSchoolInfo;
2 years ago
import com.ibeetl.jlw.entity.api.student.StudentActiveInfo;
import com.ibeetl.jlw.entity.dto.StudentEditPasswordDTO;
2 years ago
import com.ibeetl.jlw.entity.vo.StudentLogAnalysisVO;
import com.ibeetl.jlw.entity.vo.StudentLoginLogVO;
import com.ibeetl.jlw.entity.vo.StudentUseLogVO;
3 years ago
import com.ibeetl.jlw.web.query.StudentQuery;
import org.beetl.sql.core.engine.PageQuery;
3 years ago
import org.beetl.sql.mapper.BaseMapper;
import org.beetl.sql.mapper.annotation.SqlResource;
import org.beetl.sql.mapper.annotation.Update;
2 years ago
import org.springframework.cache.annotation.Cacheable;
2 years ago
import org.springframework.stereotype.Repository;
3 years ago
import java.util.List;
import java.util.Map;
/**
* Student Dao
*/
2 years ago
// 实际可以不用加Repository注解调用的地方注入时候Idea会报红看着难受
@Repository
3 years ago
@SqlResource("jlw.student")
public interface StudentDao extends BaseMapper<Student>{
2 years ago
PageQuery queryByConditionQuery(PageQuery query);
2 years ago
PageQuery<Student> queryByCondition(PageQuery query);
PageQuery<Student> queryByCondition2Student(PageQuery query);
@Update
2 years ago
void deleteStudentByIds(String ids);
@Update
void batchAppendCodeDelByIds(String ids);
@Update
2 years ago
void deleteByIds(String ids);
List<Map<String,Object>> getExcelValues (StudentQuery studentQuery);
List<Map<String,Object>> getExcelValues2Competition (StudentQuery studentQuery);
Student getByUserId(Long userId);
Student getByAccount(String account);
List<Student> getByIds (String studentIds);
default Student getById (Long studentId) {
List<Student> byIds = getByIds(studentId.toString());
return ObjectUtil.isNotEmpty(byIds)? byIds.get(0): null;
}
2 years ago
List<Student> getStudentLog (StudentQuery studentQuery);
2 years ago
PageQuery<StudentUseLogVO> queryStudentUseLogByCondition(PageQuery query);
2 years ago
/**
* -使
* @param query
* @return
*/
PageQuery<StudentUseLogVO> queryStudentTeacherOrUseLogBy(PageQuery query);
2 years ago
PageQuery<StudentLoginLogVO> queryStudentLoginLogByCondition(PageQuery query);
/**
*
* @param query
* @return
*/
PageQuery<StudentLoginLogVO> queryUserLoginLogByCondition(PageQuery query);
2 years ago
PageQuery<StudentLogAnalysisVO> queryStudentLogAnalysisByCondition(PageQuery query);
/**
* -
* @param query
* @return
*/
PageQuery<StudentLogAnalysisVO> queryStatisticalStatementNumberPeopleByCondition(PageQuery query);
2 years ago
List<Student> getValuesByQuery (StudentQuery studentQuery);
3 years ago
2 years ago
PageQuery<Student> getPracticePerformanceStatistic (PageQuery query);
List<Student> getPracticePerformanceStatisticInfo (StudentQuery studentQuery);
List<Student> getPracticeProgress (StudentQuery studentQuery);
PageQuery<CourseInfo> getErrorStatistics (PageQuery query);
/**
*
* ---
*
* @param studentIds
* @return
*/
2 years ago
@Cacheable(value = "studentDao:getStudentExtendSchoolInfo", key = "#studentIds", unless="#result == null || #result.size() == 0")
List<StudentExtendSchoolInfo> getStudentExtendSchoolInfo(String studentIds);
/**
* ID
* @param userIds
* @return
*/
List<StudentExtendSchoolInfo> getStudentExtendSchoolInfoListByUserIds(String userIds);
/**
* -
* @param dto
* @return
*/
Student getStudentByStudentEditPasswordDTO(StudentEditPasswordDTO dto);
2 years ago
StudentActiveInfo studentActiveInfo(Long studentId, Long userId);
3 years ago
}