{{-- brafa Systems — Property locks. Livewire backing: App\Http\Livewire\Dashboard\PropertyLocks. Bindings preserved: wire:submit.prevent="saveScienerDetails", wire:model username/password, wire:click goToLockDetails/unlockLock, $showDetailsForm, $locks, $numberOfLocks, $isUnlocking, $message, $error, $propertyName, $refreshComponent, showToast JS. --}}
@php $brafaLockModel = function ($lockName) { $name = (string) $lockName; return match (true) { \Illuminate\Support\Str::startsWith($name, 'H31') => ['img' => 'H31', 'label' => 'brafa Hotel'], \Illuminate\Support\Str::startsWith($name, 'M302') => ['img' => 'M302', 'label' => 'brafa ASSA'], \Illuminate\Support\Str::startsWith($name, 'S31') => ['img' => 'S31', 'label' => 'brafa Slim'], \Illuminate\Support\Str::startsWith($name, 'K3') => ['img' => 'K3', 'label' => 'brafa Keypad K3'], \Illuminate\Support\Str::startsWith($name, 'K2') => ['img' => 'K3', 'label' => 'brafa Keypad K2'], \Illuminate\Support\Str::startsWith($name, 'N30') => ['img' => 'N30', 'label' => 'brafa Cylinder'], \Illuminate\Support\Str::startsWith($name, 'LL80') => ['img' => 'LL80', 'label' => 'brafa FaceID'], default => ['img' => null, 'label' => $name ?: 'N/A'], }; }; @endphp
@if ($showDetailsForm)

Sciener access

@error('username')

{{ $message }}

@enderror
@error('password')

{{ $message }}

@enderror
@else
{{ $propertyName }}
{{ $numberOfLocks }}
locks on this property
@if ($message)
{{ $message }}
@endif @if ($error)
{{ $error }}
@endif

{{ $propertyName }} lock list

@forelse ($locks as $lock) @php $battery = (int) ($lock['electricQuantity'] ?? 0); $batClass = $battery > 69 ? 'battery-chip--high' : ($battery > 35 ? 'battery-chip--mid' : 'battery-chip--low'); $model = $brafaLockModel($lock['lockName'] ?? ''); @endphp @empty @endforelse
Lock aliasModelBatteryConnectionAction
{{ $lock['lockAlias'] ?? 'N/A' }} @if ($model['img'])@endif {{ $model['label'] }} battery_std{{ $battery }}% @if ($lock['hasGateway'] == 1) Online @else Offline @endif
No locks found.
@endif
{{ $refreshComponent }}
@push('js') @endpush