Browse Source

Fixes for issues found from Islandora conference. QA TRIAL BY FIRE

7.x-2.x
Daniel Lamb 9 years ago
parent
commit
ee3fc9e968
  1. 4
      islandora/include/rdf_mapping.inc
  2. 9
      islandora_basic_image/islandora_basic_image.module

4
islandora/include/rdf_mapping.inc

@ -20,10 +20,6 @@ function islandora_get_default_rdf_mapping($bundle, array $rdf_types) {
$default_rdf_types = array(
'ldp:RDFSource',
'ldp:Container',
'nt:hierarchyNode',
'nt:folder',
'nt:base',
'mix:referenceable',
'fedora:Resource',
'fedora:Container',
);

9
islandora_basic_image/islandora_basic_image.module

@ -42,24 +42,23 @@ function islandora_basic_image_form_islandora_basic_image_node_form_alter(&$form
);
// Add a collection picker if node is new (e.g. this is an insert form).
$node = $form_state['node'];
if (!isset($node->nid) || isset($node->is_new)) {
// Construct list of options from db and a default.
$default = array('' => t('None'));
$from_db = db_select('node', 'n')
->fields('n', array('uuid', 'title'))
->condition('n.type', ISLANDORA_COLLECTION_CONTENT_TYPE)
->execute()
->fetchAllKeyed();
$options = $default + $from_db;
// Add the select to the form.
$form['parent_collection'] = array(
'#type' => 'select',
'#title' => t('Parent Collection'),
'#description' => t('Select the parent collection to add this to. Select "Fedora Root" if you want it to be a top-level collection'),
'#options' => $options,
'#default_value' => '',
'#description' => t('Select the parent collection to add this to.'),
'#options' => $from_db,
'#weight' => -4,
'#required' => TRUE,
);
// Keep title on top.

Loading…
Cancel
Save