|
|
@ -90,9 +90,8 @@ async function list (ctx) { |
|
|
|
let alarmQueryOptionStr = ` |
|
|
|
FROM |
|
|
|
alarms |
|
|
|
${//LEFT JOIN DeviceStatus
|
|
|
|
//ON DeviceStatus.DeviceId = alarms.SourceId
|
|
|
|
''} |
|
|
|
LEFT JOIN DeviceStatus |
|
|
|
ON DeviceStatus.DeviceId = alarms.SourceId |
|
|
|
LEFT JOIN ${anxinyun}.t_structure |
|
|
|
ON ${anxinyun}.t_structure.id = alarms.StructureId |
|
|
|
LEFT JOIN ${anxinyun}.t_alarm_code |
|
|
@ -110,8 +109,7 @@ async function list (ctx) { |
|
|
|
SourceTypeId, |
|
|
|
AlarmAdviceProblem, AlarmGroup, AlarmGroupUnit, AlarmAdviceProblem, |
|
|
|
alarms.StructureId AS StructureId, |
|
|
|
${//`DeviceStatus.Status AS DeviceStatus,`
|
|
|
|
''} |
|
|
|
${`DeviceStatus.Status AS DeviceStatus,`} |
|
|
|
${anxinyun}.t_structure.name AS StructureName, |
|
|
|
${anxinyun}.t_structure.longitude AS StructureLongitude, |
|
|
|
${anxinyun}.t_structure.latitude AS StructureLatitude, |
|
|
|