[damned-lies] Make table sorting work on all columns (Fixes #653622)
- From: Claude Paroz <claudep src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [damned-lies] Make table sorting work on all columns (Fixes #653622)
- Date: Wed, 29 Jun 2011 09:22:31 +0000 (UTC)
commit b4a921b07a341311e1eb48720fecee66fa1c6500
Author: Claude Paroz <claude 2xlibre net>
Date: Wed Jun 29 11:22:04 2011 +0200
Make table sorting work on all columns (Fixes #653622)
media/css/main.css | 5 +++++
templates/languages/language_release.html | 2 +-
templates/languages/language_release_stats.html | 3 ++-
3 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/media/css/main.css b/media/css/main.css
index d0491f9..1c443c8 100644
--- a/media/css/main.css
+++ b/media/css/main.css
@@ -74,6 +74,11 @@ table.tablesorter thead tr .headerSortDown {
background-image: url(../img/desc.gif);
}
+table.tablesorter th.headerNoSort {
+ background-color: #EEEEEE;
+ border-bottom: #AAAAAA solid 1px;
+}
+
h2 {
width: 100%;
margin-top: 1.5em;
diff --git a/templates/languages/language_release.html b/templates/languages/language_release.html
index 8f65811..db4fed4 100644
--- a/templates/languages/language_release.html
+++ b/templates/languages/language_release.html
@@ -7,7 +7,7 @@
<script type="text/javascript">
$(document).ready(function()
{
- $("#stats-table").tablesorter();
+ $("#stats-table").tablesorter({headers: {3:{sorter: false}}});
$("#stats-table").bind("sortStart",function() {
/* Hide category subheaders when sorting */
$("tr.subheader").hide();
diff --git a/templates/languages/language_release_stats.html b/templates/languages/language_release_stats.html
index 5bf742b..ceb474a 100644
--- a/templates/languages/language_release_stats.html
+++ b/templates/languages/language_release_stats.html
@@ -19,7 +19,8 @@
<table class="tablesorter" name="stats-table" id="stats-table">
<thead>
<tr><th>{% trans "Module" %}</th><th>{% trans "Branch" %}</th>
- <th colspan="2">{% trans "Statistics" %}</th>
+ {# colspan=2 for Statistics is causing offset in sort effect for following columns #}
+ <th>{% trans "Statistics" %}</th><th class="headerNoSort"></th>
<th>{% trans "Status" %}</th><th>{% trans "Date" %}</th>
</tr>
</thead>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]