diff --git a/titles/idac/frontend/js/idac_scripts.js b/titles/idac/frontend/js/idac_scripts.js index e652337..dffc1ea 100644 --- a/titles/idac/frontend/js/idac_scripts.js +++ b/titles/idac/frontend/js/idac_scripts.js @@ -11,7 +11,7 @@ function evaluateRank(evalId) { } else if (evalId >= 13 && evalId <= 16) { return "Expert"; } else if (evalId >= 17 && evalId <= 20) { - return "Professional"; + return "Pro"; } else if (evalId >= 21 && evalId <= 24) { return "Master"; } else if (evalId == 25) { diff --git a/titles/idac/frontend/ranking/js/scripts.js b/titles/idac/frontend/ranking/js/scripts.js index 900061b..9b2fc57 100644 --- a/titles/idac/frontend/ranking/js/scripts.js +++ b/titles/idac/frontend/ranking/js/scripts.js @@ -19,13 +19,14 @@ function loadRanking(courseId, pageNumber = 1) { var total_pages = data.total_pages; // Generate the HTML table - var tableHtml = '
'; + var tableHtml = '
#Name/CarTimeEvalStore/Date
'; $.each(data.ranking, function (i, ranking) { - tableHtml += ''; + // Add a 1 to the i variable to get the correct rank number + tableHtml += ``; tableHtml += ''; tableHtml += ''; - tableHtml += ''; - tableHtml += ''; + tableHtml += ''; + tableHtml += ''; // Ignore the Store and Date columns on small screens tableHtml += ''; tableHtml += ''; @@ -39,15 +40,15 @@ function loadRanking(courseId, pageNumber = 1) { var paginationHtml = ''; @@ -83,7 +84,7 @@ $(document).ready(function () { // Event delegation for pagination links $("#pagination-ranking").on("click", "a.page-link", function (event) { - event.preventDefault(); // Prevent the default behavior of the link + // event.preventDefault(); // Prevent the default behavior of the link var clickedPage = $(this).data("page"); // Check if the changePage function is not already in progress if (!$(this).hasClass('disabled')) {
#Name/CarTimeEvalStore/Date
' + ranking.rank + '' + ranking.name + '
' + getCarName(ranking.style_car_id) + '
' + formatGoalTime(ranking.record) + '' + evaluateRank(ranking.eval_id) + '' + formatGoalTime(ranking.record) + '' + evaluateRank(ranking.eval_id) + '' + ranking.store + '
' + ranking.update_date + '