<?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.njcn.product.advance.responsility.mapper.RespDataMapper">

    <select id="page" resultType="RespDataDTO">
        SELECT pqs_resp_data.*,
               pqs_resp_user_data.name userDataName
        FROM pqs_resp_data pqs_resp_data
           left join pqs_resp_user_data pqs_resp_user_data on  pqs_resp_data.user_data_id = pqs_resp_user_data.id
        WHERE
           ${ew.sqlSegment}
    </select>

    <update id="deleteByIds" >
        update
        pqs_resp_data
        set state = 0
        where
        id
        in
        <foreach collection="ids" item="item" separator="," open="(" close=")">
            #{item}
        </foreach>
    </update>

</mapper>
