@@ -1336,9 +1336,9 @@ discard block |
||
| 1336 | 1336 | * @param integer $sessionCategoryId |
| 1337 | 1337 | * @param int $visibility |
| 1338 | 1338 | * @param string $description |
| 1339 | - * @param bool $showDescription |
|
| 1339 | + * @param integer $showDescription |
|
| 1340 | 1340 | * @param int $duration |
| 1341 | - * @param array $extraFields |
|
| 1341 | + * @param boolean|null $extraFields |
|
| 1342 | 1342 | * @param int $sessionAdminId |
| 1343 | 1343 | * @param boolean $sendSubscriptionNotification Optional. |
| 1344 | 1344 | * Whether send a mail notification to users being subscribed |
@@ -1558,7 +1558,7 @@ discard block |
||
| 1558 | 1558 | * @param array $user_list |
| 1559 | 1559 | * @param int $session_visibility |
| 1560 | 1560 | * @param bool $empty_users |
| 1561 | - * @return bool |
|
| 1561 | + * @return false|null |
|
| 1562 | 1562 | */ |
| 1563 | 1563 | public static function suscribe_users_to_session( |
| 1564 | 1564 | $id_session, |
@@ -1830,7 +1830,7 @@ discard block |
||
| 1830 | 1830 | * @param array $courseInfo |
| 1831 | 1831 | * @param int $status |
| 1832 | 1832 | * @param bool $updateTotal |
| 1833 | - * @return bool |
|
| 1833 | + * @return false|null |
|
| 1834 | 1834 | */ |
| 1835 | 1835 | public static function removeUsersFromCourseSession( |
| 1836 | 1836 | $userList, |
@@ -1896,7 +1896,7 @@ discard block |
||
| 1896 | 1896 | * @param string $course_code |
| 1897 | 1897 | * @param int $session_visibility |
| 1898 | 1898 | * @param bool $removeUsersNotInList |
| 1899 | - * @return bool |
|
| 1899 | + * @return false|null |
|
| 1900 | 1900 | */ |
| 1901 | 1901 | public static function subscribe_users_to_session_course( |
| 1902 | 1902 | $user_list, |
@@ -2079,7 +2079,7 @@ discard block |
||
| 2079 | 2079 | * @param bool $removeExistingCoursesWithUsers Whether to unsubscribe |
| 2080 | 2080 | * existing courses and users (true, default) or not (false) |
| 2081 | 2081 | * @param $copyEvaluation from base course to session course |
| 2082 | - * @return void Nothing, or false on error |
|
| 2082 | + * @return false|null Nothing, or false on error |
|
| 2083 | 2083 | * */ |
| 2084 | 2084 | public static function add_courses_to_session( |
| 2085 | 2085 | $sessionId, |
@@ -2275,6 +2275,8 @@ discard block |
||
| 2275 | 2275 | * |
| 2276 | 2276 | * @param int Session id |
| 2277 | 2277 | * @param int Course id |
| 2278 | + * @param integer $session_id |
|
| 2279 | + * @param integer $course_id |
|
| 2278 | 2280 | * @return bool True in case of success, false otherwise |
| 2279 | 2281 | */ |
| 2280 | 2282 | public static function unsubscribe_course_from_session($session_id, $course_id) |
@@ -2330,7 +2332,7 @@ discard block |
||
| 2330 | 2332 | * @param string $variable Field's internal variable name |
| 2331 | 2333 | * @param int $fieldType Field's type |
| 2332 | 2334 | * @param string $displayText Field's language var name |
| 2333 | - * @return int new extra field id |
|
| 2335 | + * @return boolean new extra field id |
|
| 2334 | 2336 | */ |
| 2335 | 2337 | public static function create_session_extra_field($variable, $fieldType, $displayText) |
| 2336 | 2338 | { |
@@ -2349,7 +2351,7 @@ discard block |
||
| 2349 | 2351 | * @param integer Course ID |
| 2350 | 2352 | * @param string Field variable name |
| 2351 | 2353 | * @param string Field value |
| 2352 | - * @return boolean true if field updated, false otherwise |
|
| 2354 | + * @return boolean|null true if field updated, false otherwise |
|
| 2353 | 2355 | */ |
| 2354 | 2356 | public static function update_session_extra_field_value($sessionId, $variable, $value = '') |
| 2355 | 2357 | { |
@@ -2554,7 +2556,7 @@ discard block |
||
| 2554 | 2556 | * @param array id_checked |
| 2555 | 2557 | * @param bool include delete session |
| 2556 | 2558 | * @param bool optional, true if the function is called by a webservice, false otherwise. |
| 2557 | - * @return void Nothing, or false on error |
|
| 2559 | + * @return boolean Nothing, or false on error |
|
| 2558 | 2560 | * The parameters is a array to delete sessions |
| 2559 | 2561 | * */ |
| 2560 | 2562 | public static function delete_session_category($id_checked, $delete_session = false, $from_ws = false) |
@@ -3049,6 +3051,7 @@ discard block |
||
| 3049 | 3051 | * @param string $orderCondition |
| 3050 | 3052 | * @param string $keyword |
| 3051 | 3053 | * @param string $description |
| 3054 | + * @param integer $status |
|
| 3052 | 3055 | * @return array sessions |
| 3053 | 3056 | */ |
| 3054 | 3057 | public static function getSessionsFollowedByUser( |
@@ -3261,8 +3264,8 @@ discard block |
||
| 3261 | 3264 | /** |
| 3262 | 3265 | * Gets the list of courses by session filtered by access_url |
| 3263 | 3266 | * |
| 3264 | - * @param $userId |
|
| 3265 | - * @param $sessionId |
|
| 3267 | + * @param integer $userId |
|
| 3268 | + * @param null|integer $sessionId |
|
| 3266 | 3269 | * @param null $from |
| 3267 | 3270 | * @param null $limit |
| 3268 | 3271 | * @param null $column |
@@ -3387,6 +3390,7 @@ discard block |
||
| 3387 | 3390 | /** |
| 3388 | 3391 | * Gets the count of courses by session filtered by access_url |
| 3389 | 3392 | * @param int session id |
| 3393 | + * @param integer $session_id |
|
| 3390 | 3394 | * @return array list of courses |
| 3391 | 3395 | */ |
| 3392 | 3396 | public static function getCourseCountBySessionId($session_id, $keyword = null) |
@@ -3638,6 +3642,7 @@ discard block |
||
| 3638 | 3642 | * Updates a session status |
| 3639 | 3643 | * @param int session id |
| 3640 | 3644 | * @param int status |
| 3645 | + * @param integer $status |
|
| 3641 | 3646 | */ |
| 3642 | 3647 | public static function set_session_status($session_id, $status) |
| 3643 | 3648 | { |
@@ -3949,7 +3954,7 @@ discard block |
||
| 3949 | 3954 | |
| 3950 | 3955 | /** |
| 3951 | 3956 | * @param $id |
| 3952 | - * @return bool |
|
| 3957 | + * @return null|boolean |
|
| 3953 | 3958 | */ |
| 3954 | 3959 | public static function protect_teacher_session_edit($id) |
| 3955 | 3960 | { |
@@ -4013,7 +4018,7 @@ discard block |
||
| 4013 | 4018 | * true: if the session exists it will be updated. |
| 4014 | 4019 | * false: if session exists a new session will be created adding a counter session1, session2, etc |
| 4015 | 4020 | * @param int $defaultUserId |
| 4016 | - * @param mixed $logger |
|
| 4021 | + * @param Logger $logger |
|
| 4017 | 4022 | * @param array $extraFields convert a file row to an extra field. Example in CSV file there's a SessionID then it will |
| 4018 | 4023 | * converted to extra_external_session_id if you set this: array('SessionId' => 'extra_external_session_id') |
| 4019 | 4024 | * @param string $extraFieldId |
@@ -5255,7 +5260,6 @@ discard block |
||
| 5255 | 5260 | * @param string $lastConnectionDate |
| 5256 | 5261 | * @param array $sessionIdList |
| 5257 | 5262 | * @param array $studentIdList |
| 5258 | - * @param int $userStatus STUDENT|COURSEMANAGER constants |
|
| 5259 | 5263 | * |
| 5260 | 5264 | * @return array|int |
| 5261 | 5265 | */ |
@@ -5407,7 +5411,7 @@ discard block |
||
| 5407 | 5411 | /** |
| 5408 | 5412 | * Get the list of course tools that have to be dealt with in case of |
| 5409 | 5413 | * registering any course to a session |
| 5410 | - * @return array The list of tools to be dealt with (literal names) |
|
| 5414 | + * @return string[] The list of tools to be dealt with (literal names) |
|
| 5411 | 5415 | */ |
| 5412 | 5416 | public static function getCourseToolToBeManaged() |
| 5413 | 5417 | { |
@@ -5421,7 +5425,7 @@ discard block |
||
| 5421 | 5425 | * Calls the methods bound to each tool when a course is registered into a session |
| 5422 | 5426 | * @param int $sessionId |
| 5423 | 5427 | * @param int $courseId |
| 5424 | - * @return void |
|
| 5428 | + * @return boolean|null |
|
| 5425 | 5429 | */ |
| 5426 | 5430 | public static function installCourse($sessionId, $courseId) |
| 5427 | 5431 | { |
@@ -6061,6 +6065,7 @@ discard block |
||
| 6061 | 6065 | * @param int $categoryId The internal ID of the session category |
| 6062 | 6066 | * @param string $target Value to search for in the session field values |
| 6063 | 6067 | * @param array $extraFields A list of fields to be scanned and returned |
| 6068 | + * @param DateTime $publicationDate |
|
| 6064 | 6069 | * @return mixed |
| 6065 | 6070 | */ |
| 6066 | 6071 | public static function getShortSessionListAndExtraByCategory($categoryId, $target, $extraFields = null, $publicationDate = null) |
@@ -7390,7 +7395,7 @@ discard block |
||
| 7390 | 7395 | /** |
| 7391 | 7396 | * Get link to the admin page for this session |
| 7392 | 7397 | * @param int $id Session ID |
| 7393 | - * @return mixed URL to the admin page to manage the session, or false on error |
|
| 7398 | + * @return false|string URL to the admin page to manage the session, or false on error |
|
| 7394 | 7399 | */ |
| 7395 | 7400 | public static function getAdminPath($id) |
| 7396 | 7401 | { |
@@ -7407,7 +7412,7 @@ discard block |
||
| 7407 | 7412 | * If a course is provided, build the link to the course |
| 7408 | 7413 | * @param int $id Session ID |
| 7409 | 7414 | * @param int $courseId Course ID (optional) in case the link has to send straight to the course |
| 7410 | - * @return mixed URL to the page to use the session, or false on error |
|
| 7415 | + * @return false|string URL to the page to use the session, or false on error |
|
| 7411 | 7416 | */ |
| 7412 | 7417 | public static function getPath($id, $courseId = 0) |
| 7413 | 7418 | { |
@@ -7505,7 +7510,7 @@ discard block |
||
| 7505 | 7510 | /** |
| 7506 | 7511 | * Return true if coach is allowed to access this session |
| 7507 | 7512 | * @param int $sessionId |
| 7508 | - * @return bool |
|
| 7513 | + * @return integer |
|
| 7509 | 7514 | */ |
| 7510 | 7515 | public static function isSessionDateOkForCoach($sessionId) |
| 7511 | 7516 | { |
@@ -80,7 +80,7 @@ discard block |
||
| 80 | 80 | } |
| 81 | 81 | |
| 82 | 82 | if ($debug) { |
| 83 | - error_log("checkip " . intval($check_ip)); |
|
| 83 | + error_log("checkip ".intval($check_ip)); |
|
| 84 | 84 | } |
| 85 | 85 | |
| 86 | 86 | if ($check_ip) { |
@@ -138,7 +138,7 @@ discard block |
||
| 138 | 138 | '', |
| 139 | 139 | 'SOAP-ENC:Array', |
| 140 | 140 | array(), |
| 141 | - array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType' => 'tns:extras[]')), |
|
| 141 | + array(array('ref'=>'SOAP-ENC:arrayType', 'wsdl:arrayType' => 'tns:extras[]')), |
|
| 142 | 142 | 'tns:extras' |
| 143 | 143 | ); |
| 144 | 144 | |
@@ -171,7 +171,7 @@ discard block |
||
| 171 | 171 | '', |
| 172 | 172 | 'SOAP-ENC:Array', |
| 173 | 173 | array(), |
| 174 | - array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType' => 'tns:usersParams[]')), |
|
| 174 | + array(array('ref'=>'SOAP-ENC:arrayType', 'wsdl:arrayType' => 'tns:usersParams[]')), |
|
| 175 | 175 | 'tns:usersParams' |
| 176 | 176 | ); |
| 177 | 177 | |
@@ -210,17 +210,17 @@ discard block |
||
| 210 | 210 | '', |
| 211 | 211 | 'SOAP-ENC:Array', |
| 212 | 212 | array(), |
| 213 | - array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType' => 'tns:result_createUsers[]')),'tns:result_createUsers' |
|
| 213 | + array(array('ref'=>'SOAP-ENC:arrayType', 'wsdl:arrayType' => 'tns:result_createUsers[]')), 'tns:result_createUsers' |
|
| 214 | 214 | ); |
| 215 | 215 | |
| 216 | 216 | // Register the method to expose |
| 217 | -$server->register('WSCreateUsers', // method name |
|
| 218 | - array('createUsers' => 'tns:createUsers'), // input parameters |
|
| 219 | - array('return' => 'tns:results_createUsers'), // output parameters |
|
| 220 | - 'urn:WSRegistration', // namespace |
|
| 221 | - 'urn:WSRegistration#WSCreateUsers', // soapaction |
|
| 222 | - 'rpc', // style |
|
| 223 | - 'encoded', // use |
|
| 217 | +$server->register('WSCreateUsers', // method name |
|
| 218 | + array('createUsers' => 'tns:createUsers'), // input parameters |
|
| 219 | + array('return' => 'tns:results_createUsers'), // output parameters |
|
| 220 | + 'urn:WSRegistration', // namespace |
|
| 221 | + 'urn:WSRegistration#WSCreateUsers', // soapaction |
|
| 222 | + 'rpc', // style |
|
| 223 | + 'encoded', // use |
|
| 224 | 224 | 'This service adds a user' // documentation |
| 225 | 225 | ); |
| 226 | 226 | |
@@ -401,7 +401,7 @@ discard block |
||
| 401 | 401 | continue; |
| 402 | 402 | } |
| 403 | 403 | |
| 404 | - $results[] = $userId; |
|
| 404 | + $results[] = $userId; |
|
| 405 | 405 | |
| 406 | 406 | } // end principal foreach |
| 407 | 407 | |
@@ -447,13 +447,13 @@ discard block |
||
| 447 | 447 | |
| 448 | 448 | |
| 449 | 449 | // Register the method to expose |
| 450 | -$server->register('WSCreateUser', // method name |
|
| 451 | - array('createUser' => 'tns:createUser'), // input parameters |
|
| 452 | - array('return' => 'xsd:string'), // output parameters |
|
| 453 | - 'urn:WSRegistration', // namespace |
|
| 454 | - 'urn:WSRegistration#WSCreateUser', // soapaction |
|
| 455 | - 'rpc', // style |
|
| 456 | - 'encoded', // use |
|
| 450 | +$server->register('WSCreateUser', // method name |
|
| 451 | + array('createUser' => 'tns:createUser'), // input parameters |
|
| 452 | + array('return' => 'xsd:string'), // output parameters |
|
| 453 | + 'urn:WSRegistration', // namespace |
|
| 454 | + 'urn:WSRegistration#WSCreateUser', // soapaction |
|
| 455 | + 'rpc', // style |
|
| 456 | + 'encoded', // use |
|
| 457 | 457 | 'This service adds a user' // documentation |
| 458 | 458 | ); |
| 459 | 459 | |
@@ -558,7 +558,7 @@ discard block |
||
| 558 | 558 | } |
| 559 | 559 | |
| 560 | 560 | if (isset($original_user_id_name) && isset($original_user_id_value)) { |
| 561 | - $_SESSION['ws_' . $original_user_id_name] = $original_user_id_value; |
|
| 561 | + $_SESSION['ws_'.$original_user_id_name] = $original_user_id_value; |
|
| 562 | 562 | } |
| 563 | 563 | |
| 564 | 564 | /** @var User $user */ |
@@ -606,7 +606,7 @@ discard block |
||
| 606 | 606 | ); |
| 607 | 607 | |
| 608 | 608 | if (isset($original_user_id_name) && isset($original_user_id_value)) { |
| 609 | - unset($_SESSION['ws_' . $original_user_id_name]); |
|
| 609 | + unset($_SESSION['ws_'.$original_user_id_name]); |
|
| 610 | 610 | } |
| 611 | 611 | |
| 612 | 612 | if (is_array($extra_list) && count($extra_list) > 0) { |
@@ -658,7 +658,7 @@ discard block |
||
| 658 | 658 | 'language' => array('name' => 'language', 'type' => 'xsd:string'), |
| 659 | 659 | 'phone' => array('name' => 'phone', 'type' => 'xsd:string'), |
| 660 | 660 | 'expiration_date' => array('name' => 'expiration_date', 'type' => 'xsd:string'), |
| 661 | - 'official_code' => array('name' => 'official_code', 'type' => 'xsd:string'), |
|
| 661 | + 'official_code' => array('name' => 'official_code', 'type' => 'xsd:string'), |
|
| 662 | 662 | 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
| 663 | 663 | 'original_user_id_value'=> array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
| 664 | 664 | 'extra' => array('name' => 'extra', 'type' => 'tns:extrasList') |
@@ -686,7 +686,7 @@ discard block |
||
| 686 | 686 | 'all', |
| 687 | 687 | '', |
| 688 | 688 | array( |
| 689 | - 'users' => array('name' => 'users', 'type' => 'tns:createUsersPassEncryptParamsList'), |
|
| 689 | + 'users' => array('name' => 'users', 'type' => 'tns:createUsersPassEncryptParamsList'), |
|
| 690 | 690 | 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
| 691 | 691 | ) |
| 692 | 692 | ); |
@@ -716,13 +716,13 @@ discard block |
||
| 716 | 716 | ); |
| 717 | 717 | |
| 718 | 718 | // Register the method to expose |
| 719 | -$server->register('WSCreateUsersPasswordCrypted', // method name |
|
| 719 | +$server->register('WSCreateUsersPasswordCrypted', // method name |
|
| 720 | 720 | array('createUsersPasswordCrypted' => 'tns:createUsersPasswordCrypted'), // input parameters |
| 721 | - array('return' => 'tns:results_createUsersPassEncrypt'), // output parameters |
|
| 722 | - 'urn:WSRegistration', // namespace |
|
| 723 | - 'urn:WSRegistration#WSCreateUsersPasswordCrypted', // soapaction |
|
| 724 | - 'rpc', // style |
|
| 725 | - 'encoded', // use |
|
| 721 | + array('return' => 'tns:results_createUsersPassEncrypt'), // output parameters |
|
| 722 | + 'urn:WSRegistration', // namespace |
|
| 723 | + 'urn:WSRegistration#WSCreateUsersPasswordCrypted', // soapaction |
|
| 724 | + 'rpc', // style |
|
| 725 | + 'encoded', // use |
|
| 726 | 726 | 'This service adds users to the system' // documentation |
| 727 | 727 | ); |
| 728 | 728 | |
@@ -769,7 +769,7 @@ discard block |
||
| 769 | 769 | $salt = ''; |
| 770 | 770 | |
| 771 | 771 | if (!empty($_configuration['password_encryption'])) { |
| 772 | - if ($_configuration['password_encryption'] === $encrypt_method ) { |
|
| 772 | + if ($_configuration['password_encryption'] === $encrypt_method) { |
|
| 773 | 773 | if ($encrypt_method == 'md5' && !preg_match('/^[A-Fa-f0-9]{32}$/', $password)) { |
| 774 | 774 | $msg = "Encryption $encrypt_method is invalid"; |
| 775 | 775 | $results[] = $msg; |
@@ -792,7 +792,7 @@ discard block |
||
| 792 | 792 | |
| 793 | 793 | if (is_array($extra_list) && count($extra_list) > 0) { |
| 794 | 794 | foreach ($extra_list as $extra) { |
| 795 | - if($extra['field_name'] == 'salt') { |
|
| 795 | + if ($extra['field_name'] == 'salt') { |
|
| 796 | 796 | $salt = $extra['field_value']; |
| 797 | 797 | break; |
| 798 | 798 | } |
@@ -847,7 +847,7 @@ discard block |
||
| 847 | 847 | active='1', |
| 848 | 848 | hr_dept_id=".intval($hr_dept_id); |
| 849 | 849 | |
| 850 | - $sql .= " WHERE user_id='".$r_check_user[0]."'"; |
|
| 850 | + $sql .= " WHERE user_id='".$r_check_user[0]."'"; |
|
| 851 | 851 | Database::query($sql); |
| 852 | 852 | |
| 853 | 853 | if (is_array($extra_list) && count($extra_list) > 0) { |
@@ -967,7 +967,7 @@ discard block |
||
| 967 | 967 | |
| 968 | 968 | $count_results = count($results); |
| 969 | 969 | $output = array(); |
| 970 | - for($i = 0; $i < $count_results; $i++) { |
|
| 970 | + for ($i = 0; $i < $count_results; $i++) { |
|
| 971 | 971 | $output[] = array( |
| 972 | 972 | 'original_user_id_value' => $orig_user_id_value[$i], |
| 973 | 973 | 'result' => $results[$i], |
@@ -986,9 +986,9 @@ discard block |
||
| 986 | 986 | 'all', |
| 987 | 987 | '', |
| 988 | 988 | array( |
| 989 | - 'user_id' => array('name' => 'course', 'type' => 'xsd:string'), // Chamilo user Id |
|
| 990 | - 'session_id' => array('name' => 'user_id', 'type' => 'xsd:string'), // Current Session course ID |
|
| 991 | - 'course_id' =>array('name' => 'courseId', 'type' => 'xsd:string'), // Course Real Id |
|
| 989 | + 'user_id' => array('name' => 'course', 'type' => 'xsd:string'), // Chamilo user Id |
|
| 990 | + 'session_id' => array('name' => 'user_id', 'type' => 'xsd:string'), // Current Session course ID |
|
| 991 | + 'course_id' =>array('name' => 'courseId', 'type' => 'xsd:string'), // Course Real Id |
|
| 992 | 992 | 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string'), |
| 993 | 993 | |
| 994 | 994 | // optional |
@@ -1044,9 +1044,9 @@ discard block |
||
| 1044 | 1044 | ); |
| 1045 | 1045 | } |
| 1046 | 1046 | |
| 1047 | - if ($debug) error_log('$userId found: '. $userId); |
|
| 1048 | - if ($debug) error_log('$courseId found: '. $courseId); |
|
| 1049 | - if ($debug) error_log('$sessionId found: '. $sessionId); |
|
| 1047 | + if ($debug) error_log('$userId found: '.$userId); |
|
| 1048 | + if ($debug) error_log('$courseId found: '.$courseId); |
|
| 1049 | + if ($debug) error_log('$sessionId found: '.$sessionId); |
|
| 1050 | 1050 | |
| 1051 | 1051 | return [ |
| 1052 | 1052 | 'user_id' => $userId, |
@@ -1082,7 +1082,7 @@ discard block |
||
| 1082 | 1082 | return returnError(WS_ERROR_SECRET_KEY); |
| 1083 | 1083 | } |
| 1084 | 1084 | |
| 1085 | - if ($debug) error_log('Params '. print_r($params, 1)); |
|
| 1085 | + if ($debug) error_log('Params '.print_r($params, 1)); |
|
| 1086 | 1086 | |
| 1087 | 1087 | $params = parseCourseSessionUserParams($params); |
| 1088 | 1088 | |
@@ -1095,13 +1095,13 @@ discard block |
||
| 1095 | 1095 | $result = 0; |
| 1096 | 1096 | |
| 1097 | 1097 | if (!empty($coaches)) { |
| 1098 | - if ($debug) error_log('Coaches: '. print_r($coaches, 1)); |
|
| 1098 | + if ($debug) error_log('Coaches: '.print_r($coaches, 1)); |
|
| 1099 | 1099 | if (in_array($userId, $coaches)) { |
| 1100 | 1100 | $result = 1; |
| 1101 | 1101 | } |
| 1102 | 1102 | } |
| 1103 | 1103 | |
| 1104 | - if ($debug) error_log('Result: '. $result); |
|
| 1104 | + if ($debug) error_log('Result: '.$result); |
|
| 1105 | 1105 | |
| 1106 | 1106 | return $result; |
| 1107 | 1107 | } |
@@ -1133,7 +1133,7 @@ discard block |
||
| 1133 | 1133 | return returnError(WS_ERROR_SECRET_KEY); |
| 1134 | 1134 | } |
| 1135 | 1135 | |
| 1136 | - if ($debug) error_log('Params '. print_r($params, 1)); |
|
| 1136 | + if ($debug) error_log('Params '.print_r($params, 1)); |
|
| 1137 | 1137 | |
| 1138 | 1138 | $params = parseCourseSessionUserParams($params); |
| 1139 | 1139 | |
@@ -1147,7 +1147,7 @@ discard block |
||
| 1147 | 1147 | $result = 0; |
| 1148 | 1148 | |
| 1149 | 1149 | if (!empty($coaches)) { |
| 1150 | - if ($debug) error_log('Coaches: ' . print_r($coaches, 1)); |
|
| 1150 | + if ($debug) error_log('Coaches: '.print_r($coaches, 1)); |
|
| 1151 | 1151 | if (!in_array($userId, $coaches)) { |
| 1152 | 1152 | $result = 1; |
| 1153 | 1153 | } |
@@ -1155,7 +1155,7 @@ discard block |
||
| 1155 | 1155 | $result = 1; |
| 1156 | 1156 | } |
| 1157 | 1157 | |
| 1158 | - if ($debug) error_log('Final Result: '. $result); |
|
| 1158 | + if ($debug) error_log('Final Result: '.$result); |
|
| 1159 | 1159 | |
| 1160 | 1160 | return $result; |
| 1161 | 1161 | } |
@@ -1173,32 +1173,32 @@ discard block |
||
| 1173 | 1173 | 'all', |
| 1174 | 1174 | '', |
| 1175 | 1175 | array( |
| 1176 | - 'firstname' => array('name' => 'firstname', 'type' => 'xsd:string'), |
|
| 1177 | - 'lastname' => array('name' => 'lastname', 'type' => 'xsd:string'), |
|
| 1178 | - 'status' => array('name' => 'status', 'type' => 'xsd:string'), |
|
| 1179 | - 'email' => array('name' => 'email', 'type' => 'xsd:string'), |
|
| 1180 | - 'loginname' => array('name' => 'loginname', 'type' => 'xsd:string'), |
|
| 1181 | - 'password' => array('name' => 'password', 'type' => 'xsd:string'), //encripted password using the encrypt_method |
|
| 1182 | - 'encrypt_method' => array('name' => 'encrypt_method', 'type' => 'xsd:string'), |
|
| 1183 | - 'language' => array('name' => 'language', 'type' => 'xsd:string'), |
|
| 1184 | - 'phone' => array('name' => 'phone', 'type' => 'xsd:string'), |
|
| 1185 | - 'expiration_date' => array('name' => 'expiration_date', 'type' => 'xsd:string'), |
|
| 1186 | - 'official_code' => array('name' => 'official_code', 'type' => 'xsd:string'), |
|
| 1187 | - 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 1188 | - 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 1189 | - 'extra' => array('name' => 'extra', 'type' => 'tns:extrasList'), |
|
| 1190 | - 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 1176 | + 'firstname' => array('name' => 'firstname', 'type' => 'xsd:string'), |
|
| 1177 | + 'lastname' => array('name' => 'lastname', 'type' => 'xsd:string'), |
|
| 1178 | + 'status' => array('name' => 'status', 'type' => 'xsd:string'), |
|
| 1179 | + 'email' => array('name' => 'email', 'type' => 'xsd:string'), |
|
| 1180 | + 'loginname' => array('name' => 'loginname', 'type' => 'xsd:string'), |
|
| 1181 | + 'password' => array('name' => 'password', 'type' => 'xsd:string'), //encripted password using the encrypt_method |
|
| 1182 | + 'encrypt_method' => array('name' => 'encrypt_method', 'type' => 'xsd:string'), |
|
| 1183 | + 'language' => array('name' => 'language', 'type' => 'xsd:string'), |
|
| 1184 | + 'phone' => array('name' => 'phone', 'type' => 'xsd:string'), |
|
| 1185 | + 'expiration_date' => array('name' => 'expiration_date', 'type' => 'xsd:string'), |
|
| 1186 | + 'official_code' => array('name' => 'official_code', 'type' => 'xsd:string'), |
|
| 1187 | + 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 1188 | + 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 1189 | + 'extra' => array('name' => 'extra', 'type' => 'tns:extrasList'), |
|
| 1190 | + 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 1191 | 1191 | ) |
| 1192 | 1192 | ); |
| 1193 | 1193 | |
| 1194 | 1194 | // Register the method to expose |
| 1195 | -$server->register('WSCreateUserPasswordCrypted', // method name |
|
| 1196 | - array('createUserPasswordCrypted' => 'tns:createUserPasswordCrypted'), // input parameters |
|
| 1197 | - array('return' => 'xsd:string'), // output parameters |
|
| 1198 | - 'urn:WSRegistration', // namespace |
|
| 1199 | - 'urn:WSRegistration#WSCreateUserPasswordCrypted', // soapaction |
|
| 1200 | - 'rpc', // style |
|
| 1201 | - 'encoded', // use |
|
| 1195 | +$server->register('WSCreateUserPasswordCrypted', // method name |
|
| 1196 | + array('createUserPasswordCrypted' => 'tns:createUserPasswordCrypted'), // input parameters |
|
| 1197 | + array('return' => 'xsd:string'), // output parameters |
|
| 1198 | + 'urn:WSRegistration', // namespace |
|
| 1199 | + 'urn:WSRegistration#WSCreateUserPasswordCrypted', // soapaction |
|
| 1200 | + 'rpc', // style |
|
| 1201 | + 'encoded', // use |
|
| 1202 | 1202 | 'This service adds users' // documentation |
| 1203 | 1203 | ); |
| 1204 | 1204 | |
@@ -1208,7 +1208,7 @@ discard block |
||
| 1208 | 1208 | global $_user, $_configuration, $debug; |
| 1209 | 1209 | $debug = 1; |
| 1210 | 1210 | if ($debug) error_log('WSCreateUserPasswordCrypted'); |
| 1211 | - if ($debug) error_log(print_r($params,1)); |
|
| 1211 | + if ($debug) error_log(print_r($params, 1)); |
|
| 1212 | 1212 | |
| 1213 | 1213 | if (!WSHelperVerifyKey($params)) { |
| 1214 | 1214 | return returnError(WS_ERROR_SECRET_KEY); |
@@ -1241,7 +1241,7 @@ discard block |
||
| 1241 | 1241 | $extra_list = isset($params['extra']) ? $params['extra'] : ''; |
| 1242 | 1242 | |
| 1243 | 1243 | if (!empty($_configuration['password_encryption'])) { |
| 1244 | - if ($_configuration['password_encryption'] === $encrypt_method ) { |
|
| 1244 | + if ($_configuration['password_encryption'] === $encrypt_method) { |
|
| 1245 | 1245 | if ($encrypt_method == 'md5' && !preg_match('/^[A-Fa-f0-9]{32}$/', $password)) { |
| 1246 | 1246 | $msg = "Encryption $encrypt_method is invalid"; |
| 1247 | 1247 | if ($debug) error_log($msg); |
@@ -1303,7 +1303,7 @@ discard block |
||
| 1303 | 1303 | if (!is_null($auth_source)) { |
| 1304 | 1304 | $sql .= " auth_source='".Database::escape_string($auth_source)."',"; |
| 1305 | 1305 | } |
| 1306 | - $sql .= " |
|
| 1306 | + $sql .= " |
|
| 1307 | 1307 | password='".Database::escape_string($password)."', |
| 1308 | 1308 | email='".Database::escape_string($email)."', |
| 1309 | 1309 | status='".Database::escape_string($status)."', |
@@ -1312,7 +1312,7 @@ discard block |
||
| 1312 | 1312 | expiration_date='".Database::escape_string($expiration_date)."', |
| 1313 | 1313 | active='1', |
| 1314 | 1314 | hr_dept_id=".intval($hr_dept_id); |
| 1315 | - $sql .= " WHERE user_id='".$r_check_user[0]."'"; |
|
| 1315 | + $sql .= " WHERE user_id='".$r_check_user[0]."'"; |
|
| 1316 | 1316 | if ($debug) error_log($sql); |
| 1317 | 1317 | Database::query($sql); |
| 1318 | 1318 | |
@@ -1492,13 +1492,13 @@ discard block |
||
| 1492 | 1492 | ); |
| 1493 | 1493 | |
| 1494 | 1494 | // Register the method to expose |
| 1495 | -$server->register('WSEditUserCredentials', // method name |
|
| 1496 | - array('editUserCredentials' => 'tns:editUserCredentials'), // input parameters |
|
| 1497 | - array('return' => 'xsd:string'), // output parameters |
|
| 1498 | - 'urn:WSRegistration', // namespace |
|
| 1499 | - 'urn:WSRegistration#WSEditUserCredentials', // soapaction |
|
| 1500 | - 'rpc', // style |
|
| 1501 | - 'encoded', // use |
|
| 1495 | +$server->register('WSEditUserCredentials', // method name |
|
| 1496 | + array('editUserCredentials' => 'tns:editUserCredentials'), // input parameters |
|
| 1497 | + array('return' => 'xsd:string'), // output parameters |
|
| 1498 | + 'urn:WSRegistration', // namespace |
|
| 1499 | + 'urn:WSRegistration#WSEditUserCredentials', // soapaction |
|
| 1500 | + 'rpc', // style |
|
| 1501 | + 'encoded', // use |
|
| 1502 | 1502 | 'This service edits the username and password of a user' // documentation |
| 1503 | 1503 | ); |
| 1504 | 1504 | |
@@ -1597,13 +1597,13 @@ discard block |
||
| 1597 | 1597 | ); |
| 1598 | 1598 | |
| 1599 | 1599 | // Register the method to expose |
| 1600 | -$server->register('WSEditUsers', // method name |
|
| 1601 | - array('editUsers' => 'tns:editUsers'), // input parameters |
|
| 1600 | +$server->register('WSEditUsers', // method name |
|
| 1601 | + array('editUsers' => 'tns:editUsers'), // input parameters |
|
| 1602 | 1602 | array('return' => 'tns:results_editUsers'), // output parameters |
| 1603 | - 'urn:WSRegistration', // namespace |
|
| 1604 | - 'urn:WSRegistration#WSEditUsers', // soapaction |
|
| 1605 | - 'rpc', // style |
|
| 1606 | - 'encoded', // use |
|
| 1603 | + 'urn:WSRegistration', // namespace |
|
| 1604 | + 'urn:WSRegistration#WSEditUsers', // soapaction |
|
| 1605 | + 'rpc', // style |
|
| 1606 | + 'encoded', // use |
|
| 1607 | 1607 | 'This service edits a user from wiener' // documentation |
| 1608 | 1608 | ); |
| 1609 | 1609 | |
@@ -1795,13 +1795,13 @@ discard block |
||
| 1795 | 1795 | ); |
| 1796 | 1796 | |
| 1797 | 1797 | // Register the method to expose |
| 1798 | -$server->register('WSEditUser', // method name |
|
| 1799 | - array('editUser' => 'tns:editUser'), // input parameters |
|
| 1800 | - array('return' => 'xsd:string'), // output parameters |
|
| 1801 | - 'urn:WSRegistration', // namespace |
|
| 1802 | - 'urn:WSRegistration#WSEditUser', // soapaction |
|
| 1803 | - 'rpc', // style |
|
| 1804 | - 'encoded', // use |
|
| 1798 | +$server->register('WSEditUser', // method name |
|
| 1799 | + array('editUser' => 'tns:editUser'), // input parameters |
|
| 1800 | + array('return' => 'xsd:string'), // output parameters |
|
| 1801 | + 'urn:WSRegistration', // namespace |
|
| 1802 | + 'urn:WSRegistration#WSEditUser', // soapaction |
|
| 1803 | + 'rpc', // style |
|
| 1804 | + 'encoded', // use |
|
| 1805 | 1805 | 'This service edits a user from wiener' // documentation |
| 1806 | 1806 | ); |
| 1807 | 1807 | |
@@ -1972,13 +1972,13 @@ discard block |
||
| 1972 | 1972 | ); |
| 1973 | 1973 | |
| 1974 | 1974 | // Register the method to expose |
| 1975 | -$server->register('WSEditUserWithPicture', // method name |
|
| 1976 | - array('editUserWithPicture' => 'tns:editUserWithPicture'), // input parameters |
|
| 1977 | - array('return' => 'xsd:string'), // output parameters |
|
| 1978 | - 'urn:WSRegistration', // namespace |
|
| 1979 | - 'urn:WSRegistration#WSEditUserWithPicture', // soapaction |
|
| 1980 | - 'rpc', // style |
|
| 1981 | - 'encoded', // use |
|
| 1975 | +$server->register('WSEditUserWithPicture', // method name |
|
| 1976 | + array('editUserWithPicture' => 'tns:editUserWithPicture'), // input parameters |
|
| 1977 | + array('return' => 'xsd:string'), // output parameters |
|
| 1978 | + 'urn:WSRegistration', // namespace |
|
| 1979 | + 'urn:WSRegistration#WSEditUserWithPicture', // soapaction |
|
| 1980 | + 'rpc', // style |
|
| 1981 | + 'encoded', // use |
|
| 1982 | 1982 | 'This service edits a user from wiener' // documentation |
| 1983 | 1983 | ); |
| 1984 | 1984 | |
@@ -2036,8 +2036,8 @@ discard block |
||
| 2036 | 2036 | $tempDir = api_get_path(SYS_ARCHIVE_PATH); |
| 2037 | 2037 | // Make sure the file download was OK by checking the HTTP headers for OK |
| 2038 | 2038 | if (strpos(get_headers($picture_url)[0], "OK")) { |
| 2039 | - file_put_contents($tempDir . $filename, file_get_contents($picture_url)); |
|
| 2040 | - $pictureUri = UserManager::update_user_picture($user_id, $filename, $tempDir . $filename); |
|
| 2039 | + file_put_contents($tempDir.$filename, file_get_contents($picture_url)); |
|
| 2040 | + $pictureUri = UserManager::update_user_picture($user_id, $filename, $tempDir.$filename); |
|
| 2041 | 2041 | } |
| 2042 | 2042 | |
| 2043 | 2043 | if ($user_id == 0) { |
@@ -2108,7 +2108,7 @@ discard block |
||
| 2108 | 2108 | ->setExpirationDate($expiration_date) |
| 2109 | 2109 | ->setHrDeptId($hr_dept_id) |
| 2110 | 2110 | ->setActive(true) |
| 2111 | - ->setPictureUri($pictureUri);; |
|
| 2111 | + ->setPictureUri($pictureUri); ; |
|
| 2112 | 2112 | |
| 2113 | 2113 | if (!is_null($creator_id)) { |
| 2114 | 2114 | $user->setCreatorId($creator_id); |
@@ -2205,13 +2205,13 @@ discard block |
||
| 2205 | 2205 | ); |
| 2206 | 2206 | |
| 2207 | 2207 | // Register the method to expose |
| 2208 | -$server->register('WSEditUsersPasswordCrypted', // method name |
|
| 2209 | - array('editUsersPasswordCrypted' => 'tns:editUsersPasswordCrypted'), // input parameters |
|
| 2210 | - array('return' => 'tns:results_editUsersPasswordCrypted'), // output parameters |
|
| 2211 | - 'urn:WSRegistration', // namespace |
|
| 2212 | - 'urn:WSRegistration#WSEditUsersPasswordCrypted', // soapaction |
|
| 2213 | - 'rpc', // style |
|
| 2214 | - 'encoded', // use |
|
| 2208 | +$server->register('WSEditUsersPasswordCrypted', // method name |
|
| 2209 | + array('editUsersPasswordCrypted' => 'tns:editUsersPasswordCrypted'), // input parameters |
|
| 2210 | + array('return' => 'tns:results_editUsersPasswordCrypted'), // output parameters |
|
| 2211 | + 'urn:WSRegistration', // namespace |
|
| 2212 | + 'urn:WSRegistration#WSEditUsersPasswordCrypted', // soapaction |
|
| 2213 | + 'rpc', // style |
|
| 2214 | + 'encoded', // use |
|
| 2215 | 2215 | 'This service edits a user' // documentation |
| 2216 | 2216 | ); |
| 2217 | 2217 | |
@@ -2219,7 +2219,7 @@ discard block |
||
| 2219 | 2219 | function WSEditUsersPasswordCrypted($params) { |
| 2220 | 2220 | global $_configuration; |
| 2221 | 2221 | |
| 2222 | - if(!WSHelperVerifyKey($params)) { |
|
| 2222 | + if (!WSHelperVerifyKey($params)) { |
|
| 2223 | 2223 | return returnError(WS_ERROR_SECRET_KEY); |
| 2224 | 2224 | } |
| 2225 | 2225 | |
@@ -2256,7 +2256,7 @@ discard block |
||
| 2256 | 2256 | |
| 2257 | 2257 | $password = $user_param['password']; |
| 2258 | 2258 | $encrypt_method = $user_param['encrypt_method']; |
| 2259 | - if ($_configuration['password_encryption'] === $encrypt_method ) { |
|
| 2259 | + if ($_configuration['password_encryption'] === $encrypt_method) { |
|
| 2260 | 2260 | if ($encrypt_method == 'md5' && !preg_match('/^[A-Fa-f0-9]{32}$/', $password)) { |
| 2261 | 2261 | $msg = "Encryption $encrypt_method is invalid"; |
| 2262 | 2262 | $results[] = $msg; |
@@ -2271,11 +2271,11 @@ discard block |
||
| 2271 | 2271 | $results[] = $msg; |
| 2272 | 2272 | continue; |
| 2273 | 2273 | } |
| 2274 | - } elseif (!empty($user_param['password']) && empty($user_param['encrypt_method'])){ |
|
| 2274 | + } elseif (!empty($user_param['password']) && empty($user_param['encrypt_method'])) { |
|
| 2275 | 2275 | $msg = "If password is not empty the encrypt_method param is required "; |
| 2276 | 2276 | $results[] = $msg; |
| 2277 | 2277 | continue; |
| 2278 | - } elseif (empty($user_param['password']) && !empty($user_param['encrypt_method'])){ |
|
| 2278 | + } elseif (empty($user_param['password']) && !empty($user_param['encrypt_method'])) { |
|
| 2279 | 2279 | $msg = "If encrypt_method is not empty the password param is required "; |
| 2280 | 2280 | $results[] = $msg; |
| 2281 | 2281 | continue; |
@@ -2411,13 +2411,13 @@ discard block |
||
| 2411 | 2411 | ); |
| 2412 | 2412 | |
| 2413 | 2413 | // Register the method to expose |
| 2414 | -$server->register('WSEditUserPasswordCrypted', // method name |
|
| 2414 | +$server->register('WSEditUserPasswordCrypted', // method name |
|
| 2415 | 2415 | array('editUserPasswordCrypted' => 'tns:editUserPasswordCrypted'), // input parameters |
| 2416 | - array('return' => 'xsd:string'), // output parameters |
|
| 2417 | - 'urn:WSRegistration', // namespace |
|
| 2418 | - 'urn:WSRegistration#WSEditUserPasswordCrypted', // soapaction |
|
| 2419 | - 'rpc', // style |
|
| 2420 | - 'encoded', // use |
|
| 2416 | + array('return' => 'xsd:string'), // output parameters |
|
| 2417 | + 'urn:WSRegistration', // namespace |
|
| 2418 | + 'urn:WSRegistration#WSEditUserPasswordCrypted', // soapaction |
|
| 2419 | + 'rpc', // style |
|
| 2420 | + 'encoded', // use |
|
| 2421 | 2421 | 'This service edits a user' // documentation |
| 2422 | 2422 | ); |
| 2423 | 2423 | |
@@ -2461,7 +2461,7 @@ discard block |
||
| 2461 | 2461 | if (!empty($params['password']) && !empty($params['encrypt_method'])) { |
| 2462 | 2462 | $password = $params['password']; |
| 2463 | 2463 | $encrypt_method = $params['encrypt_method']; |
| 2464 | - if ($_configuration['password_encryption'] === $encrypt_method ) { |
|
| 2464 | + if ($_configuration['password_encryption'] === $encrypt_method) { |
|
| 2465 | 2465 | if ($encrypt_method == 'md5' && !preg_match('/^[A-Fa-f0-9]{32}$/', $password)) { |
| 2466 | 2466 | $msg = "Encryption $encrypt_method is invalid"; |
| 2467 | 2467 | return $msg; |
@@ -2606,7 +2606,7 @@ discard block |
||
| 2606 | 2606 | '', |
| 2607 | 2607 | 'SOAP-ENC:Array', |
| 2608 | 2608 | array(), |
| 2609 | - array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType' => 'tns:user_id[]')),'tns:user_id' |
|
| 2609 | + array(array('ref'=>'SOAP-ENC:arrayType', 'wsdl:arrayType' => 'tns:user_id[]')), 'tns:user_id' |
|
| 2610 | 2610 | ); |
| 2611 | 2611 | |
| 2612 | 2612 | $server->wsdl->addComplexType( |
@@ -2622,35 +2622,35 @@ discard block |
||
| 2622 | 2622 | ); |
| 2623 | 2623 | |
| 2624 | 2624 | function WSHelperActionOnUsers($params, $type) { |
| 2625 | - if(!WSHelperVerifyKey($params)) { |
|
| 2625 | + if (!WSHelperVerifyKey($params)) { |
|
| 2626 | 2626 | return returnError(WS_ERROR_SECRET_KEY); |
| 2627 | 2627 | } |
| 2628 | 2628 | |
| 2629 | 2629 | $original_user_ids = $params['ids']; |
| 2630 | - foreach($original_user_ids as $original_user_id) { |
|
| 2630 | + foreach ($original_user_ids as $original_user_id) { |
|
| 2631 | 2631 | $user_id = UserManager::get_user_id_from_original_id( |
| 2632 | 2632 | $original_user_id['original_user_id_value'], |
| 2633 | 2633 | $original_user_id['original_user_id_name'] |
| 2634 | 2634 | ); |
| 2635 | - if($user_id > 0) { |
|
| 2636 | - if($type == "delete") { |
|
| 2635 | + if ($user_id > 0) { |
|
| 2636 | + if ($type == "delete") { |
|
| 2637 | 2637 | UserManager::delete_user($user_id); |
| 2638 | - } else if($type == "disable") { |
|
| 2638 | + } else if ($type == "disable") { |
|
| 2639 | 2639 | UserManager::disable($user_id); |
| 2640 | - } else if($type == "enable") { |
|
| 2640 | + } else if ($type == "enable") { |
|
| 2641 | 2641 | UserManager::enable($user_id); |
| 2642 | 2642 | } |
| 2643 | 2643 | } |
| 2644 | 2644 | } |
| 2645 | 2645 | } |
| 2646 | 2646 | |
| 2647 | -$server->register('WSDeleteUsers', // method name |
|
| 2648 | - array('user_ids' => 'tns:user_ids'), // input parameters |
|
| 2649 | - array(), // output parameters |
|
| 2650 | - 'urn:WSRegistration', // namespace |
|
| 2651 | - 'urn:WSRegistration#WSDeleteUsers', // soapaction |
|
| 2652 | - 'rpc', // style |
|
| 2653 | - 'encoded', // use |
|
| 2647 | +$server->register('WSDeleteUsers', // method name |
|
| 2648 | + array('user_ids' => 'tns:user_ids'), // input parameters |
|
| 2649 | + array(), // output parameters |
|
| 2650 | + 'urn:WSRegistration', // namespace |
|
| 2651 | + 'urn:WSRegistration#WSDeleteUsers', // soapaction |
|
| 2652 | + 'rpc', // style |
|
| 2653 | + 'encoded', // use |
|
| 2654 | 2654 | 'Deletes users provided as parameters from the system' // documentation |
| 2655 | 2655 | ); |
| 2656 | 2656 | |
@@ -2659,13 +2659,13 @@ discard block |
||
| 2659 | 2659 | } |
| 2660 | 2660 | |
| 2661 | 2661 | /** WSDisableUsers **/ |
| 2662 | -$server->register('WSDisableUsers', // method name |
|
| 2663 | - array('user_ids' => 'tns:user_ids'), // input parameters |
|
| 2664 | - array(), // output parameters |
|
| 2665 | - 'urn:WSRegistration', // namespace |
|
| 2666 | - 'urn:WSRegistration#WSDisableUsers', // soapaction |
|
| 2667 | - 'rpc', // style |
|
| 2668 | - 'encoded', // use |
|
| 2662 | +$server->register('WSDisableUsers', // method name |
|
| 2663 | + array('user_ids' => 'tns:user_ids'), // input parameters |
|
| 2664 | + array(), // output parameters |
|
| 2665 | + 'urn:WSRegistration', // namespace |
|
| 2666 | + 'urn:WSRegistration#WSDisableUsers', // soapaction |
|
| 2667 | + 'rpc', // style |
|
| 2668 | + 'encoded', // use |
|
| 2669 | 2669 | 'Disables users provided as parameters from the system' // documentation |
| 2670 | 2670 | ); |
| 2671 | 2671 | |
@@ -2674,13 +2674,13 @@ discard block |
||
| 2674 | 2674 | } |
| 2675 | 2675 | |
| 2676 | 2676 | /** WSEnableUsers **/ |
| 2677 | -$server->register('WSEnableUsers', // method name |
|
| 2678 | - array('user_ids' => 'tns:user_ids'), // input parameters |
|
| 2679 | - array(), // output parameters |
|
| 2680 | - 'urn:WSRegistration', // namespace |
|
| 2681 | - 'urn:WSRegistration#WSEnableUsers', // soapaction |
|
| 2682 | - 'rpc', // style |
|
| 2683 | - 'encoded', // use |
|
| 2677 | +$server->register('WSEnableUsers', // method name |
|
| 2678 | + array('user_ids' => 'tns:user_ids'), // input parameters |
|
| 2679 | + array(), // output parameters |
|
| 2680 | + 'urn:WSRegistration', // namespace |
|
| 2681 | + 'urn:WSRegistration#WSEnableUsers', // soapaction |
|
| 2682 | + 'rpc', // style |
|
| 2683 | + 'encoded', // use |
|
| 2684 | 2684 | 'Enables users provided as parameters' // documentation |
| 2685 | 2685 | ); |
| 2686 | 2686 | |
@@ -2730,7 +2730,7 @@ discard block |
||
| 2730 | 2730 | '', |
| 2731 | 2731 | 'SOAP-ENC:Array', |
| 2732 | 2732 | array(), |
| 2733 | - array(array('ref'=>'SOAP-ENC:arrayType','wsdl:arrayType' => 'tns:createCourseParams[]')),'tns:createCourseParams' |
|
| 2733 | + array(array('ref'=>'SOAP-ENC:arrayType', 'wsdl:arrayType' => 'tns:createCourseParams[]')), 'tns:createCourseParams' |
|
| 2734 | 2734 | ); |
| 2735 | 2735 | |
| 2736 | 2736 | // Register the data structures used by the service |
@@ -2771,13 +2771,13 @@ discard block |
||
| 2771 | 2771 | ); |
| 2772 | 2772 | |
| 2773 | 2773 | // Register the method to expose |
| 2774 | -$server->register('WSCreateCourse', // method name |
|
| 2775 | - array('createCourse' => 'tns:createCourse'), // input parameters |
|
| 2774 | +$server->register('WSCreateCourse', // method name |
|
| 2775 | + array('createCourse' => 'tns:createCourse'), // input parameters |
|
| 2776 | 2776 | array('return' => 'tns:results_createCourse'), // output parameters |
| 2777 | - 'urn:WSRegistration', // namespace |
|
| 2778 | - 'urn:WSRegistration#WSCreateCourse', // soapaction |
|
| 2779 | - 'rpc', // style |
|
| 2780 | - 'encoded', // use |
|
| 2777 | + 'urn:WSRegistration', // namespace |
|
| 2778 | + 'urn:WSRegistration#WSCreateCourse', // soapaction |
|
| 2779 | + 'rpc', // style |
|
| 2780 | + 'encoded', // use |
|
| 2781 | 2781 | 'This service adds a course' // documentation |
| 2782 | 2782 | ); |
| 2783 | 2783 | |
@@ -2833,7 +2833,7 @@ discard block |
||
| 2833 | 2833 | category_code='".Database::escape_string($category_code)."', |
| 2834 | 2834 | tutor_name='".Database::escape_string($tutor_name)."', |
| 2835 | 2835 | visual_code='".Database::escape_string($wanted_code)."'"; |
| 2836 | - if($visibility !== null) { |
|
| 2836 | + if ($visibility !== null) { |
|
| 2837 | 2837 | $sql .= ", visibility = '$visibility' "; |
| 2838 | 2838 | } |
| 2839 | 2839 | $sql .= " WHERE id='".$courseInfo['real_id']."'"; |
@@ -2883,7 +2883,7 @@ discard block |
||
| 2883 | 2883 | $params['title'] = $title; |
| 2884 | 2884 | $params['wanted_code'] = $wanted_code; |
| 2885 | 2885 | $params['category_code'] = $category_code; |
| 2886 | - $params['course_category'] = $category_code; |
|
| 2886 | + $params['course_category'] = $category_code; |
|
| 2887 | 2887 | $params['tutor_name'] = $tutor_name; |
| 2888 | 2888 | $params['course_language'] = $course_language; |
| 2889 | 2889 | $params['user_id'] = api_get_user_id(); |
@@ -3014,13 +3014,13 @@ discard block |
||
| 3014 | 3014 | |
| 3015 | 3015 | |
| 3016 | 3016 | // Register the method to expose |
| 3017 | -$server->register('WSCreateCourseByTitle', // method name |
|
| 3017 | +$server->register('WSCreateCourseByTitle', // method name |
|
| 3018 | 3018 | array('createCourseByTitle' => 'tns:createCourseByTitle'), // input parameters |
| 3019 | - array('return' => 'tns:results_createCourseByTitle'), // output parameters |
|
| 3020 | - 'urn:WSRegistration', // namespace |
|
| 3021 | - 'urn:WSRegistration#WSCreateCourseByTitle', // soapaction |
|
| 3022 | - 'rpc', // style |
|
| 3023 | - 'encoded', // use |
|
| 3019 | + array('return' => 'tns:results_createCourseByTitle'), // output parameters |
|
| 3020 | + 'urn:WSRegistration', // namespace |
|
| 3021 | + 'urn:WSRegistration#WSCreateCourseByTitle', // soapaction |
|
| 3022 | + 'rpc', // style |
|
| 3023 | + 'encoded', // use |
|
| 3024 | 3024 | 'This service adds a course by title' // documentation |
| 3025 | 3025 | ); |
| 3026 | 3026 | |
@@ -3251,18 +3251,18 @@ discard block |
||
| 3251 | 3251 | ); |
| 3252 | 3252 | |
| 3253 | 3253 | // Register the method to expose |
| 3254 | -$server->register('WSEditCourse', // method name |
|
| 3255 | - array('editCourse' => 'tns:editCourse'), // input parameters |
|
| 3254 | +$server->register('WSEditCourse', // method name |
|
| 3255 | + array('editCourse' => 'tns:editCourse'), // input parameters |
|
| 3256 | 3256 | array('return' => 'tns:results_editCourse'), // output parameters |
| 3257 | - 'urn:WSRegistration', // namespace |
|
| 3258 | - 'urn:WSRegistration#WSEditCourse', // soapaction |
|
| 3259 | - 'rpc', // style |
|
| 3260 | - 'encoded', // use |
|
| 3257 | + 'urn:WSRegistration', // namespace |
|
| 3258 | + 'urn:WSRegistration#WSEditCourse', // soapaction |
|
| 3259 | + 'rpc', // style |
|
| 3260 | + 'encoded', // use |
|
| 3261 | 3261 | 'This service edits a course' // documentation |
| 3262 | 3262 | ); |
| 3263 | 3263 | |
| 3264 | 3264 | // Define the method WSEditCourse |
| 3265 | -function WSEditCourse($params){ |
|
| 3265 | +function WSEditCourse($params) { |
|
| 3266 | 3266 | |
| 3267 | 3267 | global $_configuration; |
| 3268 | 3268 | if (!WSHelperVerifyKey($params)) { |
@@ -3417,13 +3417,13 @@ discard block |
||
| 3417 | 3417 | |
| 3418 | 3418 | |
| 3419 | 3419 | // Register the method to expose |
| 3420 | -$server->register('WSCourseDescription', // method name |
|
| 3421 | - array('courseDescription' => 'tns:courseDescription'), // input parameters |
|
| 3422 | - array('return' => 'tns:fields_course_desc_list'), // output parameters |
|
| 3423 | - 'urn:WSRegistration', // namespace |
|
| 3424 | - 'urn:WSRegistration#WSCourseDescription', // soapaction |
|
| 3425 | - 'rpc', // style |
|
| 3426 | - 'encoded', // use |
|
| 3420 | +$server->register('WSCourseDescription', // method name |
|
| 3421 | + array('courseDescription' => 'tns:courseDescription'), // input parameters |
|
| 3422 | + array('return' => 'tns:fields_course_desc_list'), // output parameters |
|
| 3423 | + 'urn:WSRegistration', // namespace |
|
| 3424 | + 'urn:WSRegistration#WSCourseDescription', // soapaction |
|
| 3425 | + 'rpc', // style |
|
| 3426 | + 'encoded', // use |
|
| 3427 | 3427 | 'This service edits a course description' // documentation |
| 3428 | 3428 | ); |
| 3429 | 3429 | |
@@ -3476,14 +3476,14 @@ discard block |
||
| 3476 | 3476 | } |
| 3477 | 3477 | |
| 3478 | 3478 | while ($row = Database::fetch_array($result)) { |
| 3479 | - $ind = (int)$row['id']; |
|
| 3479 | + $ind = (int) $row['id']; |
|
| 3480 | 3480 | $array_course_desc_title[$ind] = $row['title']; |
| 3481 | 3481 | $array_course_desc_content[$ind] = $row['content']; |
| 3482 | 3482 | } |
| 3483 | 3483 | |
| 3484 | 3484 | $count_results = count($default_titles); |
| 3485 | 3485 | $output = array(); |
| 3486 | - for($i = 1; $i <= $count_results; $i++) { |
|
| 3486 | + for ($i = 1; $i <= $count_results; $i++) { |
|
| 3487 | 3487 | $output[] = array( |
| 3488 | 3488 | 'course_desc_id' => $array_course_desc_id[$i], |
| 3489 | 3489 | 'course_desc_default_title' => $array_course_desc_default_title[$i], |
@@ -3563,13 +3563,13 @@ discard block |
||
| 3563 | 3563 | |
| 3564 | 3564 | |
| 3565 | 3565 | // Register the method to expose |
| 3566 | -$server->register('WSEditCourseDescription', // method name |
|
| 3566 | +$server->register('WSEditCourseDescription', // method name |
|
| 3567 | 3567 | array('editCourseDescription' => 'tns:editCourseDescription'), // input parameters |
| 3568 | - array('return' => 'tns:results_editCourseDescription'), // output parameters |
|
| 3569 | - 'urn:WSRegistration', // namespace |
|
| 3570 | - 'urn:WSRegistration#WSEditCourseDescription', // soapaction |
|
| 3571 | - 'rpc', // style |
|
| 3572 | - 'encoded', // use |
|
| 3568 | + array('return' => 'tns:results_editCourseDescription'), // output parameters |
|
| 3569 | + 'urn:WSRegistration', // namespace |
|
| 3570 | + 'urn:WSRegistration#WSEditCourseDescription', // soapaction |
|
| 3571 | + 'rpc', // style |
|
| 3572 | + 'encoded', // use |
|
| 3573 | 3573 | 'This service edits a course description' // documentation |
| 3574 | 3574 | ); |
| 3575 | 3575 | |
@@ -3613,7 +3613,7 @@ discard block |
||
| 3613 | 3613 | $course_desc_title = Database::escape_string($course_desc_title); |
| 3614 | 3614 | $course_desc_content = Database::escape_string($course_desc_content); |
| 3615 | 3615 | |
| 3616 | - $course_desc_id = (int)$course_desc_id; |
|
| 3616 | + $course_desc_id = (int) $course_desc_id; |
|
| 3617 | 3617 | if ($course_desc_id > 8 && $course_desc_id < 1) { |
| 3618 | 3618 | $results[] = 0; // course_desc_id invalid. |
| 3619 | 3619 | continue; |
@@ -3647,7 +3647,7 @@ discard block |
||
| 3647 | 3647 | |
| 3648 | 3648 | $count_results = count($results); |
| 3649 | 3649 | $output = array(); |
| 3650 | - for($i = 0; $i < $count_results; $i++) { |
|
| 3650 | + for ($i = 0; $i < $count_results; $i++) { |
|
| 3651 | 3651 | $output[] = array( |
| 3652 | 3652 | 'original_course_id_value' => $orig_course_id_value[$i], |
| 3653 | 3653 | 'result' => $results[$i], |
@@ -3719,13 +3719,13 @@ discard block |
||
| 3719 | 3719 | 'tns:result_deleteCourse' |
| 3720 | 3720 | ); |
| 3721 | 3721 | |
| 3722 | -$server->register('WSDeleteCourse', // method name |
|
| 3723 | - array('deleteCourse' => 'tns:deleteCourse'), // input parameters |
|
| 3722 | +$server->register('WSDeleteCourse', // method name |
|
| 3723 | + array('deleteCourse' => 'tns:deleteCourse'), // input parameters |
|
| 3724 | 3724 | array('return' => 'tns:results_deleteCourse'), // output parameters |
| 3725 | - 'urn:WSRegistration', // namespace |
|
| 3726 | - 'urn:WSRegistration#WSDeleteCourse', // soapaction |
|
| 3727 | - 'rpc', // style |
|
| 3728 | - 'encoded', // use |
|
| 3725 | + 'urn:WSRegistration', // namespace |
|
| 3726 | + 'urn:WSRegistration#WSDeleteCourse', // soapaction |
|
| 3727 | + 'rpc', // style |
|
| 3728 | + 'encoded', // use |
|
| 3729 | 3729 | 'This service deletes a course ' // documentation |
| 3730 | 3730 | ); |
| 3731 | 3731 | |
@@ -3851,13 +3851,13 @@ discard block |
||
| 3851 | 3851 | ); |
| 3852 | 3852 | |
| 3853 | 3853 | // Register the method to expose |
| 3854 | -$server->register('WSCreateSession', // method name |
|
| 3855 | - array('createSession' => 'tns:createSession'), // input parameters |
|
| 3854 | +$server->register('WSCreateSession', // method name |
|
| 3855 | + array('createSession' => 'tns:createSession'), // input parameters |
|
| 3856 | 3856 | array('return' => 'tns:results_createSession'), // output parameters |
| 3857 | - 'urn:WSRegistration', // namespace |
|
| 3858 | - 'urn:WSRegistration#WSCreateSession', // soapaction |
|
| 3859 | - 'rpc', // style |
|
| 3860 | - 'encoded', // use |
|
| 3857 | + 'urn:WSRegistration', // namespace |
|
| 3858 | + 'urn:WSRegistration#WSCreateSession', // soapaction |
|
| 3859 | + 'rpc', // style |
|
| 3860 | + 'encoded', // use |
|
| 3861 | 3861 | 'This service edits a session' // documentation |
| 3862 | 3862 | ); |
| 3863 | 3863 | |
@@ -3911,8 +3911,8 @@ discard block |
||
| 3911 | 3911 | } |
| 3912 | 3912 | |
| 3913 | 3913 | if (empty($nolimit)) { |
| 3914 | - $date_start = "$year_start-".(($month_start < 10)?"0$month_start":$month_start)."-".(($day_start < 10)?"0$day_start":$day_start) . ' 00:00:00'; |
|
| 3915 | - $date_end = "$year_end-".(($month_end < 10)?"0$month_end":$month_end)."-".(($day_end < 10)?"0$day_end":$day_end) . ' 23:59:59'; |
|
| 3914 | + $date_start = "$year_start-".(($month_start < 10) ? "0$month_start" : $month_start)."-".(($day_start < 10) ? "0$day_start" : $day_start).' 00:00:00'; |
|
| 3915 | + $date_end = "$year_end-".(($month_end < 10) ? "0$month_end" : $month_end)."-".(($day_end < 10) ? "0$day_end" : $day_end).' 23:59:59'; |
|
| 3916 | 3916 | } else { |
| 3917 | 3917 | $date_start = ""; |
| 3918 | 3918 | $date_end = ""; |
@@ -3930,7 +3930,7 @@ discard block |
||
| 3930 | 3930 | } |
| 3931 | 3931 | $results[] = 0; |
| 3932 | 3932 | continue; |
| 3933 | - } elseif (empty($nolimit) && (!$month_end || !$day_end || !$year_end || !checkdate($month_end, $day_end, $year_end))) { |
|
| 3933 | + } elseif (empty($nolimit) && (!$month_end || !$day_end || !$year_end || !checkdate($month_end, $day_end, $year_end))) { |
|
| 3934 | 3934 | $results[] = 0; |
| 3935 | 3935 | if ($debug) { |
| 3936 | 3936 | error_log("There's an error with the end date: $month_end - $day_end - $year_end"); |
@@ -4033,7 +4033,7 @@ discard block |
||
| 4033 | 4033 | |
| 4034 | 4034 | $count_results = count($results); |
| 4035 | 4035 | $output = array(); |
| 4036 | - for($i = 0; $i < $count_results; $i++) { |
|
| 4036 | + for ($i = 0; $i < $count_results; $i++) { |
|
| 4037 | 4037 | $output[] = array( |
| 4038 | 4038 | 'original_session_id_value' => $orig_session_id_value[$i], |
| 4039 | 4039 | 'result' => $results[$i], |
@@ -4118,13 +4118,13 @@ discard block |
||
| 4118 | 4118 | |
| 4119 | 4119 | |
| 4120 | 4120 | // Register the method to expose |
| 4121 | -$server->register('WSEditSession', // method name |
|
| 4122 | - array('editSession' => 'tns:editSession'), // input parameters |
|
| 4121 | +$server->register('WSEditSession', // method name |
|
| 4122 | + array('editSession' => 'tns:editSession'), // input parameters |
|
| 4123 | 4123 | array('return' => 'tns:results_editSession'), // output parameters |
| 4124 | - 'urn:WSRegistration', // namespace |
|
| 4125 | - 'urn:WSRegistration#WSEditSession', // soapaction |
|
| 4126 | - 'rpc', // style |
|
| 4127 | - 'encoded', // use |
|
| 4124 | + 'urn:WSRegistration', // namespace |
|
| 4125 | + 'urn:WSRegistration#WSEditSession', // soapaction |
|
| 4126 | + 'rpc', // style |
|
| 4127 | + 'encoded', // use |
|
| 4128 | 4128 | 'This service edits a session' // documentation |
| 4129 | 4129 | ); |
| 4130 | 4130 | |
@@ -4174,11 +4174,11 @@ discard block |
||
| 4174 | 4174 | } |
| 4175 | 4175 | |
| 4176 | 4176 | if (empty($nolimit)) { |
| 4177 | - $date_start="$year_start-".(($month_start < 10)?"0$month_start":$month_start)."-".(($day_start < 10)?"0$day_start":$day_start); |
|
| 4178 | - $date_end="$year_end-".(($month_end < 10)?"0$month_end":$month_end)."-".(($day_end < 10)?"0$day_end":$day_end); |
|
| 4177 | + $date_start = "$year_start-".(($month_start < 10) ? "0$month_start" : $month_start)."-".(($day_start < 10) ? "0$day_start" : $day_start); |
|
| 4178 | + $date_end = "$year_end-".(($month_end < 10) ? "0$month_end" : $month_end)."-".(($day_end < 10) ? "0$day_end" : $day_end); |
|
| 4179 | 4179 | } else { |
| 4180 | - $date_start=""; |
|
| 4181 | - $date_end=""; |
|
| 4180 | + $date_start = ""; |
|
| 4181 | + $date_end = ""; |
|
| 4182 | 4182 | } |
| 4183 | 4183 | if (empty($name)) { |
| 4184 | 4184 | $results[] = 0; //SessionNameIsRequired |
@@ -4322,13 +4322,13 @@ discard block |
||
| 4322 | 4322 | 'tns:result_deleteSession' |
| 4323 | 4323 | ); |
| 4324 | 4324 | |
| 4325 | -$server->register('WSDeleteSession', // method name |
|
| 4326 | - array('deleteSession' => 'tns:deleteSession'), // input parameters |
|
| 4325 | +$server->register('WSDeleteSession', // method name |
|
| 4326 | + array('deleteSession' => 'tns:deleteSession'), // input parameters |
|
| 4327 | 4327 | array('return' => 'tns:results_deleteSession'), // output parameters |
| 4328 | - 'urn:WSRegistration', // namespace |
|
| 4329 | - 'urn:WSRegistration#WSDeleteSession', // soapaction |
|
| 4330 | - 'rpc', // style |
|
| 4331 | - 'encoded', // use |
|
| 4328 | + 'urn:WSRegistration', // namespace |
|
| 4329 | + 'urn:WSRegistration#WSDeleteSession', // soapaction |
|
| 4330 | + 'rpc', // style |
|
| 4331 | + 'encoded', // use |
|
| 4332 | 4332 | 'This service deletes a session ' // documentation |
| 4333 | 4333 | ); |
| 4334 | 4334 | |
@@ -4410,10 +4410,10 @@ discard block |
||
| 4410 | 4410 | 'struct', |
| 4411 | 4411 | 'all', |
| 4412 | 4412 | '', |
| 4413 | - array ( |
|
| 4413 | + array( |
|
| 4414 | 4414 | 'course_id' => array('name' => 'course_id', 'type' => 'tns:course_id'), |
| 4415 | - 'user_id' => array('name' => 'user_id', 'type' => 'tns:user_id'), |
|
| 4416 | - 'status' => array('name' => 'status', 'type' => 'xsd:int') |
|
| 4415 | + 'user_id' => array('name' => 'user_id', 'type' => 'tns:user_id'), |
|
| 4416 | + 'status' => array('name' => 'status', 'type' => 'xsd:int') |
|
| 4417 | 4417 | ) |
| 4418 | 4418 | ); |
| 4419 | 4419 | |
@@ -4423,9 +4423,9 @@ discard block |
||
| 4423 | 4423 | 'struct', |
| 4424 | 4424 | 'all', |
| 4425 | 4425 | '', |
| 4426 | - array ( |
|
| 4427 | - 'userscourses' => array('name' => 'userscourses', 'type' => 'tns:user_course_status_array'), //removed [] |
|
| 4428 | - 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 4426 | + array( |
|
| 4427 | + 'userscourses' => array('name' => 'userscourses', 'type' => 'tns:user_course_status_array'), //removed [] |
|
| 4428 | + 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 4429 | 4429 | ) |
| 4430 | 4430 | ); |
| 4431 | 4431 | |
@@ -4450,9 +4450,9 @@ discard block |
||
| 4450 | 4450 | 'all', |
| 4451 | 4451 | '', |
| 4452 | 4452 | array( |
| 4453 | - 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 4454 | - 'original_course_id_value' => array('name' => 'original_course_id_value', 'type' => 'xsd:string'), |
|
| 4455 | - 'result' => array('name' => 'result', 'type' => 'xsd:int') |
|
| 4453 | + 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 4454 | + 'original_course_id_value' => array('name' => 'original_course_id_value', 'type' => 'xsd:string'), |
|
| 4455 | + 'result' => array('name' => 'result', 'type' => 'xsd:int') |
|
| 4456 | 4456 | ) |
| 4457 | 4457 | ); |
| 4458 | 4458 | |
@@ -4468,13 +4468,13 @@ discard block |
||
| 4468 | 4468 | ); |
| 4469 | 4469 | |
| 4470 | 4470 | // Register the method to expose |
| 4471 | -$server->register('WSSubscribeUserToCourse', // method name |
|
| 4472 | - array('subscribeUserToCourse' => 'tns:subscribeUserToCourse_arg'), // input parameters |
|
| 4471 | +$server->register('WSSubscribeUserToCourse', // method name |
|
| 4472 | + array('subscribeUserToCourse' => 'tns:subscribeUserToCourse_arg'), // input parameters |
|
| 4473 | 4473 | array('return' => 'tns:subscribeUserToCourse_return_global'), |
| 4474 | - 'urn:WSRegistration', // namespace |
|
| 4475 | - 'urn:WSRegistration#WSSubscribeUserToCourse', // soapaction |
|
| 4476 | - 'rpc', // style |
|
| 4477 | - 'encoded', // use |
|
| 4474 | + 'urn:WSRegistration', // namespace |
|
| 4475 | + 'urn:WSRegistration#WSSubscribeUserToCourse', // soapaction |
|
| 4476 | + 'rpc', // style |
|
| 4477 | + 'encoded', // use |
|
| 4478 | 4478 | 'This service subscribes a user to a course' // documentation |
| 4479 | 4479 | ); |
| 4480 | 4480 | |
@@ -4484,7 +4484,7 @@ discard block |
||
| 4484 | 4484 | if (!WSHelperVerifyKey($params)) { |
| 4485 | 4485 | return returnError(WS_ERROR_SECRET_KEY); |
| 4486 | 4486 | } |
| 4487 | - if ($debug) error_log('WSSubscribeUserToCourse params: '.print_r($params,1)); |
|
| 4487 | + if ($debug) error_log('WSSubscribeUserToCourse params: '.print_r($params, 1)); |
|
| 4488 | 4488 | |
| 4489 | 4489 | $results = array(); |
| 4490 | 4490 | $userscourses = $params['userscourses']; |
@@ -4552,8 +4552,8 @@ discard block |
||
| 4552 | 4552 | 'all', |
| 4553 | 4553 | '', |
| 4554 | 4554 | array( |
| 4555 | - 'course' => array('name' => 'course', 'type' => 'xsd:string'), //Course string code |
|
| 4556 | - 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), //Chamilo user_id |
|
| 4555 | + 'course' => array('name' => 'course', 'type' => 'xsd:string'), //Course string code |
|
| 4556 | + 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), //Chamilo user_id |
|
| 4557 | 4557 | 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
| 4558 | 4558 | ) |
| 4559 | 4559 | ); |
@@ -4566,18 +4566,18 @@ discard block |
||
| 4566 | 4566 | 'struct', |
| 4567 | 4567 | 'all', |
| 4568 | 4568 | '', |
| 4569 | - array('message' => array('name' => 'message', 'type' => 'xsd:string')) |
|
| 4569 | + array('message' => array('name' => 'message', 'type' => 'xsd:string')) |
|
| 4570 | 4570 | ); |
| 4571 | 4571 | |
| 4572 | 4572 | |
| 4573 | 4573 | // Register the method to expose |
| 4574 | -$server->register('WSSubscribeUserToCourseSimple', // method name |
|
| 4574 | +$server->register('WSSubscribeUserToCourseSimple', // method name |
|
| 4575 | 4575 | array('subscribeUserToCourseSimple' => 'tns:subscribeUserToCourseSimple_arg'), // input parameters |
| 4576 | - array('return' => 'xsd:string'), // output parameters |
|
| 4577 | - 'urn:WSRegistration', // namespace |
|
| 4578 | - 'urn:WSRegistration#WSSubscribeUserToCourseSimple', // soapaction |
|
| 4579 | - 'rpc', // style |
|
| 4580 | - 'encoded', // use |
|
| 4576 | + array('return' => 'xsd:string'), // output parameters |
|
| 4577 | + 'urn:WSRegistration', // namespace |
|
| 4578 | + 'urn:WSRegistration#WSSubscribeUserToCourseSimple', // soapaction |
|
| 4579 | + 'rpc', // style |
|
| 4580 | + 'encoded', // use |
|
| 4581 | 4581 | 'This service subscribes a user to a course in a simple way' // documentation |
| 4582 | 4582 | ); |
| 4583 | 4583 | |
@@ -4586,7 +4586,7 @@ discard block |
||
| 4586 | 4586 | global $debug; |
| 4587 | 4587 | |
| 4588 | 4588 | if ($debug) error_log('WSSubscribeUserToCourseSimple'); |
| 4589 | - if ($debug) error_log('Params '. print_r($params, 1)); |
|
| 4589 | + if ($debug) error_log('Params '.print_r($params, 1)); |
|
| 4590 | 4590 | if (!WSHelperVerifyKey($params)) { |
| 4591 | 4591 | return returnError(WS_ERROR_SECRET_KEY); |
| 4592 | 4592 | } |
@@ -4634,9 +4634,9 @@ discard block |
||
| 4634 | 4634 | 'all', |
| 4635 | 4635 | '', |
| 4636 | 4636 | array( |
| 4637 | - 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 4638 | - 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 4639 | - 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 4637 | + 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 4638 | + 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 4639 | + 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 4640 | 4640 | ) |
| 4641 | 4641 | ); |
| 4642 | 4642 | |
@@ -4647,21 +4647,21 @@ discard block |
||
| 4647 | 4647 | 'struct', |
| 4648 | 4648 | 'all', |
| 4649 | 4649 | '', |
| 4650 | - array ( |
|
| 4651 | - 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), |
|
| 4652 | - 'firstname' => array('name' => 'firstname', 'type' => 'xsd:string'), |
|
| 4653 | - 'lastname' => array('name' => 'lastname', 'type' => 'xsd:string'), |
|
| 4650 | + array( |
|
| 4651 | + 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), |
|
| 4652 | + 'firstname' => array('name' => 'firstname', 'type' => 'xsd:string'), |
|
| 4653 | + 'lastname' => array('name' => 'lastname', 'type' => 'xsd:string'), |
|
| 4654 | 4654 | ) |
| 4655 | 4655 | ); |
| 4656 | 4656 | |
| 4657 | 4657 | // Register the method to expose |
| 4658 | -$server->register('WSGetUser', // method name |
|
| 4659 | - array('GetUser' => 'tns:GetUserArg'), // input parameters |
|
| 4660 | - array('return' => 'tns:User'), // output parameters |
|
| 4661 | - 'urn:WSRegistration', // namespace |
|
| 4662 | - 'urn:WSRegistration#WSGetUser', // soapaction |
|
| 4663 | - 'rpc', // style |
|
| 4664 | - 'encoded', // use |
|
| 4658 | +$server->register('WSGetUser', // method name |
|
| 4659 | + array('GetUser' => 'tns:GetUserArg'), // input parameters |
|
| 4660 | + array('return' => 'tns:User'), // output parameters |
|
| 4661 | + 'urn:WSRegistration', // namespace |
|
| 4662 | + 'urn:WSRegistration#WSGetUser', // soapaction |
|
| 4663 | + 'rpc', // style |
|
| 4664 | + 'encoded', // use |
|
| 4665 | 4665 | 'This service get user information by id' // documentation |
| 4666 | 4666 | ); |
| 4667 | 4667 | |
@@ -4705,17 +4705,17 @@ discard block |
||
| 4705 | 4705 | '', |
| 4706 | 4706 | array( |
| 4707 | 4707 | 'username' => array('name' => 'username', 'type' => 'xsd:string'), |
| 4708 | - 'secret_key' => array('name' => 'secret_key','type' => 'xsd:string') |
|
| 4708 | + 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 4709 | 4709 | ) |
| 4710 | 4710 | ); |
| 4711 | 4711 | // Register the method to expose |
| 4712 | -$server->register('WSGetUserFromUsername', // method name |
|
| 4713 | - array('GetUserFromUsername' => 'tns:GetUserArgUsername'), // input params |
|
| 4714 | - array('return' => 'tns:User'), // output parameters |
|
| 4715 | - 'urn:WSRegistration', // namespace |
|
| 4716 | - 'urn:WSRegistration#WSGetUserFromUsername', // soapaction |
|
| 4717 | - 'rpc', // style |
|
| 4718 | - 'encoded', // use |
|
| 4712 | +$server->register('WSGetUserFromUsername', // method name |
|
| 4713 | + array('GetUserFromUsername' => 'tns:GetUserArgUsername'), // input params |
|
| 4714 | + array('return' => 'tns:User'), // output parameters |
|
| 4715 | + 'urn:WSRegistration', // namespace |
|
| 4716 | + 'urn:WSRegistration#WSGetUserFromUsername', // soapaction |
|
| 4717 | + 'rpc', // style |
|
| 4718 | + 'encoded', // use |
|
| 4719 | 4719 | 'This service get user information by username' // documentation |
| 4720 | 4720 | ); |
| 4721 | 4721 | |
@@ -4756,10 +4756,10 @@ discard block |
||
| 4756 | 4756 | 'all', |
| 4757 | 4757 | '', |
| 4758 | 4758 | array( |
| 4759 | - 'original_user_id_values' => array('name' => 'original_user_id_values', 'type' => 'tns:originalUsersList'), |
|
| 4760 | - 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 4761 | - 'original_course_id_value' => array('name' => 'original_course_id_value', 'type' => 'xsd:string'), |
|
| 4762 | - 'original_course_id_name' => array('name' => 'original_course_id_name', 'type' => 'xsd:string'), |
|
| 4759 | + 'original_user_id_values' => array('name' => 'original_user_id_values', 'type' => 'tns:originalUsersList'), |
|
| 4760 | + 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 4761 | + 'original_course_id_value' => array('name' => 'original_course_id_value', 'type' => 'xsd:string'), |
|
| 4762 | + 'original_course_id_name' => array('name' => 'original_course_id_name', 'type' => 'xsd:string'), |
|
| 4763 | 4763 | ) |
| 4764 | 4764 | ); |
| 4765 | 4765 | |
@@ -4812,13 +4812,13 @@ discard block |
||
| 4812 | 4812 | ); |
| 4813 | 4813 | |
| 4814 | 4814 | // Register the method to expose |
| 4815 | -$server->register('WSUnsubscribeUserFromCourse', // method name |
|
| 4815 | +$server->register('WSUnsubscribeUserFromCourse', // method name |
|
| 4816 | 4816 | array('unsuscribeUserFromCourse' => 'tns:unsuscribeUserFromCourse'), // input parameters |
| 4817 | - array('return' => 'tns:results_unsuscribeUserFromCourse'), // output parameters |
|
| 4818 | - 'urn:WSRegistration', // namespace |
|
| 4819 | - 'urn:WSRegistration#WSUnsubscribeUserFromCourse', // soapaction |
|
| 4820 | - 'rpc', // style |
|
| 4821 | - 'encoded', // use |
|
| 4817 | + array('return' => 'tns:results_unsuscribeUserFromCourse'), // output parameters |
|
| 4818 | + 'urn:WSRegistration', // namespace |
|
| 4819 | + 'urn:WSRegistration#WSUnsubscribeUserFromCourse', // soapaction |
|
| 4820 | + 'rpc', // style |
|
| 4821 | + 'encoded', // use |
|
| 4822 | 4822 | 'This service unsubscribes a user from a course' // documentation |
| 4823 | 4823 | ); |
| 4824 | 4824 | |
@@ -4830,7 +4830,7 @@ discard block |
||
| 4830 | 4830 | } |
| 4831 | 4831 | |
| 4832 | 4832 | $user_table = Database::get_main_table(TABLE_MAIN_USER); |
| 4833 | - $table_course = Database :: get_main_table(TABLE_MAIN_COURSE); |
|
| 4833 | + $table_course = Database :: get_main_table(TABLE_MAIN_COURSE); |
|
| 4834 | 4834 | $table_course_user = Database :: get_main_table(TABLE_MAIN_COURSE_USER); |
| 4835 | 4835 | |
| 4836 | 4836 | $userscourses_params = $params['userscourses']; |
@@ -4840,8 +4840,8 @@ discard block |
||
| 4840 | 4840 | foreach ($userscourses_params as $usercourse_param) { |
| 4841 | 4841 | |
| 4842 | 4842 | $original_user_id_values = $usercourse_param['original_user_id_values']; |
| 4843 | - $original_user_id_name = $usercourse_param['original_user_id_name']; |
|
| 4844 | - $original_course_id_value = $usercourse_param['original_course_id_value']; |
|
| 4843 | + $original_user_id_name = $usercourse_param['original_user_id_name']; |
|
| 4844 | + $original_course_id_value = $usercourse_param['original_course_id_value']; |
|
| 4845 | 4845 | $original_course_id_name = $usercourse_param['original_course_id_name']; |
| 4846 | 4846 | $orig_course_id_value[] = $original_course_id_value; |
| 4847 | 4847 | |
@@ -4862,7 +4862,7 @@ discard block |
||
| 4862 | 4862 | $usersList[] = $user_id; |
| 4863 | 4863 | } |
| 4864 | 4864 | |
| 4865 | - $orig_user_id_value[] = implode(',',$usersList); |
|
| 4865 | + $orig_user_id_value[] = implode(',', $usersList); |
|
| 4866 | 4866 | |
| 4867 | 4867 | $courseInfo = CourseManager::getCourseInfoFromOriginalId( |
| 4868 | 4868 | $original_course_id_value, |
@@ -4895,7 +4895,7 @@ discard block |
||
| 4895 | 4895 | |
| 4896 | 4896 | $count_results = count($results); |
| 4897 | 4897 | $output = array(); |
| 4898 | - for($i = 0; $i < $count_results; $i++) { |
|
| 4898 | + for ($i = 0; $i < $count_results; $i++) { |
|
| 4899 | 4899 | $output[] = array( |
| 4900 | 4900 | 'original_user_id_values' => $orig_user_id_value[$i], |
| 4901 | 4901 | 'original_course_id_value' => $orig_course_id_value[$i], |
@@ -4924,13 +4924,13 @@ discard block |
||
| 4924 | 4924 | |
| 4925 | 4925 | |
| 4926 | 4926 | // Register the method to expose |
| 4927 | -$server->register('WSUnSubscribeUserFromCourseSimple', // method name |
|
| 4927 | +$server->register('WSUnSubscribeUserFromCourseSimple', // method name |
|
| 4928 | 4928 | array('unSubscribeUserFromCourseSimple' => 'tns:unSubscribeUserFromCourseSimple'), // input parameters |
| 4929 | - array('return' => 'tns:result_createUsersPassEncrypt'), // output parameters |
|
| 4930 | - 'urn:WSRegistration', // namespace |
|
| 4931 | - 'urn:WSRegistration#WSUnSubscribeUserFromCourseSimple', // soapaction |
|
| 4932 | - 'rpc', // style |
|
| 4933 | - 'encoded', // use |
|
| 4929 | + array('return' => 'tns:result_createUsersPassEncrypt'), // output parameters |
|
| 4930 | + 'urn:WSRegistration', // namespace |
|
| 4931 | + 'urn:WSRegistration#WSUnSubscribeUserFromCourseSimple', // soapaction |
|
| 4932 | + 'rpc', // style |
|
| 4933 | + 'encoded', // use |
|
| 4934 | 4934 | 'This service unsubscribe a user from a course' // documentation |
| 4935 | 4935 | ); |
| 4936 | 4936 | /** |
@@ -5000,10 +5000,10 @@ discard block |
||
| 5000 | 5000 | 'all', |
| 5001 | 5001 | '', |
| 5002 | 5002 | array( |
| 5003 | - 'original_user_id_values' => array('name' => 'original_user_id_values', 'type' => 'tns:originalUsersList'), |
|
| 5004 | - 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 5005 | - 'original_course_id_value' => array('name' => 'original_course_id_value', 'type' => 'xsd:string'), |
|
| 5006 | - 'original_course_id_name' => array('name' => 'original_course_id_value', 'type' => 'xsd:string') |
|
| 5003 | + 'original_user_id_values' => array('name' => 'original_user_id_values', 'type' => 'tns:originalUsersList'), |
|
| 5004 | + 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 5005 | + 'original_course_id_value' => array('name' => 'original_course_id_value', 'type' => 'xsd:string'), |
|
| 5006 | + 'original_course_id_name' => array('name' => 'original_course_id_value', 'type' => 'xsd:string') |
|
| 5007 | 5007 | ) |
| 5008 | 5008 | ); |
| 5009 | 5009 | |
@@ -5097,13 +5097,13 @@ discard block |
||
| 5097 | 5097 | |
| 5098 | 5098 | |
| 5099 | 5099 | // Register the method to expose |
| 5100 | -$server->register('WSSuscribeUsersToSession', // method name |
|
| 5100 | +$server->register('WSSuscribeUsersToSession', // method name |
|
| 5101 | 5101 | array('subscribeUsersToSession' => 'tns:subscribeUsersToSession'), // input parameters |
| 5102 | - array('return' => 'tns:results_subscribeUsersToSession'), // output parameters |
|
| 5103 | - 'urn:WSRegistration', // namespace |
|
| 5104 | - 'urn:WSRegistration#WSSuscribeUsersToSession', // soapaction |
|
| 5105 | - 'rpc', // style |
|
| 5106 | - 'encoded', // use |
|
| 5102 | + array('return' => 'tns:results_subscribeUsersToSession'), // output parameters |
|
| 5103 | + 'urn:WSRegistration', // namespace |
|
| 5104 | + 'urn:WSRegistration#WSSuscribeUsersToSession', // soapaction |
|
| 5105 | + 'rpc', // style |
|
| 5106 | + 'encoded', // use |
|
| 5107 | 5107 | 'This service subscribes a user to a session' // documentation |
| 5108 | 5108 | ); |
| 5109 | 5109 | |
@@ -5180,7 +5180,7 @@ discard block |
||
| 5180 | 5180 | |
| 5181 | 5181 | $count_results = count($results); |
| 5182 | 5182 | $output = array(); |
| 5183 | - for($i = 0; $i < $count_results; $i++) { |
|
| 5183 | + for ($i = 0; $i < $count_results; $i++) { |
|
| 5184 | 5184 | $output[] = array( |
| 5185 | 5185 | 'original_user_id_values' => $orig_user_id_value[$i], |
| 5186 | 5186 | 'original_session_id_value' => $orig_session_id_value[$i], |
@@ -5200,25 +5200,25 @@ discard block |
||
| 5200 | 5200 | 'all', |
| 5201 | 5201 | '', |
| 5202 | 5202 | array( |
| 5203 | - 'session' => array('name' => 'session', 'type' => 'xsd:string'), // Session ID |
|
| 5204 | - 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), // Chamilo user_id |
|
| 5203 | + 'session' => array('name' => 'session', 'type' => 'xsd:string'), // Session ID |
|
| 5204 | + 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), // Chamilo user_id |
|
| 5205 | 5205 | 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
| 5206 | 5206 | ) |
| 5207 | 5207 | ); |
| 5208 | -$server->register('WSSubscribeUserToSessionSimple', // method name |
|
| 5209 | - array('subscribeUserToSessionSimple' => 'tns:subscribeUserToSessionSimple_arg'), // input parameters |
|
| 5210 | - array('return' => 'xsd:string'), // output parameters |
|
| 5211 | - 'urn:WSRegistration', // namespace |
|
| 5212 | - 'urn:WSRegistration#WSSubscribeUserToSessionSimple', // soapaction |
|
| 5213 | - 'rpc', // style |
|
| 5214 | - 'encoded', // use |
|
| 5208 | +$server->register('WSSubscribeUserToSessionSimple', // method name |
|
| 5209 | + array('subscribeUserToSessionSimple' => 'tns:subscribeUserToSessionSimple_arg'), // input parameters |
|
| 5210 | + array('return' => 'xsd:string'), // output parameters |
|
| 5211 | + 'urn:WSRegistration', // namespace |
|
| 5212 | + 'urn:WSRegistration#WSSubscribeUserToSessionSimple', // soapaction |
|
| 5213 | + 'rpc', // style |
|
| 5214 | + 'encoded', // use |
|
| 5215 | 5215 | 'This service subscribes a user to a session in a simple way' // documentation |
| 5216 | 5216 | ); |
| 5217 | 5217 | function WSSubscribeUserToSessionSimple($params) { |
| 5218 | 5218 | global $debug; |
| 5219 | 5219 | |
| 5220 | 5220 | if ($debug) { |
| 5221 | - error_log('WSSubscribeUserToSessionSimple with params=[' . serialize($params). ']'); |
|
| 5221 | + error_log('WSSubscribeUserToSessionSimple with params=['.serialize($params).']'); |
|
| 5222 | 5222 | } |
| 5223 | 5223 | |
| 5224 | 5224 | // Check security key |
@@ -5227,8 +5227,8 @@ discard block |
||
| 5227 | 5227 | } |
| 5228 | 5228 | |
| 5229 | 5229 | // Get input parameters |
| 5230 | - $session_id = intval($params['session']); // Session ID |
|
| 5231 | - $user_id = intval($params['user_id']); // Chamilo user id |
|
| 5230 | + $session_id = intval($params['session']); // Session ID |
|
| 5231 | + $user_id = intval($params['user_id']); // Chamilo user id |
|
| 5232 | 5232 | |
| 5233 | 5233 | // Get user id |
| 5234 | 5234 | $user_data = api_get_user_info($user_id); |
@@ -5329,13 +5329,13 @@ discard block |
||
| 5329 | 5329 | ); |
| 5330 | 5330 | |
| 5331 | 5331 | // Register the method to expose |
| 5332 | -$server->register('WSUnsuscribeUsersFromSession', // method name |
|
| 5332 | +$server->register('WSUnsuscribeUsersFromSession', // method name |
|
| 5333 | 5333 | array('unsubscribeUsersFromSession' => 'tns:unsubscribeUsersFromSession'), // input parameters |
| 5334 | - array('return' => 'tns:results_unsubscribeUsersFromSession'), // output parameters |
|
| 5335 | - 'urn:WSRegistration', // namespace |
|
| 5336 | - 'urn:WSRegistration#WSUnsuscribeUsersFromSession', // soapaction |
|
| 5337 | - 'rpc', // style |
|
| 5338 | - 'encoded', // use |
|
| 5334 | + array('return' => 'tns:results_unsubscribeUsersFromSession'), // output parameters |
|
| 5335 | + 'urn:WSRegistration', // namespace |
|
| 5336 | + 'urn:WSRegistration#WSUnsuscribeUsersFromSession', // soapaction |
|
| 5337 | + 'rpc', // style |
|
| 5338 | + 'encoded', // use |
|
| 5339 | 5339 | 'This service unsubscribes a user to a session' // documentation |
| 5340 | 5340 | ); |
| 5341 | 5341 | |
@@ -5349,7 +5349,7 @@ discard block |
||
| 5349 | 5349 | global $debug; |
| 5350 | 5350 | |
| 5351 | 5351 | if ($debug) { |
| 5352 | - error_log('WSUnsuscribeUsersFromSession with params=[' . serialize($params). ']'); |
|
| 5352 | + error_log('WSUnsuscribeUsersFromSession with params=['.serialize($params).']'); |
|
| 5353 | 5353 | } |
| 5354 | 5354 | |
| 5355 | 5355 | $user_table = Database::get_main_table(TABLE_MAIN_USER); |
@@ -5441,7 +5441,7 @@ discard block |
||
| 5441 | 5441 | 'all', |
| 5442 | 5442 | '', |
| 5443 | 5443 | array( |
| 5444 | - 'course_code' => array('name' => 'course_code', 'type' => 'xsd:string'), |
|
| 5444 | + 'course_code' => array('name' => 'course_code', 'type' => 'xsd:string'), |
|
| 5445 | 5445 | ) |
| 5446 | 5446 | ); |
| 5447 | 5447 | |
@@ -5477,9 +5477,9 @@ discard block |
||
| 5477 | 5477 | '', |
| 5478 | 5478 | array( |
| 5479 | 5479 | 'original_course_id_values' => array('name' => 'original_course_id_values', 'type' => 'tns:originalCoursesList'), |
| 5480 | - 'original_course_id_name' => array('name' => 'original_course_id_name', 'type' => 'xsd:string'), |
|
| 5480 | + 'original_course_id_name' => array('name' => 'original_course_id_name', 'type' => 'xsd:string'), |
|
| 5481 | 5481 | 'original_session_id_value' => array('name' => 'original_session_id_value', 'type' => 'xsd:string'), |
| 5482 | - 'original_session_id_name' => array('name' => 'original_session_id_name', 'type' => 'xsd:string') |
|
| 5482 | + 'original_session_id_name' => array('name' => 'original_session_id_name', 'type' => 'xsd:string') |
|
| 5483 | 5483 | ) |
| 5484 | 5484 | ); |
| 5485 | 5485 | |
@@ -5532,13 +5532,13 @@ discard block |
||
| 5532 | 5532 | ); |
| 5533 | 5533 | |
| 5534 | 5534 | // Register the method to expose |
| 5535 | -$server->register('WSSuscribeCoursesToSession', // method name |
|
| 5535 | +$server->register('WSSuscribeCoursesToSession', // method name |
|
| 5536 | 5536 | array('subscribeCoursesToSession' => 'tns:subscribeCoursesToSession'), // input parameters |
| 5537 | - array('return' => 'tns:results_subscribeCoursesToSession'), // output parameters |
|
| 5538 | - 'urn:WSRegistration', // namespace |
|
| 5539 | - 'urn:WSRegistration#WSSuscribeCoursesToSession', // soapaction |
|
| 5540 | - 'rpc', // style |
|
| 5541 | - 'encoded', // use |
|
| 5537 | + array('return' => 'tns:results_subscribeCoursesToSession'), // output parameters |
|
| 5538 | + 'urn:WSRegistration', // namespace |
|
| 5539 | + 'urn:WSRegistration#WSSuscribeCoursesToSession', // soapaction |
|
| 5540 | + 'rpc', // style |
|
| 5541 | + 'encoded', // use |
|
| 5542 | 5542 | 'This service subscribes a course to a session' // documentation |
| 5543 | 5543 | ); |
| 5544 | 5544 | |
@@ -5676,13 +5676,13 @@ discard block |
||
| 5676 | 5676 | |
| 5677 | 5677 | |
| 5678 | 5678 | // Register the method to expose |
| 5679 | -$server->register('WSUnsuscribeCoursesFromSession', // method name |
|
| 5679 | +$server->register('WSUnsuscribeCoursesFromSession', // method name |
|
| 5680 | 5680 | array('unsubscribeCoursesFromSession' => 'tns:unsubscribeCoursesFromSession'), // input parameters |
| 5681 | - array('return' => 'tns:results_unsubscribeCoursesFromSession'), // output parameters |
|
| 5682 | - 'urn:WSRegistration', // namespace |
|
| 5683 | - 'urn:WSRegistration#WSUnsuscribeCoursesFromSession', // soapaction |
|
| 5684 | - 'rpc', // style |
|
| 5685 | - 'encoded', // use |
|
| 5681 | + array('return' => 'tns:results_unsubscribeCoursesFromSession'), // output parameters |
|
| 5682 | + 'urn:WSRegistration', // namespace |
|
| 5683 | + 'urn:WSRegistration#WSUnsuscribeCoursesFromSession', // soapaction |
|
| 5684 | + 'rpc', // style |
|
| 5685 | + 'encoded', // use |
|
| 5686 | 5686 | 'This service subscribes a course to a session' // documentation |
| 5687 | 5687 | ); |
| 5688 | 5688 | |
@@ -5789,7 +5789,7 @@ discard block |
||
| 5789 | 5789 | |
| 5790 | 5790 | $count_results = count($results); |
| 5791 | 5791 | $output = array(); |
| 5792 | - for($i = 0; $i < $count_results; $i++) { |
|
| 5792 | + for ($i = 0; $i < $count_results; $i++) { |
|
| 5793 | 5793 | $output[] = array( |
| 5794 | 5794 | 'original_course_id_values' => $orig_course_id_value[$i], |
| 5795 | 5795 | 'original_session_id_value' => $orig_session_id_value[$i], |
@@ -5847,13 +5847,13 @@ discard block |
||
| 5847 | 5847 | |
| 5848 | 5848 | |
| 5849 | 5849 | // Register the method to expose |
| 5850 | -$server->register('WSListCourses', // method name |
|
| 5850 | +$server->register('WSListCourses', // method name |
|
| 5851 | 5851 | array('listCourseInput' => 'tns:listCourseInput'), // input parameters |
| 5852 | - array('return' => 'tns:courses'), // output parameters |
|
| 5853 | - 'urn:WSRegistration', // namespace |
|
| 5854 | - 'urn:WSRegistration#WSListCourses', // soapaction |
|
| 5855 | - 'rpc', // style |
|
| 5856 | - 'encoded', // use |
|
| 5852 | + array('return' => 'tns:courses'), // output parameters |
|
| 5853 | + 'urn:WSRegistration', // namespace |
|
| 5854 | + 'urn:WSRegistration#WSListCourses', // soapaction |
|
| 5855 | + 'rpc', // style |
|
| 5856 | + 'encoded', // use |
|
| 5857 | 5857 | 'This service list courses available on the system' // documentation |
| 5858 | 5858 | ); |
| 5859 | 5859 | |
@@ -5872,7 +5872,7 @@ discard block |
||
| 5872 | 5872 | $from = isset($params['from']) ? $params['from'] : null; |
| 5873 | 5873 | $to = isset($params['to']) ? $params['to'] : null; |
| 5874 | 5874 | |
| 5875 | - error_log(print_r($params,1)); |
|
| 5875 | + error_log(print_r($params, 1)); |
|
| 5876 | 5876 | error_log($from); |
| 5877 | 5877 | error_log($to); |
| 5878 | 5878 | |
@@ -5930,27 +5930,27 @@ discard block |
||
| 5930 | 5930 | 'all', |
| 5931 | 5931 | '', |
| 5932 | 5932 | array( |
| 5933 | - 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 5934 | - 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 5935 | - 'chamilo_username' => array('name' => 'chamilo_username', 'type' => 'xsd:string'), |
|
| 5936 | - 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 5933 | + 'original_user_id_name' => array('name' => 'original_user_id_name', 'type' => 'xsd:string'), |
|
| 5934 | + 'original_user_id_value' => array('name' => 'original_user_id_value', 'type' => 'xsd:string'), |
|
| 5935 | + 'chamilo_username' => array('name' => 'chamilo_username', 'type' => 'xsd:string'), |
|
| 5936 | + 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 5937 | 5937 | ) |
| 5938 | 5938 | ); |
| 5939 | 5939 | |
| 5940 | 5940 | // Register the method to expose |
| 5941 | -$server->register('WSUpdateUserApiKey', // method name |
|
| 5941 | +$server->register('WSUpdateUserApiKey', // method name |
|
| 5942 | 5942 | array('userApiKey' => 'tns:userApiKey'), // input parameters |
| 5943 | - array('return' => 'xsd:string'), // output parameters |
|
| 5944 | - 'urn:WSRegistration', // namespace |
|
| 5945 | - 'urn:WSRegistration#WSListCourses', // soapaction |
|
| 5946 | - 'rpc', // style |
|
| 5947 | - 'encoded', // use |
|
| 5943 | + array('return' => 'xsd:string'), // output parameters |
|
| 5944 | + 'urn:WSRegistration', // namespace |
|
| 5945 | + 'urn:WSRegistration#WSListCourses', // soapaction |
|
| 5946 | + 'rpc', // style |
|
| 5947 | + 'encoded', // use |
|
| 5948 | 5948 | 'This service return user api key' // documentation |
| 5949 | 5949 | ); |
| 5950 | 5950 | |
| 5951 | 5951 | |
| 5952 | 5952 | function WSUpdateUserApiKey($params) { |
| 5953 | - if(!WSHelperVerifyKey($params)) { |
|
| 5953 | + if (!WSHelperVerifyKey($params)) { |
|
| 5954 | 5954 | return returnError(WS_ERROR_SECRET_KEY); |
| 5955 | 5955 | } |
| 5956 | 5956 | |
@@ -5992,11 +5992,11 @@ discard block |
||
| 5992 | 5992 | 'all', |
| 5993 | 5993 | '', |
| 5994 | 5994 | array( |
| 5995 | - 'from' => array('name' => 'from', 'type' => 'xsd:int'), |
|
| 5996 | - 'to' => array('name' => 'to', 'type' => 'xsd:int'), |
|
| 5997 | - 'date_start' => array('name' => 'date_start', 'type' => 'xsd:string'), |
|
| 5998 | - 'date_end' => array('name' => 'date_end', 'type' => 'xsd:string'), |
|
| 5999 | - 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 5995 | + 'from' => array('name' => 'from', 'type' => 'xsd:int'), |
|
| 5996 | + 'to' => array('name' => 'to', 'type' => 'xsd:int'), |
|
| 5997 | + 'date_start' => array('name' => 'date_start', 'type' => 'xsd:string'), |
|
| 5998 | + 'date_end' => array('name' => 'date_end', 'type' => 'xsd:string'), |
|
| 5999 | + 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
|
| 6000 | 6000 | ) |
| 6001 | 6001 | ); |
| 6002 | 6002 | |
@@ -6007,11 +6007,11 @@ discard block |
||
| 6007 | 6007 | 'all', |
| 6008 | 6008 | '', |
| 6009 | 6009 | array( |
| 6010 | - 'id' => array ('name' => 'id' , 'type' => 'xsd:int'), |
|
| 6011 | - 'title' => array ('name' => 'title', 'type' => 'xsd:string'), |
|
| 6012 | - 'url' => array ('name' => 'url', 'type' => 'xsd:string'), |
|
| 6013 | - 'date_start' => array ('name' => 'date_start', 'type' => 'xsd:string'), |
|
| 6014 | - 'date_end' => array ('name' => 'date_end', 'type' => 'xsd:string'), |
|
| 6010 | + 'id' => array('name' => 'id', 'type' => 'xsd:int'), |
|
| 6011 | + 'title' => array('name' => 'title', 'type' => 'xsd:string'), |
|
| 6012 | + 'url' => array('name' => 'url', 'type' => 'xsd:string'), |
|
| 6013 | + 'date_start' => array('name' => 'date_start', 'type' => 'xsd:string'), |
|
| 6014 | + 'date_end' => array('name' => 'date_end', 'type' => 'xsd:string'), |
|
| 6015 | 6015 | ) |
| 6016 | 6016 | ); |
| 6017 | 6017 | |
@@ -6030,13 +6030,13 @@ discard block |
||
| 6030 | 6030 | ); |
| 6031 | 6031 | |
| 6032 | 6032 | // Register the method to expose |
| 6033 | -$server->register('WSListSessions', // method name |
|
| 6034 | - array('input' => 'tns:session_arg'), // input parameters |
|
| 6035 | - array('return' => 'tns:sessions'), // output parameters |
|
| 6036 | - 'urn:WSRegistration', // namespace |
|
| 6037 | - 'urn:WSRegistration#WSListSessions', // soapaction |
|
| 6038 | - 'rpc', // style |
|
| 6039 | - 'encoded', // use |
|
| 6033 | +$server->register('WSListSessions', // method name |
|
| 6034 | + array('input' => 'tns:session_arg'), // input parameters |
|
| 6035 | + array('return' => 'tns:sessions'), // output parameters |
|
| 6036 | + 'urn:WSRegistration', // namespace |
|
| 6037 | + 'urn:WSRegistration#WSListSessions', // soapaction |
|
| 6038 | + 'rpc', // style |
|
| 6039 | + 'encoded', // use |
|
| 6040 | 6040 | 'This service returns a list of sessions' // documentation |
| 6041 | 6041 | ); |
| 6042 | 6042 | |
@@ -6094,20 +6094,20 @@ discard block |
||
| 6094 | 6094 | 'all', |
| 6095 | 6095 | '', |
| 6096 | 6096 | array( |
| 6097 | - 'course' => array('name' => 'course', 'type' => 'xsd:string'), //Course string code |
|
| 6098 | - 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), //Chamilo user_id |
|
| 6097 | + 'course' => array('name' => 'course', 'type' => 'xsd:string'), //Course string code |
|
| 6098 | + 'user_id' => array('name' => 'user_id', 'type' => 'xsd:string'), //Chamilo user_id |
|
| 6099 | 6099 | 'secret_key' => array('name' => 'secret_key', 'type' => 'xsd:string') |
| 6100 | 6100 | ) |
| 6101 | 6101 | ); |
| 6102 | 6102 | |
| 6103 | 6103 | // Register the method to expose |
| 6104 | -$server->register('WSUserSubscribedInCourse', // method name |
|
| 6105 | - array('UserSubscribedInCourse' => 'tns:UserSubscribedInCourse'), // input parameters |
|
| 6106 | - array('return' => 'xsd:string'), // output parameters |
|
| 6107 | - 'urn:WSRegistration', // namespace |
|
| 6108 | - 'urn:WSRegistration#WSUserSubscribedInCourse', // soapaction |
|
| 6109 | - 'rpc', // style |
|
| 6110 | - 'encoded', // use |
|
| 6104 | +$server->register('WSUserSubscribedInCourse', // method name |
|
| 6105 | + array('UserSubscribedInCourse' => 'tns:UserSubscribedInCourse'), // input parameters |
|
| 6106 | + array('return' => 'xsd:string'), // output parameters |
|
| 6107 | + 'urn:WSRegistration', // namespace |
|
| 6108 | + 'urn:WSRegistration#WSUserSubscribedInCourse', // soapaction |
|
| 6109 | + 'rpc', // style |
|
| 6110 | + 'encoded', // use |
|
| 6111 | 6111 | 'This service checks if user assigned to course' // documentation |
| 6112 | 6112 | ); |
| 6113 | 6113 | |
@@ -6121,7 +6121,7 @@ discard block |
||
| 6121 | 6121 | global $debug; |
| 6122 | 6122 | |
| 6123 | 6123 | if ($debug) error_log('WSUserSubscribedInCourse'); |
| 6124 | - if ($debug) error_log('Params '. print_r($params, 1)); |
|
| 6124 | + if ($debug) error_log('Params '.print_r($params, 1)); |
|
| 6125 | 6125 | if (!WSHelperVerifyKey($params)) { |
| 6126 | 6126 | |
| 6127 | 6127 | return returnError(WS_ERROR_SECRET_KEY); |
@@ -6129,7 +6129,7 @@ discard block |
||
| 6129 | 6129 | $courseCode = $params['course']; //Course code |
| 6130 | 6130 | $userId = $params['user_id']; //chamilo user id |
| 6131 | 6131 | |
| 6132 | - return (CourseManager::is_user_subscribed_in_course($userId,$courseCode)); |
|
| 6132 | + return (CourseManager::is_user_subscribed_in_course($userId, $courseCode)); |
|
| 6133 | 6133 | } |
| 6134 | 6134 | |
| 6135 | 6135 | |
@@ -6157,8 +6157,8 @@ discard block |
||
| 6157 | 6157 | 'all', |
| 6158 | 6158 | '', |
| 6159 | 6159 | array( |
| 6160 | - 'variable' => array('name'=>'variable','type'=>'xsd:string'), |
|
| 6161 | - 'value' => array('name'=>'value','type'=>'xsd:string') |
|
| 6160 | + 'variable' => array('name'=>'variable', 'type'=>'xsd:string'), |
|
| 6161 | + 'value' => array('name'=>'value', 'type'=>'xsd:string') |
|
| 6162 | 6162 | ) |
| 6163 | 6163 | ); |
| 6164 | 6164 | |
@@ -6220,12 +6220,12 @@ discard block |
||
| 6220 | 6220 | //Reister WSSearchSession |
| 6221 | 6221 | $server->register( |
| 6222 | 6222 | 'WSSearchSession', |
| 6223 | - array('SearchSession' => 'tns:SearchSession'), // input parameters |
|
| 6224 | - array('return' => 'tns:searchedSessionList'), // output parameters |
|
| 6225 | - 'urn:WSRegistration', // namespace |
|
| 6226 | - 'urn:WSRegistration#WSSearchSession', // soapaction |
|
| 6227 | - 'rpc', // style |
|
| 6228 | - 'encoded', // use |
|
| 6223 | + array('SearchSession' => 'tns:SearchSession'), // input parameters |
|
| 6224 | + array('return' => 'tns:searchedSessionList'), // output parameters |
|
| 6225 | + 'urn:WSRegistration', // namespace |
|
| 6226 | + 'urn:WSRegistration#WSSearchSession', // soapaction |
|
| 6227 | + 'rpc', // style |
|
| 6228 | + 'encoded', // use |
|
| 6229 | 6229 | 'This service to get a session list filtered by name, description or short description extra field' // documentation |
| 6230 | 6230 | ); |
| 6231 | 6231 | |
@@ -6280,12 +6280,12 @@ discard block |
||
| 6280 | 6280 | //Reister WSFetchSession |
| 6281 | 6281 | $server->register( |
| 6282 | 6282 | 'WSFetchSession', |
| 6283 | - array('SearchSession' => 'tns:FetchSession'), // input parameters |
|
| 6284 | - array('return' => 'tns:searchedSessionList'), // output parameters |
|
| 6285 | - 'urn:WSRegistration', // namespace |
|
| 6286 | - 'urn:WSRegistration#WSFetchSession', // soapaction |
|
| 6287 | - 'rpc', // style |
|
| 6288 | - 'encoded', // use |
|
| 6283 | + array('SearchSession' => 'tns:FetchSession'), // input parameters |
|
| 6284 | + array('return' => 'tns:searchedSessionList'), // output parameters |
|
| 6285 | + 'urn:WSRegistration', // namespace |
|
| 6286 | + 'urn:WSRegistration#WSFetchSession', // soapaction |
|
| 6287 | + 'rpc', // style |
|
| 6288 | + 'encoded', // use |
|
| 6289 | 6289 | 'This service get a session by its id. Optionally can get its extra fields values' // documentation |
| 6290 | 6290 | ); |
| 6291 | 6291 | |
@@ -6362,16 +6362,16 @@ discard block |
||
| 6362 | 6362 | ); |
| 6363 | 6363 | // Register the method to expose |
| 6364 | 6364 | $server->register( |
| 6365 | - 'WSCertificatesList', // method name |
|
| 6365 | + 'WSCertificatesList', // method name |
|
| 6366 | 6366 | array( |
| 6367 | - 'startingDate' => 'xsd:string', // input parameters |
|
| 6367 | + 'startingDate' => 'xsd:string', // input parameters |
|
| 6368 | 6368 | 'endingDate' => 'xsd:string' |
| 6369 | 6369 | ), |
| 6370 | - array('return' => 'tns:certificatesList'), // output parameters |
|
| 6371 | - 'urn:WSRegistration', // namespace |
|
| 6372 | - 'urn:WSRegistration#WSCertificatesList', // soapaction |
|
| 6373 | - 'rpc', // style |
|
| 6374 | - 'encoded', // use |
|
| 6370 | + array('return' => 'tns:certificatesList'), // output parameters |
|
| 6371 | + 'urn:WSRegistration', // namespace |
|
| 6372 | + 'urn:WSRegistration#WSCertificatesList', // soapaction |
|
| 6373 | + 'rpc', // style |
|
| 6374 | + 'encoded', // use |
|
| 6375 | 6375 | 'This service returns a list of certificates' // documentation |
| 6376 | 6376 | ); |
| 6377 | 6377 | |
@@ -6437,13 +6437,13 @@ discard block |
||
| 6437 | 6437 | ); |
| 6438 | 6438 | |
| 6439 | 6439 | // Register the method to expose |
| 6440 | -$server->register('WSCreateGroup', // method name |
|
| 6441 | - array('createGroup' => 'tns:createGroup'), // input parameters |
|
| 6442 | - array('return' => 'xsd:string'), // output parameters |
|
| 6443 | - 'urn:WSRegistration', // namespace |
|
| 6444 | - 'urn:WSRegistration#WSCreateGroup', // soapaction |
|
| 6445 | - 'rpc', // style |
|
| 6446 | - 'encoded', // use |
|
| 6440 | +$server->register('WSCreateGroup', // method name |
|
| 6441 | + array('createGroup' => 'tns:createGroup'), // input parameters |
|
| 6442 | + array('return' => 'xsd:string'), // output parameters |
|
| 6443 | + 'urn:WSRegistration', // namespace |
|
| 6444 | + 'urn:WSRegistration#WSCreateGroup', // soapaction |
|
| 6445 | + 'rpc', // style |
|
| 6446 | + 'encoded', // use |
|
| 6447 | 6447 | 'This service adds a group' // documentation |
| 6448 | 6448 | ); |
| 6449 | 6449 | |
@@ -6486,13 +6486,13 @@ discard block |
||
| 6486 | 6486 | ); |
| 6487 | 6487 | |
| 6488 | 6488 | // Register the method to expose |
| 6489 | -$server->register('WSUpdateGroup', // method name |
|
| 6490 | - array('updateGroup' => 'tns:updateGroup'), // input parameters |
|
| 6491 | - array('return' => 'xsd:string'), // output parameters |
|
| 6492 | - 'urn:WSRegistration', // namespace |
|
| 6493 | - 'urn:WSRegistration#WSUpdateGroup', // soapaction |
|
| 6494 | - 'rpc', // style |
|
| 6495 | - 'encoded', // use |
|
| 6489 | +$server->register('WSUpdateGroup', // method name |
|
| 6490 | + array('updateGroup' => 'tns:updateGroup'), // input parameters |
|
| 6491 | + array('return' => 'xsd:string'), // output parameters |
|
| 6492 | + 'urn:WSRegistration', // namespace |
|
| 6493 | + 'urn:WSRegistration#WSUpdateGroup', // soapaction |
|
| 6494 | + 'rpc', // style |
|
| 6495 | + 'encoded', // use |
|
| 6496 | 6496 | 'This service updates a group' // documentation |
| 6497 | 6497 | ); |
| 6498 | 6498 | |
@@ -6537,13 +6537,13 @@ discard block |
||
| 6537 | 6537 | ); |
| 6538 | 6538 | |
| 6539 | 6539 | // Register the method to expose |
| 6540 | -$server->register('WSDeleteGroup', // method name |
|
| 6541 | - array('deleteGroup' => 'tns:deleteGroup'), // input parameters |
|
| 6542 | - array('return' => 'xsd:string'), // output parameters |
|
| 6543 | - 'urn:WSRegistration', // namespace |
|
| 6544 | - 'urn:WSRegistration#WSDeleteGroup', // soapaction |
|
| 6545 | - 'rpc', // style |
|
| 6546 | - 'encoded', // use |
|
| 6540 | +$server->register('WSDeleteGroup', // method name |
|
| 6541 | + array('deleteGroup' => 'tns:deleteGroup'), // input parameters |
|
| 6542 | + array('return' => 'xsd:string'), // output parameters |
|
| 6543 | + 'urn:WSRegistration', // namespace |
|
| 6544 | + 'urn:WSRegistration#WSDeleteGroup', // soapaction |
|
| 6545 | + 'rpc', // style |
|
| 6546 | + 'encoded', // use |
|
| 6547 | 6547 | 'This service deletes a group' // documentation |
| 6548 | 6548 | ); |
| 6549 | 6549 | |
@@ -6580,13 +6580,13 @@ discard block |
||
| 6580 | 6580 | ); |
| 6581 | 6581 | |
| 6582 | 6582 | // Register the method to expose |
| 6583 | -$server->register('GroupBindToParent', // method name |
|
| 6584 | - array('groupBindToParent' => 'tns:groupBindToParent'), // input parameters |
|
| 6585 | - array('return' => 'xsd:string'), // output parameters |
|
| 6586 | - 'urn:WSRegistration', // namespace |
|
| 6587 | - 'urn:WSRegistration#GroupBindToParent', // soapaction |
|
| 6588 | - 'rpc', // style |
|
| 6589 | - 'encoded', // use |
|
| 6583 | +$server->register('GroupBindToParent', // method name |
|
| 6584 | + array('groupBindToParent' => 'tns:groupBindToParent'), // input parameters |
|
| 6585 | + array('return' => 'xsd:string'), // output parameters |
|
| 6586 | + 'urn:WSRegistration', // namespace |
|
| 6587 | + 'urn:WSRegistration#GroupBindToParent', // soapaction |
|
| 6588 | + 'rpc', // style |
|
| 6589 | + 'encoded', // use |
|
| 6590 | 6590 | 'This service binds a group to a parent' // documentation |
| 6591 | 6591 | ); |
| 6592 | 6592 | |
@@ -6622,13 +6622,13 @@ discard block |
||
| 6622 | 6622 | ); |
| 6623 | 6623 | |
| 6624 | 6624 | // Register the method to expose |
| 6625 | -$server->register('GroupUnbindFromParent', // method name |
|
| 6626 | - array('groupUnbindFromParent' => 'tns:groupUnbindFromParent'), // input parameters |
|
| 6627 | - array('return' => 'xsd:string'), // output parameters |
|
| 6628 | - 'urn:WSRegistration', // namespace |
|
| 6629 | - 'urn:WSRegistration#GroupUnbindFromParent', // soapaction |
|
| 6630 | - 'rpc', // style |
|
| 6631 | - 'encoded', // use |
|
| 6625 | +$server->register('GroupUnbindFromParent', // method name |
|
| 6626 | + array('groupUnbindFromParent' => 'tns:groupUnbindFromParent'), // input parameters |
|
| 6627 | + array('return' => 'xsd:string'), // output parameters |
|
| 6628 | + 'urn:WSRegistration', // namespace |
|
| 6629 | + 'urn:WSRegistration#GroupUnbindFromParent', // soapaction |
|
| 6630 | + 'rpc', // style |
|
| 6631 | + 'encoded', // use |
|
| 6632 | 6632 | 'This service unbinds a group from its parent' // documentation |
| 6633 | 6633 | ); |
| 6634 | 6634 | |
@@ -6662,13 +6662,13 @@ discard block |
||
| 6662 | 6662 | ); |
| 6663 | 6663 | |
| 6664 | 6664 | // Register the method to expose |
| 6665 | -$server->register('WSAddUserToGroup', // method name |
|
| 6666 | - array('addUserToGroup' => 'tns:addUserToGroup'), // input parameters |
|
| 6667 | - array('return' => 'xsd:string'), // output parameters |
|
| 6668 | - 'urn:WSRegistration', // namespace |
|
| 6669 | - 'urn:WSRegistration#WSAddUserToGroup', // soapaction |
|
| 6670 | - 'rpc', // style |
|
| 6671 | - 'encoded', // use |
|
| 6665 | +$server->register('WSAddUserToGroup', // method name |
|
| 6666 | + array('addUserToGroup' => 'tns:addUserToGroup'), // input parameters |
|
| 6667 | + array('return' => 'xsd:string'), // output parameters |
|
| 6668 | + 'urn:WSRegistration', // namespace |
|
| 6669 | + 'urn:WSRegistration#WSAddUserToGroup', // soapaction |
|
| 6670 | + 'rpc', // style |
|
| 6671 | + 'encoded', // use |
|
| 6672 | 6672 | 'This service adds a user to a group' // documentation |
| 6673 | 6673 | ); |
| 6674 | 6674 | |
@@ -6705,13 +6705,13 @@ discard block |
||
| 6705 | 6705 | ); |
| 6706 | 6706 | |
| 6707 | 6707 | // Register the method to expose |
| 6708 | -$server->register('WSUpdateUserRoleInGroup', // method name |
|
| 6709 | - array('updateUserRoleInGroup' => 'tns:updateUserRoleInGroup'), // input parameters |
|
| 6710 | - array('return' => 'xsd:string'), // output parameters |
|
| 6711 | - 'urn:WSRegistration', // namespace |
|
| 6712 | - 'urn:WSRegistration#WSUpdateUserRoleInGroup', // soapaction |
|
| 6713 | - 'rpc', // style |
|
| 6714 | - 'encoded', // use |
|
| 6708 | +$server->register('WSUpdateUserRoleInGroup', // method name |
|
| 6709 | + array('updateUserRoleInGroup' => 'tns:updateUserRoleInGroup'), // input parameters |
|
| 6710 | + array('return' => 'xsd:string'), // output parameters |
|
| 6711 | + 'urn:WSRegistration', // namespace |
|
| 6712 | + 'urn:WSRegistration#WSUpdateUserRoleInGroup', // soapaction |
|
| 6713 | + 'rpc', // style |
|
| 6714 | + 'encoded', // use |
|
| 6715 | 6715 | 'This service updates a user role in group' // documentation |
| 6716 | 6716 | ); |
| 6717 | 6717 | |
@@ -6750,13 +6750,13 @@ discard block |
||
| 6750 | 6750 | ); |
| 6751 | 6751 | |
| 6752 | 6752 | // Register the method to expose |
| 6753 | -$server->register('WSDeleteUserFromGroup', // method name |
|
| 6754 | - array('deleteUserFromGroup' => 'tns:deleteUserFromGroup'), // input parameters |
|
| 6755 | - array('return' => 'xsd:string'), // output parameters |
|
| 6756 | - 'urn:WSRegistration', // namespace |
|
| 6757 | - 'urn:WSRegistration#WSDeleteUserFromGroup', // soapaction |
|
| 6758 | - 'rpc', // style |
|
| 6759 | - 'encoded', // use |
|
| 6753 | +$server->register('WSDeleteUserFromGroup', // method name |
|
| 6754 | + array('deleteUserFromGroup' => 'tns:deleteUserFromGroup'), // input parameters |
|
| 6755 | + array('return' => 'xsd:string'), // output parameters |
|
| 6756 | + 'urn:WSRegistration', // namespace |
|
| 6757 | + 'urn:WSRegistration#WSDeleteUserFromGroup', // soapaction |
|
| 6758 | + 'rpc', // style |
|
| 6759 | + 'encoded', // use |
|
| 6760 | 6760 | 'This service deletes a user from a group' // documentation |
| 6761 | 6761 | ); |
| 6762 | 6762 | |