UI Bugfixes
This commit is contained in:
@@ -30,9 +30,9 @@ const path = require('path')
|
|||||||
app.use('/static', express.static(path.join(__dirname, 'images')))
|
app.use('/static', express.static(path.join(__dirname, 'images')))
|
||||||
|
|
||||||
// Add delay for more realistic response times
|
// Add delay for more realistic response times
|
||||||
// app.use((req, res, next) => {
|
app.use((req, res, next) => {
|
||||||
// setTimeout(next, Math.floor((Math.random () * 2000) + 100))
|
setTimeout(next, Math.floor((Math.random () * 2000) + 100))
|
||||||
// })
|
})
|
||||||
|
|
||||||
// Routes
|
// Routes
|
||||||
app.use("/api", api)
|
app.use("/api", api)
|
||||||
|
|||||||
@@ -3,6 +3,8 @@ defineProps({
|
|||||||
/** Image to display on the left side (if prepend slot is not in use) */
|
/** Image to display on the left side (if prepend slot is not in use) */
|
||||||
image: String,
|
image: String,
|
||||||
|
|
||||||
|
title: String,
|
||||||
|
|
||||||
/** Make the CardView click- and hoverable */
|
/** Make the CardView click- and hoverable */
|
||||||
link: {
|
link: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
@@ -16,9 +18,7 @@ defineProps({
|
|||||||
height: {
|
height: {
|
||||||
type: Number,
|
type: Number,
|
||||||
default: 140
|
default: 140
|
||||||
},
|
}
|
||||||
|
|
||||||
colorHeader: String
|
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@@ -76,7 +76,15 @@ defineProps({
|
|||||||
<v-sheet
|
<v-sheet
|
||||||
:height="height"
|
:height="height"
|
||||||
>
|
>
|
||||||
<slot name="content" />
|
<div>
|
||||||
|
<div class="text-h4 font-weight-black pt-2 h-100">
|
||||||
|
{{ title }}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="text-disabled">
|
||||||
|
<slot name="content" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</v-sheet>
|
</v-sheet>
|
||||||
</v-skeleton-loader>
|
</v-skeleton-loader>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|||||||
@@ -1,20 +1,43 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import cardViewHorizontal from '@/components/basics/cardViewHorizontal.vue';
|
import cardViewHorizontal from '@/components/basics/cardViewHorizontal.vue';
|
||||||
import { ConcertModel } from '@/data/models/acts/concertModel';
|
|
||||||
|
|
||||||
defineProps({
|
defineProps({
|
||||||
concert: ConcertModel,
|
/** Date of the concert */
|
||||||
date: String,
|
date: String,
|
||||||
|
|
||||||
|
/** Card title */
|
||||||
title: String,
|
title: String,
|
||||||
description: String,
|
|
||||||
|
/** Name of the event */
|
||||||
eventName: String,
|
eventName: String,
|
||||||
|
|
||||||
|
/** Price of the cheapest ticket option */
|
||||||
price: Number,
|
price: Number,
|
||||||
loading: Boolean
|
|
||||||
|
/** Number of available tickets, important to mark a concert as "sold out" */
|
||||||
|
inStock: Number,
|
||||||
|
|
||||||
|
/** Display text parts as skeleton */
|
||||||
|
loading: Boolean,
|
||||||
|
|
||||||
|
/** Show or hide the button on the right side */
|
||||||
|
showButton: {
|
||||||
|
type: Boolean,
|
||||||
|
default: true
|
||||||
|
},
|
||||||
|
|
||||||
|
/** Behaviour if user clicks on button or card */
|
||||||
|
onClick: Function
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<card-view-horizontal v-if="!loading">
|
<card-view-horizontal
|
||||||
|
:title="title"
|
||||||
|
v-if="!loading"
|
||||||
|
:link="showButton && inStock > 0"
|
||||||
|
@click="showButton && inStock > 0 ? onClick() : () => {}"
|
||||||
|
>
|
||||||
<template #prepend>
|
<template #prepend>
|
||||||
<div>
|
<div>
|
||||||
<div class="text-h4">
|
<div class="text-h4">
|
||||||
@@ -32,28 +55,25 @@ defineProps({
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template #content>
|
<template #content>
|
||||||
<div>
|
<slot name="description" />
|
||||||
<div class="text-h4 font-weight-black pt-2 h-100">
|
|
||||||
{{ title }}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="text-disabled">
|
|
||||||
<slot name="description" />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template #append>
|
<template #append>
|
||||||
<div>
|
<div>
|
||||||
<div class="text-secondary font-weight-medium text-body-1 pb-1">
|
<div class="text-secondary font-weight-medium text-h6 pb-1">
|
||||||
{{ $t('from') + ' ' + price.toFixed(2) + ' €' }}
|
{{ $t('from') + ' ' + price.toFixed(2) + ' €' }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div>
|
<div v-if="inStock == 0 && showButton" class="text-h6">
|
||||||
|
{{ $t('soldOut') }}
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div v-else-if="showButton">
|
||||||
<v-btn variant="flat" color="secondary">
|
<v-btn variant="flat" color="secondary">
|
||||||
{{ $t('goToTheConcert') }}
|
{{ $t('goToTheConcert') }}
|
||||||
</v-btn>
|
</v-btn>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</card-view-horizontal>
|
</card-view-horizontal>
|
||||||
|
|||||||
@@ -7,7 +7,10 @@ import { useRouter } from 'vue-router';
|
|||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
|
|
||||||
defineProps({
|
defineProps({
|
||||||
|
/** Event to display */
|
||||||
event: EventModel,
|
event: EventModel,
|
||||||
|
|
||||||
|
/** Display text parts as skeleton */
|
||||||
loading: Boolean
|
loading: Boolean
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
@@ -15,26 +18,25 @@ defineProps({
|
|||||||
<template>
|
<template>
|
||||||
<card-view-horizontal
|
<card-view-horizontal
|
||||||
v-if="!loading"
|
v-if="!loading"
|
||||||
|
:title="event.band.name + ' - ' + event.name"
|
||||||
:image="'http://localhost:3000/static/' + event.image"
|
:image="'http://localhost:3000/static/' + event.image"
|
||||||
@click="router.push('/bands/' + event.band.name.replaceAll(' ', '-').toLowerCase())"
|
@click="router.push('/bands/' + event.band.name.replaceAll(' ', '-').toLowerCase())"
|
||||||
>
|
>
|
||||||
<template #content>
|
<template #content>
|
||||||
<div class="text-h6 font-weight-black pt-1">
|
<div class="oneLine my-2 pr-4 text-disabled" >
|
||||||
{{ event.band.name }} - {{ event.name }}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="descriptionShort mb-2 pr-4 text-disabled" >
|
|
||||||
{{ event.band.descriptionDe }}
|
{{ event.band.descriptionDe }}
|
||||||
|
<!-- todo: Englisch text -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="text-disabled">
|
<div class="text-disabled oneLine">
|
||||||
{{ createDateRangeString(event) }} - {{ event.concerts.length }} {{ $t('concert', event.concerts.length) }}
|
{{ createDateRangeString(event) }} - {{ event.concerts.length }}
|
||||||
|
{{ $t('concert', event.concerts.length) }}
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<template #append>
|
<template #append>
|
||||||
<div>
|
<div>
|
||||||
<div class="text-secondary font-weight-medium text-body-1 pb-1">
|
<div class="text-secondary font-weight-medium text-h6 pb-1">
|
||||||
{{ $t('from') + ' ' + lowestTicketPrice(event) + ' €' }}
|
{{ $t('from') + ' ' + lowestTicketPrice(event) + ' €' }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -57,11 +59,11 @@ defineProps({
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.descriptionShort {
|
.oneLine {
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
display: -webkit-box;
|
display: -webkit-box;
|
||||||
-webkit-line-clamp: 2; /* number of lines to show */
|
-webkit-line-clamp: 1; /* number of lines to show */
|
||||||
line-clamp: 2;
|
line-clamp: 1;
|
||||||
-webkit-box-orient: vertical;
|
-webkit-box-orient: vertical;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -169,5 +169,6 @@
|
|||||||
"title": "Übungsfortschritt zurücksetzen?",
|
"title": "Übungsfortschritt zurücksetzen?",
|
||||||
"description": "Soll der Bearbeitungsfortschritt der Übungen wirklich zurückgesetzt werden? Dies kann nicht rückgänig gemacht werden!"
|
"description": "Soll der Bearbeitungsfortschritt der Übungen wirklich zurückgesetzt werden? Dies kann nicht rückgänig gemacht werden!"
|
||||||
},
|
},
|
||||||
"goToTheConcert": "Zum Konzert"
|
"goToTheConcert": "Zum Konzert",
|
||||||
|
"selectedConcert": "Ausgewähltes Konzert"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -169,5 +169,6 @@
|
|||||||
"title": "Reset Exercise progress?",
|
"title": "Reset Exercise progress?",
|
||||||
"description": "Do you really want to reset the exercise progress? This can't be undone!"
|
"description": "Do you really want to reset the exercise progress? This can't be undone!"
|
||||||
},
|
},
|
||||||
"goToTheConcert": "To the concert"
|
"goToTheConcert": "To the concert",
|
||||||
|
"selectedConcert": "Selected Concert"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -30,7 +30,8 @@ defineProps({
|
|||||||
:title="concert.location.city.name"
|
:title="concert.location.city.name"
|
||||||
:description="concert.location.name"
|
:description="concert.location.name"
|
||||||
:link="concert.inStock > 0"
|
:link="concert.inStock > 0"
|
||||||
@click="(concert.inStock > 0) && router.push('/concert/' + concert.id)"
|
:in-stock="concert.inStock"
|
||||||
|
:onClick="() => router.push('/concert/' + concert.id)"
|
||||||
>
|
>
|
||||||
<template #description>
|
<template #description>
|
||||||
<div>
|
<div>
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ defineProps({
|
|||||||
readonly
|
readonly
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<div class="px-3">{{ band.ratings.length }} {{ $t('rating', band.ratings.length) }}</div>
|
<div class="px-3 text-h6">{{ band.ratings.length }} {{ $t('rating', band.ratings.length) }}</div>
|
||||||
</div>
|
</div>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import filterBar from './filterBar.vue';
|
import filterBar from './filterBar.vue';
|
||||||
import { useRouter, useRoute } from 'vue-router';
|
import { useRoute } from 'vue-router';
|
||||||
import { useShoppingStore } from '@/data/stores/shoppingStore';
|
import { useShoppingStore } from '@/data/stores/shoppingStore';
|
||||||
import { useFeedbackStore } from '@/data/stores/feedbackStore';
|
import { useFeedbackStore } from '@/data/stores/feedbackStore';
|
||||||
import eventListItem from './eventListItem.vue';
|
import eventListItem from '../../../components/pageParts/eventListItem.vue';
|
||||||
|
|
||||||
const route = useRoute()
|
const route = useRoute()
|
||||||
const router = useRouter()
|
|
||||||
const shoppingStore = useShoppingStore()
|
const shoppingStore = useShoppingStore()
|
||||||
const feedbackStore = useFeedbackStore()
|
const feedbackStore = useFeedbackStore()
|
||||||
|
|
||||||
@@ -21,7 +20,6 @@ shoppingStore.getEvents()
|
|||||||
<v-container>
|
<v-container>
|
||||||
<v-row>
|
<v-row>
|
||||||
<v-spacer />
|
<v-spacer />
|
||||||
<!-- <div v-html="route.query.genre" /> -->
|
|
||||||
|
|
||||||
<v-col cols="10">
|
<v-col cols="10">
|
||||||
<v-row>
|
<v-row>
|
||||||
@@ -30,11 +28,16 @@ shoppingStore.getEvents()
|
|||||||
</v-col>
|
</v-col>
|
||||||
</v-row>
|
</v-row>
|
||||||
|
|
||||||
<event-list-item
|
<v-row
|
||||||
v-if="feedbackStore.fetchDataFromServerInProgress"
|
v-if="feedbackStore.fetchDataFromServerInProgress"
|
||||||
v-for="i in 3"
|
v-for="i in 3"
|
||||||
:loading="true"
|
>
|
||||||
/>
|
<v-col>
|
||||||
|
<event-list-item
|
||||||
|
:loading="true"
|
||||||
|
/>
|
||||||
|
</v-col>
|
||||||
|
</v-row>
|
||||||
|
|
||||||
<v-row
|
<v-row
|
||||||
v-else-if="shoppingStore.events.length > 0"
|
v-else-if="shoppingStore.events.length > 0"
|
||||||
|
|||||||
@@ -9,7 +9,6 @@ import sectionDivider from '@/components/basics/sectionDivider.vue';
|
|||||||
import { useBasketStore } from '@/data/stores/basketStore';
|
import { useBasketStore } from '@/data/stores/basketStore';
|
||||||
import concertListItem from '@/components/pageParts/concertListItem.vue';
|
import concertListItem from '@/components/pageParts/concertListItem.vue';
|
||||||
import { ConcertModel } from '@/data/models/acts/concertModel';
|
import { ConcertModel } from '@/data/models/acts/concertModel';
|
||||||
import { dateStringToHumanReadableString } from '@/scripts/dateTimeScripts';
|
|
||||||
import outlinedButton from '@/components/basics/outlinedButton.vue';
|
import outlinedButton from '@/components/basics/outlinedButton.vue';
|
||||||
|
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
@@ -34,18 +33,26 @@ getConcert(Number(router.currentRoute.value.params.id))
|
|||||||
<v-spacer />
|
<v-spacer />
|
||||||
|
|
||||||
<v-col cols="10">
|
<v-col cols="10">
|
||||||
|
<v-row>
|
||||||
|
<v-col>
|
||||||
|
<section-divider :title="$t('selectedConcert')" />
|
||||||
|
</v-col>
|
||||||
|
</v-row>
|
||||||
|
|
||||||
<v-row>
|
<v-row>
|
||||||
<v-col>
|
<v-col>
|
||||||
<concert-list-item
|
<concert-list-item
|
||||||
:loading="feedbackStore.fetchDataFromServerInProgress"
|
:loading="feedbackStore.fetchDataFromServerInProgress"
|
||||||
:link="false"
|
:link="false"
|
||||||
:title="concertModel.event.band.name + ' - ' + concertModel.event.name"
|
:title="concertModel.location.city.name"
|
||||||
:image="concertModel.location.imageOutdoor"
|
:image="concertModel.location.imageOutdoor"
|
||||||
|
:date="concertModel.date"
|
||||||
|
:price="concertModel.price"
|
||||||
|
:show-button="false"
|
||||||
>
|
>
|
||||||
<template #description>
|
<template #description>
|
||||||
<p>{{ dateStringToHumanReadableString(concertModel.date) }}</p>
|
|
||||||
<p>{{ concertModel.location.name }}</p>
|
<p>{{ concertModel.location.name }}</p>
|
||||||
<p>{{ concertModel.location.city.name }}</p>
|
<p>{{ concertModel.event.band.name }} - {{ concertModel.event.name }}</p>
|
||||||
</template>
|
</template>
|
||||||
</concert-list-item>
|
</concert-list-item>
|
||||||
</v-col>
|
</v-col>
|
||||||
|
|||||||
@@ -65,8 +65,9 @@ getLocation(String(router.currentRoute.value.params.locationName))
|
|||||||
<concert-list-item
|
<concert-list-item
|
||||||
:date="concert.date"
|
:date="concert.date"
|
||||||
:title="concert.event.name"
|
:title="concert.event.name"
|
||||||
|
:in-stock="concert.inStock"
|
||||||
:price="concert.price"
|
:price="concert.price"
|
||||||
@click="() => router.push('/bands/' + concert.event.bandName.replaceAll(' ', '-').toLowerCase())"
|
:onClick="() => router.push('/bands/' + concert.event.bandName.replaceAll(' ', '-').toLowerCase())"
|
||||||
>
|
>
|
||||||
<template #description>
|
<template #description>
|
||||||
{{ concert.event.bandName }}
|
{{ concert.event.bandName }}
|
||||||
|
|||||||
Reference in New Issue
Block a user