Commit 3b935d5f authored by zhangsen's avatar zhangsen

bug

parent 3dd5ee65
......@@ -42,23 +42,25 @@
<select id="selectPageData" resultType="com.yeejoin.amos.boot.module.hygf.api.dto.JpCollectorDto">
select
state,
sn_code,
station_name,
update_time,
type
hjc.state,
hjc.sn_code,
sta.station_name,
hjc.update_time,
hjc.type as collectorType,
sta.name,
sta.type
from
hygf_jp_collector hjc
left join hygf_jp_station sta on sta.third_station_id = hjc.third_station_id
<where>
<if test="dto.snCode != null and dto.snCode != ''">
sn_code = #{dto.snCode}
hjc.sn_code = #{dto.snCode}
</if>
<if test="dto.type != null and dto.type !=''">
type = #{dto.type}
hjc.type = #{dto.type}
</if>
<if test="dto.state != null and dto.state !=''">
state = #{dto.state}
hjc.state = #{dto.state}
</if>
</where>
limit #{current},#{size}
......@@ -66,23 +68,19 @@
<select id="selectPageDataTota" resultType="int">
select
state,
sn_code,
station_name,
update_time,
type
count(1)
from
hygf_jp_collector hjc
left join hygf_jp_station sta on sta.third_station_id = hjc.third_station_id
<where>
<if test="dto.snCode != null and dto.snCode != ''">
sn_code = #{dto.snCode}
hjc.sn_code = #{dto.snCode}
</if>
<if test="dto.type != null and dto.type !=''">
type = #{dto.type}
hjc.type = #{dto.type}
</if>
<if test="dto.state != null and dto.state !=''">
state = #{dto.state}
hjc.state = #{dto.state}
</if>
</where>
</select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment