From 7cfa09050726578c2cc5114e5bc8a419e6e2e466 Mon Sep 17 00:00:00 2001
From: fuliqi <fuliqi@qq.com>
Date: 星期二, 15 十月 2024 11:03:45 +0800
Subject: [PATCH] 人脸上传数据延迟修复
---
ycl-server/src/main/java/com/ycl/platform/service/impl/DataCenterServiceImpl.java | 38 +++++++++++++++++++-------------------
1 files changed, 19 insertions(+), 19 deletions(-)
diff --git a/ycl-server/src/main/java/com/ycl/platform/service/impl/DataCenterServiceImpl.java b/ycl-server/src/main/java/com/ycl/platform/service/impl/DataCenterServiceImpl.java
index 763e007..4dded27 100644
--- a/ycl-server/src/main/java/com/ycl/platform/service/impl/DataCenterServiceImpl.java
+++ b/ycl-server/src/main/java/com/ycl/platform/service/impl/DataCenterServiceImpl.java
@@ -74,10 +74,10 @@
MongoUtil.setPage(query, params, TIME_FIELD);
List<TMonitorResult> resultList = mongoTemplate.find(query, TMonitorResult.class);
resultList.forEach(item->{
- if(null != item.getOnline() && item.getOnline()){
- item.setOnlineStr("鍦ㄧ嚎");
+ if(null != item.getPingOnline() && item.getPingOnline()){
+ item.setPingOnlineStr("鍦ㄧ嚎");
}else {
- item.setOnlineStr("绂荤嚎");
+ item.setPingOnlineStr("绂荤嚎");
}
});
params.setDeptTag(-1);
@@ -117,10 +117,10 @@
MongoUtil.setPage(query, params, TIME_FIELD);
List<TMonitorResult> resultList = mongoTemplate.find(query, TMonitorResult.class);
resultList.forEach(item->{
- if(null != item.getOnline() && item.getOnline()){
- item.setOnlineStr("鍦ㄧ嚎");
+ if(null != item.getPingOnline() && item.getPingOnline()){
+ item.setPingOnlineStr("鍦ㄧ嚎");
}else {
- item.setOnlineStr("绂荤嚎");
+ item.setPingOnlineStr("绂荤嚎");
}
});
// 缁熻璁惧鏁伴噺
@@ -165,10 +165,10 @@
// 缁熻璁惧鏁伴噺
Integer distinctCount = pointMapper.distinctCount(params);
resultList.forEach(item->{
- if(null != item.getOnline() && item.getOnline()){
- item.setOnlineStr("鍦ㄧ嚎");
+ if(null != item.getPingOnline() && item.getPingOnline()){
+ item.setPingOnlineStr("鍦ㄧ嚎");
}else {
- item.setOnlineStr("绂荤嚎");
+ item.setPingOnlineStr("绂荤嚎");
}
});
Date now = new Date();
@@ -209,10 +209,10 @@
// 缁熻璁惧鏁伴噺
Integer distinctCount = pointMapper.distinctCount(params);
resultList.forEach(item->{
- if(null != item.getOnline() && item.getOnline()){
- item.setOnlineStr("鍦ㄧ嚎");
+ if(null != item.getPingOnline() && item.getPingOnline()){
+ item.setPingOnlineStr("鍦ㄧ嚎");
}else {
- item.setOnlineStr("绂荤嚎");
+ item.setPingOnlineStr("绂荤嚎");
}
});
Date now = new Date();
@@ -912,24 +912,24 @@
//鍒嗛〉鏁伴噺
long total = mongoTemplate.count(query, TMonitorResult.class);
MongoUtil.setPage(query, params, TIME_FIELD);
+ //绯荤粺ping鐨勭粨鏋�
List<TMonitorResult> resultList = mongoTemplate.find(query, TMonitorResult.class);
-
+ //TODO锛氫紭浜戝湪绾跨粨鏋�
params.setDeptTag(-1);
params.setDeviceType(2);
// 缁熻璁惧鏁伴噺
Integer distinctCount = pointMapper.distinctCount(params);
resultList.forEach(item->{
- if(null != item.getOnline() && item.getOnline()){
- item.setOnlineStr("鍦ㄧ嚎");
+ if(null != item.getPingOnline() && item.getPingOnline()){
+ item.setPingOnlineStr("鍦ㄧ嚎");
}else {
- item.setOnlineStr("绂荤嚎");
+ item.setPingOnlineStr("绂荤嚎");
}
});
- Date now = new Date();
List<CheckIndexCar> videoList = new LambdaQueryChainWrapper<>(checkIndexCarService.getBaseMapper())
.select(CheckIndexCar::getSiteOnline)
.eq(params.getDataType().equals(1), CheckIndexCar::getExamineTag, CheckConstants.Examine_Tag_Province)
- .between(CheckIndexCar::getCreateTime, DateUtils.getDayStart(now), DateUtils.getDayEnd(now))
+ .between(CheckIndexCar::getCreateTime, DateUtils.getDayStart(params.getStartTime()), DateUtils.getDayEnd(params.getEndTime()))
.list();
BigDecimal onlineRate = BigDecimal.ZERO;
if (CollectionUtils.isNotEmpty(videoList)) {
@@ -1422,7 +1422,7 @@
MongoUtil.setPage(query, params, TIME_FIELD);
List<TMonitorResult> resultList = mongoTemplate.find(query, TMonitorResult.class);
resultList.forEach(item->{
- if(null != item.getOnline() && item.getOnline()){
+ if(null != item.getPingOnline() && item.getPingOnline()){
item.setOnlineStr("鍦ㄧ嚎");
}else {
item.setOnlineStr("绂荤嚎");
--
Gitblit v1.8.0