diff --git a/src/fares_site/serve.py b/src/fares_site/serve.py index 4a2253b..be75e98 100644 --- a/src/fares_site/serve.py +++ b/src/fares_site/serve.py @@ -47,19 +47,19 @@ HTML_CONTENT_HEADER = """ -
-
+
+
Ballast-Data Product
Contact: Non-Doxxing Email Lorum Ipsum
Some Header Content

-
+
-
+

- RailFares
+ Fares

""" @@ -67,7 +67,7 @@ Some Header Content HTML_CONTENT_FOOTER = """

-
+
Open Rail Data Disclaimer Etc. | No Guarantees or Whatever | We do freelance and dont want to be poor.
@@ -100,7 +100,7 @@ class FaresHandler(BaseHTTPRequestHandler): text += ( ' Flow Fares \n' ) - for flow_fares in data: + for flow_fares in sorted(data, key=lambda d: d["flow_id"]["flow_id"]): flow_table = ( pd.json_normalize(flow_fares["flow_id"]) .rename(COLUMN_RENAMES, axis=1) @@ -116,9 +116,9 @@ class FaresHandler(BaseHTTPRequestHandler): ) _ = fares_table.hide(axis=0) - text += ' \n ' + text += ' \n ' text += flow_table.to_html() - text += ' ' + text += ' ' text += fares_table.to_html() text += " \n " text += ""