mirror of
https://github.com/RaspAP/raspap-webgui.git
synced 2024-11-22 07:30:23 +00:00
removed logic from system template
This commit is contained in:
parent
680fa1de87
commit
2c64ff0b3e
2 changed files with 9 additions and 9 deletions
|
@ -91,6 +91,15 @@ function DisplaySystem()
|
|||
'tr_TR.UTF-8' => 'Türkçe'
|
||||
);
|
||||
|
||||
if (isset($_POST['system_reboot'])) {
|
||||
$status->addMessage("System Rebooting Now!", "warning", false);
|
||||
$result = shell_exec("sudo /sbin/reboot");
|
||||
}
|
||||
if (isset($_POST['system_shutdown'])) {
|
||||
$status->addMessage("System Shutting Down Now!", "warning", false);
|
||||
$result = shell_exec("sudo /sbin/shutdown -h now");
|
||||
}
|
||||
|
||||
echo renderTemplate("system", compact("arrLocales", "status", "system"));
|
||||
}
|
||||
|
||||
|
|
|
@ -25,15 +25,6 @@ if ($cpuload > 90) {
|
|||
$cpuload_status = "success";
|
||||
}
|
||||
|
||||
if (isset($_POST['system_reboot'])) {
|
||||
$status->addMessage("System Rebooting Now!", "warning", false);
|
||||
$result = shell_exec("sudo /sbin/reboot");
|
||||
}
|
||||
if (isset($_POST['system_shutdown'])) {
|
||||
$status->addMessage("System Shutting Down Now!", "warning", false);
|
||||
$result = shell_exec("sudo /sbin/shutdown -h now");
|
||||
}
|
||||
|
||||
?>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
|
|
Loading…
Reference in a new issue