mirror of
https://github.com/myvesta/vesta
synced 2025-08-21 13:54:28 -07:00
UI performance fix 5
This commit is contained in:
parent
83acec3ec1
commit
db6360922f
8 changed files with 53 additions and 41 deletions
|
@ -3,6 +3,12 @@ input[type="checkbox"] {
|
|||
display: block;
|
||||
margin-top: 26px;
|
||||
}
|
||||
|
||||
.backup-items {
|
||||
background-color: #f8f8f8;
|
||||
margin: 10px 33px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
</style>
|
||||
<br /><br />
|
||||
<form action="/bulk/restore/" method="post" id="objects">
|
||||
|
@ -48,7 +54,7 @@ input[type="checkbox"] {
|
|||
++$i;
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check<?=$i?>" class="ch-toggle" type="checkbox" name="web[]" value="<?=$key?>">
|
||||
|
@ -99,7 +105,7 @@ input[type="checkbox"] {
|
|||
if (!empty($key)) {
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check2<?=$i?>" type="checkbox" name="mail[]" value="<?=$key?>">
|
||||
|
@ -147,7 +153,7 @@ input[type="checkbox"] {
|
|||
if (!empty($key)) {
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check3<?=$i?>" type="checkbox" name="dns[]" value="<?=$key?>">
|
||||
|
@ -194,7 +200,7 @@ input[type="checkbox"] {
|
|||
if (!empty($key)) {
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check4<?=$i?>" type="checkbox" name="db[]" value="<?=$key?>">
|
||||
|
@ -242,7 +248,7 @@ input[type="checkbox"] {
|
|||
if (!empty($key)) {
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check5<?=$i?>" type="checkbox" name="check" value="<?=$key?>">
|
||||
|
@ -290,7 +296,7 @@ input[type="checkbox"] {
|
|||
if (!empty($key)) {
|
||||
?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check6<?=$i?>" type="checkbox" name="udir[]" value="<?=$key?>">
|
||||
|
@ -329,7 +335,7 @@ input[type="checkbox"] {
|
|||
<!-- /.l-separator -->
|
||||
<? }} ?>
|
||||
|
||||
<div>
|
||||
<div class="backup-items">
|
||||
<div class="l-unit-toolbar clearfix">
|
||||
<div class="l-unit-toolbar__col l-unit-toolbar__col--left" style="margin-left: 15px;">
|
||||
<input id="check7<?=$i?>" type="checkbox" name="cron" value="<?=$i?>">
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<div class="hidden" id="token" token="<?=$_SESSION['token']?>"></div>
|
||||
<a href="#" class="to-top">
|
||||
<a href="#" class="to-top" style="right: <?=$GLOBALS['to_top_right']?>px;">
|
||||
<i class="l-icon-to-top"></i>
|
||||
</a>
|
||||
<a href="#" class="to-shortcuts">
|
||||
<a href="#" class="to-shortcuts" style="right: <?=$GLOBALS['to_shortcuts_right']?>px;">
|
||||
<i class="l-icon-shortcuts"></i>
|
||||
</a>
|
||||
|
||||
|
@ -129,9 +129,11 @@ $debian_ver=file_get_contents('/etc/debian_version');
|
|||
<span style="font-weight: bold;">Build date:</span> <?php echo $vesta_build_date;?><br />
|
||||
<span style="font-weight: bold;">Debian </span> <?php echo $debian_ver;?><br />
|
||||
</div>
|
||||
<!--
|
||||
<div style="display: block; padding: 30px 0 0 19px; color: #b9bcbd;">
|
||||
<a href="https://forum.myvestacp.com/viewtopic.php?f=23&t=819" target="_blank" style="text-decoration: underline; font-weight: bold;">Need urgent assistance?</a>
|
||||
</div>
|
||||
-->
|
||||
</div>
|
||||
<!-- /.l-stats -->
|
||||
</div>
|
||||
|
|
|
@ -16,6 +16,23 @@
|
|||
<?php
|
||||
$CURRENT_USER_FINAL=$_SESSION['user'];
|
||||
if (isset($_SESSION['look']) && $_SESSION['look']!='') $CURRENT_USER_FINAL=$_SESSION['look'];
|
||||
|
||||
$right_sidebar_right=0;
|
||||
$content_margin_right=240;
|
||||
$content_margin_right=240;
|
||||
$to_top_right=285;
|
||||
$to_shortcuts_right=330;
|
||||
if (isset($_COOKIE['iolog']) && $_COOKIE['iolog']=='0') {
|
||||
$right_sidebar_right=-200;
|
||||
$content_margin_right=40;
|
||||
$to_top_right=85;
|
||||
$to_shortcuts_right=130;
|
||||
}
|
||||
|
||||
$GLOBALS['CURRENT_USER_FINAL']=$CURRENT_USER_FINAL;
|
||||
$GLOBALS['right_sidebar_right']=$right_sidebar_right;
|
||||
$GLOBALS['to_top_right']=$to_top_right;
|
||||
$GLOBALS['to_shortcuts_right']=$to_shortcuts_right;
|
||||
?>
|
||||
var GLOBAL = {};
|
||||
GLOBAL.FTP_USER_PREFIX = 'admin_';
|
||||
|
@ -23,8 +40,11 @@
|
|||
GLOBAL.DB_DBNAME_PREFIX = 'admin_';
|
||||
GLOBAL.CURRENT_USER = '<?=$_SESSION['user']?>';
|
||||
GLOBAL.CURRENT_USER_LOOK = '<?=$_SESSION['look']?>';
|
||||
GLOBAL.CURRENT_USER_FINAL = '<?=$CURRENT_USER_FINAL?>';
|
||||
GLOBAL.CURRENT_USER_FINAL = '<?=$GLOBALS['CURRENT_USER_FINAL']?>';
|
||||
GLOBAL.AJAX_URL = '';
|
||||
</script>
|
||||
<style>
|
||||
.l-content .l-center {margin-right: <?=$content_margin_right?>px}
|
||||
</style>
|
||||
</head>
|
||||
<body class="body-<?=strtolower($TAB)?> lang-<?=$_SESSION['language']?>">
|
||||
|
|
|
@ -1,20 +1,15 @@
|
|||
<?php
|
||||
$CURRENT_USER_FINAL=$_SESSION['user'];
|
||||
if (isset($_SESSION['look']) && $_SESSION['look']!='') $CURRENT_USER_FINAL=$_SESSION['look'];
|
||||
?>
|
||||
|
||||
<div class="right_sidebar" style="width: 240px; position: fixed; display: block; z-index: 98; top: 50px; right: 0px; box-sizing: border-box; height: 100%; background: #fff; border-left: 1px solid #dee5e8;">
|
||||
<div class="right_sidebar" style="width: 240px; position: fixed; display: block; z-index: 98; top: 50px; right: <?=$GLOBALS['right_sidebar_right']?>px; box-sizing: border-box; height: 100%; background: #fff; border-left: 1px solid #dee5e8;">
|
||||
<div class="io-log">
|
||||
<h2 class="io-log-h2" id="iologbutton">
|
||||
<?php
|
||||
if ($CURRENT_USER_FINAL=='admin') echo __('Server');
|
||||
if ($GLOBALS['CURRENT_USER_FINAL']=='admin') echo __('Server');
|
||||
else echo __('Account');
|
||||
?>
|
||||
</h2>
|
||||
<div>
|
||||
|
||||
<?php
|
||||
if ($CURRENT_USER_FINAL=='admin') {
|
||||
if ($GLOBALS['CURRENT_USER_FINAL']=='admin') {
|
||||
$sysload=sys_getloadavg();
|
||||
$sysload[0]=number_format((float)$sysload[0], 2, '.', '');
|
||||
$sysload[1]=number_format((float)$sysload[1], 2, '.', '');
|
||||
|
@ -67,11 +62,11 @@
|
|||
<div>
|
||||
<?php
|
||||
$output='';
|
||||
exec (VESTA_CMD . "v-list-user ".$CURRENT_USER_FINAL." json", $output, $return_var);
|
||||
exec (VESTA_CMD . "v-list-user ".$GLOBALS['CURRENT_USER_FINAL']." json", $output, $return_var);
|
||||
$data = json_decode(implode('', $output), true);
|
||||
$data = array_reverse($data,true);
|
||||
//print_r($data); exit;
|
||||
$key=$CURRENT_USER_FINAL;
|
||||
$key=$GLOBALS['CURRENT_USER_FINAL'];
|
||||
if ($data[$key]['DISK_QUOTA']=='unlimited') echo __('unlimited');
|
||||
else echo get_percentage($data[$key]['U_DISK'],$data[$key]['DISK_QUOTA']).' %';
|
||||
?>
|
||||
|
@ -80,7 +75,7 @@
|
|||
</div>
|
||||
<?php
|
||||
}
|
||||
if ($CURRENT_USER_FINAL=='admin') {
|
||||
if ($GLOBALS['CURRENT_USER_FINAL']=='admin') {
|
||||
$output='';
|
||||
exec ("df -h | grep '^/dev'", $output, $return_var);
|
||||
foreach($output as $line) {
|
||||
|
@ -128,7 +123,7 @@
|
|||
<div>
|
||||
<?php
|
||||
$output='';
|
||||
exec (VESTA_CMD."v-list-user-log ".$CURRENT_USER_FINAL." json 25", $output, $return_var);
|
||||
exec (VESTA_CMD."v-list-user-log ".$GLOBALS['CURRENT_USER_FINAL']." json 25", $output, $return_var);
|
||||
check_error($return_var);
|
||||
$data = json_decode(implode('', $output), true);
|
||||
foreach ($data as $key => $value) {
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<script type="text/javascript" src="/js/i18n.js.php?<?=JS_LATEST_UPDATE?>"></script>
|
||||
<script type="text/javascript" src="/js/templates.js?<?=JS_LATEST_UPDATE?>"></script>
|
||||
<script type="text/javascript" src="/js/jquery.finder.js?<?=JS_LATEST_UPDATE?>"></script>
|
||||
<script type="text/javascript" src="/js/fix.js?v=4"></script>
|
||||
<script type="text/javascript" src="/js/fix.js?v=<?=JS_LATEST_UPDATE?>"></script>
|
||||
|
||||
<script>
|
||||
hover_menu = function() {}
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
<div class="hidden" id="token" token="<?=$_SESSION['token']?>"></div>
|
||||
<a href="#" class="to-top">
|
||||
<a href="#" class="to-top" style="right: <?=$GLOBALS['to_top_right']?>px;">
|
||||
<i class="l-icon-to-top"></i>
|
||||
</a>
|
||||
<a href="#" class="to-shortcuts">
|
||||
<a href="#" class="to-shortcuts" style="right: <?=$GLOBALS['to_shortcuts_right']?>px;">
|
||||
<i class="l-icon-shortcuts"></i>
|
||||
</a>
|
||||
<div class="l-header">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue