@extends('layouts.app') @section('title', $employee->name . ' - Bar & Maquis') @section('content')

{{ $employee->name }}

{{ $employee->email }}

Informations personnelles

Nom: {{ $employee->name }}
Email: {{ $employee->email }}
Téléphone: {{ $employee->phone ?: 'Non renseigné' }}
Position: {{ ucfirst($employee->position) }}

Statut et activité

Statut: @if($employee->is_active) Actif @else Inactif @endif
Dernière connexion: {{ $employee->last_login_at ? $employee->last_login_at->format('d/m/Y H:i') : 'Jamais' }}
Membre depuis: {{ $employee->created_at->format('d/m/Y') }}
@if($employee->sales->count() > 0)

Statistiques des ventes

{{ $employee->sales->count() }}
Total des ventes
{{ number_format($employee->sales->sum('total_amount'), 0, ',', ' ') }} FCFA
Chiffre d'affaires
{{ number_format($employee->sales->sum('profit'), 0, ',', ' ') }} FCFA
Profit généré
@endif @if($employee->sales->count() > 0)

Ventes récentes

@foreach($employee->sales->take(10) as $sale) @endforeach
Date Facture Client Montant Profit Paiement
{{ $sale->created_at->format('d/m/Y H:i') }} {{ $sale->invoice_number }} {{ $sale->customer_name ?: 'Client anonyme' }} {{ number_format($sale->total_amount, 0, ',', ' ') }} FCFA {{ number_format($sale->profit, 0, ',', ' ') }} FCFA {{ $sale->payment_method }}
@endif @if($employee->stockMovements->count() > 0)

Mouvements de stock

@foreach($employee->stockMovements->take(10) as $movement) @endforeach
Date Produit Type Quantité Raison
{{ $movement->created_at->format('d/m/Y H:i') }} {{ $movement->product->name }} {{ ucfirst($movement->type) }} {{ $movement->quantity }} {{ $movement->product->unit }} {{ $movement->reason ?: '-' }}
@endif
@endsection