<?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.api.butlerApp.dao.butler.ButlerInterviewDao">

    <select id="list" parameterType="com.api.model.butlerApp.ButlerInterviewSearch" resultType="com.api.vo.butlerApp.ButlerInterviewVo">
        select si.*,su.actual_name as create_name
        from sys_interview as si,sys_user as su
        <where>
            si.create_id = su.id
            and si.is_delete = 1
            and si.interviewers = #{id}
            <if test="interviewStatus != null">
                and si.status = #{interviewStatus}
            </if>
        </where>
        order by si.create_date desc
    </select>

    <update id="feedBack" parameterType="com.api.model.operationManagement.Interview">
        update sys_interview
        set status = #{status},
        feedback_content = #{feedbackContent},
        feedback_date = #{feedbackDate}
        where id = #{id} and interviewers = #{interviewers}
    </update>

</mapper>