// Need to build an array of Panel Objects (what we got from input was just the IDs)
     $pnlList = array();
     foreach ($pnlArray as $pnlID) {
         $pnlCount = count($pnlList);
         $pnlList[$pnlCount] = new PowerPanel();
         $pnlList[$pnlCount]->PanelID = $pnlID;
         $pnlList[$pnlCount]->GetPanel();
     }
 }
 // Now that we have a complete list of the panels, we need a list of the CDUs affected by the outage
 $pduList = array();
 // Rebuild an array of just the Panel ID values
 $pnlArray = array();
 foreach ($pnlList as $pnlDown) {
     $pdu->PanelID = $pnlDown->PanelID;
     $pduList = array_merge($pduList, $pdu->GetPDUbyPanel());
     array_push($pnlArray, $pnlDown->PanelID);
 }
 // And finally, build a list of cabinets that have at least one circuit from the affected panels
 $cabIDList = array();
 $cabList = array();
 // Also need to build a unique list of all PDU ID's included in outage
 $pduArray = array();
 $fsArray = array();
 foreach ($pduList as $outagePDU) {
     if (array_search($outagePDU->CabinetID, $cabIDList) === false) {
         array_push($cabIDList, $outagePDU->CabinetID);
         $cabCount = count($cabList);
         $cabList[$cabCount] = new Cabinet();
         $cabList[$cabCount]->CabinetID = $outagePDU->CabinetID;
         $cabList[$cabCount]->GetCabinet();
 $pdf->Ln();
 $pdf->SetFont($config->ParameterArray['PDFfont'], 'U', 12);
 $pdf->Cell(80, 5, __("Power Source") . ': ' . $sourceRow->PanelLabel);
 $pdf->SetFont($config->ParameterArray['PDFfont'], '', 8);
 $pdf->Ln();
 $pan->ParentPanelID = $sourceRow->PanelID;
 $panList = $pan->getPanelListBySource();
 foreach ($panList as $panRow) {
     $pdf->BookMark($panRow->PanelLabel, 3);
     $pdf->Ln();
     $pdf->SetFont($config->ParameterArray['PDFfont'], 'U', 12);
     $pdf->Cell(80, 5, __("Panel") . ': ' . $panRow->PanelLabel);
     $pdf->SetFont($config->ParameterArray['PDFfont'], '', 8);
     $pdf->Ln();
     $pdu->PanelID = $panRow->PanelID;
     $pduList = $pdu->GetPDUbyPanel();
     foreach ($pduList as $pduRow) {
         $pdf->BookMark($pduRow->Label, 4);
         $pdf->Ln();
         $pdf->SetFont($config->ParameterArray['PDFfont'], '', 12);
         $pdf->Cell(80, 5, __("PDU") . ': ' . $pduRow->Label);
         $pdf->SetFont($config->ParameterArray['PDFfont'], '', 8);
         $pdf->Ln();
         $dev->Cabinet = $pduRow->CabinetID;
         $devList = $dev->ViewDevicesByCabinet();
         $headerTags = array(__("Power Source"), __("Panel"), __("PDU"), __("Device Name"));
         $cellWidths = array(40, 30, 30, 60);
         $maxval = count($headerTags);
         for ($col = 0; $col < $maxval; $col++) {
             $pdf->Cell($cellWidths[$col], 7, $headerTags[$col], 1, 0, 'C', 1);
         }