@@ -178,10 +178,10 @@ discard block |
||
178 | 178 | |
179 | 179 | function bigbluebutton_bbb_view_create_meeting_data(&$bbbsession, $bigbluebuttonbn) { |
180 | 180 | $data = ['meetingID' => $bbbsession['meetingid'], |
181 | - 'name' => $bbbsession['meetingname'], |
|
182 | - 'attendeePW' => $bbbsession['viewerPW'], |
|
183 | - 'moderatorPW' => $bbbsession['modPW'], |
|
184 | - 'logoutURL' => $bbbsession['logoutURL'], |
|
181 | + 'name' => $bbbsession['meetingname'], |
|
182 | + 'attendeePW' => $bbbsession['viewerPW'], |
|
183 | + 'moderatorPW' => $bbbsession['modPW'], |
|
184 | + 'logoutURL' => $bbbsession['logoutURL'], |
|
185 | 185 | ]; |
186 | 186 | |
187 | 187 | $data['record'] = 'false'; |
@@ -221,14 +221,14 @@ discard block |
||
221 | 221 | global $USER; |
222 | 222 | |
223 | 223 | $metadata = ['bbb-origin' => $bbbsession['origin'], |
224 | - 'bbb-origin-version' => $bbbsession['originVersion'], |
|
225 | - 'bbb-origin-server-name' => $bbbsession['originServerName'], |
|
226 | - 'bbb-origin-server-common-name' => $bbbsession['originServerCommonName'], |
|
227 | - 'bbb-origin-tag' => $bbbsession['originTag'], |
|
228 | - 'bbb-context' => $bbbsession['course']->fullname, |
|
229 | - 'bbb-recording-name' => $bbbsession['meetingname'], |
|
230 | - 'bbb-recording-description' => bigbluebuttonbn_html2text($bbbsession['meetingdescription'], 64), |
|
231 | - 'bbb-recording-tags' => bigbluebuttonbn_get_tags($bbbsession['cm']->id), // Same as $id. |
|
224 | + 'bbb-origin-version' => $bbbsession['originVersion'], |
|
225 | + 'bbb-origin-server-name' => $bbbsession['originServerName'], |
|
226 | + 'bbb-origin-server-common-name' => $bbbsession['originServerCommonName'], |
|
227 | + 'bbb-origin-tag' => $bbbsession['originTag'], |
|
228 | + 'bbb-context' => $bbbsession['course']->fullname, |
|
229 | + 'bbb-recording-name' => $bbbsession['meetingname'], |
|
230 | + 'bbb-recording-description' => bigbluebuttonbn_html2text($bbbsession['meetingdescription'], 64), |
|
231 | + 'bbb-recording-tags' => bigbluebuttonbn_get_tags($bbbsession['cm']->id), // Same as $id. |
|
232 | 232 | ]; |
233 | 233 | |
234 | 234 | if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recordingstatus_enabled')) { |
@@ -236,8 +236,8 @@ discard block |
||
236 | 236 | array( |
237 | 237 | 'email' => array('"' . fullname($USER) . '" <' . $USER->email . '>'), |
238 | 238 | 'context' => $bbbsession['bigbluebuttonbnURL'] |
239 | - ) |
|
240 | - ); |
|
239 | + ) |
|
240 | + ); |
|
241 | 241 | } |
242 | 242 | if ((boolean)\mod_bigbluebuttonbn\locallib\config::get('recordingready_enabled')) { |
243 | 243 | $metadata['bn-recording-ready-url'] = $bbbsession['recordingReadyURL']; |
@@ -85,9 +85,9 @@ discard block |
||
85 | 85 | // BigBlueButton API Calls. |
86 | 86 | function bigbluebuttonbn_get_join_url($meetingid, $username, $pw, $logouturl, $configtoken = null, $userid = null) { |
87 | 87 | $data = ['meetingID' => $meetingid, |
88 | - 'fullName' => $username, |
|
89 | - 'password' => $pw, |
|
90 | - 'logoutURL' => $logouturl, |
|
88 | + 'fullName' => $username, |
|
89 | + 'password' => $pw, |
|
90 | + 'logoutURL' => $logouturl, |
|
91 | 91 | ]; |
92 | 92 | |
93 | 93 | if (!is_null($configtoken)) { |
@@ -188,24 +188,24 @@ discard block |
||
188 | 188 | function bigbluebuttonbn_get_meeting_info_array($meetingid) { |
189 | 189 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
190 | 190 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid]) |
191 | - ); |
|
191 | + ); |
|
192 | 192 | |
193 | 193 | if ($xml && $xml->returncode == 'SUCCESS' && empty($xml->messageKey)) { |
194 | 194 | // Meeting info was returned. |
195 | 195 | return array('returncode' => $xml->returncode, |
196 | - 'meetingID' => $xml->meetingID, |
|
197 | - 'moderatorPW' => $xml->moderatorPW, |
|
198 | - 'attendeePW' => $xml->attendeePW, |
|
199 | - 'hasBeenForciblyEnded' => $xml->hasBeenForciblyEnded, |
|
200 | - 'running' => $xml->running, |
|
201 | - 'recording' => $xml->recording, |
|
202 | - 'startTime' => $xml->startTime, |
|
203 | - 'endTime' => $xml->endTime, |
|
204 | - 'participantCount' => $xml->participantCount, |
|
205 | - 'moderatorCount' => $xml->moderatorCount, |
|
206 | - 'attendees' => $xml->attendees, |
|
207 | - 'metadata' => $xml->metadata, |
|
208 | - ); |
|
196 | + 'meetingID' => $xml->meetingID, |
|
197 | + 'moderatorPW' => $xml->moderatorPW, |
|
198 | + 'attendeePW' => $xml->attendeePW, |
|
199 | + 'hasBeenForciblyEnded' => $xml->hasBeenForciblyEnded, |
|
200 | + 'running' => $xml->running, |
|
201 | + 'recording' => $xml->recording, |
|
202 | + 'startTime' => $xml->startTime, |
|
203 | + 'endTime' => $xml->endTime, |
|
204 | + 'participantCount' => $xml->participantCount, |
|
205 | + 'moderatorCount' => $xml->moderatorCount, |
|
206 | + 'attendees' => $xml->attendees, |
|
207 | + 'metadata' => $xml->metadata, |
|
208 | + ); |
|
209 | 209 | } |
210 | 210 | |
211 | 211 | if ($xml) { |
@@ -269,7 +269,7 @@ discard block |
||
269 | 269 | // Do getRecordings is executed using a method GET (supported by all versions of BBB). |
270 | 270 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
271 | 271 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getRecordings', ['meetingID' => implode(',', $mids)]) |
272 | - ); |
|
272 | + ); |
|
273 | 273 | if ($xml && $xml->returncode == 'SUCCESS' && isset($xml->recordings)) { |
274 | 274 | // If there were meetings already created. |
275 | 275 | foreach ($xml->recordings->recording as $recording) { |
@@ -332,7 +332,7 @@ discard block |
||
332 | 332 | function bigbluebuttonbn_get_default_config_xml() { |
333 | 333 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
334 | 334 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getDefaultConfigXML') |
335 | - ); |
|
335 | + ); |
|
336 | 336 | |
337 | 337 | return $xml; |
338 | 338 | } |
@@ -406,7 +406,7 @@ discard block |
||
406 | 406 | foreach ($ids as $id) { |
407 | 407 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
408 | 408 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('deleteRecordings', ['recordID' => $id]) |
409 | - ); |
|
409 | + ); |
|
410 | 410 | if ($xml && $xml->returncode != 'SUCCESS') { |
411 | 411 | return false; |
412 | 412 | } |
@@ -424,7 +424,7 @@ discard block |
||
424 | 424 | foreach ($ids as $id) { |
425 | 425 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
426 | 426 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('publishRecordings', ['recordID' => $id, 'publish' => $publish]) |
427 | - ); |
|
427 | + ); |
|
428 | 428 | if ($xml && $xml->returncode != 'SUCCESS') { |
429 | 429 | return false; |
430 | 430 | } |
@@ -442,7 +442,7 @@ discard block |
||
442 | 442 | foreach ($ids as $id) { |
443 | 443 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
444 | 444 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array) $params) |
445 | - ); |
|
445 | + ); |
|
446 | 446 | if ($xml && $xml->returncode != 'SUCCESS') { |
447 | 447 | return false; |
448 | 448 | } |
@@ -501,7 +501,7 @@ discard block |
||
501 | 501 | function bigbluebuttonbn_end_meeting($meetingid, $modpw) { |
502 | 502 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
503 | 503 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('end', ['meetingID' => $meetingid, 'password' => $modpw]) |
504 | - ); |
|
504 | + ); |
|
505 | 505 | |
506 | 506 | if ($xml) { |
507 | 507 | // If the xml packet returned failure it displays the message to the user. |
@@ -518,7 +518,7 @@ discard block |
||
518 | 518 | function bigbluebuttonbn_is_meeting_running($meetingid) { |
519 | 519 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
520 | 520 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('isMeetingRunning', ['meetingID' => $meetingid]) |
521 | - ); |
|
521 | + ); |
|
522 | 522 | |
523 | 523 | if ($xml && $xml->returncode == 'SUCCESS') { |
524 | 524 | return ($xml->running == 'true'); |
@@ -530,7 +530,7 @@ discard block |
||
530 | 530 | function bigbluebuttonbn_get_server_version() { |
531 | 531 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
532 | 532 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url() |
533 | - ); |
|
533 | + ); |
|
534 | 534 | |
535 | 535 | if ($xml && $xml->returncode == 'SUCCESS') { |
536 | 536 | return $xml->version; |
@@ -591,10 +591,10 @@ discard block |
||
591 | 591 | |
592 | 592 | $options = array(); |
593 | 593 | $options['CURLOPT_HTTPHEADER'] = array( |
594 | - 'Content-Type: '.$contenttype, |
|
595 | - 'Content-Length: '.strlen($data), |
|
596 | - 'Content-Language: en-US', |
|
597 | - ); |
|
594 | + 'Content-Type: '.$contenttype, |
|
595 | + 'Content-Length: '.strlen($data), |
|
596 | + 'Content-Language: en-US', |
|
597 | + ); |
|
598 | 598 | |
599 | 599 | return $c->post($url, $data, $options); |
600 | 600 | } |
@@ -676,16 +676,16 @@ discard block |
||
676 | 676 | 'all' => array( |
677 | 677 | 'name' => get_string('mod_form_field_participant_list_type_all', 'bigbluebuttonbn'), |
678 | 678 | 'children' => [] |
679 | - ) |
|
680 | - ); |
|
679 | + ) |
|
680 | + ); |
|
681 | 681 | $data['role'] = array( |
682 | 682 | 'name' => get_string('mod_form_field_participant_list_type_role', 'bigbluebuttonbn'), |
683 | 683 | 'children' => bigbluebuttonbn_get_roles_select($context) |
684 | - ); |
|
684 | + ); |
|
685 | 685 | $data['user'] = array( |
686 | 686 | 'name' => get_string('mod_form_field_participant_list_type_user', 'bigbluebuttonbn'), |
687 | 687 | 'children' => bigbluebuttonbn_get_users_select($context) |
688 | - ); |
|
688 | + ); |
|
689 | 689 | return $data; |
690 | 690 | } |
691 | 691 | |
@@ -735,9 +735,9 @@ discard block |
||
735 | 735 | continue; |
736 | 736 | } |
737 | 737 | $participantlistarray[] = array( |
738 | - 'selectiontype' => 'role', |
|
739 | - 'selectionid' => $moderatordefault, |
|
740 | - 'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR); |
|
738 | + 'selectiontype' => 'role', |
|
739 | + 'selectionid' => $moderatordefault, |
|
740 | + 'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR); |
|
741 | 741 | } |
742 | 742 | return $participantlistarray; |
743 | 743 | } |
@@ -748,11 +748,11 @@ discard block |
||
748 | 748 | 'all' => get_string('mod_form_field_participant_list_type_all', 'bigbluebuttonbn'), |
749 | 749 | 'role' => get_string('mod_form_field_participant_list_type_role', 'bigbluebuttonbn'), |
750 | 750 | 'user' => get_string('mod_form_field_participant_list_type_user', 'bigbluebuttonbn'), |
751 | - ], |
|
751 | + ], |
|
752 | 752 | 'type_selected' => 'all', |
753 | 753 | 'options' => ['all' => '---------------'], |
754 | 754 | 'selected' => 'all', |
755 | - ]; |
|
755 | + ]; |
|
756 | 756 | } |
757 | 757 | |
758 | 758 | function bigbluebuttonbn_is_moderator($context, $participants, $userid = null, $userroles = null) { |
@@ -870,8 +870,8 @@ discard block |
||
870 | 870 | } |
871 | 871 | } |
872 | 872 | $parray = array('url' => $purl, 'name' => $pname, |
873 | - 'icon' => $picon, |
|
874 | - 'mimetype_description' => $pmimetypedescrip); |
|
873 | + 'icon' => $picon, |
|
874 | + 'mimetype_description' => $pmimetypedescrip); |
|
875 | 875 | return $parray; |
876 | 876 | } |
877 | 877 | |
@@ -945,7 +945,7 @@ discard block |
||
945 | 945 | $eventproperties['other'] = $options['other']; |
946 | 946 | } |
947 | 947 | $event = call_user_func_array('\mod_bigbluebuttonbn\event\bigbluebuttonbn_'.$eventtype.'::create', |
948 | - array($eventproperties)); |
|
948 | + array($eventproperties)); |
|
949 | 949 | $event->trigger(); |
950 | 950 | } |
951 | 951 | |
@@ -990,7 +990,7 @@ discard block |
||
990 | 990 | // Ping again and refresh the cache. |
991 | 991 | $meetinginfo = (array) bigbluebuttonbn_wrap_xml_load_file( |
992 | 992 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid]) |
993 | - ); |
|
993 | + ); |
|
994 | 994 | $cache->set($meetingid, array('creation_time' => time(), 'meeting_info' => json_encode($meetinginfo))); |
995 | 995 | return $meetinginfo; |
996 | 996 | } |
@@ -1112,7 +1112,7 @@ discard block |
||
1112 | 1112 | $actionbar .= bigbluebuttonbn_actionbar_render_button( |
1113 | 1113 | $recording, |
1114 | 1114 | bigbluebuttonbn_get_recording_data_row_actionbar_payload($recording, $tool) |
1115 | - ); |
|
1115 | + ); |
|
1116 | 1116 | } |
1117 | 1117 | $head = html_writer::start_tag('div', array( |
1118 | 1118 | 'id' => 'recording-actionbar-' . $recording['recordID'], |
@@ -1185,8 +1185,8 @@ discard block |
||
1185 | 1185 | } |
1186 | 1186 | $id = 'playbacks-'.$recording['recordID']; |
1187 | 1187 | $recordingtypes = html_writer::start_tag('div', array('id' => $id, 'data-imported' => $dataimported, |
1188 | - 'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'], |
|
1189 | - 'title' => $title, $visibility => $visibility)); |
|
1188 | + 'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'], |
|
1189 | + 'title' => $title, $visibility => $visibility)); |
|
1190 | 1190 | foreach ($recording['playbacks'] as $playback) { |
1191 | 1191 | $onclick = 'M.mod_bigbluebuttonbn.recordings.recording_play(this);'; |
1192 | 1192 | $href = $CFG->wwwroot.'/mod/bigbluebuttonbn/bbb_view.php?action=playback&bn='.$bigbluebuttonbnid. |
@@ -1291,7 +1291,7 @@ discard block |
||
1291 | 1291 | 'onclick' => $onclick, |
1292 | 1292 | 'data-action' => $data['action'], |
1293 | 1293 | 'data-links' => bigbluebuttonbn_get_count_recording_imported_instances($recording['recordID']) |
1294 | - ); |
|
1294 | + ); |
|
1295 | 1295 | return $OUTPUT->action_icon('#', $icon, null, $linkattributes, false); |
1296 | 1296 | } |
1297 | 1297 | |
@@ -1641,8 +1641,8 @@ discard block |
||
1641 | 1641 | $activitytime = ''; |
1642 | 1642 | if ($time) { |
1643 | 1643 | $activitytime = calendar_day_representation($time).' '. |
1644 | - get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '. |
|
1645 | - calendar_time_representation($time); |
|
1644 | + get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '. |
|
1645 | + calendar_time_representation($time); |
|
1646 | 1646 | } |
1647 | 1647 | |
1648 | 1648 | return $activitytime; |