diff options
Diffstat (limited to 'modules-available/systemstatus/page.inc.php')
-rw-r--r-- | modules-available/systemstatus/page.inc.php | 27 |
1 files changed, 5 insertions, 22 deletions
diff --git a/modules-available/systemstatus/page.inc.php b/modules-available/systemstatus/page.inc.php index 74ed3f47..6876d0b5 100644 --- a/modules-available/systemstatus/page.inc.php +++ b/modules-available/systemstatus/page.inc.php @@ -37,6 +37,11 @@ class Page_SystemStatus extends Page ); } Permission::addGlobalTags($data['perms'], null, ['serverreboot']); + if (file_exists('/run/reboot-required.pkgs')) { + $lines = file('/run/reboot-required.pkgs', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); + $lines = array_unique($lines); + $data['packages'] = implode(', ', $lines); + } Render::addTemplate('_page', $data); } @@ -55,28 +60,6 @@ class Page_SystemStatus extends Page echo "Action $action not known in " . get_class(); } } - - protected function ajaxDmsdUsers() - { - User::assertPermission("show.overview.dmsdusers"); - $ret = Download::asStringPost('http://127.0.0.1:9080/status/fileserver', false, 2, $code); - $args = array(); - if ($code != 200) { - $args['dmsd_error'] = true; - } else { - $data = @json_decode($ret, true); - if (is_array($data)) { - $args['uploads'] = $data['activeUploads']; - $args['downloads'] = $data['activeDownloads']; - } - } - if (file_exists('/run/reboot-required.pkgs')) { - $lines = file('/run/reboot-required.pkgs', FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); - $lines = array_unique($lines); - $args['packages'] = implode(', ', $lines); - } - echo Render::parse('ajax-reboot', $args); - } protected function ajaxDiskStat() { |