yujian
2019-04-26 77602de9c796b5fd42b74003727d934df14152fa
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package com.yeshi.fanli.dao.mybatis.brand;
 
import java.util.List;
 
import org.apache.ibatis.annotations.Param;
 
import com.yeshi.fanli.dao.BaseMapper;
import com.yeshi.fanli.entity.brand.BrandClassShop;
 
public interface BrandClassShopMapper extends BaseMapper<BrandClassShop>{
    
    /**
     * 查询有效
     * @param start
     * @param count
     * @param cid
     * @return
     */
    List<BrandClassShop> listEffective(@Param("start") long start, @Param("count") int count, @Param("cid") Long cid);
    
    long countEffective(@Param("cid") Long cid);
    
    
    List<BrandClassShop> getExistByShopIds(List<Long> list);
    
    /**
     * 根据店铺id
     * @param cid
     * @param shopId
     * @return
     */
    BrandClassShop getByShopId(@Param("shopId") Long shopId);
    
    /**
     * 根据店铺id、分类id查询
     * @param cid
     * @param shopId
     * @return
     */
    BrandClassShop getByShopIdAndCid(@Param("cid") Long cid, @Param("shopId") Long shopId);
    
    /**
     * 根据分类查询排序
     * @param cid
     * @return
     */
    int getMaxOrder(@Param("cid") Long cid);
    
    /**
     * 排序交换
     * @param order
     * @param type
     * @return
     */
    BrandClassShop getByAdjoinOrder(@Param("cid") Long cid, @Param("order") Integer order,    @Param("type") Integer type);
    
    /**
     * 查询列表
     * @param start
     * @param count
     * @param key
     * @param state
     * @return
     */
    public List<BrandClassShop> listQuery(@Param("start") long start,@Param("count") int count,
            @Param("key")String key, @Param("cid") Long cid,@Param("state") Integer state);
 
    public long countQuery(@Param("key")String key, @Param("cid") Long cid,@Param("state") Integer state);
    
    
}