Search
11364 results 2081-2090
Forum
- 9th Sep 2016Add extra filter criteria from a separate formI have a vanilla DataTable based on a Doctrine entity Chemical: $(document).ready(function() { $('#chemical).DataTable( { "processing": true, "serverSide": true, "ajax": ""/CIR/web/app_dev.php/chemical/filter" } ); } ); The entity is linked to many other entities that don't need to be displayed in the table. But they would be extremely useful for limiting the result-set. For example, a user may wish to see only those Chemicals that have Supplies which have Items. For overhead reasons, I'd prefer not to include these other entities in a query unless I have to. What I'd like to do is modify the request parameters that Datatables sends by including the field values from a separate form. Can I set option ajax = function(){ }? What is passed to the function? Is there a preferred way of modifying Datatables request parameters?
- 2nd Sep 2016Filter, length and button controls wont be on one line togetherhttps://datatables.net/examples/advanced_init/dom_multiple_elements.html I cannot understand why this is not working. I THINK it might be related to bootstraps code but i cannot actually see "row" being applied anyway on the rows. For some reason each of these elements (no matter how much i try to force them together) do not want to just sit together on one row. This is the best I have got '<"searcharea col-md-5"f> <"col-md-2" l> <"exportButtons col-md-5"B> <"col-md-12"t><"col-md-6"i><"col-md-6"p>', But I want the Length control to sit nicely next to the filter/search control. If I do this '<"searcharea col-md-7"fl> <"exportButtons col-md-5"B> <"col-md-12"t><"col-md-6"i><"col-md-6"p>', then it puts the F and L together but on new lines on the left, then the Button controls on the right! It's driving me insane.
- 29th Aug 2016Dropdown + filter working togetherIs it possible to have the dropdown filtering based on a search key term like the example below. Thanks. http://sandbox.scriptiny.com/tinytablev3/
- 19th Aug 2016How to create a global search filter for certain column?I have 5 separate tables on my page with the same columns structure. In this page I need to create a search box that would perform search query in all given tables but in the same column. I used reg. exp. Search API functions which are described here: https://datatables.net/examples/api/regex.html This is my jquery code: function filterColumn ( i ) { $('.table').DataTable().column( i ).search( $('#col'+i+'_filter').val(), $('#col'+i+'_regex').prop('checked'), $('#col'+i+'_smart').prop('checked') ).draw(); } $(document).ready(function() { $('.table').DataTable({ }); $('input.column_filter').on( 'keyup click', function () { filterColumn( $(this).parents('tr').attr('data-column') ); } ); } ); This code works fine and it really performs the search query in columns but only in the 1st table. But I want it to make the same search query in all my 5 tables. What should I change in this code? Please, help.
- 8th Aug 2016How can I reset my jquery datatable when I filter the associated jquery donut chart?I have a datatable with a donut chart. When I click a section I want to reset the pagination of the table. $("#myForm").submit(function(e) { table.fnPageChange(0); table.fnReloadAjax(); return false; }); Something like this may work?
- 3rd Aug 2016Default filter on load tableinside that table, without filtering anything before. Anyone with
- 2nd Aug 2016Select filter only shows first pages unique dataI am using datatables with ajax-datatables-rails in my Rails 4 site. The table is working beautifully, but it currently only shows selectable unique data from the first page (10 results per page). I would like to show all but cannot find any documentation on this, which is needed due to my lack of proficiency with javascript. I've also switched from the coffeescript file to in-page javascript due to an issue with coffeescript not liking the ", true, false" bit on line 16. Still not working though. Here is the javascript in my index view: $(document).ready(function() { $('#search-table').DataTable( { processing: true, serverSide: true, ajax: $('#search-table').data('source'), initComplete: function () { this.api().columns().every( function () { var column = this; var select = $('<select><option value=""></option></select>') .appendTo( $(column.footer()).empty() ) .on( 'change', function () { var val = $.fn.dataTable.util.escapeRegex( $(this).val() ); column .search( val ? '^'+val+'$' : '', true, false ) .draw(); } ); column.data().unique().sort().each( function ( d, j ) { select.append( '<option value="'+d+'">'+d+'</option>' ) } ); } ); } } ); } );
- 13th Jun 2016SharePoint - search box, filter and navigation not workingI've linked both .js file and .css file in my code as below ,but it shows the grid with my data but its not showing pagination/filter/sorting.. Am using a visual webpart and below is my code for ascx file <script type="text/javascript"> $(document).ready(function () { $('#GridView1').dataTable({ "sPaginationType": "full_numbers", "aaSorting": [], "lengthMenu": [[10, 25, 50, -1], [10, 25, 50, "All"]], "pageLength": 14, //"scrollY": "200px", //"scrollCollapse": true, "sDom": 'T<"clear">lfrtip', "tableTools": { "sSwfPath": "http://www.datatables.net/release-datatables/extensions/TableTools/swf/copy_csv_xls_pdf.swf" }, /* Disable initial sort */ "bDestroy": true, "bProcessing": true, "bpaging": false, "bSort": false }); }); </script> Please help
- 2nd Jun 2016Filter Problem When Using render FunctionDataTable example where the filtering functionality seems not to
- 1st Jun 2016Show entries are not updating after using filter or no. of entries..not updating after using filters or number of entries