<?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.unis.reserveLayout.modular.keepWork.mapper.TVentilationOperationMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.unis.reserveLayout.modular.keepWork.entity.TVentilationOperation">
        <id column="id" property="id" />
        <result column="tfzydh" property="tfzydh" />
        <result column="tfrq" property="tfrq" />
        <result column="cfbh" property="cfbh" />
        <result column="cfmc" property="cfmc" />
        <result column="tfmd" property="tfmd" />
        <result column="kxd" property="kxd" />
        <result column="tflx" property="tflx" />
        <result column="fdxs" property="fdxs" />
        <result column="cflx" property="cflx" />
        <result column="cncd" property="cncd" />
        <result column="cnkd" property="cnkd" />
        <result column="zjnj" property="zjnj" />
        <result column="sjclxgd" property="sjclxgd" />
        <result column="pz" property="pz" />
        <result column="sl" property="sl" />
        <result column="cd" property="cd" />
        <result column="kd" property="kd" />
        <result column="zj" property="zj" />
        <result column="ldgd" property="ldgd" />
        <result column="dlxs" property="dlxs" />
        <result column="fwlx" property="fwlx" />
        <result column="fwszfs" property="fwszfs" />
        <result column="zfdjmj" property="zfdjmj" />
        <result column="fwkkl" property="fwkkl" />
        <result column="kqtjb" property="kqtjb" />
        <result column="tfkszgs" property="tfkszgs" />
        <result column="tfkssj" property="tfkssj" />
        <result column="tfjssj" property="tfjssj" />
        <result column="tfzyfzr" property="tfzyfzr" />
        <result column="djrq" property="djrq" />
        <result column="tfjxh" property="tfjxh" />
        <result column="tfjts" property="tfjts" />
        <result column="dtfjedqy" property="dtfjedqy" />
        <result column="dtfjedfl" property="dtfjedfl" />
        <result column="dtfjedgl" property="dtfjedgl" />
        <result column="sffs" property="sffs" />
        <result column="dtfjscfl" property="dtfjscfl" />
        <result column="dtfjzgl" property="dtfjzgl" />
        <result column="zfl" property="zfl" />
        <result column="dwtfl" property="dwtfl" />
        <result column="scxtzl" property="scxtzl" />
        <result column="zhdl" property="zhdl" />
        <result column="work_temp" property="workTemp" />
        <result column="work_wet" property="workWet" />
        <result column="work_time" property="workTime" />
        <result column="tfqpjlw" property="tfqpjlw" />
        <result column="tfhpjlw" property="tfhpjlw" />
        <result column="jwfd" property="jwfd" />
        <result column="sslssl" property="sslssl" />
        <result column="bsxgpjjg" property="bsxgpjjg" />
        <result column="dljwnh" property="dljwnh" />
        <result column="tfqpjsf" property="tfqpjsf" />
        <result column="tfhpjsf" property="tfhpjsf" />
        <result column="jsfd" property="jsfd" />
        <result column="dljsnh" property="dljsnh" />
        <result column="jyxzx" property="jyxzx" />
        <result column="jyxsc" property="jyxsc" />
        <result column="jyxzc" property="jyxzc" />
        <result column="jyxxc" property="jyxxc" />
        <result column="tfqcnw" property="tfqcnw" />
        <result column="tfqcns" property="tfqcns" />
        <result column="tfqcww" property="tfqcww" />
        <result column="tfqcws" property="tfqcws" />
        <result column="tfqzglw" property="tfqzglw" />
        <result column="tfqzdlw" property="tfqzdlw" />
        <result column="tfhcnw" property="tfhcnw" />
        <result column="tfhcns" property="tfhcns" />
        <result column="tfhcww" property="tfhcww" />
        <result column="tfhcws" property="tfhcws" />
        <result column="tfhzglw" property="tfhzglw" />
        <result column="tfhzdlw" property="tfhzdlw" />
        <result column="tfqyq" property="tfqyq" />
        <result column="tfqeyht" property="tfqeyht" />
        <result column="tfqlhq" property="tfqlhq" />
        <result column="tfhyq" property="tfhyq" />
        <result column="tfheyht" property="tfheyht" />
        <result column="tfhlhq" property="tfhlhq" />
        <result column="bz" property="bz" />
        <result column="org_id" property="orgId" />
        <result column="zfdjmj_zhi" property="zfdjmjZhi" />
        <result column="zfdzcd" property="zfdzcd" />
        <result column="updatetime" property="updatetime" />
    </resultMap>

    <!-- 通用查询结果列 -->
    <sql id="Base_Column_List">
        id, tfzydh, tfrq, cfbh, cfmc, tfmd, kxd, tflx, fdxs, cflx, cncd, cnkd, zjnj, sjclxgd, pz, sl, cd, kd, zj, ldgd, dlxs, fwlx, fwszfs, zfdjmj, fwkkl, kqtjb, tfkszgs, tfkssj, tfjssj, tfzyfzr, djrq, tfjxh, tfjts, dtfjedqy, dtfjedfl, dtfjedgl, sffs, dtfjscfl, dtfjzgl, zfl, dwtfl, scxtzl, zhdl, work_temp, work_wet, work_time, tfqpjlw, tfhpjlw, jwfd, sslssl, bsxgpjjg, dljwnh, tfqpjsf, tfhpjsf, jsfd, dljsnh, jyxzx, jyxsc, jyxzc, jyxxc, tfqcnw, tfqcns, tfqcww, tfqcws, tfqzglw, tfqzdlw, tfhcnw, tfhcns, tfhcww, tfhcws, tfhzglw, tfhzdlw, tfqyq, tfqeyht, tfqlhq, tfhyq, tfheyht, tfhlhq, bz, org_id, zfdjmj_zhi, zfdzcd, updatetime
    </sql>
    <select id="selectPageList" parameterType="com.baomidou.mybatisplus.core.conditions.Wrapper" resultType="com.unis.reserveLayout.modular.keepWork.entity.TVentilationOperation">
        SELECT
            tvo.id,
            tvo.org_name,
            tvo.tfzydh,
            tvo.cfmc,
            tvo.tfmd,
            be.enumname tfmdName,
            tvo.tflx,
            be1.enumname tflxName,
            tvo.tfzyfzr,
            tvo.tfzyry
        FROM
            t_ventilation_operation tvo
        LEFT JOIN basic_enum be ON tvo.tfmd = be.enumId
        LEFT JOIN basic_enum be1 ON tvo.tflx = be1.enumId
        ${ew.customSqlSegment}
    </select>
    <select id="getJoinById" parameterType="string" resultType="com.unis.reserveLayout.modular.keepWork.entity.TVentilationOperation">
        SELECT
            tvo.*, be.enumname tfmdName,
            be1.enumname tflxName,
            be2.enumname fdxsName,
            be3.enumname fwszfsName,
            be4.enumname sffsName
        FROM
            t_ventilation_operation tvo
        LEFT JOIN basic_enum be ON tvo.tfmd = be.enumId
        LEFT JOIN basic_enum be1 ON tvo.tflx = be1.enumId
        LEFT JOIN basic_enum be2 ON tvo.fdxs = be2.enumId
        LEFT JOIN basic_enum be3 ON tvo.fwszfs = be3.enumId
        LEFT JOIN basic_enum be4 ON tvo.sffs = be4.enumId
        WHERE
            tvo.id = #{id}
    </select>
</mapper>
