From 97d5aac8286db440c0d158f4c10ba9d4e9228b1f Mon Sep 17 00:00:00 2001 From: Michel Weimerskirch Date: Mon, 22 Dec 2014 17:35:09 +0100 Subject: [PATCH 1/4] Bootstrap integration: replace images with font icons --- .../bootstrap/3/dataTables.bootstrap.css | 25 +++++++++++++------ 1 file changed, 18 insertions(+), 7 deletions(-) diff --git a/integration/bootstrap/3/dataTables.bootstrap.css b/integration/bootstrap/3/dataTables.bootstrap.css index f65e264..dec2c7f 100644 --- a/integration/bootstrap/3/dataTables.bootstrap.css +++ b/integration/bootstrap/3/dataTables.bootstrap.css @@ -71,18 +71,29 @@ table.dataTable thead .sorting_desc, table.dataTable thead .sorting_asc_disabled, table.dataTable thead .sorting_desc_disabled { cursor: pointer; + position: relative; } -table.dataTable thead .sorting { background: url('../images/sort_both.png') no-repeat center right; } -table.dataTable thead .sorting_asc { background: url('../images/sort_asc.png') no-repeat center right; } -table.dataTable thead .sorting_desc { background: url('../images/sort_desc.png') no-repeat center right; } +table.dataTable thead th.sorting:after, +table.dataTable thead th.sorting_asc:after, +table.dataTable thead th.sorting_desc:after { + position: absolute; + top: 8px; + right: 8px; + display: block; + font-family: 'Glyphicons Halflings'; + content: "\e150"; /* sort */ + color: #999; +} +table.dataTable thead th.sorting_asc:after { color: #333; content: "\e155"; /* sort-by-attributes */ } +table.dataTable thead th.sorting_desc:after { color: #333; content: "\e156"; /* sort-by-attributes-alt */ } -table.dataTable thead .sorting_asc_disabled { background: url('../images/sort_asc_disabled.png') no-repeat center right; } -table.dataTable thead .sorting_desc_disabled { background: url('../images/sort_desc_disabled.png') no-repeat center right; } +table.dataTable thead .sorting_asc_disabled:after, +table.dataTable thead .sorting_desc_disabled:after { color: #eee } table.dataTable thead > tr > th { - padding-left: 18px; - padding-right: 18px; + padding-left: 8px; + padding-right: 30px; } table.dataTable th:active { From 7d5e7f49576cb4bb214e5e77f9579ba833f4a6bd Mon Sep 17 00:00:00 2001 From: Batmandakh Date: Sat, 31 Jan 2015 16:09:48 +0800 Subject: [PATCH 2/4] Create Mongolian.lang Created Mongolian translation. --- i18n/Mongolian.lang | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 i18n/Mongolian.lang diff --git a/i18n/Mongolian.lang b/i18n/Mongolian.lang new file mode 100644 index 0000000..09014c4 --- /dev/null +++ b/i18n/Mongolian.lang @@ -0,0 +1,30 @@ +/** + * Mongolian - Монгол хэлний орчуулга + * @name Mongolian + * @anchor Mongolian + * @author Batmandakh Erdenebileg + */ + +{ + "sEmptyTable": "Хүснэгтэнд ямар ч мэдээлэл алга", + "sInfo": "Нийт _TOTAL_ бичлэгийн _START_ - _END_ харуулж байна", + "sInfoEmpty": "Нийт 0 бичлэгийн 0 - 0 харуулж байна", + "sInfoFiltered": "(нийт _MAX_ бичлэгээс шүүв)", + "sInfoPostFix": "", + "sInfoThousands": ",", + "sLengthMenu": "Дэлгэцэд _MENU_ бичлэг харуулна", + "sLoadingRecords": "Ачаалж байна...", + "sProcessing": "Боловсруулж байна...", + "sSearch": "Хайлт:", + "sZeroRecords": "Тохирох бичлэг олдсонгүй", + "oPaginate": { + "sFirst": "Эхнийх", + "sLast": "Сүүлийнх", + "sNext": "Өмнөх", + "sPrevious": "Дараах" + }, + "oAria": { + "sSortAscending": ": цагаан толгойн дарааллаар эрэмбэлэх", + "sSortDescending": ": цагаан толгойн эсрэг дарааллаар эрэмбэлэх" + } +} From 7e21bad999ffe5457822008fb07bd1f971a4f5af Mon Sep 17 00:00:00 2001 From: Batmandakh Date: Sat, 7 Feb 2015 15:09:30 +0800 Subject: [PATCH 3/4] Fixed misspelled word - Mongolian.lang MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixed misspelled word from "Хүснэгтэнд" to "Хүснэгтэд". I'm sorry for wrong typed word... --- i18n/Mongolian.lang | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/Mongolian.lang b/i18n/Mongolian.lang index 09014c4..c603515 100644 --- a/i18n/Mongolian.lang +++ b/i18n/Mongolian.lang @@ -6,7 +6,7 @@ */ { - "sEmptyTable": "Хүснэгтэнд ямар ч мэдээлэл алга", + "sEmptyTable": "Хүснэгтэд ямар ч мэдээлэл алга", "sInfo": "Нийт _TOTAL_ бичлэгийн _START_ - _END_ харуулж байна", "sInfoEmpty": "Нийт 0 бичлэгийн 0 - 0 харуулж байна", "sInfoFiltered": "(нийт _MAX_ бичлэгээс шүүв)", From baf1ab3435759aeeb89c2d27d931a0b8d14ba87a Mon Sep 17 00:00:00 2001 From: Rasmey SARETH Date: Sun, 8 Feb 2015 01:11:11 +0100 Subject: [PATCH 4/4] FIX: Considering the milliseconds for ordering --- sorting/datetime-moment.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sorting/datetime-moment.js b/sorting/datetime-moment.js index 0bb713b..35af232 100644 --- a/sorting/datetime-moment.js +++ b/sorting/datetime-moment.js @@ -41,7 +41,7 @@ $.fn.dataTable.moment = function ( format, locale ) { types.order[ 'moment-'+format+'-pre' ] = function ( d ) { return d === '' || d === null ? -Infinity : - moment( d, format, locale, true ).unix(); + parseInt( moment( d, format, locale, true ).format( 'x' ), 10 ); }; };