Department Login Management

Manage the usernames, emails & passwords used to sign in to the department portal

@forelse($departmentUsers as $u) @empty @endforelse
Department Username (Login) Email (Login) Last Sign-In Actions
{{ $u->initials() }}
{{ $u->department_name ?: $u->name }}
{{ $u->name }}
{{ $u->username ?: '—' }} {{ $u->email }} @if($u->latestLogin)
{{ $u->latestLogin->created_at->format('M d, Y h:i A') }}
{{ $u->latestLogin->created_at->diffForHumans() }} • {{ $u->latestLogin->ip_address ?? '—' }}
@else Never signed in @endif

No Department Logins Found

No department logins match your search criteria.

@if($departmentUsers->hasPages())
{{ $departmentUsers->links() }}
@endif
@if($showModal)

{{ $editingUserId ? 'Edit Department Login' : 'Create Department Login' }}

@error('department_name') {{ $message }} @enderror
@error('name') {{ $message }} @enderror
@error('username') {{ $message }} @enderror
@error('email') {{ $message }} @enderror
@error('password') {{ $message }} @enderror

The department can sign in with either the username or the email. Changing the password signs the department out of every device.

@endif @if($showPasswordResetModal)

Change Department Password

@error('newPassword') {{ $message }} @enderror

The department will be signed out of every device and must sign in again with the new password.

@endif @if($showHistoryModal && $historyUser)

Login History

{{ $historyUser->department_name ?: $historyUser->name }} • {{ $historyUser->username }}

@forelse($historyEntries as $entry) @empty @endforelse
Date & Time Activity IP Address Device
{{ $entry->created_at->format('M d, Y h:i:s A') }}
{{ $entry->created_at->diffForHumans() }}
@php $badgeClasses = match ($entry->event) { \App\Models\LoginHistory::EVENT_LOGIN => 'bg-emerald-50 text-emerald-700 border-emerald-200', \App\Models\LoginHistory::EVENT_FAILED => 'bg-rose-50 text-rose-700 border-rose-200', \App\Models\LoginHistory::EVENT_SIGNED_OUT_BY_ADMIN => 'bg-amber-50 text-amber-800 border-amber-200', default => 'bg-slate-100 text-slate-600 border-slate-200', }; @endphp {{ $entry->eventLabel() }} {{ $entry->ip_address ?? '—' }} {{ $entry->deviceLabel() }}

No Login Activity Yet

Sign-ins, sign-outs and failed attempts will appear here.

Showing the latest {{ $historyEntries->count() }} {{ Str::plural('entry', $historyEntries->count()) }} (up to 100)
@endif