package com.srs.routine.service;

import java.util.List;

import com.baomidou.mybatisplus.extension.service.IService;
import com.srs.routine.domain.RtStuLeaveApplication;
import com.srs.routine.domain.dto.LeaveApplicationApprovalDto;
import com.srs.routine.domain.vo.ClassStuLeaveDataStatistics;
import com.srs.routine.domain.vo.StuInfoReturnVo;
import com.srs.routine.domain.vo.StuLeaveApplicationDetailsVo;
import com.srs.routine.domain.vo.StuLeaveApplicationVo;
import com.srs.routine.domain.dto.StuLeaveApplicationDto;

/**
 * 学生请假申请Service接口
 *
 * @author LSD
 * @date 2024-03-30
 */
public interface IRtStuLeaveApplicationService extends IService<RtStuLeaveApplication> {
    /**
     * 查询学生请假申请
     *
     * @param leaveApplicationId 学生请假申请主键
     * @return 学生请假申请
     */
    public RtStuLeaveApplication selectRtStuLeaveApplicationByLeaveApplicationId(Long leaveApplicationId);

    /**
     * 查询学生请假申请列表
     *
     * @param rtStuLeaveApplication 学生请假申请
     * @return 学生请假申请集合
     */
    List<RtStuLeaveApplication> selectRtStuLeaveApplicationList(RtStuLeaveApplication rtStuLeaveApplication);

    /**
     * 查询数据
     * @param dto
     * @return
     */
    public List<StuLeaveApplicationVo> getRtStuLeaveApplicationListDto(StuLeaveApplicationDto dto);

    /**
     * 查询数据
     * @param dto
     * @return
     */
    public List<StuLeaveApplicationVo> getRtStuLeaveApplicationListVo(StuLeaveApplicationDto dto);

    /**
     * 新增学生请假申请
     *
     * @param rtStuLeaveApplication 学生请假申请
     * @return 结果
     */
    int insertRtStuLeaveApplication(RtStuLeaveApplication rtStuLeaveApplication);

    /**
     * 修改学生请假申请
     *
     * @param rtStuLeaveApplication 学生请假申请
     * @return 结果
     */
    int updateRtStuLeaveApplication(RtStuLeaveApplication rtStuLeaveApplication);

    /**
     * 修改学生请假申请
     *
     * @param rtStuLeaveApplication 学生请假申请
     * @return 结果
     */
    int editRtStuLeaveApplication(RtStuLeaveApplication rtStuLeaveApplication);

    /**
     * 批量删除学生请假申请
     *
     * @param leaveApplicationIds 需要删除的学生请假申请主键集合
     * @return 结果
     */
    int deleteRtStuLeaveApplicationByLeaveApplicationIds(Long[] leaveApplicationIds);

    /**
     * 删除学生请假申请信息
     *
     * @param leaveApplicationId 学生请假申请主键
     * @return 结果
     */
    int deleteRtStuLeaveApplicationByLeaveApplicationId(Long leaveApplicationId);

    StuLeaveApplicationDetailsVo selectRtStuLeaveApplicationDetailsByLeaveApplicationId(Long leaveApplicationId);

    /**
     * 根据学生id获取学生填报数据时基础数据回填
     * @param stuNo
     * @return
     */
    StuInfoReturnVo getStuInfo(String stuNo);

    /**
     * 审批通过
     * @param dto
     * @return
     */
    int approval(LeaveApplicationApprovalDto dto);

    /**
     * 审批拒绝
     * @param dto
     * @return
     */
    int refuse(LeaveApplicationApprovalDto dto);

    /**
     * 驳回
     * @param dto
     * @return
     */
    int reject(LeaveApplicationApprovalDto dto);

    /**
     * 学生销假
     * @param dto
     * @return
     */
    int cancellation(LeaveApplicationApprovalDto dto);

    /**
     * 辅导员核实销假-同意
     * @param dto
     * @return
     */
    int verify(LeaveApplicationApprovalDto dto);

    /**
     * 辅导员核实销假-不同意
     * @param dto
     * @return
     */
    int verifyDisagree(LeaveApplicationApprovalDto dto);

    /**
     * 根据流程id获取请假单
     * @param procInsId
     * @return
     */
    StuLeaveApplicationDetailsVo getLeaveApplicationByProcInsId(String procInsId);

    List<ClassStuLeaveDataStatistics> selectClassLeaveNumber(String tNo);

    /**
     * 获取学务角色请假数据
     * @param rtStuLeaveApplication
     * @return
     */
    List<StuLeaveApplicationVo> getRtStuLeaveApplicationListByXW(StuLeaveApplicationDto rtStuLeaveApplication);
}
