mirror of
https://github.com/Spythere/stacjownik.git
synced 2026-05-04 05:48:11 +00:00
Fix błędów z reaktywnością danych
This commit is contained in:
@@ -71,19 +71,16 @@ export default defineComponent({
|
||||
const filterManager = reactive(new StationFilterManager());
|
||||
const focusedStationName = '';
|
||||
|
||||
const computedStations: ComputedRef<Station[]> = computed(() => {
|
||||
return filterManager.getFilteredStationList(store.stationList);
|
||||
});
|
||||
|
||||
const focusedStationInfo = computed(() =>
|
||||
computedStations.value.find((station) => station.name === focusedStationName)
|
||||
const computedStations: ComputedRef<Station[]> = computed(() =>
|
||||
filterManager
|
||||
.getFilteredStationList(store.stationList)
|
||||
.filter((station) => !station.onlineInfo || station.onlineInfo.region == store.region.id)
|
||||
);
|
||||
|
||||
return {
|
||||
computedStations,
|
||||
filterManager,
|
||||
focusedStationName,
|
||||
focusedStationInfo,
|
||||
};
|
||||
},
|
||||
mounted() {
|
||||
|
||||
Reference in New Issue
Block a user