@foreach($staff as $sta)
@php
$checked = false;
if(!empty($preSelectedStaff[$sta->id])) $checked = true;
@endphp
{!! Form::checkbox('attach_staff['.$sta->id.']', $sta->id, $checked,
['id' => 'attach_staff_'.$sta->id, 'class' => 'p-0']) !!}
{!! Form::label('attach_staff_'.$sta->id, $sta->user->name) !!}
@endforeach
{!! Form::number('', 14, ['id' => 'days-ahead']) !!}
Start
@php
$start_date = null;
if(!empty($time_slot->start)){
$start_date = $time_slot->start->format('Y-m-d\TH:m');
}
@endphp
{!! Form::datetimeLocal('start', $start_date, ['id' => 'start']) !!}
Finish
@php
$end_date = null;
if(!empty($time_slot->end)){
$end_date = $time_slot->end->format('Y-m-d\TH:m');
}
@endphp
{!! Form::datetimeLocal('end', $end_date, ['id' => 'end']) !!}
@if(!empty($appointment_type))
Appointment type
{!! Form::select('appointment_type', $timeslot_types, null,
['id' => 'type-select']) !!}
@else
Type
{!! Form::select('type', $timeslot_types, null,
['id' => 'type-select']) !!}
@endif
Area
{!! Form::select('area_id', $areas, null,
['id' => 'area-select']) !!}