Free cookie consent management tool by TermsFeed Policy Generator

source: branches/WebApplication/MVC2/HeuristicLabWeb.PluginHost/HLWebPluginHost/Content/jQuery/jQueryPlugins/DataTables-1.7.6/media/unit_testing/tests_onhold/3_ajax/bFilter.js @ 6286

Last change on this file since 6286 was 6286, checked in by dkahn, 13 years ago

#1198 Added jQuery plus plugins

File size: 1.1 KB
Line 
1// DATA_TEMPLATE: empty_table
2oTest.fnStart( "bFilter" );
3
4$(document).ready( function () {
5  /* Check the default */
6  $('#example').dataTable( {
7    "sAjaxSource": "../../../examples/examples_support/json_source.txt"
8  } );
9 
10  oTest.fnWaitTest(
11    "Filtering div exists by default",
12    null,
13    function () { return document.getElementById('example_filter') != null; }
14  );
15 
16  /* Check can disable */
17  oTest.fnWaitTest(
18    "Fltering can be disabled",
19    function () {
20      oSession.fnRestore();
21      $('#example').dataTable( {
22        "sAjaxSource": "../../../examples/examples_support/json_source.txt",
23        "bFilter": false
24      } );
25    },
26    function () { return document.getElementById('example_filter') == null; }
27  );
28 
29  /* Enable makes no difference */
30  oTest.fnWaitTest(
31    "Filtering enabled override",
32    function () {
33      oSession.fnRestore();
34      $('#example').dataTable( {
35        "sAjaxSource": "../../../examples/examples_support/json_source.txt",
36        "bFilter": true
37      } );
38    },
39    function () { return document.getElementById('example_filter') != null; }
40  );
41 
42 
43  oTest.fnComplete();
44} );
Note: See TracBrowser for help on using the repository browser.