0, "s_location" =>1, "s_status" =>17, "s_mediaType" =>19, "s_wwnn" =>3 ); $f_columnMap = array( "f_partitionName" =>0, "f_location" =>1, "f_status" =>17, "f_mediaType" =>19); $u_columnMap = array( "f_location" =>1); $columnMap = array("partitionName" =>"name", "location" =>"location", "status" =>"status", "mediaType" =>"mediaType", "wwnn" =>"wwnn"); if ($_SERVER[REQUEST_METHOD] == "GET") { $type = $_GET['type']; if( $type == 'SCSI') $sortCriteria = new SortCriteria($s_columnMap["partitionName"], "1"); else $sortCriteria = new SortCriteria($f_columnMap["partitionName"], "1"); } else { // The user must have pressed a column header to change sorting $type = $_POST['type']; if( $type == 'SCSI') $sortCriteria = new SortCriteria($s_columnMap[$_POST['orderOn']], ($_POST['orderBy']=="ASC")?(1):(0)); else if( $type == 'Fibre') $sortCriteria = new SortCriteria($f_columnMap[$_POST['orderOn']], ($_POST['orderBy']=="ASC")?(1):(0)); else $sortCriteria = new SortCriteria($u_columnMap[$_POST['orderOn']], ($_POST['orderBy']=="ASC")?(1):(0)); } $currentType = $type; $drives = $_SESSION['drives']; $drives = columnSort($drives, $columnMap[substr($_POST['orderOn'], 2)], $_POST['orderBy']); // count the drives with this type // $numRows = 0; foreach($drives as $drive) { if( $drive->interfaceType == "$currentType" || (( !($drive->interfaceType) || ($drive->interfaceType == 'Unknown')) && ($currentType == 'unknown') )) { $numRows++; } } // insure that the document is empty if there are no drives of this type if( $numRows <= 0 ) { return; } $numPages = ceil($numRows / DRIVES_PER_PAGE); $lowPageList = 1; $highPageList = min($numRows, DRIVES_PER_PAGE); ?> parent.document.getElementById( 'driveTypeHeader' ).innerHTML = 'Modify the settings on SCSI drives:';"; } else if( $currentType == 'SCSI' ) { echo ""; } else { echo ""; } } else { echo "\n"; echo "\n"; } ?>
interfaceType ) { ?> interfaceType == 'Unknown' ) { ?> isReady ? '' : ' disabled'; $disabled = ''; if( $currentType == 'SCSI' && ($drive->interfaceType == 'SCSI') ) { echo '"; echo ''; echo ' '; } else if( $currentType == 'Fibre' && ($drive->interfaceType == 'Fibre') ) { echo '"; /*############################################################ # Note: Even though the CMI mode states that 0 = No change. # For the Actual FC Topo and Speed setting 0 = Unknown ############################################################*/ $sTopo = array("Unknown", "Auto (LN)", "Loop (L)", "Point to Point", "Auto (NL)"); echo '"; $sSpeed = array("Auto", "1 Gb/s", "2 Gb/s", "4 Gb/s" ); $sSpeedAct = array("Unknown", "1 Gb/s", "2 Gb/s", "4 Gb/s" ); echo '"; echo ''; // !?! Put actual Topo here echo ''; // !?! Put actual Speed here echo ''; echo ' '; } // Don't create a new page if we don't have a drive to put in it yet. if( !$gotOne ) continue; $currentIndex++; if((($currentIndex % DRIVES_PER_PAGE) == 0) && ($currentIndex != 0 )) { $lowPageList += DRIVES_PER_PAGE; $highPageList = min($numRows, ($highPageList + DRIVES_PER_PAGE)); $currentPage++; if ($currentIndex < $numRows) { ?>