forked from Islandora/islandora
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implementing default services hook using exported code.
- Loading branch information
1 parent
1459e24
commit 34ce0ae
Showing
14 changed files
with
110 additions
and
2 deletions.
There are no files selected for viewing
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 1 addition & 2 deletions
3
modules/islandora/islandora.info → drupal/islandora/islandora.info
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
name = Islandora | ||
name = Islandora | ||
description = "View and manage Fedora 4 objects" | ||
package = Islandora | ||
version = 7.x-dev | ||
core = 7.x | ||
configure = admin/islandora/configure | ||
dependencies[] = rest_server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
<?php | ||
|
||
/** | ||
* Implements hook_ctools_plugin_api(). | ||
*/ | ||
function islandora_ctools_plugin_api($owner, $api) { | ||
if ($owner == 'services' && $api == 'services') { | ||
return array( | ||
'version' => 3, | ||
); | ||
} | ||
} | ||
|
||
/** | ||
* Implements hook_default_services_endpoint(). | ||
*/ | ||
function islandora_default_services_endpoint() { | ||
$endpoint = new stdClass(); | ||
$endpoint->disabled = FALSE; /* Edit this to true to make a default endpoint disabled initially */ | ||
$endpoint->api_version = 3; | ||
$endpoint->name = 'islandora'; | ||
$endpoint->server = 'rest_server'; | ||
$endpoint->path = 'islandora'; | ||
$endpoint->authentication = array(); | ||
$endpoint->server_settings = array(); | ||
$endpoint->resources = array( | ||
'node' => array( | ||
'operations' => array( | ||
'retrieve' => array( | ||
'enabled' => '1', | ||
), | ||
'create' => array( | ||
'enabled' => '1', | ||
), | ||
'update' => array( | ||
'enabled' => '1', | ||
), | ||
'delete' => array( | ||
'enabled' => '1', | ||
), | ||
'index' => array( | ||
'enabled' => '1', | ||
), | ||
), | ||
'relationships' => array( | ||
'files' => array( | ||
'enabled' => '1', | ||
), | ||
'comments' => array( | ||
'enabled' => '1', | ||
), | ||
), | ||
'targeted_actions' => array( | ||
'attach_file' => array( | ||
'enabled' => '1', | ||
), | ||
), | ||
), | ||
'user' => array( | ||
'operations' => array( | ||
'retrieve' => array( | ||
'enabled' => '1', | ||
), | ||
'create' => array( | ||
'enabled' => '1', | ||
), | ||
'update' => array( | ||
'enabled' => '1', | ||
), | ||
'delete' => array( | ||
'enabled' => '1', | ||
), | ||
'index' => array( | ||
'enabled' => '1', | ||
), | ||
), | ||
'actions' => array( | ||
'login' => array( | ||
'enabled' => '1', | ||
), | ||
'logout' => array( | ||
'enabled' => '1', | ||
), | ||
'token' => array( | ||
'enabled' => '1', | ||
), | ||
'request_new_password' => array( | ||
'enabled' => '1', | ||
), | ||
'register' => array( | ||
'enabled' => '1', | ||
), | ||
), | ||
'targeted_actions' => array( | ||
'cancel' => array( | ||
'enabled' => '1', | ||
), | ||
'password_reset' => array( | ||
'enabled' => '1', | ||
), | ||
'resend_welcome_email' => array( | ||
'enabled' => '1', | ||
), | ||
), | ||
), | ||
); | ||
$endpoint->debug = 0; | ||
return array($endpoint); | ||
} |