datatables needs to know second column is numeric
This commit is contained in:
@@ -21,6 +21,9 @@
|
||||
<script src="https://cdn.datatables.net/1.10.22/js/dataTables.bootstrap4.min.js"></script>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$('#book_table').DataTable( { "paging": false, "searching": false, "info": false, "order": [[1, 'asc']] } );
|
||||
} );
|
||||
$('#book_table').DataTable( {
|
||||
"paging": false, "searching": false, "info": false,
|
||||
"order": [[1, 'asc']],
|
||||
"columnDefs": [ { "type": "num", "targets": 1 } ] } );
|
||||
} );
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user