<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.lframework.xingyun.template.gen.mappers.GenCustomListToolbarMapper">
  <resultMap id="GenCustomListToolbar" type="com.lframework.xingyun.template.gen.entity.GenCustomListToolbar">
    <id column="id" property="id"/>
    <result column="custom_list_id" property="customListId"/>
    <result column="name" property="name"/>
    <result column="view_type" property="viewType"/>
    <result column="btn_type" property="btnType"/>
    <result column="btn_config" property="btnConfig"/>
    <result column="icon" property="icon"/>
    <result column="request_param" property="requestParam"/>
    <result column="order_no" property="orderNo"/>
  </resultMap>

  <sql id="GenCustomListToolbar_sql">
    SELECT o.id,
           o.custom_list_id,
           o.name,
           o.view_type,
           o.btn_type,
           o.btn_config,
           o.icon,
           o.request_param,
           o.order_no
    FROM gen_custom_list_toolbar AS o
  </sql>
  <select id="getByCustomListId"
          resultType="com.lframework.xingyun.template.gen.entity.GenCustomListToolbar">
    <include refid="GenCustomListToolbar_sql"/>
    WHERE o.custom_list_id = #{customListId}
    ORDER BY o.order_no
  </select>
</mapper>