From f5fc440ae47bc8ff6e4b80ce1dd8905db3da189c Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 12 十二月 2024 14:54:15 +0800
Subject: [PATCH] 10162 后台优化(等级分布、在线人数子服查询默认否;在线人数支持勾选查询单服历史;)
---
serverinfo/online.php | 18 +++++++++++++++++-
1 files changed, 17 insertions(+), 1 deletions(-)
diff --git a/serverinfo/online.php b/serverinfo/online.php
index 2cdedd8..99d1635 100644
--- a/serverinfo/online.php
+++ b/serverinfo/online.php
@@ -19,8 +19,12 @@
// 榛樿褰撳ぉ
$startDate = array_key_exists("startDate", $_POST) ? $_POST["startDate"] : date("Y-m-d");
$endDate = array_key_exists("endDate", $_POST) ? $_POST["endDate"] : date("Y-m-d");
+$onlyServerIDHis = $_POST["onlyServerIDHis"];
+$OnlyServerID = null;
+if ($onlyServerIDHis == "on") {
+ $OnlyServerID = 1; // 榛樿鍙煡鎸囧畾鏈�
+}
-$OnlyServerID = 1; // 榛樿鍙煡鎸囧畾鏈�
// 璁剧疆榛樿鏁版嵁锛屽紑鐣岄潰榛樿鏌ラ�変腑鏈�
$_POST["startDate"] = $startDate;
$_POST["endDate"] = $endDate;
@@ -61,6 +65,10 @@
~
<input type="text" name="endDate" id="endDate" onclick="new Calendar().show(this);" readonly value="<?php echo $endDate; ?>" size="8" />
<input type="submit" value="<?php echo \Lang\gettext("鏌ヨ鏈湇"); ?>" onclick="onCurSubmit()" />
+ <?php
+ echo " ";
+ echo '<input type="checkbox" name="onlyServerIDHis" id="onlyServerIDHis" ' . ($onlyServerIDHis == "on" ? "checked" : "") . ' onchange="onOnlyServerIDHisChange()" />' . \Lang\gettext("鏌ヨ鍗曟湇鍘嗗彶");
+ ?>
<div id="OnlinePlayerInfo"></div>
<hr />
<?php
@@ -107,6 +115,14 @@
}
}
+ function onOnlyServerIDHisChange() {
+ if (document.getElementById("onlyServerIDHis").checked) {
+ document.getElementById("OnlyServerID").selectedIndex = 1;
+ } else {
+ document.getElementById("OnlyServerID").selectedIndex = 0;
+ }
+ }
+
function drawChartLine(chartID, serverName, drData) {
var backgroundColors = [
--
Gitblit v1.8.0