Example #1
0
                                 //get the contact ID and remove that
                                 $group = new Contact($_GET['groupID']);
                                 removeGroup($group);
                             } else {
                                 if ($_GET['action'] == 'showGroupTypes') {
                                     displayAllGroupTypes();
                                 } else {
                                     if ($_GET['action'] == 'showContactTypes') {
                                         displayAllContactTypes();
                                     } else {
                                         if ($_GET['action'] == 'showPeople') {
                                             displayAllPeople();
                                         } else {
                                             if ($_GET['action'] == 'showArchivedGroup') {
                                                 $groupTypes = new ContactType();
                                                 displayAllArchived($groupTypes);
                                             } else {
                                                 $groupTypes = new ContactType();
                                                 displayAll($groupTypes);
                                             }
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
     }
 }
Example #2
0
 } else {
     if ($_GET['action'] == remove && $_SESSION['access'] >= 50) {
         //remove the port if it is a port
         if (isset($_GET['portID'])) {
             $ports = new ControlPort($_GET['portID']);
             removePort($ports);
         } else {
             $devices = new Device($_GET['ID']);
             removeDevice($devices);
         }
     } else {
         if ($_GET['action'] == ipReport) {
             displayIP();
         } else {
             if ($_GET['action'] == showArchived) {
                 displayAllArchived($devices);
             } else {
                 if ($_GET['action'] == changeControlledPort && $_SESSION['access'] >= 50) {
                     //give power controls a grouping value
                     echo "<td class='info'>GROUP ";
                     if ($_GET['mode'] == 'power_control') {
                         echo "<input type='text' name='group' value='' />";
                     } else {
                         echo "NOT APPLICABLE";
                     }
                     echo "</td>";
                     $types = $devices->get_devices_by_class($_GET['mode']);
                     echo "<select name='controlledDevice'>";
                     foreach ($types as $id => $value) {
                         echo "<option value='{$id}'>{$value}</option>";
                     }
Example #3
0
                                     $location = new Location($_GET['locationID']);
                                     removeLocation($location);
                                 } else {
                                     if ($_GET['action'] == removeLocationType && $_SESSION['access'] >= 50) {
                                         //get the client ID and remove that
                                         $locationType = new LocationType($_GET['locationTypeID']);
                                         removeLocationType($locationType);
                                     } else {
                                         if ($_GET['action'] == 'showRoomTypes') {
                                             displayAllRoomTypes();
                                         } else {
                                             if ($_GET['action'] == 'showLocationTypes') {
                                                 displayAllLocationTypes();
                                             } else {
                                                 if ($_GET['action'] == 'showArchivedLocation') {
                                                     displayAllArchived();
                                                 } else {
                                                     displayAll();
                                                 }
                                             }
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
     }
 }
Example #4
0
                                        removeService($servicePort);
                                    } else {
                                        //get the service ID and remove that
                                        $services = new Service($_GET['ID']);
                                        removeService($services);
                                    }
                                } else {
                                    if ($_GET['action'] == removeServiceType && $_SESSION['access'] >= 50) {
                                        $serviceType = new ServiceType($_GET['ID']);
                                        removeServiceType($serviceType);
                                    } else {
                                        if ($_GET['action'] == showAllServiceTypes) {
                                            displayAllServiceTypes();
                                        } else {
                                            if ($_GET['action'] == showArchived) {
                                                displayAllArchived($services);
                                            } else {
                                                displayAll($services);
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
?>