MQyxxMapper.xml
3.53 KB
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
<?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.hotent.lpg.manage.dao.MQyxxDao">
<!-- 通用查询映射结果 -->
<resultMap id="BaseResultMap" type="com.hotent.lpg.common.model.WQyxx">
<id column="ID_" property="id" />
<result column="REF_ID_" property="refId" />
<result column="F_qymc" property="fQymc" />
<result column="F_qyjc" property="fQyjc" />
<result column="F_tyshxydm" property="fTyshxydm" />
<result column="F_qylx" property="fQylx" />
<result column="F_qydz" property="fQydz" />
<result column="F_jd" property="fJd" />
<result column="F_wd" property="fWd" />
<result column="F_zczj" property="fZczj" />
<result column="F_jyfg" property="fJyfg" />
<result column="F_jyqy" property="fJyqy" />
<result column="F_qyfr" property="fQyfr" />
<result column="F_qyfrdh" property="fQyfrdh" />
<result column="F_zjlxm" property="fZjlxm" />
<result column="F_zjldh" property="fZjldh" />
<result column="F_gwlc" property="fGwlc" />
<result column="F_cqnl" property="fCqnl" />
<result column="F_zt" property="fZt" />
<result column="F_cjr" property="fCjr" />
<result column="F_gxr" property="fGxr" />
<result column="F_form_data_rev_" property="fFormDataRev" />
<result column="F_cjsj" property="fCjsj" />
<result column="F_zcsj" property="fZcsj" />
<result column="F_gxsj" property="fGxsj" />
</resultMap>
<resultMap id="qyxxMap" type="com.hotent.lpg.manage.vo.QyxxVO">
<result column="qyId" property="qyId" />
<result column="qymc" property="qymc" />
</resultMap>
<resultMap id="qyxxMap1" extends="qyxxMap" type="com.hotent.lpg.manage.vo.QyxxVO">
<collection property="qzxxList" ofType="com.hotent.lpg.manage.vo.QzxxVO"
select="com.hotent.lpg.dao.WCzxxDao.listByQyId"
column="{qyId = qyId}">
</collection>
</resultMap>
<!-- 通用查询结果列 -->
<sql id="Base_Column_List">
ID_,
REF_ID_,
F_qymc,
F_qyjc,
F_tyshxydm,
F_qylx,
F_qydz,
F_jd,
F_wd,
F_zczj,
F_jyfg,
F_jyqy,
F_qyfr,
F_qyfrdh,
F_zjlxm,
F_zjldh,
F_gwlc,
F_cqnl,
F_zt,
F_cjr,
F_gxr,
F_form_data_rev_,
F_cjsj,
F_zcsj,
F_gxsj
</sql>
<select id="selectPage" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from
w_qyxx
${ew.customSqlSegment}
</select>
<select id="selectList" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from
w_qyxx
${ew.customSqlSegment}
</select>
<select id="selectById" resultMap="BaseResultMap">
select
<include refid="Base_Column_List"/>
from
w_qyxx
where
ID_ = #{id}
</select>
<select id="qyList" resultMap="qyxxMap1">
select
w_qyxx.ID_ as qyId,
w_qyxx.F_qymc as qymc
from w_qyxx w_qyxx
where 1 = 1
<if test="list != null and list.size() > 0 ">
and w_qyxx.ID_ in
<foreach collection="list" item="id" open="(" close=")" separator=",">
#{id}
</foreach>
</if>
</select>
</mapper>