Dodano możliwość zmieniania posterunków w przeglądzie RJ

This commit is contained in:
2020-11-14 21:30:28 +01:00
parent 0c52ba43c8
commit df33b557d7
7 changed files with 566 additions and 174 deletions
+8 -1
View File
@@ -202,7 +202,14 @@ export default class StationTable extends styleMixin {
@Prop() readonly changeSorter!: () => void;
setScenery(sceneryHash: string) {
this.$router.push({ name: "SceneryView", query: { hash: sceneryHash } })
if (
this.stations.findIndex(
(station) => station.stationHash === sceneryHash && station.online
) == -1
)
return;
this.$router.push({ name: "SceneryView", query: { hash: sceneryHash } });
}
icons: { ascSVG; descSVG } = { ascSVG, descSVG };