Files
opensem/resources/views/components/form/options/options-complex.blade.php
2021-10-30 02:22:51 +02:00

15 lines
393 B
PHP

@if (isset($list) && count($list))
@foreach($list as $item)
<option
@if (isset($value) && ($item['id'] == $value)) selected @endif value="{{$item['id']}}"
@foreach($item as $item_key => $item_value)
@if (($item_key != 'id') && ($item_key != 'txt'))
data-{{ $item_key }}="{{ $item_value }}"
@endif
@endforeach
>
{{ $item['txt'] }}
</option>
@endforeach
@endif