mirror of
https://github.com/ansible/awx.git
synced 2026-05-24 09:07:45 -02:30
Job detail page
Fixed key sorting. Turns out reverse() doesn't sort keys in reverse, it just reverses them. To sort in reverse: sort().reverse(). Ugh. Fixed JS liting issues for dashboard stuff.
This commit is contained in:
@@ -947,7 +947,7 @@ function($rootScope, $log, UpdatePlayStatus, UpdateHostStatus, AddHostResult, Ge
|
||||
newKeys = [],
|
||||
plays = JSON.parse(JSON.stringify(scope.jobData.plays)),
|
||||
keys = Object.keys(plays);
|
||||
keys.reverse();
|
||||
keys.sort().reverse();
|
||||
for (idx=0; idx < scope.playsMaxRows && idx < keys.length; idx++) {
|
||||
newKeys.push(keys[idx]);
|
||||
}
|
||||
@@ -973,7 +973,7 @@ function($rootScope, $log, UpdatePlayStatus, UpdateHostStatus, AddHostResult, Ge
|
||||
if (scope.activePlay) {
|
||||
tasks = JSON.parse(JSON.stringify(scope.jobData.plays[scope.activePlay].tasks));
|
||||
keys = Object.keys(tasks);
|
||||
keys.reverse();
|
||||
keys.sort().reverse();
|
||||
newKeys = [];
|
||||
for (idx=0; result.length < scope.tasksMaxRows && idx < keys.length; idx++) {
|
||||
newKeys.push(keys[idx]);
|
||||
|
||||
Reference in New Issue
Block a user