Skip to content

Commit

Permalink
Fixes #10 - Added cadaveres_api service + rest dependency.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ale authored and ccamara committed Nov 24, 2015
1 parent 4ffefb4 commit 51863ef
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
* Implements hook_ctools_plugin_api().
*/
function ft_c_inmobiliarios_services_ctools_plugin_api($module = NULL, $api = NULL) {
if ($module == "services" && $api == "services") {
return array("version" => "3");
}
if ($module == "strongarm" && $api == "strongarm") {
return array("version" => "1");
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@ core = 7.x
package = Cadáveres Inmobiliarios
version = 7.x-1.0-alpha1
dependencies[] = cors
dependencies[] = rest_server
dependencies[] = services
dependencies[] = services_views
dependencies[] = strongarm
dependencies[] = views
features[ctools][] = services:services:3
features[ctools][] = strongarm:strongarm:1
features[ctools][] = views:views_default:3.0
features[features_api][] = api:2
features[services_endpoint][] = cadaveres_api
features[variable][] = cors_domains
features[views_view][] = c_inmobiliarios_services
features_exclude[dependencies][ctools] = ctools
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?php
/**
* @file
* ft_c_inmobiliarios_services.services.inc
*/

/**
* Implements hook_default_services_endpoint().
*/
function ft_c_inmobiliarios_services_default_services_endpoint() {
$export = array();

$endpoint = new stdClass();
$endpoint->disabled = FALSE; /* Edit this to true to make a default endpoint disabled initially */
$endpoint->api_version = 3;
$endpoint->name = 'cadaveres_api';
$endpoint->server = 'rest_server';
$endpoint->path = 'api';
$endpoint->authentication = array();
$endpoint->server_settings = array();
$endpoint->resources = array(
'lista-general' => array(
'operations' => array(
'index' => array(
'enabled' => '1',
),
),
),
);
$endpoint->debug = 0;
$export['cadaveres_api'] = $endpoint;

return $export;
}

0 comments on commit 51863ef

Please sign in to comment.