@extends('layouts.app') @section('content') @include('layouts.title-header', [ 'title' => 'Mi Perfil', 'breadcrumbs' => [ ['text' => 'Cuenta', 'url' => null], ['text' => 'Mi Perfil'] ] ])
@if($user->foto_perfil) Foto de perfil @else Avatar por defecto @endif

{{ $user->nombre }} {{ $user->apellido }}

@if($user->isAdmin())
Administrador
@endif
{{ $userPoints->getBadge() }} (Nivel {{ $userPoints->level }})
{{ number_format($userPoints->points) }} Puntos
@if($user->descripcion || (auth()->check() && auth()->id() == $user->id))
@if($user->descripcion)

{{ $user->descripcion }}

@else

Añade una descripción sobre ti

@endif
@endif
Mis Estadísticas
Miembro desde: {{ $user->created_at->format('d/m/Y') }}
{{ $user->citas()->where('estado', 'completado')->count() }}
Citas Completadas
{{ $user->citaImagenes()->count() }}
Imágenes Subidas
{{ $user->citaImagenes()->withCount('likes')->get()->sum('likes_count') }}
Likes Recibidos
{{ \App\Models\Like::where('user_id', $user->id)->count() }}
Likes Enviados
@if(auth()->check() && auth()->id() == $user->id)
Progreso al siguiente nivel {{ number_format($userPoints->getProgressToNextLevel(), 1) }}%
{{ $userPoints->getPointsForNextLevel() }} puntos para el nivel {{ $userPoints->level + 1 }}
@endif

{{ number_format($userPoints->points) }}

Puntos Totales

Beneficios Actuales
  • {{ $userPoints->getDiscountPercentage() }}% de descuento
  • @if($userPoints->level >= 6)
  • Prioridad en citas
  • @endif @if($userPoints->level >= 11)
  • Regalos especiales
  • @endif
@if(auth()->check() && auth()->id() == $user->id) @endif
Mi Galería de Imágenes
Ver Todas
@if($user->citaImagenes()->count() > 0)
@foreach($user->citaImagenes()->latest()->take(8)->get() as $imagen) @php $imagen->loadMissing('cita'); $capGalU = trim((string) ($imagen->cita?->publicacion_descripcion ?? '')); $capGalUShort = $capGalU !== '' ? Str::limit($capGalU, 20) : 'Imagen'; $altGalU = $capGalU !== '' ? Str::limit($capGalU, 60) : 'Imagen de la cita'; @endphp
{{ $altGalU }} @if($imagen->es_destacada)
@endif
{{ $capGalUShort }}
@endforeach
@if($user->citaImagenes()->count() > 8) @endif @else
No tienes imágenes en tu galería

¡Comparte tus uñas con nosotros!

Subir Primera Imagen
@endif
@if(auth()->check() && auth()->id() == $user->id)
Actividad Reciente de Puntos
Ver Todo el Historial
@if($transactions->count() > 0)
@foreach($transactions as $transaction) @endforeach
Fecha Descripción Puntos Tipo
{{ $transaction->created_at->format('d/m/Y H:i') }} {{ $transaction->description }} {{ $transaction->getIcon() }} {{ $transaction->points }} @switch($transaction->type) @case('earned') Ganados @break @case('spent') Gastados @break @case('bonus') Bonus @break @default Otros @endswitch
@if($transactions->hasPages())
{{ $transactions->links() }}
@endif @else
No hay actividad aún

¡Comienza a ganar puntos con tus citas y actividades!

@endif
@endif
¿Cómo Ganar Puntos?
Ver Guía
Completar Citas
+50 puntos por cita completada
Subir Imágenes
+25 puntos por imagen subida
Recibir Likes
+5 puntos por like recibido
Bonus Especiales
+100 puntos por logros especiales
@endsection