This commit is contained in:
parent
326bbe8296
commit
fc6255ded5
|
@ -83,7 +83,7 @@ public class OutSideServiceImpl implements OutSideService {
|
|||
if (rootNode.isArray()) {
|
||||
for (JsonNode node : rootNode) {
|
||||
SensorData sd = insertOldData(node);
|
||||
|
||||
|
||||
outSideMapper.insertDevice(sd);
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -242,8 +242,8 @@ select t.id,t. name,t.unit_no,t.system_no,t.status,t.sn,t.file_url,t.note,t.crea
|
|||
LEFT JOIN th_device_deal d ON th_device_report.id = d.report_id
|
||||
<where>
|
||||
(th_device_report.zt='一级报警' or th_device_report.zt='二级报警')
|
||||
<if test="deptId != null">
|
||||
and th_device_report.sn IN (
|
||||
<if test="deptId != null and deptId != 228">
|
||||
and th_device_report.sn IN (
|
||||
SELECT td.sn
|
||||
FROM th_device td
|
||||
LEFT JOIN sys_dept p ON td.dept_id = p.dept_id
|
||||
|
@ -330,7 +330,7 @@ select t.id,t. name,t.unit_no,t.system_no,t.status,t.sn,t.file_url,t.note,t.crea
|
|||
<if test="endTime != null">and report_time <= #{endTime,jdbcType=TIMESTAMP}</if>
|
||||
<if test="sn != null">and th_device_report.sn= #{sn}</if>
|
||||
<if test="name != null">and t.name like concat('%', #{name}, '%')</if>
|
||||
<if test="deptId != null">and t.dept_id IN
|
||||
<if test="deptId != null and deptId != 228">and t.dept_id IN
|
||||
(SELECT dept_id
|
||||
FROM sys_dept START WITH dept_id = #{deptId}
|
||||
CONNECT BY PRIOR dept_id = parent_id)</if>
|
||||
|
|
Loading…
Reference in New Issue