Radio sonde on map
This commit is contained in:
@@ -14,7 +14,13 @@ export async function getSondes() {
|
|||||||
|
|
||||||
sondeCache = Object.entries(data).map(([id, sonde]) => {
|
sondeCache = Object.entries(data).map(([id, sonde]) => {
|
||||||
const t = sonde.latest_telem ?? {};
|
const t = sonde.latest_telem ?? {};
|
||||||
const path = sonde.path ?? [];
|
|
||||||
|
const history = (sonde.path ?? []).map(([latitude, longitude, altitude]) => ({
|
||||||
|
id,
|
||||||
|
latitude,
|
||||||
|
longitude,
|
||||||
|
altitude
|
||||||
|
}));
|
||||||
|
|
||||||
return {
|
return {
|
||||||
id,
|
id,
|
||||||
@@ -45,7 +51,7 @@ export async function getSondes() {
|
|||||||
ref_datetime: t.ref_datetime,
|
ref_datetime: t.ref_datetime,
|
||||||
ref_position: t.ref_position,
|
ref_position: t.ref_position,
|
||||||
sdr_device_idx: t.sdr_device_idx,
|
sdr_device_idx: t.sdr_device_idx,
|
||||||
history: path
|
history
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user