|
|
|
@ -165,11 +165,13 @@ public class DeviceDataBaStatusServiceImpl implements DeviceDataBaStatusService |
|
|
|
data.setStopRun(commonOpt.judgeStopRun(objectMapper, realtime85Map.get(deviceId))); |
|
|
|
} |
|
|
|
|
|
|
|
if (0 == data.getStopRun()) { |
|
|
|
data.setContinuousRunningTimeStr(SecondsToHMSConverter.covertSeconds(data.getContinuousRunningTime())); |
|
|
|
} else if (StringUtils.isNotBlank(data.getLatestTs()) && currentTs >= Long.parseLong(data.getLatestTs())) { |
|
|
|
long diff = currentTs - Long.parseLong(data.getLatestTs()); |
|
|
|
data.setContinuousRunningTimeStr(SecondsToHMSConverter.covertSeconds(diff)); |
|
|
|
if (null != data.getStopRun()) { |
|
|
|
if (0 == data.getStopRun()) { |
|
|
|
data.setContinuousRunningTimeStr(SecondsToHMSConverter.covertSeconds(data.getContinuousRunningTime())); |
|
|
|
} else if (StringUtils.isNotBlank(data.getLatestTs()) && currentTs >= Long.parseLong(data.getLatestTs())) { |
|
|
|
long diff = currentTs - Long.parseLong(data.getLatestTs()); |
|
|
|
data.setContinuousRunningTimeStr(SecondsToHMSConverter.covertSeconds(diff)); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|