Skip to content
Snippets Groups Projects
Commit 2e53520f authored by Ere Maijala's avatar Ere Maijala
Browse files

Switched Primo record retrieval to an unquoted contains search to work around...

Switched Primo record retrieval to an unquoted contains search to work around a Primo issue where colons in the ID cause retrieval to fail otherwise.
parent 63d870bd
No related merge requests found
...@@ -605,8 +605,13 @@ class Connector implements \Zend\Log\LoggerAwareInterface ...@@ -605,8 +605,13 @@ class Connector implements \Zend\Log\LoggerAwareInterface
// Query String Parameters // Query String Parameters
if (isset($recordId)) { if (isset($recordId)) {
$qs = []; $qs = [];
$qs[] = 'query=rid,exact,"' . urlencode(addcslashes($recordId, '"')) // There is currently (at 2015-12-17) a problem with Primo fetching
. '"'; // records that have colons in the id (e.g.
// doaj_xmloai:doaj.org/article:94935655971c4917aab4fcaeafeb67b9).
// According to Ex Libris support we must use contains search without
// quotes for the time being.
$qs[] = 'query=rid,contains,'
. urlencode(addcslashes($recordId, '":-()'));
$qs[] = "institution=$inst_code"; $qs[] = "institution=$inst_code";
$qs[] = 'onCampus=' . ($onCampus ? 'true' : 'false'); $qs[] = 'onCampus=' . ($onCampus ? 'true' : 'false');
$qs[] = "indx=1"; $qs[] = "indx=1";
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment