|
@ -1925,8 +1925,10 @@ public class SecurityMonitoringOrderService extends BaseJpaService<SecurityMonit
|
|
Double lat = locationTmp.getJSONArray("coordinates").getDouble(1);
|
|
Double lat = locationTmp.getJSONArray("coordinates").getDouble(1);
|
|
if (!response.getBoolean("online")) {//设备离线 取居民表定位
|
|
if (!response.getBoolean("online")) {//设备离线 取居民表定位
|
|
result.put("X1online", false);
|
|
result.put("X1online", false);
|
|
|
|
result.put("contactStatus", 0);
|
|
} else {
|
|
} else {
|
|
result.put("X1online", true);
|
|
result.put("X1online", true);
|
|
|
|
result.put("contactStatus", 1);
|
|
}
|
|
}
|
|
JSONObject tmp = gpsUtil.gcj02_To_Bd09(lat, lon);
|
|
JSONObject tmp = gpsUtil.gcj02_To_Bd09(lat, lon);
|
|
tmp.put("city", response.getString("last_city"));
|
|
tmp.put("city", response.getString("last_city"));
|
|
@ -2114,6 +2116,14 @@ public class SecurityMonitoringOrderService extends BaseJpaService<SecurityMonit
|
|
sleepInfo.put("sleepPlan", false);
|
|
sleepInfo.put("sleepPlan", false);
|
|
}
|
|
}
|
|
sleepInfo.put("online", tmp.getBooleanValue("online"));
|
|
sleepInfo.put("online", tmp.getBooleanValue("online"));
|
|
|
|
if(tmp.getBooleanValue("online")){
|
|
|
|
sleepInfo.put("contactStatus", 1);
|
|
|
|
}
|
|
|
|
else {
|
|
|
|
sleepInfo.put("contactStatus", 0);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (tmp.getBooleanValue("onbed")) {
|
|
if (tmp.getBooleanValue("onbed")) {
|
|
sleepInfo.put("bedStatus", 1);
|
|
sleepInfo.put("bedStatus", 1);
|
|
sleepInfo.put("heartRate", tmp.getString("heartrate"));
|
|
sleepInfo.put("heartRate", tmp.getString("heartrate"));
|