diff --git a/horizon/static/horizon/js/horizon.tables.js b/horizon/static/horizon/js/horizon.tables.js index cd93f8282d..b8a5dd9e14 100644 --- a/horizon/static/horizon/js/horizon.tables.js +++ b/horizon/static/horizon/js/horizon.tables.js @@ -307,6 +307,10 @@ $.tablesorter.addParser({ // innertext smashed together with no delimiters, so we need to find // the original cell and grab its first element to do the work var a = $(cell).find('li').first().text().split('.'); + // if the cell doesn't contains the list, try to get the text directly + if (a === "") { + a = $(cell).text().split('.'); + } if (a.length !== 4) { return false; } @@ -323,6 +327,10 @@ $.tablesorter.addParser({ format: function(s, table, cell) { var result = 0; var a = $(cell).find('li').first().text().split('.'); + // if the cell doesn't contains the list, try to get the text directly + if (a === "") { + a = $(cell).text().split('.'); + } var last_index = a.length - 1; // inet_aton(3), Javascript-style. The unsigned-right-shift operation is // needed to keep the result from flipping over to negative when suitably