Update device_delete.php
This commit is contained in:
@@ -17,21 +17,25 @@
|
|||||||
|
|
||||||
The Initial Developer of the Original Code is
|
The Initial Developer of the Original Code is
|
||||||
Mark J Crane <markjcrane@fusionpbx.com>
|
Mark J Crane <markjcrane@fusionpbx.com>
|
||||||
Copyright (C) 2008-2012 All Rights Reserved.
|
Copyright (C) 2008-2016 All Rights Reserved.
|
||||||
|
|
||||||
Contributor(s):
|
Contributor(s):
|
||||||
Mark J Crane <markjcrane@fusionpbx.com>
|
Mark J Crane <markjcrane@fusionpbx.com>
|
||||||
*/
|
*/
|
||||||
require_once "root.php";
|
|
||||||
require_once "resources/require.php";
|
//includes
|
||||||
require_once "resources/check_auth.php";
|
require_once "root.php";
|
||||||
if (permission_exists('device_delete')) {
|
require_once "resources/require.php";
|
||||||
//access granted
|
require_once "resources/check_auth.php";
|
||||||
}
|
|
||||||
else {
|
//check permissions
|
||||||
echo "access denied";
|
if (permission_exists('device_delete')) {
|
||||||
exit;
|
//access granted
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
echo "access denied";
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
|
||||||
//add multi-lingual support
|
//add multi-lingual support
|
||||||
$language = new text;
|
$language = new text;
|
||||||
@@ -71,11 +75,15 @@ else {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//write the provision files
|
//write the provision files
|
||||||
require_once "app/provision/provision_write.php";
|
if (strlen($_SESSION['provision']['path']['text']) > 0) {
|
||||||
|
$prov = new provision;
|
||||||
|
$prov->domain_uuid = $domain_uuid;
|
||||||
|
$response = $prov->write();
|
||||||
|
}
|
||||||
|
|
||||||
//set the message and redirect the user
|
//set the message and redirect the user
|
||||||
$_SESSION["message"] = $text['message-delete'];
|
$_SESSION["message"] = $text['message-delete'];
|
||||||
header("Location: devices.php");
|
header("Location: devices.php");
|
||||||
return;
|
return;
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|||||||
Reference in New Issue
Block a user