package com.reading.platform.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.reading.platform.dto.request.StudentCreateRequest;
import com.reading.platform.dto.request.StudentUpdateRequest;
import com.reading.platform.dto.response.StudentTransferHistoryResponse;
import com.reading.platform.entity.Student;

import java.util.List;

/**
 * Student Service Interface
 */
public interface StudentService extends IService<Student> {

    Student createStudent(String tenantId, StudentCreateRequest request);

    Student updateStudent(String id, StudentUpdateRequest request);

    Student getStudentById(String id);

    Page<Student> getStudentPage(String tenantId, Integer pageNum, Integer pageSize, String keyword, String grade, String status);

    Page<Student> getStudentsByClassId(String classId, Integer pageNum, Integer pageSize);

    void deleteStudent(String id);

    List<Student> getStudentsByParentId(String parentId);

    List<Student> importStudents(String tenantId, List<StudentCreateRequest> requests);

    // ==================== 新增方法 ====================

    /**
     * 学生调班
     */
    void transferStudent(String tenantId, String studentId, String toClassId, String reason);

    /**
     * 获取学生调班历史
     */
    List<StudentTransferHistoryResponse> getStudentClassHistory(String studentId);

}
