Browse Source

Merge branch '6.x' of github.com:Islandora/islandora into 6.x

pull/66/head
jonathangreen 13 years ago
parent
commit
0d0219f01b
  1. 4
      CollectionClass.inc
  2. 5
      CollectionPolicy.inc
  3. 3
      ObjectHelper.inc
  4. 1
      SecurityClass.inc
  5. 3
      fedora_repository.info
  6. 2
      plugins/fedora_imageapi.info

4
CollectionClass.inc

@ -519,6 +519,7 @@ class CollectionClass {
$show_batch_tab = FALSE; $show_batch_tab = FALSE;
$policy = CollectionPolicy::loadFromCollection($this->pid, TRUE); $policy = CollectionPolicy::loadFromCollection($this->pid, TRUE);
if(!empty($policy)){ if(!empty($policy)){
$content_models = $policy->getContentModels(); $content_models = $policy->getContentModels();
} }
@ -528,7 +529,7 @@ class CollectionClass {
if (!$show_ingest_tab) { if (!$show_ingest_tab) {
$view_selected = TRUE; $view_selected = TRUE;
} }
if(!$collection_items){ if (!$collection_items) {
$view_selected = FALSE; $view_selected = FALSE;
$add_selected = TRUE; $add_selected = TRUE;
} }
@ -540,7 +541,6 @@ class CollectionClass {
'#title' => 'View', '#title' => 'View',
'#selected' => $view_selected, '#selected' => $view_selected,
'#content' => $collection_items, '#content' => $collection_items,
); );
$tabset['add_tab'] = array( $tabset['add_tab'] = array(
'#type' => 'tabpage', '#type' => 'tabpage',

5
CollectionPolicy.inc

@ -360,13 +360,14 @@ class CollectionPolicy extends XMLDatastream {
* @param string $dsid * @param string $dsid
* @return string $nextPid * @return string $nextPid
*/ */
public function getNextPid($dsid) { public function getNextPid($dsid, $content_model = null) {
$ret = FALSE; $ret = FALSE;
if (self::valid_dsid($dsid) && $this->validate()) { if (self::valid_dsid($dsid) && $this->validate()) {
$content_models = $this->xml->getElementsByTagName('content_models')->item(0)->getElementsByTagName('content_model'); $content_models = $this->xml->getElementsByTagName('content_models')->item(0)->getElementsByTagName('content_model');
$namespace = FALSE; $namespace = FALSE;
for ($i = 0; $namespace === FALSE && $i < $content_models->length; $i++) { for ($i = 0; $namespace === FALSE && $i < $content_models->length; $i++) {
if (strtolower($content_models->item($i)->getAttribute('dsid')) == strtolower($dsid)) { if (strtolower($content_models->item($i)->getAttribute('dsid')) == strtolower($dsid) && (strtolower($content_models->item($i)->getAttribute('pid') == $content_model) || $content_model == null)) {
$namespace = $content_models->item($i)->getAttribute('namespace'); $namespace = $content_models->item($i)->getAttribute('namespace');
} }
} }

3
ObjectHelper.inc

@ -336,11 +336,12 @@ class ObjectHelper {
$versions = $item->get_datastream_history($id); $versions = $item->get_datastream_history($id);
if (is_array($versions)) { if (is_array($versions)) {
$downloadVersion = '<form method="GET" action="' . $action . '" onsubmit="this.action=\'' . $action . '\' + \'/\'+this.version.value;">'; $downloadVersion = '<form method="GET" action="' . $action . '" onsubmit="this.action=\'' . $action . '\' + \'/\'+this.version.value;">';
$downloadVersion .= '<input type="submit" value="' . t('Download') . '">';
$downloadVersion .= '<select name="version">'; $downloadVersion .= '<select name="version">';
foreach ($versions as $version) { foreach ($versions as $version) {
$downloadVersion .= '<option>' . $version->createDate . '</option>'; $downloadVersion .= '<option>' . $version->createDate . '</option>';
} }
$downloadVersion .= '</select><input type="submit" value="' . t('Download') . '"></form>'; $downloadVersion .= '</select></form>';
} }
} }

1
SecurityClass.inc

@ -95,7 +95,6 @@ class SecurityClass {
$usersAndRoles['users'] = $allowedUsers; $usersAndRoles['users'] = $allowedUsers;
$usersAndRoles['roles'] = $allowedRoles; $usersAndRoles['roles'] = $allowedRoles;
dd($usersAndRoles);
return $usersAndRoles; return $usersAndRoles;
} }

3
fedora_repository.info

@ -1,9 +1,8 @@
; $Id$
name = Islandora Repository name = Islandora Repository
dependencies[] = imageapi dependencies[] = imageapi
dependencies[] = tabs dependencies[] = tabs
dependencies[] = islandora_content_model_forms dependencies[] = islandora_content_model_forms
description = Shows a list of items in a fedora collection. description = Shows a list of items in a fedora collection.
package = Islandora package = Islandora
version = 11.2.0 version = 11.3beta2
core = 6.x core = 6.x

2
plugins/fedora_imageapi.info

@ -3,5 +3,5 @@ description = Adds image manipulation support through a REST interface
package = Islandora Dependencies package = Islandora Dependencies
dependencies[] = fedora_repository dependencies[] = fedora_repository
dependencies[] = imageapi dependencies[] = imageapi
version = 11.2.0 version = 11.3beta2
core = 6.x core = 6.x

Loading…
Cancel
Save