Ejemplo n.º 1
0
     Aastra_save_user_context($user, 'follow', NULL);
     Aastra_save_user_context($user, 'parking', NULL);
     Aastra_save_user_context($user, 'vmail', NULL);
 } else {
     # Erase mac.cfg
     Aastra_delete_mac($header['mac']);
     # Reboot needed
     require_once 'AastraIPPhoneExecute.class.php';
     $object = new AastraIPPhoneExecute();
     # Bug 673i
     if ($header['model'] != 'Aastra6739i') {
         $object->addEntry($XML_SERVER . '&action=display');
     } else {
         $object->setTriggerDestroyOnExit();
     }
     if (Aastra_is_local_reset_supported() and $header['model'] != 'Aastra6739i') {
         $object->addEntry('Command: ClearCallersList');
         $object->addEntry('Command: ClearDirectory');
         $object->addEntry('Command: ClearRedialList');
         $object->addEntry('Command: ClearLocal');
     } else {
         if (Aastra_is_fastreboot_supported()) {
             $object->AddEntry('Command: FastReboot');
         } else {
             $object->addEntry('Command: Reset');
         }
     }
 }
 # Set status to Disconnected
 if ($AA_PRESENCE_STATE and $action != 'forced_logout' and !$AA_ISYMPHONY) {
     if (Aastra_manage_presence_Asterisk($user, 'status') == AA_PRESENCE_AVAILABLE) {
Ejemplo n.º 2
0
 # Save device context
 $data['user'] = $user;
 $data['config'] = $config;
 Aastra_save_user_context($device, 'login_out', $data);
 # Create the XML object
 require_once 'AastraIPPhoneExecute.class.php';
 $object = new AastraIPPhoneExecute();
 # Real configuration
 if ($config != NULL) {
     # Send a check
     if ($user != '') {
         $object->addEntry($XML_SERVER . '?user='******'&action=check2');
     }
     if ($user != $last_user) {
         # Clear display
         if (Aastra_is_local_reset_supported()) {
             $object->addEntry('Command: ClearCallersList');
             $object->addEntry('Command: ClearDirectory');
             $object->addEntry('Command: ClearRedialList');
         }
         $object->addEntry($XML_SERVER . '?action=purge_msg');
     }
     if ($user == '') {
         if (Aastra_is_ledcontrol_supported()) {
             $cfwd = Aastra_get_user_context($device, 'cfwd');
             if ($cfwd['key'] != '') {
                 $object->AddEntry('Led: ' . $cfwd['key'] . '=off');
             }
             $dnd = Aastra_get_user_context($device, 'dnd');
             if ($dnd['key'] != '') {
                 $object->AddEntry('Led: ' . $dnd['key'] . '=off');