mirror of
https://github.com/DataTables/DataTables.git
synced 2025-03-15 16:29:16 +01:00
Dev fix: $.fn.dataTable and $.fn.DataTable should both have the same properties available
- This fixes DataTables/DataTables issue #241. - Most of the properties attached are objects, so we want the references to them, rather than a copy, so a simple assignment is all that is needed. Strings etc will continue to work as well.
This commit is contained in:
parent
d4a1028a1d
commit
d0a0ef8ad1
@ -1 +1 @@
|
||||
a3f57e46e1a0429dc63527ce1ea125925226eaa3
|
||||
7f7a3b2ca3e74e671e475d4043ac45c220f984ca
|
||||
|
17
media/js/jquery.dataTables.js
vendored
17
media/js/jquery.dataTables.js
vendored
@ -13717,13 +13717,24 @@
|
||||
} );
|
||||
|
||||
|
||||
// jQuery aliases
|
||||
// jQuery access
|
||||
$.fn.dataTable = DataTable;
|
||||
|
||||
// Legacy aliases
|
||||
$.fn.dataTableSettings = DataTable.settings;
|
||||
$.fn.dataTableExt = DataTable.ext;
|
||||
|
||||
// With a capital `D` we return a DataTables API instance rather than a
|
||||
// jQuery object
|
||||
$.fn.DataTable = function ( opts ) {
|
||||
return $(this).dataTable( opts ).api();
|
||||
};
|
||||
$.fn.dataTableSettings = DataTable.settings;
|
||||
$.fn.dataTableExt = DataTable.ext;
|
||||
|
||||
// All properties that are available to $.fn.dataTable should also be
|
||||
// available on $.fn.DataTable
|
||||
$.each( DataTable, function ( prop, val ) {
|
||||
$.fn.DataTable[ prop ] = val;
|
||||
} );
|
||||
|
||||
|
||||
// Information about events fired by DataTables - for documentation.
|
||||
|
Loading…
x
Reference in New Issue
Block a user