From 89e4329a8068e3631d3f64f6896fa3907c687cf5 Mon Sep 17 00:00:00 2001
From: Marius Cramer <m.cramer@pixcept.de>
Date: Thu, 08 Jan 2015 09:08:50 -0500
Subject: [PATCH] Layout fix: tab toggle and monitor tables

---
 interface/web/admin/remote_action_osupdate.php |   29 +++++++++++++++--------------
 1 files changed, 15 insertions(+), 14 deletions(-)

diff --git a/interface/web/admin/remote_action_osupdate.php b/interface/web/admin/remote_action_osupdate.php
index afa0ec6..61c6c23 100644
--- a/interface/web/admin/remote_action_osupdate.php
+++ b/interface/web/admin/remote_action_osupdate.php
@@ -27,11 +27,12 @@
 EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 */
 
-require_once('../../lib/config.inc.php');
-require_once('../../lib/app.inc.php');
+require_once '../../lib/config.inc.php';
+require_once '../../lib/app.inc.php';
 
 //* Check permissions for module
 $app->auth->check_module_permissions('admin');
+$app->auth->check_security_permissions('admin_allow_osupdate');
 
 //* This is only allowed for administrators
 if(!$app->auth->is_admin()) die('only allowed for administrators.');
@@ -43,7 +44,7 @@
 
 //* load language file
 $lng_file = 'lib/lang/'.$_SESSION['s']['language'].'_remote_action.lng';
-include($lng_file);
+include $lng_file;
 
 /*
  * We need a list of all Servers
@@ -74,21 +75,21 @@
 		$servers[] = $_POST['server_select'];
 	}
 	foreach ($servers as $serverId) {
-		$sql = "INSERT INTO sys_remoteaction (server_id, tstamp, action_type, action_param, action_status, response) " .
-				"VALUES (".
-				(int)$serverId . ", " .
-				time() . ", " .
-				"'os_update', " .
-				"'', " .
-				"'pending', " .
-				"''" .
-				")";
+		$sql = "INSERT INTO sys_remoteaction (server_id, tstamp, action_type, action_param, action_state, response) " .
+			"VALUES (".
+			$app->functions->intval($serverId) . ", " .
+			time() . ", " .
+			"'os_update', " .
+			"'', " .
+			"'pending', " .
+			"''" .
+			")";
 		$app->db->query($sql);
 	}
 	$msg = $wb['action_scheduled'];
 }
 
-$app->tpl->setVar('msg',$msg);
+$app->tpl->setVar('msg', $msg);
 
 $app->tpl->setVar($wb);
 
@@ -96,4 +97,4 @@
 $app->tpl->pparse();
 
 
-?>
\ No newline at end of file
+?>

--
Gitblit v1.9.1