feat: первое подключение фронтенда
🚀 Create and publish a Docker image / Detect changes in backend and frontend (push) Successful in 8s
🚀 Create and publish a Docker image / Build & publish backend image (push) Successful in 54s
🚀 Create and publish a Docker image / Build & publish frontend image (push) Successful in 27s
🚀 Create and publish a Docker image / Update stack on Portainer (push) Successful in 6s

This commit is contained in:
2026-05-11 01:33:38 +03:00
parent 71e7d84e0f
commit 779b6aba77
21 changed files with 942 additions and 365 deletions
+17 -2
View File
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { computed, ref } from 'vue'
import { computed, onMounted, ref } from 'vue'
import { useAuthStore } from '@/stores/auth'
import { useUserStore } from '@/stores/user'
import GlassCard from '@/components/ui/GlassCard.vue'
@@ -7,6 +7,7 @@ import CoinChip from '@/components/ui/CoinChip.vue'
import ProgressBar from '@/components/ui/ProgressBar.vue'
import AchievementBadge from '@/components/ui/AchievementBadge.vue'
import DataTable from '@/components/ui/DataTable.vue'
import EmptyState from '@/components/ui/EmptyState.vue'
const auth = useAuthStore()
const userStore = useUserStore()
@@ -27,6 +28,10 @@ const historyColumns = [
{ key: 'description', label: 'Описание' },
{ key: 'amount', label: 'Монеты', align: 'right' },
]
onMounted(() => {
void userStore.fetchStudentData(user.value.id)
})
</script>
<template>
@@ -87,7 +92,12 @@ const historyColumns = [
</label>
</div>
<div class="section-title">Достижения</div>
<div class="achievements">
<EmptyState
v-if="!userStore.achievements.length"
title="Достижений пока нет"
subtitle="Они появятся после посещений, отзывов и начислений."
/>
<div v-else class="achievements">
<AchievementBadge
v-for="a in userStore.achievements.slice(0, 3)"
:key="a.id"
@@ -104,6 +114,11 @@ const historyColumns = [
<GlassCard>
<div class="section-title">История начисления монет</div>
<EmptyState
v-if="!userStore.coinHistory.length"
title="История монет пуста"
subtitle="Начисления появятся после активностей на платформе."
/>
<DataTable :columns="historyColumns" :rows="userStore.coinHistory">
<template #amount="{ value }">
<span :class="value > 0 ? 'positive' : 'negative'">{{ value > 0 ? `+${value}` : value }}</span>