|
@@ -12,26 +12,25 @@
|
|
|
a.id AS id
|
|
|
FROM
|
|
|
base_camera_management AS a inner join
|
|
|
- base_railway_management AS l on a.railway_code=l.railway_code
|
|
|
+ base_railway_management AS l on a.railway_code = l.railway_code
|
|
|
<where>
|
|
|
<if test="railwayCode != null and railwayCode !=''">
|
|
|
- concat(l.railway_name,a.camera_code)
|
|
|
- like concat("%",#{railwayCode},"%")
|
|
|
+ and concat(l.railway_name,a.camera_code) like concat("%",#{railwayCode},"%")
|
|
|
</if>
|
|
|
<if test="lineDir != null and lineDir != ''">
|
|
|
- line_dir = #{lineDir}
|
|
|
+ and line_dir = #{lineDir}
|
|
|
</if>
|
|
|
<if test="mils != null and mils != ''">
|
|
|
- concat(a.install_mile, a.begin_mile, a.end_mile) = #{mils}
|
|
|
+ and (a.install_mile = #{mils} or a.begin_mile = #{mils} or a.end_mile = #{mils})
|
|
|
</if>
|
|
|
<if test="!dsFlay">
|
|
|
and
|
|
|
<trim prefix="(" prefixOverrides="or" suffix=")">
|
|
|
<if test="dsUserId != null and dsUserId != ''">
|
|
|
- or a.create_by=#{dsUserId}
|
|
|
+ or a.create_by = #{dsUserId}
|
|
|
</if>
|
|
|
<if test="dsDeptId != null and dsDeptId != 0">
|
|
|
- or a.dept_id=#{dsDeptId}
|
|
|
+ or a.dept_id = #{dsDeptId}
|
|
|
</if>
|
|
|
<if test="dsDeptIds != null">
|
|
|
or a.dept_id in
|