/** * Get default OpenURL parameters. * * @return array */ protected function getDefaultOpenUrlParams() { $params = parent::getDefaultOpenUrlParams(); if (isset($this->fields['isbn'])) { $isbn = $this->fields['isbn']; if (is_array($isbn) && !empty($isbn)) { $isbn = $isbn[0]; } $params['rft.isbn'] = $isbn; } if (isset($this->fields['issn'])) { $issn = $this->fields['issn']; if (is_array($issn) && !empty($issn)) { $issn = $issn[0]; } $params['rft.issn'] = $issn; } if (isset($this->fields['container_volume'])) { $params['rft.volume'] = $this->fields['container_volume']; } if (isset($this->fields['container_issue'])) { $params['rft.issue'] = $this->fields['container_issue']; } $params['rft.atitle'] = $params['rft.title']; return $params; }
/** * Factory for SolrMarc record driver. * * @param ServiceManager $sm Service manager. * * @return SolrMarc */ public static function getSolrMarc(ServiceManager $sm) { $driver = new SolrMarc($sm->getServiceLocator()->get('VuFind\\Config')->get('config'), null, $sm->getServiceLocator()->get('VuFind\\Config')->get('searches'), $sm->getServiceLocator()->get('VuFind\\SearchResultsPluginManager'), $sm->getServiceLocator()->get('VuFind\\Config')->get('datasources')); $driver->attachILS($sm->getServiceLocator()->get('VuFind\\ILSConnection'), $sm->getServiceLocator()->get('VuFind\\ILSHoldLogic'), $sm->getServiceLocator()->get('VuFind\\ILSTitleHoldLogic')); $driver->attachSearchService($sm->getServiceLocator()->get('VuFind\\Search')); return $driver; }