Browse Source

Return a key for the filter, coding standards.

pull/504/head
Jordan Dukart 11 years ago
parent
commit
24cc6e667d
  1. 6
      includes/utilities.inc
  2. 36
      islandora.api.php
  3. 2
      islandora.module

6
includes/utilities.inc

@ -486,10 +486,12 @@ function islandora_prepare_new_object($namespace = NULL, $label = NULL, $datastr
// set datastream_file by url for the given scheme. Https (SSL) can // set datastream_file by url for the given scheme. Https (SSL) can
// cause this to fail, and trigger an output log in watchdog. // cause this to fail, and trigger an output log in watchdog.
$datastream_file = url($ds['datastream_file'], array('absolute' => TRUE)); $datastream_file = url($ds['datastream_file'], array('absolute' => TRUE));
watchdog('islandora', watchdog(
'islandora',
'Attempting to ingest %file in islandora_prepare_new_object(), but it does not appear to be readable. We will pass the path through url(), and pass along as such.', 'Attempting to ingest %file in islandora_prepare_new_object(), but it does not appear to be readable. We will pass the path through url(), and pass along as such.',
array('%file' => $datastream_file), array('%file' => $datastream_file),
WATCHDOG_WARNING); WATCHDOG_WARNING
);
} }
} }

36
islandora.api.php

