|
|
@ -1,5 +1,6 @@ |
|
|
package com.dongjian.dashboard.back.service.impl; |
|
|
package com.dongjian.dashboard.back.service.impl; |
|
|
|
|
|
|
|
|
|
|
|
import com.alibaba.fastjson2.JSONObject; |
|
|
import com.dongjian.dashboard.back.bo.LatestValueBO; |
|
|
import com.dongjian.dashboard.back.bo.LatestValueBO; |
|
|
import com.dongjian.dashboard.back.common.Constants; |
|
|
import com.dongjian.dashboard.back.common.Constants; |
|
|
import com.dongjian.dashboard.back.common.language.msg.MsgLanguageChange; |
|
|
import com.dongjian.dashboard.back.common.language.msg.MsgLanguageChange; |
|
|
@ -199,7 +200,7 @@ public class DeviceDataBaStatusServiceImpl implements DeviceDataBaStatusService |
|
|
Object cacheLastValue = redisUtil.HGet(redisKey, lineDataSearchParams.getDeviceId().toLowerCase()); |
|
|
Object cacheLastValue = redisUtil.HGet(redisKey, lineDataSearchParams.getDeviceId().toLowerCase()); |
|
|
if (null != cacheLastValue) { |
|
|
if (null != cacheLastValue) { |
|
|
try { |
|
|
try { |
|
|
LatestValueBO latestValueBO = objectMapper.readValue(cacheLastValue.toString(), LatestValueBO.class); |
|
|
LatestValueBO latestValueBO = objectMapper.readValue(JSONObject.toJSONString(cacheLastValue), LatestValueBO.class); |
|
|
String dateFormatted = Instant.ofEpochMilli(latestValueBO.getUpdateTs()) |
|
|
String dateFormatted = Instant.ofEpochMilli(latestValueBO.getUpdateTs()) |
|
|
.atZone(Constants.ZONE_TOKYO) |
|
|
.atZone(Constants.ZONE_TOKYO) |
|
|
.format(Constants.FORMATTER_YMDHMS); |
|
|
.format(Constants.FORMATTER_YMDHMS); |
|
|
|