I had a table that I filled with the items that backend returns like so:
<table id="productsTable" class="bg-white table table-striped table-hover nowrap rounded shadow-xs border-xs mt-2" cellspacing="0">
<thead>
<tr>
@foreach( $field['columns'] as $column )
<th style="font-weight: 600!important;">
{{ $column }}
</th>
@endforeach
</tr>
</thead>
<tbody>
@foreach( $field['items'] as $key => $item )
<tr>
<td>
@if($item['checked'])
<input type="checkbox" id="checkbox_{{$item['id']}}" product_id="{{$item['id']}}" checked>
@else
<input type="checkbox" id="checkbox_{{$item['id']}}" product_id="{{$item['id']}}">
</td>
<td>
{{ $item['name'] }}
</td>
<td>
<input type="text" id="menu_name_{{$item['id']}}" style="width: 100%;" readonly>
</td>
<td>
<input class="form-control form-control-sm" type="number" id="price_{{$item['id']}}" step="0.01" min="1" value="{{$item['price']}}">
</td>
</tr>
@endforeach
</tbody>
</table>
Which then I turn into datatable and everything works allright.
Problem came when I tried to get the same table but with the data loaded by ajax, all the cells are just text and not the elements I want and had on the table.
Is it possible to have custom cells (to add checkboxes, selects, all kind of input types, etc) with an ajax loaded datatable?