mirror of
https://bitbucket.org/jsuto/piler.git
synced 2025-06-14 00:57:02 +02:00
orig theme renamed to mobile
This commit is contained in:
108
webui/view/theme/mobile/templates/health/daily-report.tpl
Normal file
108
webui/view/theme/mobile/templates/health/daily-report.tpl
Normal file
@ -0,0 +1,108 @@
|
||||
<html>
|
||||
<head>
|
||||
<title><?php print $text_daily_piler_report; ?>, <?php print $date; ?></title>
|
||||
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Language" content="<?php print getenv("LANG"); ?>" />
|
||||
|
||||
<style type="text/css">
|
||||
.row { display: table-row; }
|
||||
|
||||
#health1 { display: table-cell; margin-top: 10px; margin-bottom: 0; }
|
||||
#health2 { display: table-cell; text-align: right; }
|
||||
|
||||
.cellhealthleft { display: table-cell; height: 25px; text-align: left; padding: 3px; font: bold 12px Arial, sans-serif; }
|
||||
.cellhealthright { display: table-cell; height: 25px; text-align: left; padding: 3px; font: normal 12px Arial, sans-serif; }
|
||||
|
||||
#health1 .ok { color: green; font-weight: bold; }
|
||||
#health1 .error { color: red; font-weight: bold; }
|
||||
|
||||
</style>
|
||||
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1><?php print $text_daily_piler_report; ?>, <?php print $date; ?></h1>
|
||||
|
||||
<div id="search">
|
||||
|
||||
<div id="health1">
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_server_name; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $sysinfo[0]; ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_server_operating_system; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $sysinfo[1]; ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_uptime; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $uptime; ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_archive_size; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $archive_size; ?>B</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_smtp_status; ?>:</div>
|
||||
<div class="cellhealthright">
|
||||
<?php foreach($_health as $h) {
|
||||
if(preg_match("/^220/", $h[1])) {
|
||||
$status = 'OK'; $class = 'ok';
|
||||
} else {
|
||||
$status = 'ERROR'; $class = 'error';
|
||||
}
|
||||
?>
|
||||
<div class="<?php print $class; ?>"><?php print $h[3]; ?>: <?php print $status; ?> (<?php print $h[1]; ?>, <?php print $h[2]; ?>)</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_processed_emails; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $processed_emails[0]; ?> (<?php print $text_24_hours; ?>)<br /><?php print $processed_emails[1]; ?> (<?php print $text_1_week; ?>)<br /><?php print $processed_emails[2]; ?> (<?php print $text_30_days; ?>)</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_cpu_usage; ?>:</div>
|
||||
<div class="cellhealthright"><span class="<?php if($cpuinfo < HEALTH_RATIO) { ?>ok<?php } else { ?>error<?php } ?>"><?php print $cpuinfo; ?>% <?php print $cpuload; ?></span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_memory_usage; ?>:</div>
|
||||
<div class="cellhealthright"><span class="<?php if($meminfo < HEALTH_RATIO) { ?>ok<?php } else { ?>error<?php } ?>"><?php print $meminfo; ?>% / <?php print $totalmem; ?> MB</span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_swap_usage; ?></div>
|
||||
<div class="cellhealthright"><span class="<?php if($swapinfo < HEALTH_RATIO) { ?>ok<?php } else { ?>error<?php } ?>"><?php print $swapinfo; ?>% / <?php print $totalswap; ?> MB</span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_disk_usage; ?></div>
|
||||
<div class="cellhealthright"><?php foreach($shortdiskinfo as $partition) { ?><span class="<?php if($partition['utilization'] < HEALTH_RATIO) { ?>ok<?php } else { ?>error<?php } ?>"><?php print $partition['partition']; ?> <?php print $partition['utilization']; ?>%</span> <?php } ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_space_projection; ?></div>
|
||||
<div class="cellhealthright">
|
||||
<?php print $averagemessages; ?> (<?php print $text_average_messages_day; ?>)<br/>
|
||||
<?php print $averagemessagesize; ?> + <?php print $averagesqlsize; ?> + <?php print $averagesphinxsize; ?> (<?php print $text_average_message_size; ?>)<br/>
|
||||
<?php print $averagesizeday; ?> (<?php print $text_average_size_day; ?>)<br/>
|
||||
<?php print $daysleftatcurrentrate[0]; ?> years, <?php print $daysleftatcurrentrate[1]; ?> months, <?php print $daysleftatcurrentrate[2]; ?> days ("<?php print DATA_PARTITION; ?>" <?php print $text_partition_full; ?>)<br/>
|
||||
<?php if ( $usagetrend > 0 ) { print $text_usage_increasing; } elseif( $usagetrend < 0 ) { print $text_usage_decreasing; } else { print $text_usage_neutral; } ?> (<?php print $text_usage_trend; ?>)<br/>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div></div>
|
||||
|
||||
</body>
|
||||
</html>
|
1
webui/view/theme/mobile/templates/health/health.tpl
Normal file
1
webui/view/theme/mobile/templates/health/health.tpl
Normal file
@ -0,0 +1 @@
|
||||
<span id="A1"><?php print $text_loading; ?> . . .</span>
|
158
webui/view/theme/mobile/templates/health/worker.tpl
Normal file
158
webui/view/theme/mobile/templates/health/worker.tpl
Normal file
@ -0,0 +1,158 @@
|
||||
<div id="search">
|
||||
|
||||
<div id="health1">
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_refresh_period; ?>:</div>
|
||||
<div class="cellhealthright"><?php print HEALTH_REFRESH; ?> sec</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_server_name; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $sysinfo[0]; ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_server_operating_system; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $sysinfo[1]; ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_uptime; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $uptime; ?></div>
|
||||
</div>
|
||||
|
||||
<?php if(ENABLE_SAAS == 1) { ?>
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_online_users; ?>:</div>
|
||||
<div class="cellhealthright"><a href="index.php?route=stat/online"><?php print $num_of_online_users; ?></a></div>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_archive_size; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $archive_size; ?>B</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_smtp_status; ?>:</div>
|
||||
<div class="cellhealthright">
|
||||
<?php foreach($health as $h) {
|
||||
if(preg_match("/^220/", $h[1])) {
|
||||
$status = 'OK'; $class = 'text-success';
|
||||
} else {
|
||||
$status = 'ERROR'; $class = 'text-error';
|
||||
}
|
||||
?>
|
||||
<div class="bold <?php print $class; ?>"><span><?php print $h[3]; ?>: <?php print $status; ?></span></div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_processed_emails; ?>:</div>
|
||||
<div class="cellhealthright"><?php print $processed_emails[0]; ?> (<?php print $text_24_hours; ?>)<br /><?php print $processed_emails[1]; ?> (<?php print $text_1_week; ?>)<br /><?php print $processed_emails[2]; ?> (<?php print $text_30_days; ?>)</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_cpu_usage; ?>:</div>
|
||||
<div class="cellhealthright"><span class="bold <?php if($cpuinfo < HEALTH_RATIO) { ?>text-success<?php } else { ?>text-error<?php } ?>"><?php print $cpuinfo; ?>% <?php print $cpuload; ?></span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_memory_usage; ?>:</div>
|
||||
<div class="cellhealthright"><span class="bold <?php if($meminfo < HEALTH_RATIO) { ?>text-success<?php } else { ?>text-error<?php } ?>"><?php print $meminfo; ?>% / <?php print $totalmem; ?> MB</span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_swap_usage; ?></div>
|
||||
<div class="cellhealthright"><span class="bold <?php if($swapinfo < HEALTH_RATIO) { ?>text-success<?php } else { ?>text-error<?php } ?>"><?php print $swapinfo; ?>% / <?php print $totalswap; ?> MB</span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_disk_usage; ?></div>
|
||||
<div class="cellhealthright"><?php foreach($shortdiskinfo as $partition) { ?><span class="bold <?php if($partition['utilization'] < HEALTH_RATIO) { ?>text-success<?php } else { ?>text-error<?php } ?>"><?php print $partition['partition']; ?> <?php print $partition['utilization']; ?>%</span> <?php } ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_periodic_purge; ?></div>
|
||||
<div class="cellhealthright"><span class="bold <?php if($options['enable_purge'] == 1) { ?>text-success<?php } else { ?>text-error<?php } ?>"><?php if($options['enable_purge'] == 1) { print $text_enabled; ?>. <a href="<?php print HEALTH_URL; ?>&toggle_enable_purge"><?php print $text_disable; ?></a><?php } else { print $text_disabled; ?>. <a href="<?php print HEALTH_URL; ?>&toggle_enable_purge"><?php print $text_enable; ?></a><?php } ?> </span></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_oldest_record; ?></div>
|
||||
<div class="cellhealthright">
|
||||
<?php print date("d M Y", $oldestmessagets); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_counters; ?></div>
|
||||
<div class="cellhealthright">
|
||||
<?php while(list($k, $v) = each($counters)) {
|
||||
if(!is_numeric($k)) { ?>
|
||||
<div class="row">
|
||||
<div class="cellhealthright"><?php $a = preg_replace("/^_piler\:/", "", $k); if(isset($$a)) { print $$a; } else { print $k; } ?></div>
|
||||
<div class="cellhealthright"><?php print $v; ?></div>
|
||||
</div>
|
||||
<?php } } ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_space_projection; ?></div>
|
||||
<div class="cellhealthright">
|
||||
<div class="row">
|
||||
<div class="cellhealthright"><?php print $text_average_messages_day; ?></div>
|
||||
<div class="cellhealthright"><?php print $averagemessages; ?></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="cellhealthright"><?php print $text_average_message_size; ?></div>
|
||||
<div class="cellhealthright"><?php print $averagemessagesize; ?> + <?php print $averagesqlsize; ?> + <?php print $averagesphinxsize; ?></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="cellhealthright"><?php print $text_average_size_day; ?></div>
|
||||
<div class="cellhealthright"><?php print $averagesizeday; ?></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="cellhealthright">"<?php print DATA_PARTITION; ?>" <?php print $text_partition_full; ?></div>
|
||||
<div class="cellhealthright"><?php print $daysleftatcurrentrate[0]; ?> <?php print $text_years; ?>, <?php print $daysleftatcurrentrate[1]; ?> <?php print $text_months; ?>, <?php print $daysleftatcurrentrate[2]; ?> <?php print $text_days2; ?></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="cellhealthright"><?php print $text_usage_trend; ?></div>
|
||||
<div class="cellhealthright"><?php if ( $usagetrend > 0 ) { print $text_usage_increasing; } elseif( $usagetrend < 0 ) { print $text_usage_decreasing; } else { print $text_usage_neutral; } ?></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div id="health2">
|
||||
<?php if(isset($queues)) { ?>
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $text_queue_status; ?></div>
|
||||
</div>
|
||||
|
||||
<?php foreach ($queues as $queue) {
|
||||
|
||||
if(isset($queue['desc'])) { ?>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthleft"><?php print $queue['desc']; ?></div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="cellhealthright"><pre><?php print $queue['lines']; ?></pre></div>
|
||||
</div>
|
||||
|
||||
<?php }
|
||||
} ?>
|
||||
|
||||
<?php } ?>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
Reference in New Issue
Block a user