ascending = true; $sortCriteria->sortColumn = LIB_SORT_DEFAULT; $numRows = 0; $numlogLibs = 0; $empty_cleaning = 0; $empty_data = 0; // Used for Filtering $llView = "All Logical Libraries"; $enclView = "All Enclosures"; // Used for Sorting $sortBy = "Index"; // Used for Message box $errorCode = 0; $displayMessage = 0; // Get necessary data from the library //$counts = get_all_resource_counts($user); $counts = get_library_summary_info($user); $loglibs = get_logical_libraries($user, $sortCriteria); $numlogLibs = count($loglibs); $sortCriteria->sortColumn = SLOT_SORT_DEFAULT; $temp_carts = get_physical_mailbox($user, $sortCriteria, (int)2); $numTempCarts = count($temp_carts); $cartIndex = 0; for ($t = 0; $t < $numTempCarts; $t++) { if (strncmp($temp_carts[$t]->barcode, "CLN", 3) == 0) { $carts[$cartIndex] = $temp_carts[$t]; $cartIndex++; } } $temp_carts = ""; for ($l = 0; $l < $numlogLibs; $l++) { // store the index of this logical library for later use $libIndex[$loglibs[$l]->name] = $l; $temp_carts = get_mailbox($user, $sortCriteria,(int)2, $loglibs[$l]->guid); //$temp_carts = get_all_media($user, $sortCriteria); $numTempCarts = count($temp_carts); for ($t = 0; $t < $numTempCarts; $t++) { //if ((strncmp($temp_carts[$t]->barcode, "CLN", 3) != 0) || ($l == 0)) //{ // if (strncmp($temp_carts[$t]->barcode, "CLN", 3) == 0) // { // $temp_carts[$t]->name = "Cleaning Slot"; // } $carts[$cartIndex] = $temp_carts[$t]; $cartIndex++; //} } $temp_carts = ""; } // If a post, then this is a return from an operation // retrieve the results of the operation if ($_SERVER['REQUEST_METHOD'] == "POST") { $llView = $_REQUEST["llView"]; $enclView = $_REQUEST["enclView"]; $sortBy = $_REQUEST["sortBy"]; $errorCode= $_REQUEST["errorCode"]; $displayMessage = $_REQUEST["Message"]; $returnMessage = $_REQUEST["returnMessage"]; } // get the counts needed to display the main table $numRows = count($carts); $empty_cleaning = $counts->avail_cleaning_slot_count; // sort the table data based on the sortBy value $oldi = sortSlots($carts, $sortBy); // determine the attributes for the div that handles displaying and scrolling // for the counts table if ($numlogLibs >= MAX_ROWS_IO_LIB) { // table is big enough to require scrolling $div1Attributes['divClass'] = "table-scroll"; $div1Attributes['thClass'] = "table-noscroll"; $div1Attributes['divHeight'] = MAX_SIZE_IO_LIB; } else { // table does not require scrolling $div1Attributes['divClass'] = ""; $div1Attributes['thClass'] = ""; $div1Attributes['divHeight'] = ""; } // determine the attributes for the div that handles displaying and scrolling // for the main data table $divAttributes = calculateDivAttributes($llView, $enclView, $carts, $numRows, MAX_ROWS_IO_LIST, MAX_SIZE_IO_LIST); $numRowsDisplayed = $divAttributes['numDisplay']; ?>