| | |
| | | package com.yeshi.fanli.dao.mybatis; |
| | | |
| | | import java.util.List; |
| | | |
| | | import org.apache.ibatis.annotations.Param; |
| | | |
| | | import com.yeshi.fanli.entity.bus.clazz.GoodsSubClass; |
| | | |
| | | public interface GoodsSubClassMapper { |
| | | |
| | | int deleteByPrimaryKey(Long id); |
| | | |
| | | int insert(GoodsSubClass record); |
| | | |
| | | int insertSelective(GoodsSubClass record); |
| | | |
| | | GoodsSubClass selectByPrimaryKey(Long id); |
| | | |
| | | int updateByPrimaryKeySelective(GoodsSubClass record); |
| | | |
| | | int updateByPrimaryKey(GoodsSubClass record); |
| | | |
| | | |
| | | /** |
| | | * 查询一级之下的所有二级分类 |
| | | * @param rootId 一级id |
| | | * @returnL |
| | | */ |
| | | List<GoodsSubClass> queryByRootId(@Param("rootId") Long rootId, @Param("state") Integer state,@Param("month") Integer month); |
| | | |
| | | /** |
| | | * 查询二级分类之下其他分类 |
| | | * @param rootId 一级id |
| | | * @return |
| | | */ |
| | | List<GoodsSubClass> queryByPid(@Param("pid") Long pid, @Param("state") Integer state); |
| | | |
| | | |
| | | List<GoodsSubClass> queryByRootIdAndWeight(@Param("rootId") Long rootId, @Param("type") int type, @Param("weight") int weight); |
| | | |
| | | List<GoodsSubClass> queryByPidAndWeight(@Param("pid") Long pid, @Param("type") int type, @Param("weight") int weight); |
| | | |
| | | /** |
| | | * 统计一级之下的所有二级分类 |
| | | * @param rootId 一级id |
| | | * @returnL |
| | | */ |
| | | int countByRootId(@Param("rootId") Long rootId); |
| | | |
| | | /** |
| | | * 统计二级分类之下其他分类 |
| | | * @param rootId 一级id |
| | | * @return |
| | | */ |
| | | int countByPid(@Param("pid") Long pid); |
| | | |
| | | /** |
| | | * 统计一级之下最大权重 |
| | | * @param rootId 一级id |
| | | * @returnL |
| | | */ |
| | | int getMaxWeightByRootId(@Param("rootId") Long rootId); |
| | | |
| | | /** |
| | | * 统计二级分类之最大权重 |
| | | * @param rootId 一级id |
| | | * @return |
| | | */ |
| | | int getMaxWeightByPid(@Param("pid") Long pid); |
| | | |
| | | /** |
| | | * 一级id查询 |
| | | * @param list |
| | | * @return |
| | | */ |
| | | List<GoodsSubClass> queryByListCid(List<Long> list); |
| | | |
| | | package com.yeshi.fanli.dao.mybatis;
|
| | |
|
| | | import java.util.List;
|
| | |
|
| | | import org.apache.ibatis.annotations.Param;
|
| | |
|
| | | import com.yeshi.fanli.entity.bus.clazz.GoodsSubClass;
|
| | |
|
| | | public interface GoodsSubClassMapper {
|
| | |
|
| | | int deleteByPrimaryKey(Long id);
|
| | |
|
| | | int insert(GoodsSubClass record);
|
| | |
|
| | | int insertSelective(GoodsSubClass record);
|
| | |
|
| | | GoodsSubClass selectByPrimaryKey(Long id);
|
| | |
|
| | | int updateByPrimaryKeySelective(GoodsSubClass record);
|
| | |
|
| | | int updateByPrimaryKey(GoodsSubClass record);
|
| | | |
| | | |
| | | /**
|
| | | * 查询一级之下的所有二级分类
|
| | | * @param rootId 一级id
|
| | | * @returnL
|
| | | */
|
| | | List<GoodsSubClass> queryByRootId(@Param("rootId") Long rootId, @Param("state") Integer state,@Param("month") Integer month);
|
| | | |
| | | /**
|
| | | * 查询二级分类之下其他分类
|
| | | * @param rootId 一级id
|
| | | * @return
|
| | | */
|
| | | List<GoodsSubClass> queryByPid(@Param("pid") Long pid, @Param("state") Integer state);
|
| | | |
| | | |
| | | List<GoodsSubClass> queryByRootIdAndWeight(@Param("rootId") Long rootId, @Param("type") int type, @Param("weight") int weight);
|
| | | |
| | | List<GoodsSubClass> queryByPidAndWeight(@Param("pid") Long pid, @Param("type") int type, @Param("weight") int weight);
|
| | | |
| | | /**
|
| | | * 统计一级之下的所有二级分类
|
| | | * @param rootId 一级id
|
| | | * @returnL
|
| | | */
|
| | | int countByRootId(@Param("rootId") Long rootId);
|
| | | |
| | | /**
|
| | | * 统计二级分类之下其他分类
|
| | | * @param rootId 一级id
|
| | | * @return
|
| | | */
|
| | | int countByPid(@Param("pid") Long pid);
|
| | | |
| | | /**
|
| | | * 统计一级之下最大权重
|
| | | * @param rootId 一级id
|
| | | * @returnL
|
| | | */
|
| | | int getMaxWeightByRootId(@Param("rootId") Long rootId);
|
| | | |
| | | /**
|
| | | * 统计二级分类之最大权重
|
| | | * @param rootId 一级id
|
| | | * @return
|
| | | */
|
| | | int getMaxWeightByPid(@Param("pid") Long pid);
|
| | | |
| | | /**
|
| | | * 一级id查询
|
| | | * @param list
|
| | | * @return
|
| | | */
|
| | | List<GoodsSubClass> queryByListCid(List<Long> list);
|
| | | |
| | | } |