2024-12-06 00:11:50 +00:00
@ use ( App\Models\Address )
2022-03-14 11:28:54 +00:00
@ extends ( 'layouts.app' )
@ section ( 'htmlheader_title' )
Link
@ endsection
@ section ( 'content' )
2024-12-06 00:11:50 +00:00
< form class = " needs-validation " method = " post " autocomplete = " off " novalidate >
2022-03-14 11:28:54 +00:00
@ csrf
2024-04-22 04:27:48 +00:00
< div class = " row " >
< div class = " col-12 " >
< div class = " greyframe titledbox shadow0xb0 " >
< h2 class = " cap " > Enter your Link code </ h2 >
2022-03-14 11:28:54 +00:00
2024-04-22 04:27:48 +00:00
<!-- SYSTEM -->
< div class = " row " >
<!-- Name -->
< div class = " col-5 " >
2024-12-06 00:11:50 +00:00
@ php
$options = Address :: select ([ 'addresses.id' , 'addresses.host_id' , 'addresses.node_id' , 'addresses.point_id' , 'addresses.zone_id' , 'systems.name' ])
-> active ()
-> join ( 'systems' ,[ 'systems.id' => 'addresses.system_id' ])
-> whereRaw ( 'systems.id NOT IN (SELECT system_id FROM "system_user")' )
-> with ([ 'system' , 'zone' ])
-> orderBy ( 'systems.name' )
-> cursor ()
@ endphp
< x - form . select name = " address_id " icon = " bi-laptop-fill " label = " BBS Address " placeholder = " Find your AKA " feedback = " AKA is required " helper = " Enter your BBS name " value = " " : options = " $options->map (fn( $item )=>['id'=> $item->id ,'value'=>sprintf('%s (%s)', $item->name , $item->ftn3d )]) " required />
2024-04-22 04:27:48 +00:00
</ div >
2022-03-14 11:28:54 +00:00
</ div >
2024-04-22 04:27:48 +00:00
<!-- CODE -->
< div class = " row " >
< div class = " col-4 " >
< label for = " code " class = " form-label " > Code </ label >
< div class = " input-group has-validation " >
< span class = " input-group-text " >< i class = " bi bi-fingerprint " ></ i ></ span >
< input type = " text " class = " form-control @error('code') is-invalid @enderror " id = " code " placeholder = " Code " name = " code " value = " { { old('code') }} " required >
< span class = " invalid-feedback " role = " alert " >
@ error ( 'code' )
{{ $message }}
@ else
A code is required .
@ enderror
</ span >
</ div >
</ div >
2022-03-14 11:28:54 +00:00
</ div >
2023-10-09 06:48:26 +00:00
2024-04-22 04:27:48 +00:00
< div class = " row " >
< div class = " col-12 " >
< a href = " { { url('home') }} " class = " btn btn-danger " > Cancel </ a >
< button type = " submit " name = " submit " class = " btn btn-success float-end " > Validate </ button >
</ div >
</ div >
2022-03-14 11:28:54 +00:00
</ div >
</ div >
</ div >
</ form >
@ endsection