/** * Return a list of valid sort options -- overrides the base class with * custom behavior for Author/Search screen. * * @access public * @return array Sort value => description array. */ protected function getSortOptions() { // Author/Search screen if ($this->searchType == 'author' && $this->searchSubType == 'search') { // It's important to remember here we are talking about on-screen // sort values, not what is sent to Solr, since this screen // is really using facet sorting. return array('relevance' => 'sort_author_relevance', 'author' => 'sort_author_author'); } // Everywhere else -- use normal default behavior return parent::getSortOptions(); }
/** * Return a list of valid sort options -- overrides the base class with * custom behavior for Author/Search screen. * * @access public * @return array Sort value => description array. */ protected function getSortOptions() { // Everywhere else -- use normal default behavior return parent::getSortOptions(); }
/** * Return a list of valid sort options -- overrides the base class with * custom behavior for Author/Search screen. * * @access public * @return array Sort value => description array. */ protected function getSortOptions() { // Author/Search screen if ($this->searchType == 'author' && $this->searchSubType == 'search') { // It's important to remember here we are talking about on-screen // sort values, not what is sent to Solr, since this screen // is really using facet sorting. return array('relevance' => 'sort_author_relevance', 'author' => 'sort_author_author'); } // Everywhere else -- use normal default behavior $sortOptions = parent::getSortOptions(); $searchLibrary = Library::getSearchLibrary($this->searchSource); if ($searchLibrary == null) { unset($sortOptions['callnumber_sort']); } return $sortOptions; }