diff --git a/ffmap/stattools.py b/ffmap/stattools.py index 770bc64..997cb5a 100644 --- a/ffmap/stattools.py +++ b/ffmap/stattools.py @@ -203,11 +203,12 @@ def hoods(mysql,selectgw=None): FROM router LEFT JOIN hoods ON router.hood = hoods.id GROUP BY hoods.id, hoods.name, status + ORDER BY hoods.name """) result = {} for rs in data: if not rs["hood"]: - rs["hoodid"] = "1" + rs["hoodid"] = 1 rs["hood"] = "NoHood" if not rs["hoodid"] in result: result[rs["hoodid"]] = {'name':rs["hood"]} diff --git a/ffmap/web/templates/statistics.html b/ffmap/web/templates/statistics.html index d799fad..9de6937 100644 --- a/ffmap/web/templates/statistics.html +++ b/ffmap/web/templates/statistics.html @@ -252,7 +252,7 @@ {%- endif -%} $("#hoodlist").DataTable({ - "order": [], + "order": [[0,'asc']], "paging": false, "info": false, "searching": false,