<?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="org.springblade.person.mapper.CorrectionalStaffMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="correctionalStaffResultMap" type="org.springblade.person.entity.CorrectionalStaff">
        <result column="id" property="id"/>
        <result column="create_user" property="createUser"/>
        <result column="create_dept" property="createDept"/>
        <result column="create_time" property="createTime"/>
        <result column="update_user" property="updateUser"/>
        <result column="update_time" property="updateTime"/>
        <result column="status" property="status"/>
        <result column="is_deleted" property="isDeleted"/>
        <result column="parent_id" property="parentId"/>
        <result column="correct_type" property="correctType"/>
        <result column="correct_person_code" property="correctPersonCode"/>
        <result column="detention_place" property="detentionPlace"/>
        <result column="case_type" property="caseType"/>
        <result column="specific_charges" property="specificCharges"/>
        <result column="original_sentence" property="originalSentence"/>
        <result column="startdate_sentence" property="startdateSentence"/>
        <result column="enddate_sentence" property="enddateSentence"/>
        <result column="startdate_correction" property="startdateCorrection"/>
        <result column="enddate_correction" property="enddateCorrection"/>
        <result column="receiving_mode" property="receivingMode"/>
        <result column="checkin_mode" property="checkinMode"/>
        <result column="is_recidivist" property="isRecidivist"/>
        <result column="four_histories" property="fourHistories"/>
        <result column="five_situation" property="fiveSituation"/>
        <result column="is_team_established" property="isTeamEstablished"/>
        <result column="team_composition" property="teamComposition"/>
        <result column="relief_type" property="reliefType"/>
        <result column="is_get_rid" property="isGetRid"/>
        <result column="reason_get_rid" property="reasonGetRid"/>
        <result column="inspect_get_rid" property="inspectGetRid"/>
        <result column="correct_get_rid" property="correctGetRid"/>
        <result column="is_unmanaged" property="isUnmanaged"/>
        <result column="reason_unmanage" property="reasonUnmanage"/>
        <result column="inspect_unmanage" property="inspectUnmanage"/>
        <result column="correct_unmanage" property="correctUnmanage"/>
        <result column="rewards_and_punishments" property="rewardsAndPunishments"/>
        <result column="penalty_change" property="penaltyChange"/>
        <result column="new_crime" property="newCrime"/>
        <result column="name_of_recidivism" property="nameOfRecidivism"/>
        <result column="category_of_law" property="categoryOfLaw"/>
        <result column="control_level" property="controlLevel"/>
        <result column="is_key_monitoring" property="isKeyMonitoring"/>
    </resultMap>


    <select id="selectCorrectionalStaffPage" resultMap="correctionalStaffResultMap">
        select * from personnel_correctional_staff where is_deleted = 0
    </select>

</mapper>
