<?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.chinaweal.aiccs.aiccs.seriousillegal.mapper.TSBizSerIllegalDissMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.chinaweal.aiccs.aiccs.seriousillegal.entity.TSBizSerIllegalDiss">
        <id column="serIllegalDissID" property="serIllegalDissID" />
        <result column="illegalListID" property="illegalListID" />
        <result column="bizSeq" property="bizSeq" />
        <result column="priPID" property="priPID" />
        <result column="regNO" property="regNO" />
        <result column="entName" property="entName" />
        <result column="leRepName" property="leRepName" />
        <result column="contacts" property="contacts" />
        <result column="telephone" property="telephone" />
        <result column="situation" property="situation" />
        <result column="approvalDate" property="approvalDate" />
        <result column="acceptStat" property="acceptStat" />
        <result column="dissentExplain" property="dissentExplain" />
        <result column="area_code" property="areaCode" />
        <result column="lauptime" property="lauptime" />
        <result column="exmainematter" property="exmainematter" />
    </resultMap>

    <!-- 通用查询结果列 -->
    <sql id="Base_Column_List">
        serIllegalDissID, illegalListID, bizSeq, priPID, regNO, entName, leRepName, contacts, telephone, situation, approvalDate, acceptStat, dissentExplain, area_code, lauptime, exmainematter
    </sql>

    <select id="selectbizDissentList" parameterType="com.chinaweal.aiccs.aiccs.seriousillegal.entity.TSBizSerIllegalDiss" resultMap="BaseResultMap">
        select
        <include refid="Base_Column_List"/>
        from TSBizSerIllegalDiss
        <where>
            <if test="tsBizDissentModel.illegalListID!=null and tsBizDissentModel.illegalListID!=''">
                and illegalListID = #{tsBizDissentModel.illegalListID}
            </if>
            <if test="tsBizDissentModel.bizseq!=null and tsBizDissentModel.bizseq!=''">
                and bizseq = #{tsBizDissentModel.bizseq}
            </if>
            <if test="tsBizDissentModel.pripid!=null and tsBizDissentModel.pripid!=''">
                and pripid = #{tsBizDissentModel.pripid}
            </if>
            <if test="tsBizDissentModel.regno!=null and tsBizDissentModel.regno!=''">
                and regno = #{tsBizDissentModel.regno}
            </if>
        </where>
    </select>

    <select id="selectBizDissentByBizSeq" parameterType="java.lang.String" resultMap="BaseResultMap">
        select
        <include refid="Base_Column_List"/>
        from TSBizSerIllegalDiss where bizseq = #{bizseq,jdbcType=CHAR}
    </select>

</mapper>
