You are here

function user_relationship_service_help in User Relationships 7

Same name and namespace in other branches
  1. 6 user_relationship_service/user_relationship_service.module \user_relationship_service_help()

Implementation of hook_help().

File

user_relationship_service/user_relationship_service.module, line 14
@author Drupal 7 and Services 3.x port by Ed Zenisek <http://drupal.org/user/2410988> @author Adapted to Services 3.x by MD3 http://drupal.org/user/1714848 @author Drupal 6 port by Darren Ferguson <http://drupal.org/user/70179> @author…

Code

function user_relationship_service_help($path, $arg) {
  switch ($path) {
    case 'admin/help#user_relationship_service':
      $output = '';
      $output .= '<h3>' . t('About') . '</h3>';
      $output .= '<p>' . t('The User Relationship Service module provides user relationship resources
          to the Services module for user relationships. It requires Services 3.x.') . '</p>';
      $output .= '<h3>' . t('Resources') . '</h3>';
      $output .= '<dl>';
      $output .= '<dt>' . t('List all relationship types') . '</dt>';
      $output .= '<dd>' . t('<em>[GET] {endpoint}/relationships (optional) ?page=0&pagesize=20</em><br />
          This lists all the relationships that are available in the system.  Access is allowed to logged
          in users that are able to have an relationship of any type.') . '</dd>';
      $output .= '<dt>' . t('List my relationships') . '</dt>';
      $output .= '<dd>' . t('<em>[GET] {endpoint}/user/{uid}/relationships/ (optional) ?page=0&pagesize=20</em><br />
          This lists all the relationships for the logged in user.  Access is allowed to logged
          in users that are able to have an relationship of any type.') . '</dd>';
      $output .= '<dt>' . t('List relationships for a user') . '</dt>';
      $output .= '<dd>' . t('<em>[GET] {endpoint}/user/{uid}/relationshipsuser/ (optional) ?page=0&pagesize=20</em><br />
          This lists all the relationships for the given user.  Access is allowed to logged
          in users that are able view all relationships.') . '</dd>';
      $output .= '<dt>' . t('Request a relationships with a user') . '</dt>';
      $output .= '<dd>' . t('<em>[POST] {endpoint}/user/{uid}/relationship/{type}</em><br />
          This requests a relationship of the specified type from the logged in user to the specified user.  Access is allowed to logged
          in users that are able to request the specified relationship type.') . '</dd>';
      $output .= '<dt>' . t('Approve a relationship') . '</dt>';
      $output .= '<dd>' . t('<em>[POST] {endpoint}/relationships/approve</em><br />
          This approves the request for a specified relationship.  Requires an array (data) containing the rid of the
          relationship to approve. {"rid":"x"}  Access is allowed to logged
          in users that are able to have the specified relationship type.') . '</dd>';
      $output .= '<dt>' . t('Delete a relationship') . '</dt>';
      $output .= '<dd>' . t('<em>[POST] {endpoint}/relationships/delete</em><br />
          This deletes request or relationship for the specified relationship.  Requires an array (data) containing the rid of the
          relationship to delete and a reason why the deletionn took place. {"rid":"x","reason","y"}  Access is allowed to logged
          in users that are able to delete the specified relationship type.') . '</dd>';
      return $output;
    case 'admin/modules#description':
      return t('Provides user relationship methods to services applications. Requires services.module.');
  }
}