admin
2020-02-23 b59fef5c00b15fdfdfa9d4be26e5bf6b41c75458
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
package com.yeshi.fanli.dao.mybatis;
 
import java.math.BigDecimal;
import java.util.List;
 
import org.apache.ibatis.annotations.Param;
 
import com.yeshi.fanli.dao.BaseMapper;
import com.yeshi.fanli.entity.system.SystemCoupon;
 
public interface SystemCouponMapper extends BaseMapper<SystemCoupon> {
    /**
     * 批量删除
     * @param list
     * @return
     */
    int deleteBatchByPrimaryKey(List<Long> list);
    
    /**
     *   根据类型查询且启用券
     * @param list
     * @return
     */
    List<SystemCoupon> getCouponListByType(@Param("list")List<String> list);
    
    /**
     * 根据类型查询
     * @param type
     * @return
     */
    SystemCoupon getCouponByType(@Param("type") String type);
    
    /**
     * 根据类型/比例查询
     * @param type
     * @return
     */
    SystemCoupon getCouponByTypeAndPercent(@Param("type") String type, @Param("percent") BigDecimal percent);
    
}