<?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.crk.business.qcrk.mapper.DataCrkywRmdjDefaultMapper">

    <!-- 通用查询映射结果 -->
    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.unis.crk.business.qcrk.entity.DataCrkywRmdjDefault">
        <id column="DataID" property="DataID" />
        <result column="UnitID" property="UnitID" />
        <result column="PeriodID" property="PeriodID" />
        <result column="RoundID" property="RoundID" />
        <result column="builder" property="builder" />
        <result column="UPDATE_TIME" property="updateTime" />
        <result column="SytelInfoID" property="SytelInfoID" />
        <result column="BuildDate" property="BuildDate" />
        <result column="editor" property="editor" />
        <result column="ModifyDate" property="ModifyDate" />
        <result column="DeptID" property="DeptID" />
        <result column="BizNo" property="BizNo" />
        <result column="PreOrder" property="PreOrder" />
        <result column="ShowOrder" property="ShowOrder" />
        <result column="kddm" property="kddm" />
        <result column="ywdjsj" property="ywdjsj" />
        <result column="ywlx" property="ywlx" />
        <result column="tzdID" property="tzdID" />
        <result column="htID" property="htID" />
        <result column="jhdh" property="jhdh" />
        <result column="djr" property="djr" />
        <result column="cph" property="cph" />
        <result column="gch" property="gch" />
        <result column="slr" property="slr" />
        <result column="slrsfzh" property="slrsfzh" />
        <result column="slrdz" property="slrdz" />
        <result column="slrdh" property="slrdh" />
        <result column="lspz" property="lspz" />
        <result column="scnf" property="scnf" />
        <result column="cd" property="cd" />
        <result column="lsxz" property="lsxz" />
        <result column="cllx" property="cllx" />
        <result column="nrchid" property="nrchid" />
        <result column="nrchbh" property="nrchbh" />
        <result column="nrhwID" property="nrhwID" />
        <result column="nrhwbh" property="nrhwbh" />
        <result column="jhdbh" property="jhdbh" />
        <result column="htbh" property="htbh" />
        <result column="tzdbh" property="tzdbh" />
        <result column="mxpz" property="mxpz" />
        <result column="cyr" property="cyr" />
        <result column="cyrsfzh" property="cyrsfzh" />
        <result column="zt" property="zt" />
        <result column="rmdh" property="rmdh" />
        <result column="djsj" property="djsj" />
        <result column="khmc" property="khmc" />
        <result column="cyrlxdh" property="cyrlxdh" />
        <result column="cyrlxdz" property="cyrlxdz" />
        <result column="bz" property="bz" />
        <result column="rkywlx" property="rkywlx" />
        <result column="hhyhmc" property="hhyhmc" />
        <result column="hfyhhb" property="hfyhhb" />
        <result column="yhkh" property="yhkh" />
        <result column="jhfl" property="jhfl" />
        <result column="bdgjh" property="bdgjh" />
        <result column="tzdcbid" property="tzdcbid" />
        <result column="skr" property="skr" />
        <result column="rcsj" property="rcsj" />
        <result column="lydj" property="lydj" />
        <result column="cydw" property="cydw" />
        <result column="fhdw" property="fhdw" />
        <result column="hcph" property="hcph" />
        <result column="clzbzl" property="clzbzl" />
        <result column="rzdh" property="rzdh" />
        <result column="cchlx" property="cchlx" />
    </resultMap>

    <select id="selectMyMapsPage" resultType="java.util.Map">
        SELECT DISTINCT
        a.ModifyDate AS "ModifyDate",
        a.BizNo AS "BizNo",
        a.cydw AS "cydw",
        a.cyrlxdh AS "cyrlxdh",
        a.ywdjsj AS "ywdjsj",
        a.lspz AS "lspz",
        b_4.enumName AS "lspz_value",
        a.cph AS "cph",
        a.slr AS "slr",
        a.cyr AS "cyr",
        a.DataID AS "DataID"
        FROM
        DATA_CRKYW_RMDJ_DEFAULT a
        LEFT JOIN basic_enum b_4 ON  a.lspz = b_4.enumId
        WHERE
        ifnull(
        a.SytelInfoID,
        ''
        ) = '402881476395411d016396360bd70003'
        AND a.PeriodID = '11'
        AND a.RoundId = 0
        <if test="ew.sqlSegment != null and ew.sqlSegment != ''">
            and ${ew.sqlSegment}
        </if>
    </select>
    <select id="getOne" resultType="java.util.Map">
        SELECT
        a.lspz AS "lspz",
        a.cllx AS "cllx",
        a.cchlx AS "cchlx",
        a.cd AS "cd",
        a.cyrlxdz AS "cyrlxdz",
        a.jhdbh AS "jhdbh",
        a.rkywlx AS "rkywlx",
        a.slrsfzh AS "slrsfzh",
        a.mxpz AS "mxpz",
        a.slrdz AS "slrdz",
        a.slrdh AS "slrdh",
        a.htbh AS "htbh",
        a.cph AS "cph",
        a.tzdbh AS "tzdbh",
        a.jhfl AS "jhfl",
        a.nrchID AS "nrchID",
        a.fhdw AS "fhdw",
        a.ywdjsj AS "ywdjsj",
        a.nrhwID AS "nrhwID",
        a.cyr AS "cyr",
        a.tzdID AS "tzdID",
        a.hfyhhb AS "hfyhhb",
        a.rcsj AS "rcsj",
        a.nrchbh AS "nrchbh",
        a.cydw AS "cydw",
        a.lydj AS "lydj",
        a.cyrsfzh AS "cyrsfzh",
        a.cyrlxdh AS "cyrlxdh",
        a.BizNo AS "BizNo",
        a.skr AS "skr",
        a.scnf AS "scnf",
        a.djr AS "djr",
        a.hhyhmc AS "hhyhmc",
        a.clzbzl AS "clzbzl",
        a.tzdcbid AS "tzdcbid",
        a.yhkh AS "yhkh",
        a.lsxz AS "lsxz",
        a.slr AS "slr",
        a.DataID AS "DataID"
        FROM
        DATA_CRKYW_RMDJ_DEFAULT a
        <where>
            <if test='id != null and id != ""'>
                 a.DataID = #{id}
            </if>
            <if test='bizNo != null and bizNo != ""'>
                and a.bizNo = #{bizNo}
            </if>
        </where>
    </select>
</mapper>