TCmsCategoryMapper.xml 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="com.sooka.mybatis.mapper.TCmsCategoryMapper">
  4. <resultMap id="BaseResultMap" type="com.sooka.mybatis.model.TCmsCategory">
  5. <!--
  6. WARNING - @mbg.generated
  7. -->
  8. <id column="category_id" jdbcType="BIGINT" property="categoryId" />
  9. <result column="alias" jdbcType="VARCHAR" property="alias" />
  10. <result column="category_name" jdbcType="VARCHAR" property="categoryName" />
  11. <result column="en_name" jdbcType="VARCHAR" property="enName" />
  12. <result column="site_id" jdbcType="INTEGER" property="siteId" />
  13. <result column="parent_id" jdbcType="BIGINT" property="parentId" />
  14. <result column="model_id" jdbcType="INTEGER" property="modelId" />
  15. <result column="alone" jdbcType="BIT" property="alone" />
  16. <result column="index_tpl" jdbcType="VARCHAR" property="indexTpl" />
  17. <result column="list_tpl" jdbcType="VARCHAR" property="listTpl" />
  18. <result column="content_tpl" jdbcType="VARCHAR" property="contentTpl" />
  19. <result column="is_nav" jdbcType="BIT" property="isNav" />
  20. <result column="url" jdbcType="VARCHAR" property="url" />
  21. <result column="has_child" jdbcType="BIT" property="hasChild" />
  22. <result column="is_common" jdbcType="BIT" property="isCommon" />
  23. <result column="allow_front_submit" jdbcType="BIT" property="allowFrontSubmit" />
  24. <result column="page_size" jdbcType="INTEGER" property="pageSize" />
  25. <result column="allow_search" jdbcType="BIT" property="allowSearch" />
  26. <result column="category_icon" jdbcType="VARCHAR" property="categoryIcon" />
  27. <result column="permission_key" jdbcType="VARCHAR" property="permissionKey" />
  28. <result column="sort_id" jdbcType="INTEGER" property="sortId" />
  29. <result column="content" jdbcType="LONGVARCHAR" property="content" />
  30. </resultMap>
  31. <select id="findByCategoryIds" resultType="java.util.Map">
  32. select * from t_cms_category where
  33. category_id in
  34. <foreach item="item" index="index" collection="categoryIds" open="(" separator="," close=")">
  35. #{item}
  36. </foreach>
  37. order by sort_id desc
  38. </select>
  39. </mapper>