|
@ -164,8 +164,6 @@ async function count (ctx) { |
|
|
alarms.StructureId IN (${anxinStrucIds.join(",")}) |
|
|
alarms.StructureId IN (${anxinStrucIds.join(",")}) |
|
|
AND |
|
|
AND |
|
|
StartTime BETWEEN '${moment().startOf('day').format('YYYY-MM-DD HH:mm:ss')}' AND '${moment().endOf('day').format('YYYY-MM-DD HH:mm:ss')}' |
|
|
StartTime BETWEEN '${moment().startOf('day').format('YYYY-MM-DD HH:mm:ss')}' AND '${moment().endOf('day').format('YYYY-MM-DD HH:mm:ss')}' |
|
|
AND |
|
|
|
|
|
State < 3 |
|
|
|
|
|
GROUP BY AlarmGroup |
|
|
GROUP BY AlarmGroup |
|
|
`).toPromise()
|
|
|
`).toPromise()
|
|
|
//今日新增数据告警
|
|
|
//今日新增数据告警
|
|
@ -228,7 +226,7 @@ async function count (ctx) { |
|
|
|
|
|
|
|
|
let dataAfter = new moment(); //验证后时间
|
|
|
let dataAfter = new moment(); //验证后时间
|
|
|
let dataduration = moment.duration(dataAfter.diff(dataFront))._data.milliseconds |
|
|
let dataduration = moment.duration(dataAfter.diff(dataFront))._data.milliseconds |
|
|
console.log('数据',dataduration); |
|
|
console.log('数据', dataduration); |
|
|
|
|
|
|
|
|
let yingyongFront = new moment(); //验证前时间
|
|
|
let yingyongFront = new moment(); //验证前时间
|
|
|
|
|
|
|
|
@ -250,7 +248,7 @@ async function count (ctx) { |
|
|
|
|
|
|
|
|
let yingyongAfter = new moment(); //验证后时间
|
|
|
let yingyongAfter = new moment(); //验证后时间
|
|
|
let yingyongduration = moment.duration(yingyongAfter.diff(yingyongFront))._data.milliseconds |
|
|
let yingyongduration = moment.duration(yingyongAfter.diff(yingyongFront))._data.milliseconds |
|
|
console.log('应用',yingyongduration); |
|
|
console.log('应用', yingyongduration); |
|
|
|
|
|
|
|
|
let videoFront = new moment(); //验证前时间
|
|
|
let videoFront = new moment(); //验证前时间
|
|
|
|
|
|
|
|
@ -364,7 +362,7 @@ async function count (ctx) { |
|
|
|
|
|
|
|
|
let videoAfter = new moment(); //验证后时间
|
|
|
let videoAfter = new moment(); //验证后时间
|
|
|
let videoduration = moment.duration(videoAfter.diff(videoFront))._data.milliseconds |
|
|
let videoduration = moment.duration(videoAfter.diff(videoFront))._data.milliseconds |
|
|
console.log('视频',videoduration); |
|
|
console.log('视频', videoduration); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
let findOptions = { |
|
|
let findOptions = { |
|
|