Fix bug breaking date/time sort

This commit is contained in:
Philip Kirkbride
2017-07-11 15:52:50 -04:00
parent 66d344b3c1
commit 4f9930fc53
3 changed files with 5 additions and 4 deletions

View File

@@ -11,7 +11,8 @@
}
$('thead th.date').data('sortBy', function(th, td, tablesort) {
return moment.utc(td.text()).unix();
var tdTime = td.text().replace("-", "");
return moment.utc(tdTime).unix();
});
$('input.filter-table').parent('div').removeClass('hide');

View File

@@ -87,7 +87,7 @@
<tr>
<th class="five wide">Status</th>
<th class="five wide">Certname</th>
<th class="five wide default-sort">Report</th>
<th class="date five wide default-sort">Report</th>
<th class="one wide"></th>
</tr>
</thead>

View File

@@ -9,8 +9,8 @@
<tr>
<th>Status</th>
<th class="default">Certname</th>
<th class="default-sort">Catalog</th>
<th>Report</th>
<th class="date default-sort">Catalog</th>
<th class="date">Report</th>
<th>&nbsp;</th>
</tr>
</thead>