diff --git a/css/islandora.admin.css b/css/islandora.admin.css
new file mode 100644
index 00000000..ab1e4e86
--- /dev/null
+++ b/css/islandora.admin.css
@@ -0,0 +1,9 @@
+/*
+ Document : islandora_basic_collection.admin.css
+ Created on : May 23, 2012, 11:23:06 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
+
diff --git a/css/islandora.base.css b/css/islandora.base.css
new file mode 100644
index 00000000..13dd8637
--- /dev/null
+++ b/css/islandora.base.css
@@ -0,0 +1,8 @@
+/*
+ Document : islandora_basic_collection.base.css
+ Created on : May 23, 2012, 11:22:04 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
diff --git a/css/islandora.theme.css b/css/islandora.theme.css
new file mode 100644
index 00000000..764ed690
--- /dev/null
+++ b/css/islandora.theme.css
@@ -0,0 +1,8 @@
+/*
+ Document : islandora_basic_collection.theme
+ Created on : May 23, 2012, 11:23:56 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
diff --git a/islandora-object-edit.tpl.php b/islandora-object-edit.tpl.php
new file mode 100644
index 00000000..e58ec9c6
--- /dev/null
+++ b/islandora-object-edit.tpl.php
@@ -0,0 +1,59 @@
+.
+ */
+?>
+label
+ * $object->id
+ * to get the contents of a datastream
+ * $object['dsid']->content
+ *
+ * $dublin_core is a Dublin_Core object
+ * which is an array of elements, such as dc.title
+ * and each element has an array of values. dc.title can have none, one or many titles
+ * this is the case for all dc elements.
+ *
+ * we can get a list of datastreams by doing
+ * foreach ($object as $ds){
+ * do something here
+ * }
+ *
+ */
+
+//dsm($object);
+
+drupal_set_title($islandora_object->label);
+
+print($islandora_object->label . ' ' . $islandora_object->id);
+print('this is the edit template');
+print ('
datastreams
');
+foreach ($islandora_object as $ds) {
+ print $ds->label . '
';
+ //do something
+}
+?>
+
diff --git a/islandora.module b/islandora.module
index e0f4aee7..49783c30 100644
--- a/islandora.module
+++ b/islandora.module
@@ -104,18 +104,18 @@ function islandora_menu() {
);
$items['islandora/object/%/view'] = array(
- 'title' => 'Repository',
+ 'title' => 'View',
'page callback' => 'islandora_view_object',
'page arguments' => array(2),
- 'type' => MENU_NORMAL_ITEM,
+ 'type' => MENU_DEFAULT_LOCAL_TASK,
'access arguments' => array(FEDORA_VIEW),
);
$items['islandora/object/%/edit'] = array(
- 'title' => 'Repository',
+ 'title' => 'Edit',
'page callback' => 'islandora_edit_object',
'page arguments' => array(2),
- 'type' => MENU_NORMAL_ITEM,
+ 'type' => MENU_LOCAL_TASK,
'access arguments' => array(FEDORA_MODIFY_STATE),
);
@@ -230,6 +230,44 @@ function islandora_get_types() {
return module_invoke_all('islandora_get_types');
}
+/**
+ * a function to call other modules edit page. If there are not any modules
+ * that handle this function this module will build a default page.
+ * @global object $user
+ * @param string $object_id
+ * @return string
+ */
+function islandora_edit_object($object_id) {
+ module_load_include('inc', 'islandora', 'RestConnection');
+ global $user;
+ try {
+ $restConnection = new RestConnection($user);
+ $fedora_object = new FedoraObject($object_id, $restConnection->repository);
+ } catch (Exception $e) {
+ drupal_set_message(t('Error getting Islandora object %s', array('%s' => $object_id)), 'error');
+ return"";
+ }
+ drupal_alter('islandora_edit_object', $fedora_object);
+ $arr = module_invoke_all('islandora_edit_object', $fedora_object);
+ $output = "";
+ foreach ($arr as $key => $value) {
+ $output .= $key . '
' . $value; //if we have multiple modules handle one cmodel we need to iterate over multiple
+ }
+ //we could do another module invoke all here to build the edit tab with a default implemented in this module?
+ return $output;
+}
+
+
+/**
+ * builds a default page for the edit tab
+ * @param object $fedora_object
+ * A tuque Fedora Object
+ */
+function islandora_islandora_edit_object($fedora_object){
+ $output = theme('islandora_default_edit', array('islandora_object' => $fedora_object));
+ return array ('Default Edit output' => $output);
+}
+
/**
*
* @paramstring $datastream_id
@@ -318,6 +356,10 @@ function islandora_theme() {
'template' => 'islandora-object',
'variables' => array('islandora_object' => NULL),
),
+ 'islandora_default_edit' => array(
+ 'template' => 'islandora-object-edit',
+ 'variables' => array('islandora_object' => NULL),
+ ),
);
}
@@ -390,4 +432,9 @@ function islandora_preprocess_islandora_default(&$variables) {
if (isset($islandora_object['TN'])) {
$variables['islandora_thumbnail_url'] = $base_url . '/islandora/object/' . $islandora_object->id . '/datastream/TN/view';
}
+}
+
+function islandora_preprocess_islandora_default_edit(&$variables){
+ //$islandora_object = $variables['islandora_object'];
+
}
\ No newline at end of file
diff --git a/islandora_basic_collection/css/islandora_basic_collection.admin.css b/islandora_basic_collection/css/islandora_basic_collection.admin.css
new file mode 100644
index 00000000..ab1e4e86
--- /dev/null
+++ b/islandora_basic_collection/css/islandora_basic_collection.admin.css
@@ -0,0 +1,9 @@
+/*
+ Document : islandora_basic_collection.admin.css
+ Created on : May 23, 2012, 11:23:06 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
+
diff --git a/islandora_basic_collection/css/islandora_basic_collection.base.css b/islandora_basic_collection/css/islandora_basic_collection.base.css
new file mode 100644
index 00000000..13dd8637
--- /dev/null
+++ b/islandora_basic_collection/css/islandora_basic_collection.base.css
@@ -0,0 +1,8 @@
+/*
+ Document : islandora_basic_collection.base.css
+ Created on : May 23, 2012, 11:22:04 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
diff --git a/islandora_basic_collection/css/islandora_basic_collection.theme.css b/islandora_basic_collection/css/islandora_basic_collection.theme.css
new file mode 100644
index 00000000..860fa8c7
--- /dev/null
+++ b/islandora_basic_collection/css/islandora_basic_collection.theme.css
@@ -0,0 +1,9 @@
+/*
+ Document : islandora_basic_collection.theme
+ Created on : May 23, 2012, 11:23:56 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
+
diff --git a/islandora_basic_image/css/islandora_basic_image.admin.css b/islandora_basic_image/css/islandora_basic_image.admin.css
new file mode 100644
index 00000000..a7f79c7c
--- /dev/null
+++ b/islandora_basic_image/css/islandora_basic_image.admin.css
@@ -0,0 +1,12 @@
+/*
+ Document : islandora_basic_collection.admin.css
+ Created on : May 23, 2012, 11:23:06 AM
+ Author : ppound
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+root {
+ display: block;
+}
+
diff --git a/islandora_basic_image/css/islandora_basic_image.base.css b/islandora_basic_image/css/islandora_basic_image.base.css
new file mode 100644
index 00000000..13dd8637
--- /dev/null
+++ b/islandora_basic_image/css/islandora_basic_image.base.css
@@ -0,0 +1,8 @@
+/*
+ Document : islandora_basic_collection.base.css
+ Created on : May 23, 2012, 11:22:04 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+
diff --git a/islandora_basic_image/css/islandora_basic_image.theme.css b/islandora_basic_image/css/islandora_basic_image.theme.css
new file mode 100644
index 00000000..764ed690
--- /dev/null
+++ b/islandora_basic_image/css/islandora_basic_image.theme.css
@@ -0,0 +1,8 @@
+/*
+ Document : islandora_basic_collection.theme
+ Created on : May 23, 2012, 11:23:56 AM
+ Description:
+ Purpose of the stylesheet follows.
+*/
+
+