From ee3ca08f0ef20d990893700e77ceab53669ca9d3 Mon Sep 17 00:00:00 2001 From: "jakub.salavec" Date: Thu, 17 Apr 2025 17:24:17 +0200 Subject: [PATCH] Added - warning that clearing server cache can break live tournaments --- .../src/main/web/includes/admin/generalAdmin.html | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/gemp-lotr/gemp-lotr-async/src/main/web/includes/admin/generalAdmin.html b/gemp-lotr/gemp-lotr-async/src/main/web/includes/admin/generalAdmin.html index 9df1279f6..35e7d930f 100644 --- a/gemp-lotr/gemp-lotr-async/src/main/web/includes/admin/generalAdmin.html +++ b/gemp-lotr/gemp-lotr-async/src/main/web/includes/admin/generalAdmin.html @@ -24,7 +24,18 @@ $("#shutdown-response").html(string); }); }); - + + hall.comm.getLiveTournaments( + function (xml) { + var root = xml.documentElement; + if (root.tagName == 'tournaments') { + var tournaments = root.getElementsByTagName("tournament"); + if (tournaments.length > 0) { + $("#cache-response").html("Ready.
Live tournaments: " + tournaments.length + "
THE ABOVE TOURNAMENTS WILL BE INTERRUPTED AND MAY NOT BE ABLE TO BE RESUMED"); + } + } + }); + $("#clear-cache-button").button().click( function () { $("#cache-response").html("Processing...");