[TASK] Followup: Update dataTables to 1.10.4 and fix parameter names 97/34897/2
authorStefan Neufeind <typo3.neufeind@speedpartner.de>
Mon, 1 Dec 2014 22:51:26 +0000 (23:51 +0100)
committerMarkus Klein <klein.t3@reelworx.at>
Tue, 2 Dec 2014 01:01:53 +0000 (02:01 +0100)
Use DataTables instead of dataTables to access the API.
Also switch to the new API.
https://datatables.net/reference/api/

Followup to change-id If564b1797a81ce63730ebf2601cc62058940493c

Change-Id: I81e2024f5a7d4032cfa65def91699bf9cbdd2982
Resolves: #63479
Releases: master
Reviewed-on: http://review.typo3.org/34897
Reviewed-by: Christoph Hofmann <typo3@its-hofmann.de>
Tested-by: Christoph Hofmann <typo3@its-hofmann.de>
Reviewed-by: Markus Klein <klein.t3@reelworx.at>
Tested-by: Markus Klein <klein.t3@reelworx.at>
typo3/sysext/documentation/Resources/Public/JavaScript/main.js
typo3/sysext/extensionmanager/Resources/Public/JavaScript/main.js
typo3/sysext/extensionmanager/Resources/Public/JavaScript/ter.js
typo3/sysext/lang/Resources/Public/JavaScript/LangModule.js

index 2695850..61712a1 100644 (file)
@@ -24,7 +24,7 @@ TYPO3.DocumentationApplication = {
        },
        // Initializes the list view
        documentationListView: function(getVars) {
-               this.datatable = jQuery('#typo3-documentation-list').dataTable({
+               this.datatable = jQuery('#typo3-documentation-list').DataTable({
                        'paging': false,
                        'jQueryUI': true,
                        'lengthChange': false,
@@ -34,12 +34,12 @@ TYPO3.DocumentationApplication = {
 
                // restore filter
                if (this.datatable.length && getVars['search']) {
-                       this.datatable.fnFilter(getVars['search']);
+                       this.datatable.search(getVars['search']);
                }
        },
        // Initializes the download view
        documentationDownloadView: function(getVars) {
-               this.datatable = jQuery('#typo3-documentation-download').dataTable({
+               this.datatable = jQuery('#typo3-documentation-download').DataTable({
                        'paging': false,
                        'jQueryUI': true,
                        'lengthChange': false,
@@ -50,7 +50,7 @@ TYPO3.DocumentationApplication = {
 
                // restore filter
                if (this.datatable.length && getVars['search']) {
-                       this.datatable.fnFilter(getVars['search']);
+                       this.datatable.search(getVars['search']);
                }
        }
 };
@@ -65,7 +65,7 @@ TYPO3.DocumentationApplication = {
                // Make the data table filter react to the clearing of the filter field
                $('.dataTables_wrapper .dataTables_filter input').clearable({
                        onClear: function() {
-                               TYPO3.DocumentationApplication.datatable.fnFilter('');
+                               TYPO3.DocumentationApplication.datatable.search('');
                        }
                });
        });
index df23c8e..238b787 100644 (file)
@@ -11,7 +11,7 @@
 
                $('.dataTables_wrapper .dataTables_filter input').clearable({
                        onClear: function() {
-                               datatable.fnFilter('');
+                               datatable.search('');
                        }
                });
 
@@ -44,7 +44,7 @@
        }
 
        function manageExtensionListing() {
-               datatable = $('#typo3-extension-list').dataTable({
+               datatable = $('#typo3-extension-list').DataTable({
                        'paging': false,
                        'jQueryUI': true,
                        'lengthChange': false,
@@ -67,7 +67,7 @@
 
                // restore filter
                if(datatable.length && getVars['search']) {
-                       datatable.fnFilter(getVars['search']);
+                       datatable.search(getVars['search']);
                }
        }
 
index 51f5746..b0f5217 100644 (file)
@@ -2,7 +2,7 @@
 (function ($) {
 
        $(document).ready(function() {
-               $('#terTable').dataTable({
+               $('#terTable').DataTable({
                        'jQueryUI': true,
                        'lengthChange': false,
                        'pageLength': 15,
@@ -14,7 +14,7 @@
                        'drawCallback': bindDownload
                });
 
-               $('#terVersionTable').dataTable({
+               $('#terVersionTable').DataTable({
                        'jQueryUI': true,
                        'lengthChange': false,
                        'pageLength': 15,
@@ -36,7 +36,7 @@
                        ]
                });
 
-               $('#terSearchTable').dataTable({
+               $('#terSearchTable').DataTable({
                        'paging': false,
                        'jQueryUI': true,
                        'lengthChange': false,
index f91c111..9deb865 100644 (file)
@@ -56,7 +56,7 @@ var languageModule = {
        initialize: function() {
                        // Initialize dataTable for selection and translation list
                languageModule.tableSetup.sScrollY = languageModule.calculateTableHeight();
-               jQuery('.selectionList, .translationList').dataTable(languageModule.tableSetup);
+               jQuery('.selectionList, .translationList').DataTable(languageModule.tableSetup);
 
                        // Prevent "jumping" style of the tables while generating
                jQuery('.languageSelectionListContainer').css('visibility', 'visible');