wuqun 2 years ago
parent
commit
a8b6d992a2
  1. 8
      api/app/lib/controllers/control/toolLink.js
  2. 4
      web/client/src/layout/containers/layout/index.jsx
  3. 3
      web/client/src/sections/control/containers/control.jsx

8
api/app/lib/controllers/control/toolLink.js

@ -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 = {

4
web/client/src/layout/containers/layout/index.jsx

@ -189,15 +189,17 @@ const LayoutContainer = props => {
} }
} }
const dom = document.getElementById('page-content'); const dom = document.getElementById('page-content');
setTimeout(() => {
if (dom) { if (dom) {
if (!scrollbar) { if (!scrollbar) {
scrollbar = new PerfectScrollbar('#page-content', { suppressScrollX: true }); scrollbar = new PerfectScrollbar('#page-content', { suppressScrollX: true });
scrollbar.update(); // scrollbar.update();
} else { } else {
scrollbar.update(); scrollbar.update();
dom.scrollTop = 0; dom.scrollTop = 0;
} }
} }
}, 300)
}) })

3
web/client/src/sections/control/containers/control.jsx

@ -235,6 +235,7 @@ const Control = (props) => {
let webtop = 0 let webtop = 0
let webId = document.getElementById('web'); let webId = document.getElementById('web');
if (web) clearInterval(web) if (web) clearInterval(web)
let memberId = document.getElementById('member');
if (memberId) { if (memberId) {
function webstart () { function webstart () {
member = setInterval(() => { member = setInterval(() => {
@ -1058,7 +1059,7 @@ const Control = (props) => {
text: v.name, text: v.name,
}, },
grid: { grid: {
left: '5%', left: '10%',
// right: '4%', // right: '4%',
// bottom: '3%', // bottom: '3%',
// containLabel: true // containLabel: true

Loading…
Cancel
Save