package cn.iocoder.yudao.module.jx.mapper;

import cn.iocoder.yudao.module.jx.domain.DriveSchoolCoach;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 驾校教练Mapper接口
 *
 * @author ruoyi
 * @date 2024-03-29
 */
@Mapper
public interface DriveSchoolCoachMapper
{
    /**
     * 查询驾校教练
     *
     * @param id 驾校教练主键
     * @return 驾校教练
     */
    public DriveSchoolCoach selectDriveSchoolCoachById(Long id);

    /**
     * 查询驾校教练列表
     *
     * @param driveSchoolCoach 驾校教练
     * @return 驾校教练集合
     */
    public IPage<DriveSchoolCoach> selectDriveSchoolCoachList(@Param("entity") DriveSchoolCoach driveSchoolCoach, Page<DriveSchoolCoach> page);
    public List<DriveSchoolCoach> selectDriveSchoolCoachListAll(@Param("entity") DriveSchoolCoach driveSchoolCoach);

    /**
     * 新增驾校教练
     *
     * @param driveSchoolCoach 驾校教练
     * @return 结果
     */
    public int insertDriveSchoolCoach(DriveSchoolCoach driveSchoolCoach);

    /**
     * 修改驾校教练
     *
     * @param driveSchoolCoach 驾校教练
     * @return 结果
     */
    public int updateDriveSchoolCoach(DriveSchoolCoach driveSchoolCoach);

    /**
     * 删除驾校教练
     *
     * @param id 驾校教练主键
     * @return 结果
     */
    public int deleteDriveSchoolCoachById(Long id);

    /**
     * 批量删除驾校教练
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDriveSchoolCoachByIds(Long[] ids);

    List<DriveSchoolCoach> selectAllJlId();

    DriveSchoolCoach findSelfJl(Long userId);

    DriveSchoolCoach findCoachByCoachName(String coachName);

    DriveSchoolCoach findInfoByJxId(Long jxId);

    List<DriveSchoolCoach> findJlByDeptId(Long deptId);

    Integer getCoachNumber(Long deptId);

    DriveSchoolCoach selectByPhonenumber(String phonenumber);
}
