<?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.community.huiju.dao.TaSysMenuMapper">

    <select id="selectList" parameterType="integer" resultType="com.community.huiju.model.TaSysMenu" >
        SELECT
            tas.id,
            tas.community_id,
            tas.menu_name,
            tas.menu_url,
            tas.parent_id,
            tas.sort,
            tas.menu_type,
            tas.status,
            tas.remark,
            tas.`explain`,
            (select menu_icon_img from ta_sys_menu_img where ta_menu_id = tas.id limit 0,1) imgUrl
        FROM
            ta_sys_menu tas
        WHERE
            tas.community_id = #{communityId}
        order by sort
    </select>

</mapper>
