perf: reduce ref update times
This commit is contained in:
@@ -68,7 +68,8 @@ export function useLineDevicesQuery() {
|
||||
if (!lineDevices.value[station.code]) {
|
||||
lineDevices.value[station.code] = createEmptyStationDevices();
|
||||
}
|
||||
const stationDevices = lineDevices.value[station.code];
|
||||
// const stationDevices = lineDevices.value[station.code];
|
||||
const stationDevices = createEmptyStationDevices();
|
||||
|
||||
await Promise.allSettled([
|
||||
postNdmCameraPage(station.code, pageQuery, signal)
|
||||
@@ -144,6 +145,8 @@ export function useLineDevicesQuery() {
|
||||
stationDevices[DeviceType.VideoServer] = [];
|
||||
}),
|
||||
]);
|
||||
|
||||
lineDevices.value[station.code] = stationDevices;
|
||||
}
|
||||
|
||||
// console.timeEnd('useLineDevicesQuery');
|
||||
|
||||
Reference in New Issue
Block a user