<?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.yami.shop.mp.comment.dao.WeixinKeywordresponseMapper">
  <resultMap id="BaseResultMap" type="com.yami.shop.mp.comment.model.WeixinKeywordresponse">
    <id column="id" jdbcType="INTEGER" property="id" />
    <result column="keyword" jdbcType="VARCHAR" property="keyword" />
    <result column="pptype" jdbcType="INTEGER" property="pptype" />
    <result column="msg_type" jdbcType="VARCHAR" property="msgType" />
    <result column="media_id" jdbcType="VARCHAR" property="mediaId" />
    <result column="content" jdbcType="VARCHAR" property="content" />
  </resultMap>
  
  <resultMap id="WeixinKeywordresponseAndMaterialMap" type="com.yami.shop.mp.comment.model.WeixinKeywordresponse">
    <id column="id" jdbcType="INTEGER" property="id" />
    <result column="keyword" jdbcType="VARCHAR" property="keyword" />
    <result column="pptype" jdbcType="INTEGER" property="pptype" />
    <result column="msg_type" jdbcType="VARCHAR" property="msgType" />
    <result column="media_id" jdbcType="VARCHAR" property="mediaId" />
    <result column="content" jdbcType="VARCHAR" property="content" />
    <association property="weixinMaterial" javaType="com.yami.shop.mp.comment.model.WeixinMaterial">
    	<id column="media_id" jdbcType="VARCHAR" property="mediaId" />
	    <result column="media_type" jdbcType="VARCHAR" property="mediaType" />
	    <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
	    <result column="media_name" jdbcType="VARCHAR" property="mediaName" />
    </association>
  </resultMap>
  
    <!--<select id="listWeixinKeywordresponseAndMaterial" resultMap="WeixinKeywordresponseAndMaterialMap">-->
  	<!--select * from tz_weixin_keywordresponse wk -->
  	<!--left join tz_weixin_material wm on wk.media_id = wm.media_id-->
  <!--</select>-->
</mapper>