AppraiseOrderMetaMapper.xml 1.07 KB
<?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.yoho.order.dal.AppraiseOrderMetaMapper">
    <resultMap id="BaseResultMap" type="com.yoho.order.model.AppraiseOrderMeta">
      <result column="id" property="id" jdbcType="INTEGER" />
      <result column="uid" property="uid" jdbcType="INTEGER" />
      <result column="order_code" property="orderCode" jdbcType="BIGINT" />
      <result column="storage_id" property="storageId" jdbcType="INTEGER" />
      <result column="meta_key" property="metaKey" jdbcType="VARCHAR" />
      <result column="meta_value" property="metaValue" jdbcType="VARCHAR" />
    </resultMap>

    <sql id="Base_Column_List">
        id, uid, order_code, storage_id, meta_key, meta_value 
    </sql>
    
    <select id="selectByOrderCodeAndMetaKey" resultMap="BaseResultMap">
        select <include refid="Base_Column_List" />
        from appraise_order_goods where order_code =#{orderCode} and meta_key=#{metaKey}
    </select>
    
</mapper>