Update device_profile_copy.php

This commit is contained in:
FusionPBX
2016-10-23 00:12:58 -06:00
committed by GitHub
parent 20a9384433
commit fa34450488

View File

@@ -17,7 +17,7 @@
The Initial Developer of the Original Code is
Mark J Crane <markjcrane@fusionpbx.com>
Portions created by the Initial Developer are Copyright (C) 2008-2015
Portions created by the Initial Developer are Copyright (C) 2008-2016
the Initial Developer. All Rights Reserved.
Contributor(s):
@@ -104,16 +104,17 @@
//}
//create the device array
$device_profile = $device_profiles[0];
$device_profile["device_keys"] = $device_keys;
//$device["device_settings"] = $device_settings;
$array["device_profile"][0] = $device_profiles;
$array["device_profile"][0]["device_keys"] = $device_keys;
//$array["device_settings"][0] = $device_settings;
//copy the device
if ($save) {
$orm = new orm;
$orm->name('device_profiles');
$orm->save($device_profile);
$response = $orm->message;
$database = new database;
$database->app_name = 'devices';
$database->app_uuid = '4efa1a1a-32e7-bf83-534b-6c8299958a8e';
$database->save($array);
$response = $database->message;
$_SESSION["message"] = $text['message-copy'];
}