@extends('layouts.app') @section('title', 'My Profile') @push('styles') @endpush @section('content') @if(session('success'))
{{ session('success') }}
@endif @if($errors->any())
{{ $errors->first() }}
@endif
@csrf
{{-- LEFT: avatar + identity --}}
@if($user->avatar) {{ $user->name }} @else {{ strtoupper(substr($user->name ?: $user->email, 0, 1)) }} @endif
{{ $user->name }} {{ $user->email }} @if($tenant) @php $isOwner = (int) $tenant->user_id === (int) $user->id; $staffRow = $isOwner ? null : \App\Modules\Inventory\Models\InventoryStaff::where('inventory_tenant_id', $tenant->id)->where('user_id', $user->id)->first(); @endphp
@if($isOwner) Owner of {{ $tenant->business_name ?: $tenant->name }} @else Staff · {{ ucwords(str_replace('_', ' ', optional($staffRow)->role ?? 'member')) }} @endif
@endif

JPG, PNG or GIF. Max 2 MB.
@error('avatar')
{{ $message }}
@enderror

Account & Security

{{-- RIGHT: edit form --}}

Personal Info

@error('name')
{{ $message }}
@enderror
To change your email, contact support — we'll verify the new address.
@error('phone')
{{ $message }}
@enderror
Used for SMS verification and order alerts.
@endsection @push('scripts') @endpush