MDL-66078 mod_forum: Add webservice to pull discussion data for user

Part of MDL-66074
This commit is contained in:
Mathew May 2019-07-11 11:51:13 +08:00
parent 5123b5c9d7
commit 34e6dd2475
11 changed files with 711 additions and 7 deletions

View file

@ -175,6 +175,7 @@ $functions = array(
'ajax' => true,
'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
),
'mod_forum_delete_post' => array(
'classname' => 'mod_forum_external',
'methodname' => 'delete_post',
@ -183,4 +184,14 @@ $functions = array(
'type' => 'write',
'services' => array(MOODLE_OFFICIAL_MOBILE_SERVICE),
),
'mod_forum_get_discussion_posts_by_userid' => array(
'classname' => 'mod_forum_external',
'methodname' => 'get_discussion_posts_by_userid',
'classpath' => 'mod/forum/externallib.php',
'description' => 'Returns a list of forum posts for a discussion for a user.',
'type' => 'read',
'ajax' => true,
'capabilities' => 'mod/forum:viewdiscussion, mod/forum:viewqandawithoutposting',
),
);