62 lines
2.1 KiB
PHP
62 lines
2.1 KiB
PHP
@use(App\Models\Address)
|
|
|
|
@extends('layouts.app')
|
|
@section('htmlheader_title')
|
|
Link
|
|
@endsection
|
|
|
|
@section('content')
|
|
<form class="needs-validation" method="post" autocomplete="off" novalidate>
|
|
@csrf
|
|
|
|
<div class="row">
|
|
<div class="col-12">
|
|
<div class="greyframe titledbox shadow0xb0">
|
|
<h2 class="cap">Enter your Link code</h2>
|
|
|
|
<!-- SYSTEM -->
|
|
<div class="row">
|
|
<!-- Name -->
|
|
<div class="col-5">
|
|
@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/>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- 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>
|
|
</div>
|
|
|
|
<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>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
@endsection |