package jnpf.personnels.mapper;

import cn.hutool.core.date.DateTime;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import jnpf.model.personnels.dto.base.PersonnelsQueryDTO;
import jnpf.model.personnels.dto.regular.FtbPersonnelsForAppQueryDTO;
import jnpf.model.personnels.po.FtbPersonnelsRegularManagement;
import jnpf.model.personnels.vo.regular.FtbPersonnelsRegularManagementVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface FtbPersonnelsRegularManagementMapper extends BaseMapper<FtbPersonnelsRegularManagement> {

    Page<FtbPersonnelsRegularManagementVO> pageList(Page<FtbPersonnelsRegularManagementVO> page,
                                                    @Param("dto") PersonnelsQueryDTO dto);
    List<FtbPersonnelsRegularManagementVO> queryList(@Param("dto") PersonnelsQueryDTO dto);

    Page<FtbPersonnelsRegularManagementVO> getListForApp(Page<FtbPersonnelsRegularManagementVO> page,
                                                         @Param("dto")  FtbPersonnelsForAppQueryDTO dto);

    Page<FtbPersonnelsRegularManagementVO> getThePendingApprovalList(Page<FtbPersonnelsRegularManagementVO> page, @Param("dto") FtbPersonnelsForAppQueryDTO covert);

    Page<FtbPersonnelsRegularManagementVO> getAuditedDataList(Page<FtbPersonnelsRegularManagementVO> page,
                                                              @Param("dto") FtbPersonnelsForAppQueryDTO covert);

    Page<FtbPersonnelsRegularManagementVO> getListForCC(Page<FtbPersonnelsRegularManagementVO> page,
                                                        @Param("dto") FtbPersonnelsForAppQueryDTO covert);

    Long queryNumberOfRegulars(@Param("userIds") List<String> userIds);

    List<FtbPersonnelsRegularManagementVO> queryRegualList(@Param("dto") PersonnelsQueryDTO dto);

    List<FtbPersonnelsRegularManagementVO> queryUserInfoForRegularization(@Param("startDate") DateTime startDate, @Param("endDate") DateTime endDate , @Param("userIds") List<String> userIds);

    List<String> getRegularizationStoreDimension(@Param("startDate") String startDate,@Param("endDate")  String endDate, @Param("userIds") List<String> userIds);
}