Browse Source

ISLANDORA-171 Don't show Add tab if the add object form is empty.

pull/105/head
Alexander O'Neill 14 years ago
parent
commit
767699a07b
  1. 5
      CollectionClass.inc
  2. 2
      formClass.inc

5
CollectionClass.inc

@ -436,12 +436,11 @@ class CollectionClass {
$tabset['add_tab'] = array(
// #type and #title are the minimum requirements.
'#type' => 'tabpage',
'#title' => t('Add / Edit'),
'#title' => t('Add'),
'#selected' => $show_ingest_tab,
// This will be the content of the tab.
'#content' => $add_to_collection,
);
return $tabset;
}
@ -464,7 +463,7 @@ class CollectionClass {
}
}
else {
$ingestObject = ' ';
$ingestObject = '';
}
return $ingestObject;

2
formClass.inc

@ -708,7 +708,9 @@ class formClass {
'#weight' => '-1',
'#description' => t('Datastream IDs defined by the content model.'),
);
$form['stream_id']['#options'] = array_combine($unused_dsids, $unused_dsids);
}
else {
$form['stream_id'] = array(

Loading…
Cancel
Save