moodle_local_treestudyplan/db/services.php

584 lines
34 KiB
PHP
Raw Normal View History

<?php
2023-08-24 23:02:41 +02:00
// This file is part of the Studyplan plugin for Moodle
//
// Moodle is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// Moodle is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with Moodle. If not, see <https://www.gnu.org/licenses/>.
/**
*
* @package local_treestudyplan
* @copyright 2023 P.M. Kuipers
* @license https://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
*/
$services = [
"Competency listing" => [
'functions' => [
'local_treestudyplan_get_studyplan_map',
'local_treestudyplan_get_studyline_map',
'local_treestudyplan_add_studyplan',
'local_treestudyplan_add_studyline',
'local_treestudyplan_edit_studyplan',
'local_treestudyplan_edit_studyline',
'local_treestudyplan_delete_studyplan',
'local_treestudyplan_delete_studyline',
'local_treestudyplan_reorder_studylines',
'local_treestudyplan_get_studyitem',
'local_treestudyplan_add_studyitem',
'local_treestudyplan_edit_studyitem',
'local_treestudyplan_reorder_studyitems',
'local_treestudyplan_delete_studyitem',
'local_treestudyplan_connect_studyitems',
'local_treestudyplan_disconnect_studyitems',
'local_treestudyplan_get_user_studyplan_map',
'local_treestudyplan_map_courses',
'local_treestudyplan_export_studyplan',
'local_treestudyplan_import_studyplan',
],
'requiredcapability' => 'local/treestudyplan:configure',
2023-08-25 10:41:56 +02:00
'shortname' => 'local_treestudyplan_cohorts',
'restrictedusers' => 0,
'enabled' => 0,
'ajax' => true,
],
];
$functions = [
/***************************
2023-08-24 23:02:41 +02:00
* Studyplan functions
***************************/
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_studyplans' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'list_studyplans', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List available studyplans',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan, local/treestudyplan:viewuserreports',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_get_studyplan_map' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'get_studyplan_map', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve studyplan map',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan, local/treestudyplan:viewuserreports',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_get_studyline_map' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'get_studyline_map', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve studyline map',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_add_studyplan' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'add_studyplan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Add studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
2023-08-24 23:02:41 +02:00
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_add_studyline' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'add_studyline', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Add studyline',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_edit_studyplan' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'edit_studyplan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Edit studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_edit_studyline' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'edit_studyline', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Edit studyline',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_delete_studyplan' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'delete_studyplan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Delete studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_delete_studyline' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'delete_studyline', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Delete studyline',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_reorder_studylines' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'reorder_studylines', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Reorder studylines',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_get_studyitem' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'get_studyitem', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve study item',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
2023-08-24 23:02:41 +02:00
'loginrequired' => true,
],
'local_treestudyplan_add_studyitem' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'add_studyitem', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Add study item',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
2023-08-24 23:02:41 +02:00
'loginrequired' => true,
],
'local_treestudyplan_edit_studyitem' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'edit_studyitem', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Edit study item',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
2023-08-24 23:02:41 +02:00
'loginrequired' => true,
],
'local_treestudyplan_reorder_studyitems' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'reorder_studyitems', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Reorder study items',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
2023-08-24 23:02:41 +02:00
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_delete_studyitem' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'delete_studyitem', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Delete study item',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_connect_studyitems' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'connect_studyitems', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Connect study items',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_disconnect_studyitems' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'disconnect_studyitems', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Disconnect study items',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
/***************************
2023-08-24 23:02:41 +02:00
* Badge functions
***************************/
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_badges' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'list_badges', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List availabel site badges',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
/***************************
2023-08-24 23:02:41 +02:00
* Association functions
***************************/
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_cohort' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'list_cohort', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List available cohorts',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_find_user' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'find_user', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Find user',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_connect_cohort' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'connect_cohort', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Connect cohort to studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_disconnect_cohort' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'disconnect_cohort', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Disconnect cohort from study plan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_connect_user' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'connect_user', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Connect user to study plan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_disconnect_user' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'disconnect_user', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Disconnect user from studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_associated_users' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'associated_users', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List users associated with a studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_associated_cohorts' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'associated_cohorts', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List cohorts associated with a studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_user_studyplans' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'list_user_studyplans', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List user studyplans',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_get_user_studyplans' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'get_user_studyplans', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve user studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_get_user_studyplan' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'get_user_studyplan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve user studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_get_invited_studyplan' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'get_invited_studyplan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve user studyplan based on invite',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => '',
'loginrequired' => false,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_list_own_studyplans' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'list_own_studyplans', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List own studyplans',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => '',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_get_own_studyplan' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'get_own_studyplan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Retrieve own studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => '',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_map_categories' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'map_categories', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List available root categories',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_get_category' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'get_category', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Get details for specified category',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_include_grade' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'include_grade', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Include gradable in result',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan, local/treestudyplan:selectowngradables',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_all_associated' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'all_associated', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List associated users',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_list_aggregators' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'list_aggregators', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List available aggregators',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_disable_autoenddate' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'disable_autoenddate', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Disable automatic end dates on courses in the study plan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:forcescales',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_force_studyplan_scale' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'force_studyplan_scale', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Change all associated gradables to the chosen scale if possible',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:forcescales',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_scales' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'list_scales', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'List system scales',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:forcescales',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_duplicate_plan' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'duplicate_plan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Copy studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_export_plan' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'export_plan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Export study plan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_export_studylines' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'export_studylines', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Export study plan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_import_plan' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'import_plan', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Import study plan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_import_studylines' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'import_studylines', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Import study plan',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_edit_period' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'edit_period', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Edit period name and timing',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_submit_cm_editform' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'submit_cm_editform', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Submit course module edit form',
2023-08-24 23:02:41 +02:00
'type' => 'write', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_get_teaching_studyplans' => [ //web service function name.
'classname' => '\local_treestudyplan\studentstudyplanservice', //class containing the external function.
'methodname' => 'get_teaching_studyplans', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Get the studyplans I currently teach in',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_accessible_categories' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'list_accessible_categories', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Get categories accessible to the current user',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
'ajax' => true,
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_list_used_categories' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'list_used_categories', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Get categories hosting a studyplan',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'ajax' => true,
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_scan_badge_progress' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'scan_badge_progress', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Scan progress of students in attaining badge',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'ajax' => true,
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_scan_completion_progress' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'scan_completion_progress', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Scan progress of students in attaining completions',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'ajax' => true,
'loginrequired' => true,
],
2023-08-24 23:02:41 +02:00
'local_treestudyplan_scan_grade_progress' => [ //web service function name.
'classname' => '\local_treestudyplan\courseservice', //class containing the external function.
'methodname' => 'scan_grade_progress', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Scan progress of students in attaining grades',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:viewuserreports',
'ajax' => true,
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_cascade_cohortsync' => [ //web service function name.
'classname' => '\local_treestudyplan\associationservice', //class containing the external function.
'methodname' => 'cascade_cohortsync', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Sync cohortsync to studyplan association',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
2023-08-24 23:02:41 +02:00
'ajax' => true,
'loginrequired' => true,
],
'local_treestudyplan_course_period_timing' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'course_period_timing', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Chenge course start and end times to match period',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'ajax' => true,
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
'local_treestudyplan_set_studyitem_span' => [ //web service function name.
'classname' => '\local_treestudyplan\studyplanservice', //class containing the external function.
'methodname' => 'set_studyitem_span', //external function name.
2023-08-25 11:52:05 +02:00
'description' => 'Change the span of a course item',
2023-08-24 23:02:41 +02:00
'type' => 'read', //database rights of the web service function (read, write).
2023-08-25 11:52:05 +02:00
'capabilities' => 'local/treestudyplan:editstudyplan',
'ajax' => true,
'loginrequired' => true,
2023-08-24 23:02:41 +02:00
],
];