diff --git a/web/OJ/template/hznu/daliy_detail.php b/web/OJ/template/hznu/daliy_detail.php index d11e3ea4..e8bef664 100644 --- a/web/OJ/template/hznu/daliy_detail.php +++ b/web/OJ/template/hznu/daliy_detail.php @@ -127,4 +127,4 @@ function getDaliyDetailData(lastday, today, alldata) { } window.addEventListener('resize', myChart.resize); - \ No newline at end of file + diff --git a/web/OJ/template/hznu/study_detail.php b/web/OJ/template/hznu/study_detail.php index 688f9673..a193b67d 100644 --- a/web/OJ/template/hznu/study_detail.php +++ b/web/OJ/template/hznu/study_detail.php @@ -2,100 +2,26 @@ require_once("header.php"); -require_once("study_detail_data.php"); ?> -query($sql); - -while ($row = $result->fetch_assoc()) { - $studydata[$row['tag']] = $row['count']; -} - -$result->free(); - - -///////////////////////////////////////////////////////////////////////////////cs -// if($user == "admin") -// foreach ($studytags as $tag) -// $studydata[$tag] = 1; - -///////////////////////////////////////////////////////////////////////////////cs - -//此处修改层次颜色 -$color = ['#cccccc', '#d0f0c0', '#aadf8f', '#85c96e']; - -$neednum = array(); -$neednum = array_fill_keys($studytags, [0, 1, 2, 4]); -//neednum['xx'] = [0, 1, 2, 4]; - - -foreach ($studytags3 as $tag) { - $studydata[$tagfa[$tag]] = 0; - $neednum[$tagfa[$tag]] = [0, 0, 0, 0]; -} -foreach ($studytags2 as $tag) { - $studydata[$tagfa[$tag]] = 0; - $neednum[$tagfa[$tag]] = [0, 0, 0, 0]; -} - -foreach ($studytags3 as $tag) { - $studydata[$tagfa[$tag]] += $studydata[$tag]; - $counts = $neednum[$tag]; - for ($i = 0; $i < count($counts); $i++) { - $neednum[$tagfa[$tag]][$i] += $counts[$i]; - } -} -foreach ($studytags2 as $tag) { - $studydata[$tagfa[$tag]] += $studydata[$tag]; - $counts = $neednum[$tag]; - for ($i = 0; $i < count($counts); $i++) { - $neednum[$tagfa[$tag]][$i] += $counts[$i]; + -