фикс
This commit is contained in:
parent
7c06cf85a5
commit
19a041266d
@ -222,7 +222,7 @@ const userAge = computed(() => {
|
||||
|
||||
// Methods
|
||||
const loadUser = async () => {
|
||||
if (!route.params.id) {
|
||||
if (!route.params.userId) {
|
||||
error.value = 'ID пользователя не указан';
|
||||
loading.value = false;
|
||||
return;
|
||||
@ -232,13 +232,13 @@ const loadUser = async () => {
|
||||
error.value = '';
|
||||
|
||||
try {
|
||||
console.log('[UserProfileView] Загрузка пользователя:', route.params.id);
|
||||
const response = await api.getUserById(route.params.id);
|
||||
console.log('[UserProfileView] Загрузка пользователя:', route.params.userId);
|
||||
const response = await api.getUserById(route.params.userId);
|
||||
user.value = response.data;
|
||||
|
||||
// Записываем просмотр профиля
|
||||
try {
|
||||
await api.recordProfileView(route.params.id, 'profile_link');
|
||||
await api.recordProfileView(route.params.userId, 'profile_link');
|
||||
console.log('[UserProfileView] Просмотр профиля записан');
|
||||
} catch (viewError) {
|
||||
console.warn('[UserProfileView] Не удалось записать просмотр профиля:', viewError);
|
||||
|
Loading…
x
Reference in New Issue
Block a user