|
|
@@ -26,9 +26,7 @@
|
|
|
<sql id="Base_Column_List">
|
|
|
t.id,
|
|
|
t.line_id,
|
|
|
- t1.line_name,
|
|
|
t.substation_id,
|
|
|
- s.substation_name,
|
|
|
t.xingbie,
|
|
|
t.marker,
|
|
|
t.yylx,
|
|
|
@@ -157,18 +155,18 @@
|
|
|
sub.substation_name,
|
|
|
dict1.dict_label as xingbie_text,
|
|
|
dict2.dict_label as yylx_text,
|
|
|
- a.*
|
|
|
+ <include refid="Base_Column_List"/>
|
|
|
FROM
|
|
|
- base_jlgz a
|
|
|
+ base_jlgz t
|
|
|
LEFT JOIN base_line line ON a.line_id = line.line_id
|
|
|
LEFT JOIN base_substation sub ON a.substation_id = sub.substation_id
|
|
|
LEFT JOIN sys_dict_data dict1 ON (a.xingbie = dict1.dict_value AND dict1.dict_type = 'xingbie')
|
|
|
LEFT JOIN sys_dict_data dict2 ON (a.yylx = dict2.dict_value AND dict2.dict_type = 'gzyy')
|
|
|
WHERE
|
|
|
- a.del_flag = '0'
|
|
|
+ t.del_flag = '0'
|
|
|
AND line.del_flag = '0'
|
|
|
AND sub.del_flag = '0'
|
|
|
- AND a.id = #{id}
|
|
|
+ AND t.id = #{id}
|
|
|
</select>
|
|
|
|
|
|
<select id="getList" resultMap="BaseResultMap">
|
|
|
@@ -177,56 +175,56 @@
|
|
|
sub.substation_name,
|
|
|
dict1.dict_label as xingbie_text,
|
|
|
dict2.dict_label as yylx_text,
|
|
|
- a.*
|
|
|
+ <include refid="Base_Column_List"/>
|
|
|
FROM
|
|
|
- base_jlgz a
|
|
|
- LEFT JOIN base_line line ON a.line_id = line.line_id
|
|
|
- LEFT JOIN base_substation sub ON a.substation_id = sub.substation_id
|
|
|
- LEFT JOIN sys_dict_data dict1 ON (a.xingbie = dict1.dict_value AND dict1.dict_type = 'xingbie')
|
|
|
- LEFT JOIN sys_dict_data dict2 ON (a.yylx = dict2.dict_value AND dict2.dict_type = 'gzyy')
|
|
|
+ base_jlgz t
|
|
|
+ LEFT JOIN base_line line ON t.line_id = line.line_id
|
|
|
+ LEFT JOIN base_substation sub ON t.substation_id = sub.substation_id
|
|
|
+ LEFT JOIN sys_dict_data dict1 ON (t.xingbie = dict1.dict_value AND dict1.dict_type = 'xingbie')
|
|
|
+ LEFT JOIN sys_dict_data dict2 ON (t.yylx = dict2.dict_value AND dict2.dict_type = 'gzyy')
|
|
|
<where>
|
|
|
- a.del_flag = '0'
|
|
|
+ t.del_flag = '0'
|
|
|
AND line.del_flag = '0'
|
|
|
AND sub.del_flag = '0'
|
|
|
<if test="lineId!=null and lineId!=''">
|
|
|
- and a.line_id=#{lineId}
|
|
|
+ and t.line_id=#{lineId}
|
|
|
</if>
|
|
|
<if test="substationId!=null and substationId!=''">
|
|
|
- and a.substation_id=#{substationId}
|
|
|
+ and t.substation_id=#{substationId}
|
|
|
</if>
|
|
|
<if test="xingbie!=null and xingbie!=''">
|
|
|
- and a.xingbie=#{xingbie}
|
|
|
+ and t.xingbie=#{xingbie}
|
|
|
</if>
|
|
|
<if test="marker!=null and marker!=''">
|
|
|
- and a.marker=#{marker}
|
|
|
+ and t.marker=#{marker}
|
|
|
</if>
|
|
|
<if test="yylx!=null and yylx!=''">
|
|
|
- and a.yylx=#{yylx}
|
|
|
+ and t.yylx=#{yylx}
|
|
|
</if>
|
|
|
<if test="operationDate!=null and operationDate!=''">
|
|
|
- and a.operation_date=#{operationDate}
|
|
|
+ and t.operation_date=#{operationDate}
|
|
|
</if>
|
|
|
<if test="gzms!=null and gzms!=''">
|
|
|
- and a.gzms=#{gzms}
|
|
|
+ and t.gzms=#{gzms}
|
|
|
</if>
|
|
|
<if test="createBy!=null and createBy!=''">
|
|
|
- and a.create_by=#{createBy}
|
|
|
+ and t.create_by=#{createBy}
|
|
|
</if>
|
|
|
<if test="createTime!=null and createTime!=''">
|
|
|
- and a.create_time=#{createTime}
|
|
|
+ and t.create_time=#{createTime}
|
|
|
</if>
|
|
|
<if test="updateBy!=null and updateBy!=''">
|
|
|
- and a.update_by=#{updateBy}
|
|
|
+ and t.update_by=#{updateBy}
|
|
|
</if>
|
|
|
<if test="updateTime!=null and updateTime!=''">
|
|
|
- and a.update_time=#{updateTime}
|
|
|
+ and t.update_time=#{updateTime}
|
|
|
</if>
|
|
|
<if test="delFlag!=null and delFlag!=''">
|
|
|
- and a.del_flag=#{delFlag}
|
|
|
+ and t.del_flag=#{delFlag}
|
|
|
</if>
|
|
|
</where>
|
|
|
<!-- <if test="orderBy!=null and orderBy!=''">
|
|
|
- order by a.${orderBy}
|
|
|
+ order by t.${orderBy}
|
|
|
</if>
|
|
|
<if test="isAsc!=null and isAsc!=''">
|
|
|
<if test="isAsc == '1'.toString()">
|
|
|
@@ -248,24 +246,24 @@
|
|
|
sub.substation_name,
|
|
|
dict1.dict_label as xingbie_text,
|
|
|
dict2.dict_label as yylx_text,
|
|
|
- a.*
|
|
|
- FROM base_jlgz a
|
|
|
- LEFT JOIN base_line line ON a.line_id = line.line_id
|
|
|
- LEFT JOIN base_substation sub ON a.substation_id = sub.substation_id
|
|
|
- LEFT JOIN sys_dict_data dict1 ON (a.xingbie = dict1.dict_value AND dict1.dict_type = 'xingbie')
|
|
|
- LEFT JOIN sys_dict_data dict2 ON (a.yylx = dict2.dict_value AND dict2.dict_type = 'gzyy')
|
|
|
- WHERE a.del_flag = '0'
|
|
|
+ <include refid="Base_Column_List"/>
|
|
|
+ FROM base_jlgz t
|
|
|
+ LEFT JOIN base_line line ON t.line_id = line.line_id
|
|
|
+ LEFT JOIN base_substation sub ON t.substation_id = sub.substation_id
|
|
|
+ LEFT JOIN sys_dict_data dict1 ON (t.xingbie = dict1.dict_value AND dict1.dict_type = 'xingbie')
|
|
|
+ LEFT JOIN sys_dict_data dict2 ON (t.yylx = dict2.dict_value AND dict2.dict_type = 'gzyy')
|
|
|
+ WHERE t.del_flag = '0'
|
|
|
AND line.del_flag = '0'
|
|
|
AND sub.del_flag = '0'
|
|
|
) D,
|
|
|
(
|
|
|
SELECT distinct zzdzxx.marker
|
|
|
- FROM base_zzdzxx zzdzxx,
|
|
|
+ FROM base_pillar zzdzxx,
|
|
|
(
|
|
|
SELECT zz.id,
|
|
|
zz.pillar_code,
|
|
|
zz.marker
|
|
|
- FROM base_zzdzxx zz
|
|
|
+ FROM base_pillar zz
|
|
|
WHERE 1 = 1
|
|
|
<if test="query.lineId != null and query.lineId != ''">
|
|
|
AND zz.line_id = #{query.lineId}
|