SecondhandInfoMapper.xml
1.71 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.product.dal.SecondhandInfoMapper" >
<resultMap id="BaseResultMap" type="com.yoho.product.model.SecondhandInfo" >
<id column="id" property="id" jdbcType="INTEGER" />
<result column="skup" property="skup" jdbcType="INTEGER" />
<result column="flaw_id" property="flawId" jdbcType="VARCHAR" />
<result column="flaw_attr" property="flawAttr" jdbcType="VARCHAR" />
<result column="describe_info" property="describeInfo" jdbcType="VARCHAR" />
<result column="create_time" property="createTime" jdbcType="INTEGER" />
<result column="audit_uid" property="auditUid" jdbcType="INTEGER" />
<result column="audit_name" property="auditName" jdbcType="VARCHAR" />
<result column="audit_time" property="auditTime" jdbcType="INTEGER" />
<result column="reject_reason" property="rejectReason" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, skup, flaw_id, flaw_attr, describe_info, create_time, audit_uid, audit_name, audit_time, reject_reason
</sql>
<select id="selectBySkups" resultMap="BaseResultMap" >
select <include refid="Base_Column_List" />
from secondhand_info where skup in
<foreach item="item" index="index" collection="skupList" open="(" separator="," close=")">
#{item}
</foreach>
</select>
<update id="updateAuditInfoBySkup" parameterType="com.yoho.product.model.SecondhandInfo">
update secondhand_info
set reject_reason=#{rejectReason},
audit_uid=#{auditUid}, audit_name=#{auditName}, audit_time=#{auditTime}
where skup=#{skup}
</update>
</mapper>