mirror of
https://github.com/Spythere/station-manager-2.0.git
synced 2026-05-03 05:28:13 +00:00
feature: project URL
This commit is contained in:
+15
-9
@@ -85,27 +85,33 @@ body,
|
||||
html {
|
||||
padding: 0 0.25em;
|
||||
margin: 0;
|
||||
background-color: #1e263f;
|
||||
background-color: #1e2341;
|
||||
color: white;
|
||||
}
|
||||
|
||||
button {
|
||||
appearance: none;
|
||||
outline: none;
|
||||
border: none;
|
||||
|
||||
background-color: #151515;
|
||||
background-color: #000000;
|
||||
color: white;
|
||||
border: 1px solid white;
|
||||
|
||||
padding: 0.35rem 0.75rem;
|
||||
padding: 0.5rem 0.75rem;
|
||||
margin: 0.5rem 0;
|
||||
|
||||
cursor: pointer;
|
||||
transition: background-color 100ms;
|
||||
}
|
||||
font-weight: bold;
|
||||
|
||||
button:focus-visible {
|
||||
border: 1px solid gold;
|
||||
cursor: pointer;
|
||||
transition: all 75ms;
|
||||
|
||||
&:focus-visible {
|
||||
outline: 1px solid gold;
|
||||
}
|
||||
|
||||
&:hover {
|
||||
color: gold;
|
||||
}
|
||||
}
|
||||
|
||||
// Text
|
||||
|
||||
@@ -202,6 +202,7 @@ export default defineComponent({
|
||||
url: '',
|
||||
lines: '',
|
||||
project: null,
|
||||
projectUrl: null,
|
||||
reqLevel: -1,
|
||||
signalType: 'współczesna',
|
||||
controlType: 'SCS',
|
||||
|
||||
@@ -4,6 +4,7 @@ export type ChangeProp =
|
||||
| 'url'
|
||||
| 'lines'
|
||||
| 'project'
|
||||
| 'projectUrl'
|
||||
| 'reqLevel'
|
||||
| 'signalType'
|
||||
| 'controlType'
|
||||
@@ -18,6 +19,7 @@ export enum HeaderTypes {
|
||||
url = 'URL',
|
||||
lines = 'Linie',
|
||||
project = 'Projekt',
|
||||
projectUrl = "URL projektu",
|
||||
reqLevel = 'Wym. poziom',
|
||||
signalType = 'Sygnalizacja',
|
||||
controlType = 'Sterowanie',
|
||||
@@ -43,6 +45,7 @@ export interface SceneryRowItem {
|
||||
url: string;
|
||||
lines: string;
|
||||
project: string | null;
|
||||
projectUrl: string | null;
|
||||
reqLevel: number;
|
||||
signalType: string;
|
||||
controlType: string;
|
||||
|
||||
@@ -55,7 +55,6 @@ export default defineComponent({
|
||||
async signIn(e: Event) {
|
||||
e.preventDefault();
|
||||
this.loginState = LoginState.LOADING;
|
||||
console.log('Ładowanie');
|
||||
|
||||
try {
|
||||
const loginData = (await this.store.login(this.name, this.password)).data;
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
<tr v-for="(station, row) in sortedStationList" tabindex="0">
|
||||
<td v-for="(value, propName) in headerNameList" @click="changeProperty(station, row, propName as string)">
|
||||
<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>
|
||||
|
||||
<span v-else-if="propName === 'checkpoints'">{{ station[propName] ? 'POKAŻ' : 'DODAJ' }}</span>
|
||||
|
||||
@@ -76,6 +77,7 @@ export default defineComponent({
|
||||
url: 'URL',
|
||||
lines: 'Linie',
|
||||
project: 'Projekt',
|
||||
projectUrl: 'URL projektu',
|
||||
reqLevel: 'Wym. poziom',
|
||||
signalType: 'Sygnalizacja',
|
||||
controlType: 'Sterowanie',
|
||||
@@ -135,7 +137,7 @@ export default defineComponent({
|
||||
return;
|
||||
}
|
||||
|
||||
let newValue = prompt(`Zmień wartość dla rubryki ${this.headerNameList[propertyName]}`, oldValue);
|
||||
let newValue = prompt(`Zmień wartość dla rubryki ${this.headerNameList[propertyName]}`, oldValue || '');
|
||||
if (newValue == null) return;
|
||||
(this.store.stationList[stationListRow] as any)[propertyName] =
|
||||
typeof oldValue === 'number' ? parseInt(newValue) : newValue;
|
||||
|
||||
Reference in New Issue
Block a user