KpiGroupUserDao.java 1.09 KB
package cn.fw.morax.dao.kpi;

import cn.fw.morax.domain.db.kpi.KpiGroupUser;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.time.YearMonth;

/**
 * @author : kurisu
 * @className : KpiGroupUserDao
 * @description : 绩效组人员
 * @date: 2022-04-06 14:35
 */
@Repository
public interface KpiGroupUserDao extends BaseMapper<KpiGroupUser> {

    /**
     * 获取某月最近的绩效组人员数据
     *
     * @param yearMonth
     * @return
     */
    KpiGroupUser getMonthLastData(@Param("kpiGroupId") Long kpiGroupId,
                                  @Param("userId") Long userId,
                                  @Param("yearMonth") YearMonth yearMonth);
    /**
     * 获取某月第一天的绩效组人员数据
     *
     * @param yearMonth
     * @return
     */
    KpiGroupUser getMonthFirstData(@Param("kpiGroupId") Long kpiGroupId,
                                  @Param("userId") Long userId,
                                  @Param("yearMonth") YearMonth yearMonth);
}