1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?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="cn.flightfeather.supervision.domain.ds2.mapper.LedgerRecordMapper" >
  <resultMap id="BaseResultMap" type="cn.flightfeather.supervision.domain.ds2.entity.LedgerRecord" >
    <!--
      WARNING - @mbg.generated
    -->
    <id column="LR_GUID" property="lrGuid" jdbcType="VARCHAR" />
    <result column="LS_SubTypeId" property="lsSubtypeid" jdbcType="INTEGER" />
    <result column="LS_SubTypeName" property="lsSubtypename" jdbcType="VARCHAR" />
    <result column="LR_Year" property="lrYear" jdbcType="INTEGER" />
    <result column="LR_Month" property="lrMonth" jdbcType="TINYINT" />
    <result column="LR_Day" property="lrDay" jdbcType="TINYINT" />
    <result column="CI_GUID" property="ciGuid" jdbcType="VARCHAR" />
    <result column="CI_Name" property="ciName" jdbcType="VARCHAR" />
    <result column="LR_EASubmitKind" property="lrEasubmitkind" jdbcType="TINYINT" />
    <result column="LR_VerifierID" property="lrVerifierid" jdbcType="INTEGER" />
    <result column="LR_VerifierRealName" property="lrVerifierrealname" jdbcType="VARCHAR" />
    <result column="LR_VerifyDate" property="lrVerifydate" jdbcType="TIMESTAMP" />
    <result column="LR_IsVerify" property="lrIsverify" jdbcType="BIT" />
    <result column="LR_VerifyRst" property="lrVerifyrst" jdbcType="VARCHAR" />
    <result column="LR_AIVerifyTime" property="lrAiverifytime" jdbcType="INTEGER" />
    <result column="LR_AIIsVerify" property="lrAiisverify" jdbcType="BIT" />
    <result column="LR_AIVerifyRst" property="lrAiverifyrst" jdbcType="VARCHAR" />
    <result column="LR_IsAI" property="lrIsai" jdbcType="BIT" />
    <result column="LR_SubmitID" property="lrSubmitid" jdbcType="VARCHAR" />
    <result column="LR_SubmitName" property="lrSubmitname" jdbcType="VARCHAR" />
    <result column="LR_IsSubmitOnTime" property="lrIssubmitontime" jdbcType="BIT" />
    <result column="LR_SubmitDate" property="lrSubmitdate" jdbcType="TIMESTAMP" />
    <result column="LR_UpdateType" property="lrUpdatetype" jdbcType="TINYINT" />
    <result column="LR_Extension1" property="lrExtension1" jdbcType="VARCHAR" />
    <result column="LR_Extension2" property="lrExtension2" jdbcType="VARCHAR" />
    <result column="LR_Extension3" property="lrExtension3" jdbcType="VARCHAR" />
    <result column="LR_Remark" property="lrRemark" jdbcType="VARCHAR" />
  </resultMap>
  <sql id="Base_Column_List" >
    <!--
      WARNING - @mbg.generated
    -->
    LR_GUID, LS_SubTypeId, LS_SubTypeName, LR_Year, LR_Month, LR_Day, CI_GUID, CI_Name, 
    LR_EASubmitKind, LR_VerifierID, LR_VerifierRealName, LR_VerifyDate, LR_IsVerify, 
    LR_VerifyRst, LR_AIVerifyTime, LR_AIIsVerify, LR_AIVerifyRst, LR_IsAI, LR_SubmitID, 
    LR_SubmitName, LR_IsSubmitOnTime, LR_SubmitDate, LR_UpdateType, LR_Extension1, LR_Extension2, 
    LR_Extension3, LR_Remark
  </sql>
 
  <select id="selectByUser" resultMap="BaseResultMap">
    select *
    from ea_t_ledgerrecord
    where LR_SubmitID = #{param1} and LR_Year = #{param2} and LR_Month = #{param3}
    <if test="param4 != null">
      and LS_SubTypeId = #{param4}
    </if>
    <if test="param5 == 1">
      and (LR_Extension1 is null or LR_Extension1 = #{param5})
    </if>
    <if test="param5 != 0">
      and LR_Extension1 = #{param5}
    </if>
    <if test="param6 != null">
      limit #{param6}, #{param7}
    </if>
  </select>
</mapper>