Skip to content

Commit

Permalink
Merge pull request #777 from mbriskar/WINDUP-840
Browse files Browse the repository at this point in the history
WINDUP-840:The first column (issue name) in the Migration Issues Repo…
  • Loading branch information
jsight committed Dec 3, 2015
2 parents 70d9c7b + a0fdb16 commit 8d98e34
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ body {
margin:23px;
}

.tablesorter > thead > tr > th {
.tablesorter > thead > tr > th.sortable{
cursor:pointer;
background-position: left center;
padding-left: 20px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@
<table id="issues_table" class="table table-hover table-condensed tablesorter">
<thead>
<tr>
<th>Issue</th>
<th>Incidents Found</th>
<th>Story Points per Incident</th>
<th>Total Story Points</th>
<th class="sortable">Issue</th>
<th class="sortable">Incidents Found</th>
<th class="sortable">Story Points per Incident</th>
<th class="sortable">Total Story Points</th>
<th class="col-md-1">Rule</th>
</tr>
</thead>
Expand Down Expand Up @@ -135,7 +135,7 @@
});
});
});
// we need this parser because we are using comma to separate thousands
// we need these parsers because we are using comma to separate thousands and are also sorting links
$.tablesorter.addParser({
id: 'thousands',
is: function(s) {
Expand All @@ -146,15 +146,31 @@
},
type: 'numeric'
});
$.tablesorter.addParser({
id: 'a-elements',
is: function(s)
{
// return false so this parser is not auto detected
return false;
},
format: function(s)
{
// format your data for normalization
return s.replace(new RegExp(/<.*?>/),"");
},
type: 'text'
});
$(document).ready(function() {
$("#issues_table").tablesorter({
selectorHeaders: '> thead > tr > th',
sortList: [[3,1]],
headers: {
// 2nd,3rd,4th columns are parsed using thousands parser
0: {sorter:'a-elements'},
1: {sorter:'thousands'},
2: {sorter:'thousands'},
3: {sorter:'thousands'}
3: {sorter:'thousands'},
4: {sorter: false}
}
});
});
Expand Down

0 comments on commit 8d98e34

Please sign in to comment.