modified: serv_nginx/bbvue/src/stores/user.js

modified:   serv_nginx/bbvue/src/views/Profile.vue
change GET path for personal-bests
This commit is contained in:
2025-10-20 03:32:41 +05:00
parent 402296b726
commit 88046f722d
2 changed files with 2 additions and 5 deletions
+1 -1
View File
@@ -155,7 +155,7 @@ export const useUserStore = defineStore('user', () => {
const fetchPersonalBests = async () => {
return withStoreLoading(async () => {
try {
const response = await apiClient.get('/personal-bests')
const response = await apiClient.get('/user/personal-bests')
console.log("debug /user/personal-bests " + response.data)
personalBests.value = response.data
return { success: true, data: personalBests.value }
+1 -4
View File
@@ -250,9 +250,6 @@ export default {
if (!this.user?.created_at) {
return 'Неизвестно';
}
console.log('DEBUG - created_at:', this.user.created_at, 'Type:', typeof this.user.created_at);
// Пробуем разные форматы даты
let date;
if (this.user.created_at.includes('T')) {
@@ -375,7 +372,7 @@ export default {
async fetchPersonalBests() {
try {
const response = await this.userStore.apiClient.get('/personal-bests');
const response = await this.userStore.fetchPersonalBests;
this.personalBests = response.data;
return { success: true };
} catch (error) {