Blame view

parking-module-order/src/main/resources/mybatis/mapper/smapper/OrderEtcSMapper.xml 3.45 KB
55f68655   王彪总   新项目
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
  <?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.zteits.order.mapper.smapper.OrderEtcSMapper">
      <resultMap id="BaseResultMap" type="com.zteits.order.domain.OrderEtc">
          <id column="id" jdbcType="BIGINT" property="id"/>
          <result column="park_ser_no" jdbcType="VARCHAR" property="parkSerNo"/>
          <result column="entry_time" jdbcType="TIMESTAMP" property="entryTime"/>
          <result column="entrance_no" jdbcType="VARCHAR" property="entranceNo"/>
          <result column="out_time" jdbcType="TIMESTAMP" property="outTime"/>
          <result column="exit_no" jdbcType="VARCHAR" property="exitNo"/>
          <result column="vehplate_no" jdbcType="VARCHAR" property="vehplateNo"/>
          <result column="vehcolor_code" jdbcType="VARCHAR" property="vehcolorCode"/>
          <result column="parking_time" jdbcType="BIGINT" property="parkingTime"/>
          <result column="bill_amount" jdbcType="BIGINT" property="billAmount"/>
          <result column="manufactor" jdbcType="INTEGER" property="manufactor"/>
          <result column="status" jdbcType="INTEGER" property="status"/>
          <result column="batch_undo" jdbcType="INTEGER" property="batchUndo"/>
          <result column="remarks" jdbcType="VARCHAR" property="remarks"/>
          <result column="undo_remarks" jdbcType="VARCHAR" property="undoRemarks"/>
          <result column="data_state" jdbcType="INTEGER" property="dataState"/>
          <result column="create_emp_id" jdbcType="VARCHAR" property="createEmpId"/>
          <result column="create_emp_name" jdbcType="VARCHAR" property="createEmpName"/>
          <result column="create_date" jdbcType="TIMESTAMP" property="createDate"/>
          <result column="modfiy_emp_id" jdbcType="VARCHAR" property="modfiyEmpId"/>
          <result column="modfiy_emp_name" jdbcType="VARCHAR" property="modfiyEmpName"/>
          <result column="modfiy_date" jdbcType="TIMESTAMP" property="modfiyDate"/>
          <result column="org_id" jdbcType="BIGINT" property="orgId"/>
          <result column="org_name" jdbcType="VARCHAR" property="orgName"/>
          <result column="pl_no" jdbcType="VARCHAR" property="plNo"/>
          <result column="pl_name" jdbcType="VARCHAR" property="plName"/>
      </resultMap>
  
      <sql id="Base_Column_List">
          id, park_ser_no, entry_time, entrance_no, out_time, exit_no, vehplate_no, vehcolor_code,
          parking_time, bill_amount, manufactor, status, batch_undo, remarks, undo_remarks,
          data_state, create_emp_id, create_emp_name, create_date, modfiy_emp_id, modfiy_emp_name,
          modfiy_date, org_id, org_name, pl_no, pl_name
      </sql>
  
      <select id="getSubmitSuccessEtcOrder" parameterType="com.zteits.clouds.api.dto.order.etc.param.EtcQueryReq"
              resultMap="BaseResultMap">
          SELECT
          <include refid="Base_Column_List"/>
          FROM order_etc
          <where>
              status = 1
              AND batch_undo = 0
              <if test="startDate != null">
                  <![CDATA[AND out_time >= #{startDate}]]>
              </if>
              <if test="endDate != null">
                  <![CDATA[AND out_time <= #{endDate}]]>
              </if>
              <if test="vehplateNo != null">
                  <![CDATA[AND vehplate_no = #{vehplateNo}]]>
              </if>
              <if test="vehcolorCode != null">
                  <![CDATA[AND vehcolor_code = #{vehcolorCode}]]>
              </if>
          </where>
      </select>
  </mapper>