datatable.directory codebase
https://datatable.directory/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
29 lines
567 B
29 lines
567 B
{{--
|
|
args: $rows, $cols
|
|
--}}
|
|
|
|
@php
|
|
/** @var object[] $columns */
|
|
/** @var \App\Models\Row[] $rows */
|
|
@endphp
|
|
|
|
<table class="table table-hover table-sm">
|
|
<thead>
|
|
<tr>
|
|
<th>_id</th>
|
|
@foreach($columns as $col)
|
|
<th>{{$col->name}} ("{{ $col->title }}") [ {{$col->id}} ]</th>
|
|
@endforeach
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@foreach($rows as $row)
|
|
<tr>
|
|
<td>{{ $row->_id }}</td>
|
|
@foreach($columns as $col)
|
|
<td data-id="{{ $row->_id }}">{{ $row->{$col->name} }}</td>
|
|
@endforeach
|
|
</tr>
|
|
@endforeach
|
|
</tbody>
|
|
</table>
|
|
|