mirror of
https://github.com/Spythere/station-manager-2.0.git
synced 2026-05-03 13:38:13 +00:00
asdek; hotfixy
This commit is contained in:
+1
-1
@@ -35,7 +35,7 @@ export default defineComponent({
|
||||
const response = await client.post<IUser>('/auth/token');
|
||||
|
||||
this.store.setUserData(response.data);
|
||||
this.$router.push('/');
|
||||
// this.$router.push('/');
|
||||
} catch (error) {
|
||||
this.store.removeUserData();
|
||||
this.$router.push('/login');
|
||||
|
||||
@@ -148,7 +148,7 @@ export default defineComponent({
|
||||
signalType: 'współczesna',
|
||||
controlType: 'SCS',
|
||||
SUP: false,
|
||||
routes: 'Test_1EPB:0:0',
|
||||
ASDEK: false,
|
||||
hidden: false,
|
||||
routesInfo: [
|
||||
{
|
||||
|
||||
+5
-1
@@ -20,6 +20,10 @@ router.beforeEach((to, from, next) => {
|
||||
return;
|
||||
}
|
||||
|
||||
if (to.meta.loginPage && window.localStorage.getItem('user')) {
|
||||
next('/');
|
||||
return;
|
||||
}
|
||||
|
||||
next();
|
||||
});
|
||||
|
||||
|
||||
+3
-1
@@ -10,6 +10,7 @@ export type ChangeProp =
|
||||
| 'signalType'
|
||||
| 'controlType'
|
||||
| 'SUP'
|
||||
| 'ASDEK'
|
||||
| 'routesInfo'
|
||||
| 'checkpoints'
|
||||
| 'authors'
|
||||
@@ -28,6 +29,7 @@ export enum HeaderTypes {
|
||||
signalType = 'Sygnalizacja',
|
||||
controlType = 'Sterowanie',
|
||||
SUP = 'SUP',
|
||||
ASDEK = 'ASDEK',
|
||||
authors = 'Autorzy',
|
||||
routesInfo = 'Szlaki',
|
||||
checkpoints = 'Posterunki',
|
||||
@@ -68,8 +70,8 @@ export interface SceneryRowItem {
|
||||
signalType: string;
|
||||
controlType: string;
|
||||
SUP: boolean;
|
||||
ASDEK: boolean;
|
||||
hidden: boolean;
|
||||
routes: string;
|
||||
routesInfo: SceneryRoutesInfo[];
|
||||
checkpoints: string;
|
||||
authors: string;
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
<tbody>
|
||||
<tr v-for="(station, row) in store.sortedStationList" tabindex="0">
|
||||
<td v-for="(value, propName) in headerNameList" @click="changeProperty(station, row, propName as string)" :class="propName">
|
||||
<td v-for="(_, propName) in headerNameList" @click="changeProperty(station, row, propName as string)" :class="propName">
|
||||
<span v-if="propName === 'url'" :style="station.url ? 'color: gold' : 'color: gray;'">URL</span>
|
||||
<span v-else-if="propName === 'projectUrl'" :style="station.projectUrl ? 'color: gold' : 'color: gray;'">URL</span>
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
<span v-else-if="typeof (station as any)[propName] === 'boolean'">
|
||||
{{ (station as any)[propName] ? '✅' : '❌' }}
|
||||
</span>
|
||||
|
||||
<span v-else>{{ (station as any)[propName] }}</span>
|
||||
</td>
|
||||
|
||||
@@ -85,6 +86,7 @@ export default defineComponent({
|
||||
signalType: 'Sygnalizacja',
|
||||
controlType: 'Sterowanie',
|
||||
SUP: 'SUP',
|
||||
ASDEK: 'ASDEK',
|
||||
authors: 'Autorzy',
|
||||
routes: 'Szlaki',
|
||||
checkpoints: 'Posterunki',
|
||||
|
||||
Reference in New Issue
Block a user