Commit 55747c41 authored by 赵啸非's avatar 赵啸非

修改设备新增

parent b535087e
...@@ -76,6 +76,7 @@ public class UploadTask implements Runnable { ...@@ -76,6 +76,7 @@ public class UploadTask implements Runnable {
deviceEntity.setOnlineTime(new Date()); deviceEntity.setOnlineTime(new Date());
deviceEntity.setDeviceOnlineStatus(DeviceOnlineStatusEnum.在线.getValue()); deviceEntity.setDeviceOnlineStatus(DeviceOnlineStatusEnum.在线.getValue());
deviceEntity.setIp(req.getIp()); deviceEntity.setIp(req.getIp());
deviceEntity.setDeviceType(req.getType());
deviceEntity.setPort(req.getPort()); deviceEntity.setPort(req.getPort());
deviceEntity.setSiteNum(req.getSitenum()); deviceEntity.setSiteNum(req.getSitenum());
deviceEntity.setCenternum(req.getCenternum()); deviceEntity.setCenternum(req.getCenternum());
......
...@@ -92,7 +92,7 @@ public class DeviceStatTaskImpl implements ITaskExcuteService { ...@@ -92,7 +92,7 @@ public class DeviceStatTaskImpl implements ITaskExcuteService {
*/ */
private void doDeviceLogDel() { private void doDeviceLogDel() {
//默认保存30天日志 //默认保存30天日志
int timeout = -GlobalSysInfo.getParamIntValue(ParamKey.SYS_PARAM_LOG_TIME, 30); int timeout = -GlobalSysInfo.getParamIntValue(ParamKey.SYS_PARAM_LOG_TIME, 15);
try { try {
DeviceLogQuery query = new DeviceLogQuery(); DeviceLogQuery query = new DeviceLogQuery();
query.setCreateTimeEnd(DateUtils.getStrDateTime(DateUtils.addCurrDate(timeout))); query.setCreateTimeEnd(DateUtils.getStrDateTime(DateUtils.addCurrDate(timeout)));
...@@ -111,7 +111,6 @@ public class DeviceStatTaskImpl implements ITaskExcuteService { ...@@ -111,7 +111,6 @@ public class DeviceStatTaskImpl implements ITaskExcuteService {
* 定时查询更新其它设备状态 * 定时查询更新其它设备状态
*/ */
private void doDeviceQuery() { private void doDeviceQuery() {
try { try {
deviceService.getCacheList().parallelStream() deviceService.getCacheList().parallelStream()
.filter(f -> f.getDeviceSource() == DeviceSourceEnum.其它.getValue()) .filter(f -> f.getDeviceSource() == DeviceSourceEnum.其它.getValue())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment