package com.ruoyi.hezhi.mapper; import com.ruoyi.hezhi.domain.TbStudent; import org.apache.ibatis.annotations.Param; import java.util.List; import java.util.Set; /** * 学员Mapper接口 * * @author ruoyi * @date 2024-10-21 */ public interface TbStudentMapper { /** * 查询学员 * * @param studentId 学员主键 * @return 学员 */ public TbStudent selectTbStudentByStudentId(Long studentId); /** * 查询学员列表 * * @param tbStudent 学员 * @return 学员集合 */ public List selectTbStudentList(TbStudent tbStudent); /** * 新增学员 * * @param tbStudent 学员 * @return 结果 */ public int insertTbStudent(TbStudent tbStudent); /** * 修改学员 * * @param tbStudent 学员 * @return 结果 */ public int updateTbStudent(TbStudent tbStudent); /** * 删除学员 * * @param studentId 学员主键 * @return 结果 */ public int deleteTbStudentByStudentId(Long studentId); /** * 批量删除学员 * * @param studentIds 需要删除的数据主键集合 * @return 结果 */ public int deleteTbStudentByStudentIds(Long[] studentIds); /** * 查询学员 * * @param phone 电话/手机 * @param identityCard 身份证号 * @return 结果 */ public TbStudent selectTbStudentBy(@Param("phone") String phone, @Param("identityCard") String identityCard); /** * 查询学员 公众号openId * * @param gzhOpenId 公众号openId * @return 学员 */ public TbStudent selectTbStudentByGzhOpenId(String gzhOpenId); /** * 根据openid获取用户信息 * * @param openId openId * @return TbStudent */ TbStudent getByOpenId(@Param("openId") String openId); /** * 根据unionId获取用户信息 * * @param unionId unionId * @return TbStudent */ TbStudent getByUnionId(@Param("unionId") String unionId); /** * 根据身份证号获取对应的用户id * * @param identityCard 身份证号 * @return TbStudent */ Long selectTbStudentByIdCard(String identityCard); /** * 根据手机号获取对应的用户id * * @param phone 手机号 * @return TbStudent */ Long selectTbStudentByPhone(String phone); List selectTbStudentByPhones(@Param("phoneSet") Set phoneSet); List selectTbStudentByIdCards(@Param("idCardSet") Set idCardSet); int batchInsertStudents(List insertList); }