Skip to content

Commit 89e4329

Browse files
author
Marius Cramer
committed
Layout fix: tab toggle and monitor tables
1 parent 5d742c7 commit 89e4329

File tree

2 files changed

+30
-24
lines changed

2 files changed

+30
-24
lines changed

interface/lib/classes/tools_monitor.inc.php

Lines changed: 29 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -91,24 +91,26 @@ function showDiskUsage () {
9191
$html =
9292
'<div class="systemmonitor-state state-'.$record['state'].'">
9393
<div class="systemmonitor-content icons32 ico-'.$record['state'].'">
94-
<table>
94+
<table class="table">
95+
<thead class="dark">
9596
<tr>
96-
<td>'.$app->lng("monitor_diskusage_filesystem_txt").'</td>
97-
<td>'.$app->lng("monitor_diskusage_type_txt").'</td>
98-
<td>'.$app->lng("monitor_diskusage_size_txt").'</td>
99-
<td>'.$app->lng("monitor_diskusage_used_txt").'</td>
100-
<td>'.$app->lng("monitor_diskusage_available_txt").'</td>
101-
<td>'.$app->lng("monitor_diskusage_usage_txt").'</td>
102-
<td>'.$app->lng("monitor_diskusage_mounted_txt").'</td>
103-
</tr>';
97+
<th>'.$app->lng("monitor_diskusage_filesystem_txt").'</th>
98+
<th class="small-col">'.$app->lng("monitor_diskusage_type_txt").'</th>
99+
<th class="tiny-col">'.$app->lng("monitor_diskusage_size_txt").'</th>
100+
<th class="tiny-col">'.$app->lng("monitor_diskusage_used_txt").'</th>
101+
<th class="tiny-col">'.$app->lng("monitor_diskusage_available_txt").'</th>
102+
<th class="tiny-col">'.$app->lng("monitor_diskusage_usage_txt").'</th>
103+
<th>'.$app->lng("monitor_diskusage_mounted_txt").'</th>
104+
</tr></thead>
105+
<tbody>';
104106
foreach($data as $line) {
105107
$html .= '<tr>';
106108
foreach ($line as $item) {
107109
$html .= '<td>' . $item . '</td>';
108110
}
109111
$html .= '</tr>';
110112
}
111-
$html .= '</table>';
113+
$html .= '</tbody></table>';
112114
$html .= '</div></div>';
113115
} else {
114116
$html = '<p>'.$app->lng("no_data_diskusage_txt").'</p>';
@@ -128,12 +130,13 @@ function showDatabaseSize () {
128130
$html =
129131
'<div class="systemmonitor-state state-'.$record['state'].'">
130132
<div class="systemmonitor-content icons32 ico-'.$record['state'].'">
131-
<table><thead><tr>
132-
<td>'.$app->lng("monitor_database_name_txt").'</td>
133-
<td>'.$app->lng("monitor_database_size_txt").'</td>
134-
<td>'.$app->lng("monitor_database_client_txt").'</td>
135-
<td>'.$app->lng("monitor_database_domain_txt").'</td>
136-
</tr>';
133+
<table class="table"><thead class="dark"><tr>
134+
<th>'.$app->lng("monitor_database_name_txt").'</th>
135+
<th class="tiny-col">'.$app->lng("monitor_database_size_txt").'</th>
136+
<th>'.$app->lng("monitor_database_client_txt").'</th>
137+
<th>'.$app->lng("monitor_database_domain_txt").'</th>
138+
</tr></thead>
139+
<tbody>';
137140
foreach($data as $line) {
138141
$html .= '<tr>';
139142
if ($line['size'] > 0) $line['size'] = $app->functions->formatBytes($line['size']);
@@ -150,7 +153,7 @@ function showDatabaseSize () {
150153
foreach ($line as $item) {
151154
$html .= '<td>' . $item . '</td>';
152155
}
153-
$html .= '</tr></tmpl loop>';
156+
$html .= '</tr>';
154157
}
155158
$html .= '</tbody></table></div></div>';
156159
} else {
@@ -174,7 +177,8 @@ function showMemUsage () {
174177
$html =
175178
'<div class="systemmonitor-state state-'.$record['state'].'">
176179
<div class="systemmonitor-content icons32 ico-'.$record['state'].'">
177-
<table>';
180+
<table class="table">
181+
<tbody>';
178182

179183
foreach($data as $key => $value) {
180184
if ($key != '') {
@@ -184,7 +188,7 @@ function showMemUsage () {
184188
</tr>';
185189
}
186190
}
187-
$html .= '</table>';
191+
$html .= '</tbody></table>';
188192
$html .= '</div></div>';
189193

190194
} else {
@@ -209,7 +213,8 @@ function showCpuInfo () {
209213
$html =
210214
'<div class="systemmonitor-state state-'.$record['state'].'">
211215
<div class="systemmonitor-content icons32 ico-'.$record['state'].'">
212-
<table>';
216+
<table class="table">
217+
<tbody>';
213218
foreach($data as $key => $value) {
214219
if ($key != '') {
215220
$html .= '<tr>
@@ -218,7 +223,7 @@ function showCpuInfo () {
218223
</tr>';
219224
}
220225
}
221-
$html .= '</table>';
226+
$html .= '</tbody></table>';
222227
$html .= '</div></div>';
223228
} else {
224229
$html = '<p>'.$app->lng("no_data_cpuinfo_txt").'</p>';
@@ -242,7 +247,8 @@ function showServices () {
242247
$html =
243248
'<div class="systemmonitor-state state-'.$record['state'].'">
244249
<div class="systemmonitor-content icons32 ico-'.$record['state'].'">
245-
<table>';
250+
<table class="table">
251+
<tbody>';
246252

247253
if($data['webserver'] != -1) {
248254
if($data['webserver'] == 1) {
@@ -330,7 +336,7 @@ function showServices () {
330336
}
331337

332338

333-
$html .= '</table></div></div>';
339+
$html .= '</tbody></table></div></div>';
334340
} else {
335341
$html = '<p>'.$app->lng("no_data_services_txt").'</p>';
336342
}

interface/web/themes/default/templates/tabbed_form.tpl.htm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ <h1><tmpl_var name="form_hint"></h1>
2525
<ul class='nav nav-tabs'>
2626
<tmpl_loop name="formTab">
2727
<li<tmpl_if name="active"> class='active'</tmpl_if>>
28-
<a href='#' data-toggle='tab' onclick="return changeTab('<tmpl_var name='name'>','<tmpl_var name='app_module'>/<tmpl_var name='form_action'>')"><tmpl_var name='title'></a>
28+
<a href='#' onclick="return changeTab('<tmpl_var name='name'>','<tmpl_var name='app_module'>/<tmpl_var name='form_action'>')"><tmpl_var name='title'></a>
2929
</li>
3030
</tmpl_loop>
3131
</ul>

0 commit comments

Comments
 (0)