package com.crm.manager.dao.mapper;

import com.crm.rely.backend.core.entity.custom.login.special.CustomLoginSpecialCalcListEntity;
import com.crm.rely.backend.core.pojo.table.CustomLoginSpecialCalcTable;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
@Mapper
public interface CustomLoginSpecialCalcMapper {

    @Select("select * from custom_login_special_calc where id=#{id}")
    CustomLoginSpecialCalcTable getOne(@Param("id") Long id);

    Integer countSearch(CustomLoginSpecialCalcListEntity entity);

    List<CustomLoginSpecialCalcTable> listSearch(CustomLoginSpecialCalcListEntity entity);

    @Select("select count(login) from custom_login_special_calc where login=#{login}")
    Integer countByLogin(@Param("login") Long login);
}
