Support of out-of-bound rank for PB

pull/3/head
Sami Mokaddem 2017-11-02 15:27:31 +01:00
parent e76240951b
commit 6f3998df68
1 changed files with 5 additions and 1 deletions

View File

@ -197,7 +197,11 @@ function updateProgressHeader(org) {
popoverRank.options.content = generateRankingSheet(rank, data.stepPts, data.points, data.remainingPts);
$('#orgRankDiv').html(getRankIcon(rank, 40, true));
$('#orgNextRankDiv').html(getRankIcon(rank+1, 40, true));
$('#progressBarDiv').width((data.rank - rank)*150); //150 is empty bar width
if (data.rank > 16){
$('#progressBarDiv').width(1*150); //150 is empty bar width
} else {
$('#progressBarDiv').width((data.rank - rank)*150); //150 is empty bar width
}
// update color in other dataTables
datatableTop.rows().every( function() {
var row = this.node();