From 8d0a13729c94f509da1df1145e3985141489ba72 Mon Sep 17 00:00:00 2001 From: Pablo Revilla Date: Mon, 11 Aug 2025 16:07:56 -0700 Subject: [PATCH] add API code for /api/packets --- meshview/templates/stats.html.old | 80 +++++++++++++++++++++++++++++++ 1 file changed, 80 insertions(+) create mode 100644 meshview/templates/stats.html.old diff --git a/meshview/templates/stats.html.old b/meshview/templates/stats.html.old new file mode 100644 index 0000000..a826a0f --- /dev/null +++ b/meshview/templates/stats.html.old @@ -0,0 +1,80 @@ +{% extends "base.html" %} + +{% block css %} + #packet_details { + height: 95vh; + overflow: auto; + } + + .main-container, .container { + max-width: 600px; + margin: 0 auto; + text-align: center; + } + + .card-section { + background-color: #272b2f; + border: 1px solid #474b4e; + padding: 15px 20px; + margin-bottom: 10px; + border-radius: 10px; + transition: background-color 0.2s ease; + } + + .card-section:hover { + background-color: #2f3338; + } + + .section-header { + font-size: 16px; + margin: 0; + font-weight: 500; + } + + .section-value { + font-weight: 700; + color: #03dac6; + } + + .percentage { + font-size: 12px; + color: #ffeb3b; + font-weight: 400; + } + + .main-header { + font-size: 22px; + margin-bottom: 20px; + font-weight: 600; + } +{% endblock %} + +{% block body %} +
+

Mesh Statistics

+ + +
+

+ Total Active Nodes (24 hours):
+ {{ "{:,}".format(total_nodes) }} +

+
+ + +
+

+ Total Packets (14 days): + {{ "{:,}".format(total_packets) }} +

+
+ + +
+

+ Total MQTT Reports (14 days): + {{ "{:,}".format(total_packets_seen) }} +

+
+
+{% endblock %}