From 69f15066bb5fd14f2820328ebc6b7fbd8f3429eb Mon Sep 17 00:00:00 2001 From: bergware Date: Thu, 30 Nov 2023 14:20:03 +0100 Subject: [PATCH] Enhanced boot page --- emhttp/plugins/dynamix/include/Boot.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/emhttp/plugins/dynamix/include/Boot.php b/emhttp/plugins/dynamix/include/Boot.php index ff1828ca8..25dd6f880 100644 --- a/emhttp/plugins/dynamix/include/Boot.php +++ b/emhttp/plugins/dynamix/include/Boot.php @@ -59,10 +59,10 @@ boot.on('message', function(msg) { switch (ini['fsState']) { case 'Stopped' : var status = ""; break; case 'Started' : var status = ""; break; - case 'Formatting': var status = ""; break; + case 'Formatting': var status = "
"; break; default : var status = ""+_('Array '+ini['fsState'])+""; } - if (ini['fsProgress']) status += "•"+_(ini['fsProgress'])+""; + status += ini['fsProgress'] ? "
"+_(ini['fsProgress'])+"" : "
"; $('.sub1').html(status); }); @@ -158,18 +158,18 @@ $(document).ajaxSend(function(elm, xhr, s){ {$var['fsProgress']}" : ""; +$progress = (_var($var,'fsProgress')!='') ? "
{$var['fsProgress']}" : "
"; switch (_var($_POST,'cmd','shutdown')) { case 'reboot': if (isset($_POST['safemode'])) touch($safemode); else @unlink($safemode); - exec('/sbin/reboot -n'); echo ''; + exec('/sbin/reboot -n'); break; case 'shutdown': if (isset($_POST['safemode'])) touch($safemode); else @unlink($safemode); - exec('/sbin/poweroff -n'); echo ''; + exec('/sbin/poweroff -n'); break; } echo '
';