diff --git a/integration/bootstrap/1/dataTables.bootstrap.css b/integration/bootstrap/1/dataTables.bootstrap.css new file mode 100644 index 0000000..b6850a0 --- /dev/null +++ b/integration/bootstrap/1/dataTables.bootstrap.css @@ -0,0 +1,28 @@ +div.dataTables_length label { + width: 460px; + float: left; + text-align: left; +} + +div.dataTables_length select { + width: 75px; +} + +div.dataTables_filter label { + float: right; + width: 460px; +} + +div.dataTables_info { + padding-top: 8px; +} + +div.dataTables_paginate { + float: right; + margin: 0; +} + +table { + margin: 1em 0; + clear: both; +} \ No newline at end of file diff --git a/pagination/bootstrap3.js b/integration/bootstrap/1/dataTables.bootstrap.js similarity index 67% rename from pagination/bootstrap3.js rename to integration/bootstrap/1/dataTables.bootstrap.js index f867f66..0c3a76f 100644 --- a/pagination/bootstrap3.js +++ b/integration/bootstrap/1/dataTables.bootstrap.js @@ -1,18 +1,19 @@ -/** - * This plug-in provides the mark-up needed for using Twitter Bootstrap's - * pagination styling with DataTables. Note that this plug-in uses the - * fnPagingInfo API plug-in method to obtain paging information. - * @name Twitter Bootstrap - * @anchor bootstrap - * @author Allan Jardine - * - * @example - * $(document).ready(function() { - * $('#example').dataTable( { - * "sPaginationType": "bootstrap" - * } ); - * } ); - */ +/* Set the defaults for DataTables initialisation */ +$.extend( true, $.fn.dataTable.defaults, { + "sDom": "<'row'<'span8'l><'span8'f>r>t<'row'<'span8'i><'span8'p>>", + "sPaginationType": "bootstrap", + "oLanguage": { + "sLengthMenu": "_MENU_ records per page" + } +} ); + + +/* Default class modification */ +$.extend( $.fn.dataTableExt.oStdClasses, { + "sSortAsc": "header headerSortDown", + "sSortDesc": "header headerSortUp", + "sSortable": "header" +} ); /* API method to get paging information */ @@ -44,8 +45,8 @@ $.extend( $.fn.dataTableExt.oPagination, { } }; - $(nPaging).append( - '