@ -57,7 +57,7 @@ function hook_islandora_view_print_object($object) {
* @return array * @return array
* An array whose values are markup. * An array whose values are markup.
*/ */
function hook_CMODEL_PID_islandora_view_object($object) { function hook_cmodel_pid_islandora_view_object($object) {
} }
@ -82,7 +82,7 @@ function hook_islandora_view_object_alter(&$object, &$rendered) {
* @param array $rendered * @param array $rendered
* The array of rendered views. * The array of rendered views.
*/ */
function hook_CMODEL_PID_islandora_view_object_alter(&$object, &$rendered) { function hook_cmodel_pid_islandora_view_object_alter(&$object, &$rendered) {
} }
/** /**
@ -109,7 +109,7 @@ function hook_islandora_edit_object($object) {
* @return array * @return array
* An array whose values are markup. * An array whose values are markup.
*/ */
function hook_CMODEL_PID_islandora_edit_object($object) { function hook_cmodel_pid_islandora_edit_object($object) {
} }
/** /**
@ -160,7 +160,7 @@ function hook_islandora_object_alter(AbstractObject $object, array &$context) {
* *
* @see hook_islandora_object_alter() * @see hook_islandora_object_alter()
*/ */
function hook_CMODEL_PID_islandora_object_alter(AbstractObject $object, array &$context) { function hook_cmodel_pid_islandora_object_alter(AbstractObject $object, array &$context) {
} }
/** /**
@ -209,7 +209,7 @@ function hook_islandora_datastream_alter(AbstractObject $object, AbstractDatastr
* *
* @see hook_islandora_datastream_alter() * @see hook_islandora_datastream_alter()
*/ */
function hook_CMODEL_PID_DSID_islandora_datastream_alter(AbstractObject $object, AbstractDatastream $datastream, array &$context) { function hook_cmodel_pid_dsid_islandora_datastream_alter(AbstractObject $object, AbstractDatastream $datastream, array &$context) {
} }
/** /**
@ -233,7 +233,7 @@ function hook_islandora_object_ingested(AbstractObject $object) {
* *
* @see hook_islandora_object_ingested() * @see hook_islandora_object_ingested()
*/ */
function hook_CMODEL_PID_islandora_object_ingested(AbstractObject $object) { function hook_cmodel_pid_islandora_object_ingested(AbstractObject $object) {
} }
/** /**
@ -258,7 +258,7 @@ function hook_islandora_object_modified(AbstractObject $object) {
* *
* @see hook_islandora_object_modified() * @see hook_islandora_object_modified()
*/ */
function hook_CMODEL_PID_islandora_object_modified(AbstractObject $object) { function hook_cmodel_pid_islandora_object_modified(AbstractObject $object) {
} }
/** /**
@ -278,7 +278,7 @@ function hook_islandora_object_purged($pid) {
* *
* @see hook_islandora_object_purged() * @see hook_islandora_object_purged()
*/ */
function hook_CMODEL_PID_islandora_object_purged($pid) { function hook_cmodel_pid_islandora_object_purged($pid) {
} }
/** /**
@ -303,7 +303,7 @@ function hook_islandora_datastream_ingested(AbstractObject $object, AbstractData
* *
* @see hook_islandora_object_ingested() * @see hook_islandora_object_ingested()
*/ */
function hook_CMODEL_PID_DSID_islandora_datastream_ingested(AbstractObject $object, AbstractDatastream $datastream) { function hook_cmodel_pid_dsid_islandora_datastream_ingested(AbstractObject $object, AbstractDatastream $datastream) {
} }
/** /**
@ -330,7 +330,7 @@ function hook_islandora_datastream_modified(AbstractObject $object, AbstractData
* *
* @see hook_islandora_datastream_modified() * @see hook_islandora_datastream_modified()
*/ */
function hook_CMODEL_PID_islandora_datastream_modified(AbstractObject $object, AbstractDatastream $datastream) { function hook_cmodel_pid_islandora_datastream_modified(AbstractObject $object, AbstractDatastream $datastream) {
} }
/** /**
@ -352,7 +352,7 @@ function hook_islandora_datastream_purged(AbstractObject $object, $dsid) {
* *
* @see hook_islandora_datastream_purged() * @see hook_islandora_datastream_purged()
*/ */
function hook_CMODEL_PID_islandora_datastream_purged(AbstractObject $object, $dsid) { function hook_cmodel_pid_islandora_datastream_purged(AbstractObject $object, $dsid) {
} }
/** /**
@ -489,7 +489,7 @@ function hook_islandora_ingest_steps_alter(array &$steps, array &$form_state) {
* *
* @see hook_islandora_ingest_steps() * @see hook_islandora_ingest_steps()
*/ */
function hook_CMODEL_PID_islandora_ingest_steps(array $form_state) { function hook_cmodel_pid_islandora_ingest_steps(array $form_state) {
} }
/** /**
@ -501,7 +501,7 @@ function hook_CMODEL_PID_islandora_ingest_steps(array $form_state) {
* @param array $form_state * @param array $form_state
* An array containing the Drupal form_state. * An array containing the Drupal form_state.
*/ */
function hook_CMODEL_PID_islandora_ingest_steps_alter(array &$steps, array &$form_state) { function hook_cmodel_pid_islandora_ingest_steps_alter(array &$steps, array &$form_state) {
} }
/** /**
@ -540,7 +540,7 @@ function hook_islandora_object_access($op, $object, $user) {
* *
* @see hook_islandora_object_access() * @see hook_islandora_object_access()
*/ */
function hook_CMODEL_PID_islandora_object_access($op, $object, $user) { function hook_cmodel_pid_islandora_object_access($op, $object, $user) {
} }
/** /**
@ -579,7 +579,7 @@ function hook_islandora_datastream_access($op, $object, $user) {
* *
* @see hook_islandora_datastream_access() * @see hook_islandora_datastream_access()
*/ */
function hook_CMODEL_PID_islandora_datastream_access($op, $object, $user) { function hook_cmodel_pid_islandora_datastream_access($op, $object, $user) {
} }
/** /**
@ -594,7 +594,7 @@ function hook_islandora_overview_object(AbstractObject $object) {
* *
* Content model specific. * Content model specific.
*/ */
function hook_CMODEL_PID_islandora_overview_object(AbstractObject $object) { function hook_cmodel_pid_islandora_overview_object(AbstractObject $object) {
return drupal_render(drupal_get_form('some_form', $object)); return drupal_render(drupal_get_form('some_form', $object));
} }
/** /**
@ -609,7 +609,7 @@ function hook_islandora_overview_object_alter(AbstractObject &$object, &$output)
* *
* Content model specific. * Content model specific.
*/ */
function hook_CMODEL_PID_islandora_overview_object_alter(AbstractObject &$object, &$output) { function hook_cmodel_pid_islandora_overview_object_alter(AbstractObject &$object, &$output) {
$output = $output . drupal_render(drupal_get_form('some_form', $object)); $output = $output . drupal_render(drupal_get_form('some_form', $object));
} }
@ -694,7 +694,7 @@ function hook_islandora_derivative(AbstractObject $object = NULL) {
* *
* @see hook_islandora_derivative() * @see hook_islandora_derivative()
*/ */
function hook_CMODEL_PID_islandora_derivative() { function hook_cmodel_pid_islandora_derivative() {
} }

2
islandora.module

@ -1728,7 +1728,7 @@ function islandora_islandora_basic_collection_get_query_filters() {
if ($enforced) { if ($enforced) {
$namespace_array = islandora_get_allowed_namespaces(); $namespace_array = islandora_get_allowed_namespaces();
$namespace_sparql = implode('|', $namespace_array); $namespace_sparql = implode('|', $namespace_array);
return format_string('regex(str(?object), "info:fedora/(!namespaces):")', array('!namespaces' => $namespace_sparql)); return array('islandora_namespace_restrictions' => format_string('regex(str(?object), "info:fedora/(!namespaces):")', array('!namespaces' => $namespace_sparql)));
} }
} }

Loading…
Cancel
Save