<?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.jeeplus.test.cw.projectReport.mapper.CwProjectReportReviewMapper">
    <update id="updateReviewStatysByReportId">
        update cw_project_report_review set review_status = #{reviewStatus} where report_id = #{id}
    </update>
    <select id="selectByReportId" resultType="com.jeeplus.test.cw.projectReport.domain.CwProjectReview">
        select * from cw_project_report_review where report_id = #{id}
    </select>
    <select id="selectByPortId" resultType="com.jeeplus.test.cw.projectReport.domain.CwProjectReportData">
        select * from cw_project_report_review where report_id = #{id}
    </select>
    <select id="getProjectIdByReportId" resultType="java.lang.String">
        SELECT project_id FROM cw_project_report cw_p
        LEFT JOIN cw_project_report_review cw_re
        on cw_p.id = cw_re.report_id and cw_re.del_flag = '0'
        WHERE cw_p.id = #{id}
    </select>
</mapper>
