generated from Flycro/laravel-nuxt
style: Mobile Styles
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
5534f00a7d
commit
91592b06d7
|
|
@ -23,6 +23,12 @@ steps:
|
||||||
- docker compose exec php php artisan migrate --force
|
- docker compose exec php php artisan migrate --force
|
||||||
- docker compose exec php php artisan optimize
|
- docker compose exec php php artisan optimize
|
||||||
- docker compose exec php php artisan storage:link
|
- docker compose exec php php artisan storage:link
|
||||||
|
- >
|
||||||
|
if grep -q "GIT_HASH=" .env; then
|
||||||
|
sed -i 's/GIT_HASH=.*/GIT_HASH=$(git rev-parse --short HEAD)/' .env
|
||||||
|
else
|
||||||
|
echo "GIT_HASH=$(git rev-parse --short HEAD)" >> .env
|
||||||
|
fi
|
||||||
- npx nuxi cleanup
|
- npx nuxi cleanup
|
||||||
- pnpm run build
|
- pnpm run build
|
||||||
- find /var/www/html/bookstack.octolabs.net -type f -exec chmod 664 {} \\;
|
- find /var/www/html/bookstack.octolabs.net -type f -exec chmod 664 {} \\;
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,18 @@ function resolveStatus(status: string) {
|
||||||
return bookRecommendationStore.statusOptions.find(option => option.value === status)
|
return bookRecommendationStore.statusOptions.find(option => option.value === status)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const rows = computed(() => {
|
||||||
|
// return all bookRecommendationStore.recommendations but add actions
|
||||||
|
return bookRecommendationStore.recommendations.map((recommendation) => {
|
||||||
|
return {
|
||||||
|
...recommendation,
|
||||||
|
actions: {
|
||||||
|
class: 'max-w-96',
|
||||||
|
},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
$echo.private(`BookRecommendation`)
|
$echo.private(`BookRecommendation`)
|
||||||
.listen('.BookRecommendationUpdated', (e) => {
|
.listen('.BookRecommendationUpdated', (e) => {
|
||||||
|
|
@ -86,7 +98,6 @@ onMounted(() => {
|
||||||
|
|
||||||
$echo.private(`Vote`)
|
$echo.private(`Vote`)
|
||||||
.listen('.VoteCreated', (e) => {
|
.listen('.VoteCreated', (e) => {
|
||||||
console.log(e)
|
|
||||||
bookRecommendationStore.createVoteWS(e.vote)
|
bookRecommendationStore.createVoteWS(e.vote)
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
@ -95,18 +106,13 @@ onMounted(() => {
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<NewBookRecommendation />
|
<NewBookRecommendation />
|
||||||
<UTable :sort="sort" :loading="bookRecommendationStore.fetchRecommendationsStatus === 'pending'" :columns="columns" :rows="bookRecommendationStore.recommendations">
|
<UTable :ui="{ td: { base: 'max-w-[0] truncate' } }" :sort="sort" :loading="bookRecommendationStore.fetchRecommendationsStatus === 'pending'" :columns="columns" :rows="rows">
|
||||||
<template #created_at-data="{ row }">
|
<template #created_at-data="{ row }">
|
||||||
<div>{{ dayjs(row.created_at).format('DD.MM.YYYY') }}</div>
|
<div>{{ dayjs(row.created_at).format('DD.MM.YYYY') }}</div>
|
||||||
</template>
|
</template>
|
||||||
<template #published_at-data="{ row }">
|
<template #published_at-data="{ row }">
|
||||||
<div>{{ dayjs(row.published_at).format('DD.MM.YYYY') }}</div>
|
<div>{{ dayjs(row.published_at).format('DD.MM.YYYY') }}</div>
|
||||||
</template>
|
</template>
|
||||||
<template #description-data="{ row }">
|
|
||||||
<div v-if="row.description">
|
|
||||||
{{ `${row.description.substring(0, 50)}...` }}
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
<template #votes-data="{ row }">
|
<template #votes-data="{ row }">
|
||||||
{{ row.votes.length }}
|
{{ row.votes.length }}
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -116,7 +122,7 @@ onMounted(() => {
|
||||||
</UBadge>
|
</UBadge>
|
||||||
</template>
|
</template>
|
||||||
<template #actions-data="{ row }">
|
<template #actions-data="{ row }">
|
||||||
<div class="flex space-x-2">
|
<div class="flex max-w-full space-x-2">
|
||||||
<CastVote :row="row" />
|
<CastVote :row="row" />
|
||||||
<EditBookRecommendation :row="row" />
|
<EditBookRecommendation :row="row" />
|
||||||
<DeleteBookRecommendation :row="row" />
|
<DeleteBookRecommendation :row="row" />
|
||||||
|
|
|
||||||
|
|
@ -17,12 +17,12 @@ const dayjs = useDayjs()
|
||||||
<div class="hidden w-1/5 md:block">
|
<div class="hidden w-1/5 md:block">
|
||||||
<img :src="$storage(props.book.cover_image)" :alt="props.book.book_name" class="rounded-lg">
|
<img :src="$storage(props.book.cover_image)" :alt="props.book.book_name" class="rounded-lg">
|
||||||
</div>
|
</div>
|
||||||
<div class="w-4/5 space-y-4">
|
<div class="w-full space-y-4 md:w-4/5">
|
||||||
<div class="space-y-2">
|
<div class="space-y-2">
|
||||||
<h1 class="font-sans text-3xl font-bold">
|
<h1 class="font-sans text-3xl font-bold">
|
||||||
{{ props.book.book_name }}
|
{{ props.book.book_name }}
|
||||||
</h1>
|
</h1>
|
||||||
<div class="flex justify-between">
|
<div class="flex flex-col flex-wrap gap-y-2 md:flex-row md:justify-between">
|
||||||
<div>
|
<div>
|
||||||
<UBadge>
|
<UBadge>
|
||||||
{{ props.book.author }}
|
{{ props.book.author }}
|
||||||
|
|
|
||||||
|
|
@ -13,8 +13,8 @@ async function runJobs(job: string) {
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div class="flex gap-4">
|
<div class="flex flex-col gap-4 md:flex-row">
|
||||||
<UCard class="w-1/2">
|
<UCard class="w-full md:w-1/2">
|
||||||
<template #header>
|
<template #header>
|
||||||
<h1 class="font-sans text-3xl font-bold">
|
<h1 class="font-sans text-3xl font-bold">
|
||||||
Server Jobs
|
Server Jobs
|
||||||
|
|
@ -24,7 +24,7 @@ async function runJobs(job: string) {
|
||||||
</UButton>
|
</UButton>
|
||||||
</template>
|
</template>
|
||||||
</UCard>
|
</UCard>
|
||||||
<UCard class="w-1/2">
|
<UCard class="w-full md:w-1/2">
|
||||||
<template #header>
|
<template #header>
|
||||||
<h1 class="font-sans text-3xl font-bold">
|
<h1 class="font-sans text-3xl font-bold">
|
||||||
Server Logs
|
Server Logs
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ definePageMeta({ middleware: ['role-admin'] })
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<UCard class="w-1/2">
|
<UCard class="w-full md:w-1/2">
|
||||||
<template #header>
|
<template #header>
|
||||||
<h1 class="font-sans text-3xl font-bold">
|
<h1 class="font-sans text-3xl font-bold">
|
||||||
Benutzer Aktionen
|
Benutzer Aktionen
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue