Skip to content

Commit eb200f8

Browse files
committed
Make sorting a toggle
If the commitfest entries are sorted by a column clicking the header again will now remove the sort. In a future commit, it would be nice to also support for reverse sorting.
1 parent 226959a commit eb200f8

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Diff for: media/commitfest/js/commitfest.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,11 @@ function flagCommitted(committer) {
222222

223223

224224
function sortpatches(sortby) {
225-
$('#id_sortkey').val(sortby);
225+
if ($('#id_sortkey').val() == sortby) {
226+
$('#id_sortkey').val(0);
227+
} else {
228+
$('#id_sortkey').val(sortby);
229+
}
226230
$('#filterform').submit();
227231

228232
return false;

0 commit comments

Comments
 (0)