{{-- brafa Systems — Users. Mirror of the Properties list pattern. Livewire backing: App\Http\Livewire\LaravelExamples\UserManagement\Index. Bindings preserved: wire:model perPage/search, wire:click sortBy/destroy/ showAddUserModal/store, wire:model picture/name/email/role_id/password/ passwordConfirmation, @can policies, status/error flashes, the Bootstrap modal (data-toggle / wire:ignore.self), $users pagination. --}}
@if (Session::has('status'))
{{ Session::get('status') }}
@elseif (Session::has('error'))
{{ Session::get('error') }}
@endif
{{-- Toolbar --}}
@can('create', App\Models\User::class) @endcan
{{-- Table --}}
@can('manage-users', App\User::class) @endcan @forelse ($users as $user) @php $initials = collect(explode(' ', trim((string) $user->name))) ->filter()->take(2)->map(fn ($p) => strtoupper(mb_substr($p, 0, 1)))->implode(''); @endphp @can('manage-users', auth()->user()) @endcan @empty @endforelse
ID Photo Name Email Role CreatedActions
{{ $user->id }} @if ($user->picture) {{ $user->name }} @else
{{ $initials ?: '?' }}
@endif
{{ $user->name }}
{{ $user->email }} {{ $user->role->name }} {{ $user->created_at }}
@can('update', $user) @endcan @can('delete', $user) @endcan
No users match your search.
{{-- Footer --}}
{{-- Add User modal — kept as the existing Bootstrap modal (data-toggle / wire:ignore.self). Markup-only restyle inside. --}} @push('js') @endpush