ProgressPrizeMapper.java 1.25 KB
Newer Older
licc's avatar
licc committed
1 2 3
package cn.wisenergy.mapper;

import cn.wisenergy.model.app.ProgressPrize;
licc's avatar
licc committed
4
import cn.wisenergy.model.vo.ProgressPrizeVo;
licc's avatar
licc committed
5 6 7
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

licc's avatar
licc committed
8 9 10
import java.util.Date;
import java.util.List;

licc's avatar
licc committed
11 12 13 14 15 16 17 18 19 20
/**
 * @author 86187
 */
public interface ProgressPrizeMapper extends BaseMapper<ProgressPrize> {

    int add(ProgressPrize progressPrize);

    int edit(ProgressPrize progressPrize);

    int delById(@Param("id") Integer id);
licc's avatar
licc committed
21 22 23 24 25 26 27 28

    /**
     * 根据 年月 获取月的最大进步奖用户列表
     *
     * @param yearMonth 年月
     * @return 最大进步奖用户列表
     */
    List<ProgressPrize> getByYearMonth(@Param("yearMonth") String yearMonth);
licc's avatar
licc committed
29 30 31 32 33 34 35 36 37


    /**
     * 获取本月月的最大进步奖用户列表 倒序 增长率相等的,按注册时间倒序
     *
     * @param yearMonth 年月
     * @return 最大进步奖用户列表
     */
    List<ProgressPrizeVo> getByTime(@Param("yearMonth") String yearMonth);
licc's avatar
licc committed
38 39 40 41 42 43 44 45 46

    /**
     * 根据 userId 年月 获取月的最大进步奖用户
     *
     * @param yearMonth 年月
     * @return 最大进步奖用户列表
     */
    ProgressPrize getByUserIdYearMonth(@Param("userId") String userId,@Param("yearMonth") String yearMonth);

licc's avatar
licc committed
47
}