From 640d87e096dfedb9a0b9eddd67a52c92cce3b9da Mon Sep 17 00:00:00 2001 From: Tristan Olive Date: Wed, 5 Aug 2015 17:27:04 -0400 Subject: [PATCH] Added pass-through wrapper for team_lookup.php RPC (DBOINCP-184) --- .../boinc/modules/boinccore/boinccore.module | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/drupal/sites/default/boinc/modules/boinccore/boinccore.module b/drupal/sites/default/boinc/modules/boinccore/boinccore.module index dfc76f4bc1..dce602edb9 100644 --- a/drupal/sites/default/boinc/modules/boinccore/boinccore.module +++ b/drupal/sites/default/boinc/modules/boinccore/boinccore.module @@ -106,6 +106,13 @@ function boinccore_menu() { 'access callback' => TRUE, 'type' => MENU_CALLBACK ); + $items['team_lookup.php'] = array( + 'title' => 'Team lookup RPC', + 'description' => 'RPC for getting info on a team or matching teams.', + 'page callback' => 'boinccore_team_lookup', + 'access callback' => TRUE, + 'type' => MENU_CALLBACK + ); $items['team_email_list.php'] = array( 'title' => 'Get team member list RPC', 'description' => 'RPC for getting a list of members of a given team.', @@ -630,6 +637,16 @@ function boinccore_pending_credit() { include_boinc('user/pending.php'); } +/** + * Page callback for the team lookup RPC (team_lookup.php). + * Get info on a team by ID or a list of teams that match a given name + */ +function boinccore_team_lookup() { + // Remove q from the GET request or BOINC will panic + unset($_GET['q']); + include_boinc('user/team_lookup.php'); +} + /** * Page callback for the team email list RPC (team_email_list.php). * Get members of a given team