From d4ab380c837d2dc0f396bb993d1120ebea637ef4 Mon Sep 17 00:00:00 2001 From: Aaron Kimbrell Date: Wed, 30 Sep 2026 10:47:58 -0500 Subject: [PATCH] feat(dashboard): updates on the About page and a version badge on the home page About says what build is running (a release, or a local development or CI build with its commit, branch and uncommitted changes), the newest release with its notes, how many commits behind the build is with the compare link, the last check and any error, and Check now. The home page's Server Status card shows the build and an Update available badge. Co-Authored-By: Claude Opus 5.5 --- dDashboardServer/routes/DashboardRoutes.cpp | 5 +- dDashboardServer/templates/about.jinja2 | 79 ++++++++++++++++++- .../templates/server_status.jinja2 | 10 ++- 3 files changed, 91 insertions(+), 3 deletions(-) diff --git a/dDashboardServer/routes/DashboardRoutes.cpp b/dDashboardServer/routes/DashboardRoutes.cpp index 5b3e91f9f..3cddd1389 100644 --- a/dDashboardServer/routes/DashboardRoutes.cpp +++ b/dDashboardServer/routes/DashboardRoutes.cpp @@ -24,6 +24,7 @@ #include "BehaviorXml.h" #include "ClientAssets.h" #include "BuildInfo.h" +#include "UpdateChecker.h" #include #include #include @@ -249,6 +250,7 @@ void RegisterDashboardRoutes() { data["my_characters"] = Database::Get()->GetAccountCharacters(context.accountId); data["stats"]["totalAccounts"] = Database::Get()->GetAccountCount(); data["stats"]["totalCharacters"] = Database::Get()->GetCharacterCount(); + data["update"] = UpdateChecker::Json(); RenderPage(reply, context, "index.jinja2", "home", data); }); @@ -461,7 +463,8 @@ void RegisterDashboardRoutes() { SimplePage("/client_assets", Perm("client_files"), "client_assets.jinja2", "client_assets", "Browse the game client's files"); Route(eHTTPMethod::GET, "/about", 0, "About this server", [](HTTPReply& reply, const HTTPContext& context) { RenderPage(reply, context, "about.jinja2", "about", { {"version", std::string(BuildInfo::buildString)}, - {"commit", std::string(BuildInfo::commit)}, {"dirty", BuildInfo::dirty}, {"buildKind", std::string(BuildInfo::BuildKindName())} }); + {"commit", std::string(BuildInfo::commit)}, {"dirty", BuildInfo::dirty}, {"buildKind", std::string(BuildInfo::BuildKindName())}, + {"update", UpdateChecker::Json()} }); }); // Logs diff --git a/dDashboardServer/templates/about.jinja2 b/dDashboardServer/templates/about.jinja2 index 95e92fba0..be7aa2676 100644 --- a/dDashboardServer/templates/about.jinja2 +++ b/dDashboardServer/templates/about.jinja2 @@ -7,7 +7,8 @@
DarkflameServer {{ version }}
-

{{ buildKind }} build{% if commit %} of commit {{ commit }}{% if dirty %} with uncommitted changes{% endif %}{% endif %}

+

This server is running {{ update.build.description }}{% if update.build.branch and not update.build.release %} from the {{ update.build.branch }} branch{% endif %}. + {% if commit %}Commit {{ commit }}.{% endif %}

A server emulator for LEGO® Universe. This dashboard is part of the server and replaces the separate NexusDashboard.

+ +
+
+
Updates
+ +
+
+
+

+
+ {% if can.settings %}{% endif %} + +
+

Only checks GitHub; nothing is downloaded or installed.{% if can.settings %} Set it up under Settings, Dashboard, Update check.{% endif %}

+
+

LEGO® is a trademark of the LEGO Group. DarkflameServer is not affiliated with, sponsored or endorsed by the LEGO Group.

{% endblock %} + +{% block scripts %} + +{% endblock %} diff --git a/dDashboardServer/templates/server_status.jinja2 b/dDashboardServer/templates/server_status.jinja2 index 27e488c05..5d9cfd1ce 100644 --- a/dDashboardServer/templates/server_status.jinja2 +++ b/dDashboardServer/templates/server_status.jinja2 @@ -27,10 +27,18 @@ Offline {% endif %} -
+
Active Worlds {{ stats.worlds }}
+ {# The running build, and whether GitHub has something newer (the About page has the details) #} +