From: Bram Matthys Date: Wed, 26 Apr 2023 18:03:06 +0000 (+0200) Subject: Overview: use the live feed only, don't initially set anything. X-Git-Tag: 0.9~62 X-Git-Url: https://jfr.im/git/irc/unrealircd/unrealircd-webpanel.git/commitdiff_plain/9a4a88b54415ab2ed3e797ed07953c626d02c38b?hp=c16c239b4fd25ec9ecf291ad3901facd2d94b2d7 Overview: use the live feed only, don't initially set anything. This avoids duplicate code and also makes the page load faster on high latency connections. --- diff --git a/index.php b/index.php index 209abd0..73512bb 100644 --- a/index.php +++ b/index.php @@ -8,9 +8,7 @@ if (!isset($config['unrealircd'])) } require_once "inc/header.php"; -require_once "inc/connection.php"; -$stats = $rpc->stats()->get(); ?>

Network Overview

stats()->get(); ⚪LIVE
- user->record; ?> +
-

user->total; ?>

+

@@ -76,7 +74,7 @@ $num_of_panel_admins = count($userlist);
-

channel->total; ?>

+

@@ -98,7 +96,7 @@ $num_of_panel_admins = count($userlist);
-

user->oper; ?>

+

@@ -121,7 +119,7 @@ $num_of_panel_admins = count($userlist);
-

server->total; ?>

+

@@ -148,7 +146,7 @@ $num_of_panel_admins = count($userlist);
-

server_ban->server_ban; ?>

+

@@ -170,7 +168,7 @@ $num_of_panel_admins = count($userlist);
-

server_ban->spamfilter; ?>

+

@@ -192,7 +190,7 @@ $num_of_panel_admins = count($userlist);
-

server_ban->server_ban_exception; ?>

+

@@ -208,12 +206,7 @@ $num_of_panel_admins = count($userlist); server->ulined) { - $bg = "bg-success"; - $tooltip = "Users / Servers"; - } - else - $bg = "bg-warning"; + $bg = "bg-success"; // FIXME: this isn't dynamic ?>
@@ -223,8 +216,8 @@ $num_of_panel_admins = count($userlist);
- -

user->ulined; ?>/server->ulined; ?>

+ +