How can I implement dataTable ajax load with checkbox filters?
How can I implement dataTable ajax load with checkbox filters?
sebastian.virlan
Posts: 1Questions: 1Answers: 0
I have a lot of checkbox grouped. For example group cities depends on cities table from db, streets depends on street and so .
For example the cities group code:
<div class="form-group">
<div class="button-group">
<button type="button" class="btn btn-default btn-sm btn-block dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
Streets <span class="caret pull-right"></span>
</button>
<ul class="dropdown-menu">
@foreach($streets as $street)
<li>
<input type="checkbox" class="minimal" id="area-{{ $street->slug }}">
<label for="area-{{ $street->slug }}">{{ $street->name }}</label>
</li>
@endforeach
</ul>
</div>
</div>
And the result:
https://i.imgur.com/C2vGt02.png
So how can I collect all the filters and join the tables in backend to return the proper results? Also some of the filters are not in the table because the table would be too long.
Thank you.
This discussion has been closed.