Fix for accessing an object instead of an array
This commit is contained in:
parent
ec2947936b
commit
3f4c46edbc
|
@ -3,8 +3,8 @@
|
|||
<select class="form-control" name="{{$name ?? 'location_id'}}">
|
||||
@foreach ($locations as $location)
|
||||
<option
|
||||
value="{{ $location->id }}" {{(isset($current) && (string)$current === (string)$location->id)? 'selected' : ''}}>
|
||||
{{ $location->name }}
|
||||
value="{{ $location['id'] }}" {{(isset($current) && (string)$current === (string)$location['id'])? 'selected' : ''}}>
|
||||
{{ $location['name'] }}
|
||||
</option>
|
||||
@endforeach
|
||||
</select>
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
<div class="input-group-prepend"><span class="input-group-text">{{ $title ??'OS'}}</span></div>
|
||||
<select class="form-control" name="{{$name ?? 'os_id'}}">
|
||||
@foreach ($os as $o)
|
||||
<option value="{{ $o->id }}" {{(isset($current) && (string)$current === (string)$o->id)? 'selected' : ''}}>
|
||||
{{ $o->name }}
|
||||
<option value="{{ $o['id'] }}" {{(isset($current) && (string)$current === (string)$o['id'])? 'selected' : ''}}>
|
||||
{{ $o['name'] }}
|
||||
</option>
|
||||
@endforeach
|
||||
</select>
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
<div class="input-group-prepend"><span class="input-group-text">{{ $title ??'Provider'}}</span></div>
|
||||
<select class="form-control" name="{{$name ?? 'provider_id'}}">
|
||||
@foreach ($providers as $provider)
|
||||
<option value="{{ $provider->id }}" {{(isset($current) && (string)$current === (string)$provider->id)? 'selected' : ''}}>
|
||||
{{ $provider->name }}
|
||||
<option value="{{ $provider['id'] }}" {{(isset($current) && (string)$current === (string)$provider['id'])? 'selected' : ''}}>
|
||||
{{ $provider['name'] }}
|
||||
</option>
|
||||
@endforeach
|
||||
</select>
|
||||
|
|
Loading…
Reference in New Issue
Block a user