diff --git a/CollectionClass.inc b/CollectionClass.inc index e50ca224..bd44bbe8 100644 --- a/CollectionClass.inc +++ b/CollectionClass.inc @@ -54,13 +54,11 @@ class CollectionClass { } protected static function getDefaultCollectionQuery($pid) { - return 'select $object $title $content from <#ri> + return 'select $object $title from <#ri> where ($object $title - and $object $content and ($object or $object ) and $object ) - minus $content order by $title'; } diff --git a/api/fedora_item.inc b/api/fedora_item.inc index cdfdc210..03de0605 100644 --- a/api/fedora_item.inc +++ b/api/fedora_item.inc @@ -980,7 +980,9 @@ RDF; $params = array( 'pid' => $this->pid, - 'ownerId' => $ownerId, + 'ownerId' => (($ownerId !== NULL)? //Default to the current owner if none is provided. + $ownerId: + $this->objectProfile->objOwnerId), 'state' => $state, 'label' => $label, 'logMessage' => $logMessage @@ -1116,7 +1118,9 @@ RDF; $created_temp = TRUE; } - $file_url = file_create_url($file); + $parts = explode(DIRECTORY_SEPARATOR, $file); + $parts = array_map('rawurlencode', $parts); + $file_url = file_create_url(implode(DIRECTORY_SEPARATOR, $parts)); $toReturn = $this->modify_datastream_by_reference($file_url, $dsid, $label, $mime_type, $force, $logMessage); @@ -1140,6 +1144,14 @@ RDF; * @return type */ function modify_datastream_by_reference($external_url, $dsid, $label, $mime_type, $force = FALSE, $logMessage = 'Modified by Islandora API', $quiet=FALSE) { + global $base_url; + + // Fedora has some problems getting files from HTTPS connections sometimes, so if we are getting a file + // from the local drupal, we try to pass a HTTP url instead of a HTTPS one. + if(stripos($external_url, 'https://') !== FALSE && stripos($external_url, $base_url) !== FALSE) { + $external_url = str_ireplace('https://', 'http://', $external_url); + } + $params = array( 'pid' => $this->pid, 'dsID' => $dsid, diff --git a/api/tuque.inc b/api/tuque.inc index 553c4fe6..e53f6d5d 100644 --- a/api/tuque.inc +++ b/api/tuque.inc @@ -2,7 +2,7 @@ $islandora_module_path = drupal_get_path('module', 'fedora_repository'); -//do this until we expost these in a module or library +//do this until we export these in a module or library @include_once 'sites/all/libraries/tuque/Datastream.php'; @include_once 'sites/all/libraries/tuque/FedoraApi.php'; @include_once 'sites/all/libraries/tuque/FedoraApiSerializer.php'; @@ -67,7 +67,7 @@ class IslandoraTuque { } if (!isset($url)) { - $url = variable_get('islandora_base_url', 'http://localhost:8080/fedora'); + $url = variable_get('fedora_base_url', 'http://localhost:8080/fedora'); } if(self::exists()) { diff --git a/fedora_repository.module b/fedora_repository.module index 04e9f355..1ad76e6e 100644 --- a/fedora_repository.module +++ b/fedora_repository.module @@ -797,8 +797,9 @@ function fedora_repository_edit_qdc_form(&$form_state, $pid, $dsId = NULL) { // There is no custom function, so just load the standard QDC form. $metaDataForm = new formClass(); //currently we only edit the dc metadata. If you defined a custom form with a custom handler you are sol for now. - return $metaDataForm->createMetaDataForm($pid, $dsId, $client, $form_state); + $output = $metaDataForm->createMetaDataForm($pid, $dsId, $client, $form_state); } + return $output; } diff --git a/xsl/sparql_to_html.xsl b/xsl/sparql_to_html.xsl index 79cc438e..1b5872b8 100644 --- a/xsl/sparql_to_html.xsl +++ b/xsl/sparql_to_html.xsl @@ -90,8 +90,6 @@ - - @@ -103,17 +101,9 @@ - - + - - - - - - - +