]> jfr.im git - irc/unrealircd/unrealircd-webpanel.git/blobdiff - servers/index.php
Make "decorated" `server->server->features->software` in server tab
[irc/unrealircd/unrealircd-webpanel.git] / servers / index.php
index a6d34a9e74389fee3de83c94b6b0c2c9e12ceb30..93bebf5c78f2acc5e38baf70d58052637c11df0b 100644 (file)
@@ -20,20 +20,23 @@ Click on a server name to view more information.
                Message::Info("Listing servers which match name: \"" . $_POST['sf_name'] . "\"");
 
        ?>
-       <table class="container-xxl table table-responsive caption-top table-striped">
+       <table class="container-xxl table table-sm table-responsive caption-top table-striped">
        <thead>
                <th scope="col"><h5>Filter:</h5></th>
                <form action="" method="post">
                <th scope="col" colspan="2">Name<input name="sf_name" type="text" class="form-control short-form-control">
-               <th scope="col"> <input class="btn btn-primary" type="submit" value="Search"></th></form>
+               <th scope="col"> <input class="btn btn-primary btn-sm" type="submit" value="Search"></th></form>
        </thead></table>
 
-       <table class="container-xxl table table-responsive caption-top table-striped">
+       <table class="container-xxl table table-sm table-responsive caption-top table-striped">
        <thead class="table-primary">
                <th scope="col"><input type="checkbox" label='selectall' onClick="toggle_server(this)" /></th>
                <th scope="col">Name</th>
+               <th scope="col">Users</th>
+               <th scope="col">Version</th>
                <th scope="col">Host / IP</th>
                <th scope="col">Connected to</th>
+               <th scope="col">Up since</th>
        </thead>
        
        <tbody>
@@ -53,10 +56,18 @@ Click on a server name to view more information.
 
                        echo "<tr>";
                        echo "<th scope=\"row\"><input type=\"checkbox\" value='" . base64_encode($server->id)."' name=\"serverch[]\"></th>";
-                       $isBot = (strpos($server->server->modes, "B") !== false) ? ' <span class="badge-pill badge-dark">Bot</span>' : "";
-                       echo "<td><a href=\"details.php?nick=".$server->id."\">$server->name$isBot</a></td>";
+                       echo "<td><a href=\"details.php?server=".$server->id."\">$server->name</a></td>";
+                       echo "<td>".$server->server->num_users."</td>";
+                       
+                       $s = sinfo_conv_version_string($server);
+
+                       echo "<td>$s</td>";
                        echo "<td>".$server->hostname." (".$server->ip.")</td>";
-                       echo "<td>".$server->server->uplink."</td>";
+                       if (isset($server->server->uplink))
+                               echo "<td>".$server->server->uplink."</td>";
+                       else
+                               echo "<td></td>"; /* self */
+                       echo "<td>".$server->server->boot_time."</td>";
                }
        ?>
        </tbody></table>