<?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.huiju.estateagents.mapper.TaMiniappTemplateMapper">
    <select id="selectTplByType" resultType="com.huiju.estateagents.entity.TaMiniappTemplate">
        SELECT
            s.*
        FROM
            ta_miniapp t
        INNER JOIN ta_miniapp_template s ON t.miniapp_id = s.miniapp_id
        WHERE
            t.miniapp_id = #{appid}
        AND s.tpl_type = #{type}
        limit 1
    </select>
</mapper>
