@@ -208,7 +208,7 @@ discard block |
||
208 | 208 | |
209 | 209 | $logs = $DB->get_records('bigbluebuttonbn_logs', |
210 | 210 | array('bigbluebuttonbnid' => $bigbluebuttonbn->id, 'log' => BIGBLUEBUTTONBN_LOG_EVENT_CREATE, 'meta' => "{\"record\":true}") |
211 | - ); |
|
211 | + ); |
|
212 | 212 | $log->meta = "{\"has_recordings\":false}"; |
213 | 213 | if (!empty($logs)) { |
214 | 214 | $log->meta = "{\"has_recordings\":true}"; |
@@ -233,9 +233,9 @@ discard block |
||
233 | 233 | global $DB; |
234 | 234 | |
235 | 235 | $completed = $DB->count_records('bigbluebuttonbn_logs', array('courseid' => $course->id, |
236 | - 'bigbluebuttonbnid' => $bigbluebuttonbn->id, |
|
237 | - 'userid' => $user->id, |
|
238 | - 'log' => 'Join', ), '*'); |
|
236 | + 'bigbluebuttonbnid' => $bigbluebuttonbn->id, |
|
237 | + 'userid' => $user->id, |
|
238 | + 'log' => 'Join', ), '*'); |
|
239 | 239 | |
240 | 240 | if ($completed > 0) { |
241 | 241 | return fullname($user).' '.get_string('view_message_has_joined', 'bigbluebuttonbn').' '. |
@@ -256,9 +256,9 @@ discard block |
||
256 | 256 | global $DB; |
257 | 257 | |
258 | 258 | $completed = $DB->count_recorda('bigbluebuttonbn_logs', array('courseid' => $course->id, |
259 | - 'bigbluebuttonbnid' => $bigbluebuttonbn->id, |
|
260 | - 'userid' => $user->id, |
|
261 | - 'log' => 'Join', ), '*', IGNORE_MULTIPLE); |
|
259 | + 'bigbluebuttonbnid' => $bigbluebuttonbn->id, |
|
260 | + 'userid' => $user->id, |
|
261 | + 'log' => 'Join', ), '*', IGNORE_MULTIPLE); |
|
262 | 262 | |
263 | 263 | return $completed > 0; |
264 | 264 | } |
@@ -331,12 +331,12 @@ discard block |
||
331 | 331 | $str = '<div class="bigbluebuttonbn overview">'."\n"; |
332 | 332 | $str .= ' <div class="name">'.get_string('modulename', 'bigbluebuttonbn').': '."\n"; |
333 | 333 | $str .= ' <a '.$classes.'href="'.$CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$bigbluebuttonbn->coursemodule. |
334 | - '">'.$bigbluebuttonbn->name.'</a>'."\n"; |
|
334 | + '">'.$bigbluebuttonbn->name.'</a>'."\n"; |
|
335 | 335 | $str .= ' </div>'."\n"; |
336 | 336 | $str .= ' <div class="info">'.get_string($start, 'bigbluebuttonbn').': '.userdate($bigbluebuttonbn->openingtime). |
337 | 337 | '</div>'."\n"; |
338 | 338 | $str .= ' <div class="info">'.get_string('ends_at', 'bigbluebuttonbn').': '.userdate($bigbluebuttonbn->closingtime) |
339 | - .'</div>'."\n"; |
|
339 | + .'</div>'."\n"; |
|
340 | 340 | $str .= '</div>'."\n"; |
341 | 341 | |
342 | 342 | return $str; |
@@ -96,8 +96,8 @@ |
||
96 | 96 | $output .= html_writer::start_tag('br'); |
97 | 97 | $output .= html_writer::tag('input', '', |
98 | 98 | array('type' => 'button', 'class' => 'btn btn-secondary', |
99 | - 'value' => get_string('view_recording_button_return', 'bigbluebuttonbn'), |
|
100 | - 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$cm->id.'\'')); |
|
99 | + 'value' => get_string('view_recording_button_return', 'bigbluebuttonbn'), |
|
100 | + 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$cm->id.'\'')); |
|
101 | 101 | |
102 | 102 | // JavaScript for locales. |
103 | 103 | $PAGE->requires->strings_for_js(array_keys(bigbluebuttonbn_get_strings_for_js()), 'bigbluebuttonbn'); |
@@ -15,13 +15,13 @@ |
||
15 | 15 | // along with Moodle. If not, see <http://www.gnu.org/licenses/>. |
16 | 16 | |
17 | 17 | /** |
18 | - * The mod_bigbluebuttonbn abstract base event. |
|
19 | - * |
|
20 | - * @package mod_bigbluebuttonbn |
|
21 | - * @author Jesus Federico (jesus [at] blindsidenetworks [dt] com) |
|
22 | - * @copyright 2017 - present, Blindside Networks Inc |
|
23 | - * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
|
24 | - */ |
|
18 | + * The mod_bigbluebuttonbn abstract base event. |
|
19 | + * |
|
20 | + * @package mod_bigbluebuttonbn |
|
21 | + * @author Jesus Federico (jesus [at] blindsidenetworks [dt] com) |
|
22 | + * @copyright 2017 - present, Blindside Networks Inc |
|
23 | + * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later |
|
24 | + */ |
|
25 | 25 | |
26 | 26 | namespace mod_bigbluebuttonbn\event; |
27 | 27 |
@@ -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']; |
@@ -274,11 +274,11 @@ discard block |
||
274 | 274 | |
275 | 275 | echo $OUTPUT->box_start('generalbox boxaligncenter'); |
276 | 276 | echo '<br><div class="alert alert-warning">'.get_string('view_groups_selection_warning', 'bigbluebuttonbn'). |
277 | - '</div>'; |
|
277 | + '</div>'; |
|
278 | 278 | echo $OUTPUT->box_end(); |
279 | 279 | |
280 | 280 | groups_print_activity_menu( |
281 | - $bbbsession['cm'], $CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$bbbsession['cm']->id); |
|
281 | + $bbbsession['cm'], $CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$bbbsession['cm']->id); |
|
282 | 282 | echo '<br><br>'; |
283 | 283 | } |
284 | 284 | |
@@ -364,11 +364,11 @@ discard block |
||
364 | 364 | } |
365 | 365 | |
366 | 366 | function bigbluebuttonbn_view_include_recordings(&$bbbsession) { |
367 | - if ( $bbbsession['bigbluebuttonbn']->type == BIGBLUEBUTTONBN_TYPE_RECORDING_ONLY && |
|
367 | + if ( $bbbsession['bigbluebuttonbn']->type == BIGBLUEBUTTONBN_TYPE_RECORDING_ONLY && |
|
368 | 368 | $bbbsession['bigbluebuttonbn']->recordings_imported ) { |
369 | - return false; |
|
370 | - } |
|
371 | - return true; |
|
369 | + return false; |
|
370 | + } |
|
371 | + return true; |
|
372 | 372 | } |
373 | 373 | |
374 | 374 | function bigbluebuttonbn_view_render_recordings(&$bbbsession, $showroom, &$jsvars) { |
@@ -383,13 +383,13 @@ discard block |
||
383 | 383 | $recordings = bigbluebuttonbn_get_recordings( |
384 | 384 | $bbbsession['course']->id, $bigbluebuttonbnid, $showroom, |
385 | 385 | $bbbsession['bigbluebuttonbn']->recordings_deleted |
386 | - ); |
|
386 | + ); |
|
387 | 387 | } |
388 | 388 | |
389 | 389 | // Get recording links. |
390 | 390 | $recordingsimported = bigbluebuttonbn_get_recordings_imported_array( |
391 | 391 | $bbbsession['course']->id, $bigbluebuttonbnid, $showroom |
392 | - ); |
|
392 | + ); |
|
393 | 393 | |
394 | 394 | /* Perform aritmetic addition instead of merge so the imported recordings corresponding to existent |
395 | 395 | * recordings are not included. */ |
@@ -405,7 +405,7 @@ discard block |
||
405 | 405 | // JavaScript variables for recordings. |
406 | 406 | $jsvars += array( |
407 | 407 | 'recordings_html' => $bbbsession['bigbluebuttonbn']->recordings_html == '1', |
408 | - ); |
|
408 | + ); |
|
409 | 409 | |
410 | 410 | // If there are meetings with recordings load the data to the table. |
411 | 411 | if ($bbbsession['bigbluebuttonbn']->recordings_html) { |
@@ -417,7 +417,7 @@ discard block |
||
417 | 417 | $jsvars += array( |
418 | 418 | 'columns' => bigbluebuttonbn_get_recording_columns($bbbsession), |
419 | 419 | 'data' => bigbluebuttonbn_get_recording_data($bbbsession, $recordings), |
420 | - ); |
|
420 | + ); |
|
421 | 421 | |
422 | 422 | // Render a YUI table. |
423 | 423 | return html_writer::div('', '', array('id' => 'bigbluebuttonbn_yui_table')); |
@@ -428,10 +428,10 @@ discard block |
||
428 | 428 | |
429 | 429 | $button = html_writer::tag('input', '', |
430 | 430 | array('type' => 'button', |
431 | - 'value' => get_string('view_recording_button_import', 'bigbluebuttonbn'), |
|
432 | - 'class' => 'btn btn-secondary', |
|
433 | - 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/import_view.php?bn='. |
|
434 | - $bbbsession['bigbluebuttonbn']->id.'\'')); |
|
431 | + 'value' => get_string('view_recording_button_import', 'bigbluebuttonbn'), |
|
432 | + 'class' => 'btn btn-secondary', |
|
433 | + 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/import_view.php?bn='. |
|
434 | + $bbbsession['bigbluebuttonbn']->id.'\'')); |
|
435 | 435 | $output = html_writer::start_tag('br'); |
436 | 436 | $output .= html_writer::tag('span', $button, array('id' => 'import_recording_links_button')); |
437 | 437 | $output .= html_writer::tag('span', '', array('id' => 'import_recording_links_table')); |
@@ -449,7 +449,7 @@ discard block |
||
449 | 449 | return '<h4>'.get_string('view_section_title_presentation', 'bigbluebuttonbn').'</h4>'. |
450 | 450 | ''.$OUTPUT->action_icon($bbbsession['presentation']['url'], $icon, null, array(), false).''. |
451 | 451 | ''.$OUTPUT->action_link($bbbsession['presentation']['url'], |
452 | - $bbbsession['presentation']['name'], null, $attributes).'<br><br>'; |
|
452 | + $bbbsession['presentation']['name'], null, $attributes).'<br><br>'; |
|
453 | 453 | } |
454 | 454 | |
455 | 455 | return ''; |
@@ -371,23 +371,23 @@ discard block |
||
371 | 371 | return array( |
372 | 372 | 'status' => false, |
373 | 373 | 'message' => get_string('view_recording_'.$action.'_link_deleted', 'bigbluebuttonbn') |
374 | - ); |
|
374 | + ); |
|
375 | 375 | } |
376 | 376 | if ($realrecordings[$params['id']][$action.'ed'] !== 'true') { |
377 | 377 | return array( |
378 | 378 | 'status' => false, |
379 | 379 | 'message' => get_string('view_recording_'.$action.'_link_not_'.$action.'ed', 'bigbluebuttonbn') |
380 | - ); |
|
380 | + ); |
|
381 | 381 | } |
382 | 382 | return array( |
383 | 383 | 'status' => bigbluebuttonbn_publish_recording_imported($recordings[$params['id']]['imported'], true) |
384 | - ); |
|
384 | + ); |
|
385 | 385 | } |
386 | 386 | |
387 | 387 | // As the recordingid was not identified as imported recording link, execute publish on a real recording. |
388 | 388 | return array( |
389 | 389 | 'status' => bigbluebuttonbn_publish_recordings($params['id'], 'true') |
390 | - ); |
|
390 | + ); |
|
391 | 391 | } |
392 | 392 | |
393 | 393 | function bigbluebuttonbn_broker_recording_action_unpublishprotect($params, $recordings, $action) { |
@@ -397,7 +397,7 @@ discard block |
||
397 | 397 | // Execute unpublish or protect on imported recording link. |
398 | 398 | return array( |
399 | 399 | 'status' => bigbluebuttonbn_publish_recording_imported($recordings[$params['id']]['imported'], false) |
400 | - ); |
|
400 | + ); |
|
401 | 401 | } |
402 | 402 | |
403 | 403 | // As the recordingid was not identified as imported recording link, execute unpublish on a real recording. |
@@ -416,8 +416,8 @@ discard block |
||
416 | 416 | } |
417 | 417 | // Second: Execute the actual unpublish. |
418 | 418 | return array( |
419 | - 'status' => bigbluebuttonbn_publish_recordings($params['id'], 'false') |
|
420 | - ); |
|
419 | + 'status' => bigbluebuttonbn_publish_recordings($params['id'], 'false') |
|
420 | + ); |
|
421 | 421 | } |
422 | 422 | |
423 | 423 | function bigbluebuttonbn_broker_recording_action_delete($params, $recordings) { |
@@ -426,10 +426,10 @@ discard block |
||
426 | 426 | if (bigbluebuttonbn_broker_recording_is_imported($recordings, $params['id'])) { |
427 | 427 | // Execute delete on imported recording link. |
428 | 428 | return array( |
429 | - 'status' => bigbluebuttonbn_delete_recording_imported( |
|
430 | - $recordings[$params['id']]['imported'] |
|
429 | + 'status' => bigbluebuttonbn_delete_recording_imported( |
|
430 | + $recordings[$params['id']]['imported'] |
|
431 | 431 | ) |
432 | - ); |
|
432 | + ); |
|
433 | 433 | } |
434 | 434 | |
435 | 435 | // As the recordingid was not identified as imported recording link, execute delete on a real recording. |
@@ -444,26 +444,26 @@ discard block |
||
444 | 444 | } |
445 | 445 | // Second: Execute the actual delete. |
446 | 446 | return array( |
447 | - 'status' => bigbluebuttonbn_delete_recordings($params['id']) |
|
448 | - ); |
|
447 | + 'status' => bigbluebuttonbn_delete_recordings($params['id']) |
|
448 | + ); |
|
449 | 449 | } |
450 | 450 | |
451 | 451 | function bigbluebuttonbn_broker_recording_action_edit($params, $recordings) { |
452 | 452 | if (bigbluebuttonbn_broker_recording_is_imported($recordings, $params['id'])) { |
453 | 453 | // Execute update on imported recording link. |
454 | 454 | return array( |
455 | - 'status' => bigbluebuttonbn_update_recording_imported( |
|
456 | - $recordings[$params['id']]['imported'], json_decode($params['meta'], true) |
|
455 | + 'status' => bigbluebuttonbn_update_recording_imported( |
|
456 | + $recordings[$params['id']]['imported'], json_decode($params['meta'], true) |
|
457 | 457 | ) |
458 | - ); |
|
458 | + ); |
|
459 | 459 | } |
460 | 460 | |
461 | 461 | // As the recordingid was not identified as imported recording link, execute update on a real recording. |
462 | 462 | // (No need to update imported links as the update only affects the actual recording). |
463 | 463 | // Execute update on actual recording. |
464 | 464 | return array( |
465 | - 'status' => bigbluebuttonbn_update_recordings($params['id'], json_decode($params['meta'])) |
|
466 | - ); |
|
465 | + 'status' => bigbluebuttonbn_update_recordings($params['id'], json_decode($params['meta'])) |
|
466 | + ); |
|
467 | 467 | } |
468 | 468 | |
469 | 469 | function bigbluebuttonbn_broker_recording_ready($params, $bigbluebuttonbn) { |
@@ -604,10 +604,10 @@ discard block |
||
604 | 604 | $params['recording_import'] = ['id' => 'The recordingID must be specified.']; |
605 | 605 | $params['recording_ready'] = [ |
606 | 606 | 'signed_parameters' => 'A JWT encoded string must be included as [signed_parameters].' |
607 | - ]; |
|
607 | + ]; |
|
608 | 608 | $params['live_session_events'] = [ |
609 | 609 | 'signed_parameters' => 'A JWT encoded string must be included as [signed_parameters].' |
610 | - ]; |
|
610 | + ]; |
|
611 | 611 | return $params; |
612 | 612 | } |
613 | 613 |
@@ -94,7 +94,7 @@ discard block |
||
94 | 94 | * recordings from a different activity even from a different course. |
95 | 95 | **/ |
96 | 96 | |
97 | - /* |
|
97 | + /* |
|
98 | 98 | * When the value is set to 1 (checked) the bigbluebuttonbn rooms or |
99 | 99 | * activities will have the 'import recordings' capability enabled. |
100 | 100 | */ |
@@ -115,7 +115,7 @@ discard block |
||
115 | 115 | * 'Join session' button enabled |
116 | 116 | **/ |
117 | 117 | |
118 | - /* |
|
118 | + /* |
|
119 | 119 | * When the value is set to 1 (checked) the bigbluebuttonbn rooms or |
120 | 120 | * activities will have the 'wait for moderator' capability enabled by |
121 | 121 | * default. |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | * 5. CONFIGURATION FOR "STATIC VOICE BRIDGE" FEATURE |
150 | 150 | * |
151 | 151 | **/ |
152 | - /* |
|
152 | + /* |
|
153 | 153 | * A conference voice bridge number can be permanently assigned to a room |
154 | 154 | * or activity. |
155 | 155 | */ |
@@ -159,7 +159,7 @@ discard block |
||
159 | 159 | * 6. CONFIGURATION FOR "PRE-UPLOAD PRESENTATION" FEATURE |
160 | 160 | * |
161 | 161 | **/ |
162 | - /* |
|
162 | + /* |
|
163 | 163 | * Since version 0.8, BigBluebutton has an implementation for allowing |
164 | 164 | * preuploading presentation. When this feature is enabled, users creating or |
165 | 165 | * editing a room or activity can upload a PDF or Office document to the |
@@ -176,7 +176,7 @@ discard block |
||
176 | 176 | * applied to each room or activity, or globally. |
177 | 177 | **/ |
178 | 178 | |
179 | - /* |
|
179 | + /* |
|
180 | 180 | * The number of users allowed in a session by default when a new room or |
181 | 181 | * conference is added. If the number is set to 0, no limit is established. |
182 | 182 | * $CFG->bigbluebuttonbn['userlimit_default'] = 0; |
@@ -197,7 +197,7 @@ discard block |
||
197 | 197 | * By default only the owner is assigned. |
198 | 198 | **/ |
199 | 199 | |
200 | - /* |
|
200 | + /* |
|
201 | 201 | * The values for this parameter can be 'owner' and/or any of the roles defined in |
202 | 202 | * Moodle (including the custom parameters). The value used will be the key for the role. |
203 | 203 | * [owner|manager|coursecreator|editingteacher|teacher|student|guest|user|frontpage|ANY_CUSTOM_ROLE] |
@@ -208,7 +208,7 @@ discard block |
||
208 | 208 | * 9. CONFIGURATION FOR "NOTIFICATION SENDING" FEATURE |
209 | 209 | * |
210 | 210 | **/ |
211 | - /* |
|
211 | + /* |
|
212 | 212 | * When the value is set to 1 (checked) the 'notification sending' |
213 | 213 | * capability can be used by the user creating or editing the room or |
214 | 214 | * activity. |
@@ -222,7 +222,7 @@ discard block |
||
222 | 222 | * 10. CONFIGURATION FOR "RECORDING READY" FEATURE |
223 | 223 | * |
224 | 224 | **/ |
225 | - /* |
|
225 | + /* |
|
226 | 226 | * When the value is set to 1 (checked) the 'notify users when recording ready' |
227 | 227 | * capability is enabled, meaning that a message will be sent to all enrolled |
228 | 228 | * users in a course when a recording is ready |
@@ -246,7 +246,7 @@ discard block |
||
246 | 246 | * 12. GENERAL CONFIGURATION FOR RECORDINGS UI |
247 | 247 | * |
248 | 248 | **/ |
249 | - /* |
|
249 | + /* |
|
250 | 250 | * When the value is set to 1 (checked) the bigbluebuttonbn resources |
251 | 251 | * will show the recodings in an html table by default. |
252 | 252 | * $CFG->bigbluebuttonbn['recordings_html_default'] = 0; |
@@ -270,13 +270,13 @@ discard block |
||
270 | 270 | * $CFG->bigbluebuttonbn['recordings_deleted_editable'] = 0; |
271 | 271 | */ |
272 | 272 | |
273 | - /* |
|
273 | + /* |
|
274 | 274 | * When the value is set to 1 (checked) the bigbluebuttonbn resources for recordings |
275 | 275 | * will show only the imported links as part of the list. |
276 | 276 | * $CFG->bigbluebuttonbn['recordings_imported_default'] = 0; |
277 | 277 | */ |
278 | 278 | |
279 | - /* |
|
279 | + /* |
|
280 | 280 | * When the value is set to 1 (checked) the 'show only imported links' |
281 | 281 | * capability can be enabled/disabled by the user creating or editing the resource for recordings. |
282 | 282 | * $CFG->bigbluebuttonbn['recordings_imported_editable'] = 1; |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | 'alt' => get_string('delete'), |
112 | 112 | 'title' => get_string('delete'), |
113 | 113 | 'src' => $jsvars['pix_icon_delete'] |
114 | - ); |
|
114 | + ); |
|
115 | 115 | |
116 | 116 | $jsvars['pix_icon_delete'] = html_writer::tag('img', $options); |
117 | 117 | } |
@@ -211,8 +211,8 @@ discard block |
||
211 | 211 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
212 | 212 | $field['description_key'], 0, ['maxlength' => 4, 'size' => 6], |
213 | 213 | ['message' => get_string('mod_form_field_voicebridge_format_error', 'bigbluebuttonbn'), |
214 | - 'type' => 'numeric', 'rule' => '####', 'validator' => 'server'] |
|
215 | - ); |
|
214 | + 'type' => 'numeric', 'rule' => '####', 'validator' => 'server'] |
|
215 | + ); |
|
216 | 216 | } else { |
217 | 217 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
218 | 218 | $field['description_key'], 0, ['maxlength' => 4, 'size' => 6]); |
@@ -246,7 +246,7 @@ discard block |
||
246 | 246 | |
247 | 247 | private function bigbluebuttonbn_mform_add_block_room_recordings($mform, $cfg) { |
248 | 248 | $field = ['type' => 'hidden', 'name' => 'recordings_html', 'data_type' => PARAM_INT, |
249 | - 'description_key' => null]; |
|
249 | + 'description_key' => null]; |
|
250 | 250 | if ($cfg['recordings_html_editable']) { |
251 | 251 | $field['type'] = 'checkbox'; |
252 | 252 | $field['description_key'] = 'mod_form_field_recordings_html'; |
@@ -255,7 +255,7 @@ discard block |
||
255 | 255 | $field['description_key'], $cfg['recordings_html_default']); |
256 | 256 | |
257 | 257 | $field = ['type' => 'hidden', 'name' => 'recordings_deleted', 'data_type' => PARAM_INT, |
258 | - 'description_key' => null]; |
|
258 | + 'description_key' => null]; |
|
259 | 259 | if ($cfg['recordings_deleted_editable']) { |
260 | 260 | $field['type'] = 'checkbox'; |
261 | 261 | $field['description_key'] = 'mod_form_field_recordings_deleted'; |
@@ -264,7 +264,7 @@ discard block |
||
264 | 264 | $field['description_key'], $cfg['recordings_deleted_default']); |
265 | 265 | |
266 | 266 | $field = ['type' => 'hidden', 'name' => 'recordings_imported', 'data_type' => PARAM_INT, |
267 | - 'description_key' => null]; |
|
267 | + 'description_key' => null]; |
|
268 | 268 | if ($cfg['recordings_imported_editable']) { |
269 | 269 | $field['type'] = 'checkbox'; |
270 | 270 | $field['description_key'] = 'mod_form_field_recordings_imported'; |
@@ -319,7 +319,7 @@ discard block |
||
319 | 319 | html_writer::select($participantselection['type_options'], 'bigbluebuttonbn_participant_selection_type', |
320 | 320 | $participantselection['type_selected'], array(), |
321 | 321 | array('id' => 'bigbluebuttonbn_participant_selection_type', |
322 | - 'onchange' => 'M.mod_bigbluebuttonbn.modform.participant_selection_set(); return 0;')).' '. |
|
322 | + 'onchange' => 'M.mod_bigbluebuttonbn.modform.participant_selection_set(); return 0;')).' '. |
|
323 | 323 | html_writer::select($participantselection['options'], 'bigbluebuttonbn_participant_selection', |
324 | 324 | $participantselection['selected'], array(), |
325 | 325 | array('id' => 'bigbluebuttonbn_participant_selection', 'disabled' => 'disabled')).' '. |
@@ -98,9 +98,9 @@ discard block |
||
98 | 98 | */ |
99 | 99 | function bigbluebuttonbn_get_join_url($meetingid, $username, $pw, $logouturl, $configtoken = null, $userid = null) { |
100 | 100 | $data = ['meetingID' => $meetingid, |
101 | - 'fullName' => $username, |
|
102 | - 'password' => $pw, |
|
103 | - 'logoutURL' => $logouturl, |
|
101 | + 'fullName' => $username, |
|
102 | + 'password' => $pw, |
|
103 | + 'logoutURL' => $logouturl, |
|
104 | 104 | ]; |
105 | 105 | |
106 | 106 | if (!is_null($configtoken)) { |
@@ -201,24 +201,24 @@ discard block |
||
201 | 201 | function bigbluebuttonbn_get_meeting_info_array($meetingid) { |
202 | 202 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
203 | 203 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid]) |
204 | - ); |
|
204 | + ); |
|
205 | 205 | |
206 | 206 | if ($xml && $xml->returncode == 'SUCCESS' && empty($xml->messageKey)) { |
207 | 207 | // Meeting info was returned. |
208 | 208 | return array('returncode' => $xml->returncode, |
209 | - 'meetingID' => $xml->meetingID, |
|
210 | - 'moderatorPW' => $xml->moderatorPW, |
|
211 | - 'attendeePW' => $xml->attendeePW, |
|
212 | - 'hasBeenForciblyEnded' => $xml->hasBeenForciblyEnded, |
|
213 | - 'running' => $xml->running, |
|
214 | - 'recording' => $xml->recording, |
|
215 | - 'startTime' => $xml->startTime, |
|
216 | - 'endTime' => $xml->endTime, |
|
217 | - 'participantCount' => $xml->participantCount, |
|
218 | - 'moderatorCount' => $xml->moderatorCount, |
|
219 | - 'attendees' => $xml->attendees, |
|
220 | - 'metadata' => $xml->metadata, |
|
221 | - ); |
|
209 | + 'meetingID' => $xml->meetingID, |
|
210 | + 'moderatorPW' => $xml->moderatorPW, |
|
211 | + 'attendeePW' => $xml->attendeePW, |
|
212 | + 'hasBeenForciblyEnded' => $xml->hasBeenForciblyEnded, |
|
213 | + 'running' => $xml->running, |
|
214 | + 'recording' => $xml->recording, |
|
215 | + 'startTime' => $xml->startTime, |
|
216 | + 'endTime' => $xml->endTime, |
|
217 | + 'participantCount' => $xml->participantCount, |
|
218 | + 'moderatorCount' => $xml->moderatorCount, |
|
219 | + 'attendees' => $xml->attendees, |
|
220 | + 'metadata' => $xml->metadata, |
|
221 | + ); |
|
222 | 222 | } |
223 | 223 | |
224 | 224 | if ($xml) { |
@@ -282,7 +282,7 @@ discard block |
||
282 | 282 | // Do getRecordings is executed using a method GET (supported by all versions of BBB). |
283 | 283 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
284 | 284 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getRecordings', ['meetingID' => implode(',', $mids)]) |
285 | - ); |
|
285 | + ); |
|
286 | 286 | if ($xml && $xml->returncode == 'SUCCESS' && isset($xml->recordings)) { |
287 | 287 | // If there were meetings already created. |
288 | 288 | foreach ($xml->recordings->recording as $recording) { |
@@ -353,7 +353,7 @@ discard block |
||
353 | 353 | function bigbluebuttonbn_get_default_config_xml() { |
354 | 354 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
355 | 355 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getDefaultConfigXML') |
356 | - ); |
|
356 | + ); |
|
357 | 357 | |
358 | 358 | return $xml; |
359 | 359 | } |
@@ -430,7 +430,7 @@ discard block |
||
430 | 430 | foreach ($ids as $id) { |
431 | 431 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
432 | 432 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('deleteRecordings', ['recordID' => $id]) |
433 | - ); |
|
433 | + ); |
|
434 | 434 | if ($xml && $xml->returncode != 'SUCCESS') { |
435 | 435 | return false; |
436 | 436 | } |
@@ -448,7 +448,7 @@ discard block |
||
448 | 448 | foreach ($ids as $id) { |
449 | 449 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
450 | 450 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('publishRecordings', ['recordID' => $id, 'publish' => $publish]) |
451 | - ); |
|
451 | + ); |
|
452 | 452 | if ($xml && $xml->returncode != 'SUCCESS') { |
453 | 453 | return false; |
454 | 454 | } |
@@ -466,7 +466,7 @@ discard block |
||
466 | 466 | foreach ($ids as $id) { |
467 | 467 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
468 | 468 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('updateRecordings', ['recordID' => $id] + (array) $params) |
469 | - ); |
|
469 | + ); |
|
470 | 470 | if ($xml && $xml->returncode != 'SUCCESS') { |
471 | 471 | return false; |
472 | 472 | } |
@@ -482,7 +482,7 @@ discard block |
||
482 | 482 | function bigbluebuttonbn_end_meeting($meetingid, $modpw) { |
483 | 483 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
484 | 484 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('end', ['meetingID' => $meetingid, 'password' => $modpw]) |
485 | - ); |
|
485 | + ); |
|
486 | 486 | |
487 | 487 | if ($xml) { |
488 | 488 | // If the xml packet returned failure it displays the message to the user. |
@@ -499,7 +499,7 @@ discard block |
||
499 | 499 | function bigbluebuttonbn_is_meeting_running($meetingid) { |
500 | 500 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
501 | 501 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('isMeetingRunning', ['meetingID' => $meetingid]) |
502 | - ); |
|
502 | + ); |
|
503 | 503 | |
504 | 504 | if ($xml && $xml->returncode == 'SUCCESS') { |
505 | 505 | return ($xml->running == 'true'); |
@@ -511,7 +511,7 @@ discard block |
||
511 | 511 | function bigbluebuttonbn_get_server_version() { |
512 | 512 | $xml = bigbluebuttonbn_wrap_xml_load_file( |
513 | 513 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url() |
514 | - ); |
|
514 | + ); |
|
515 | 515 | |
516 | 516 | if ($xml && $xml->returncode == 'SUCCESS') { |
517 | 517 | return $xml->version; |
@@ -572,10 +572,10 @@ discard block |
||
572 | 572 | |
573 | 573 | $options = array(); |
574 | 574 | $options['CURLOPT_HTTPHEADER'] = array( |
575 | - 'Content-Type: '.$contenttype, |
|
576 | - 'Content-Length: '.strlen($data), |
|
577 | - 'Content-Language: en-US', |
|
578 | - ); |
|
575 | + 'Content-Type: '.$contenttype, |
|
576 | + 'Content-Length: '.strlen($data), |
|
577 | + 'Content-Language: en-US', |
|
578 | + ); |
|
579 | 579 | |
580 | 580 | return $c->post($url, $data, $options); |
581 | 581 | } |
@@ -657,16 +657,16 @@ discard block |
||
657 | 657 | 'all' => array( |
658 | 658 | 'name' => get_string('mod_form_field_participant_list_type_all', 'bigbluebuttonbn'), |
659 | 659 | 'children' => [] |
660 | - ) |
|
661 | - ); |
|
660 | + ) |
|
661 | + ); |
|
662 | 662 | $data['role'] = array( |
663 | 663 | 'name' => get_string('mod_form_field_participant_list_type_role', 'bigbluebuttonbn'), |
664 | 664 | 'children' => bigbluebuttonbn_get_roles_select($context) |
665 | - ); |
|
665 | + ); |
|
666 | 666 | $data['user'] = array( |
667 | 667 | 'name' => get_string('mod_form_field_participant_list_type_user', 'bigbluebuttonbn'), |
668 | 668 | 'children' => bigbluebuttonbn_get_users_select($context) |
669 | - ); |
|
669 | + ); |
|
670 | 670 | return $data; |
671 | 671 | } |
672 | 672 | |
@@ -716,9 +716,9 @@ discard block |
||
716 | 716 | continue; |
717 | 717 | } |
718 | 718 | $participantlistarray[] = array( |
719 | - 'selectiontype' => 'role', |
|
720 | - 'selectionid' => $moderatordefault, |
|
721 | - 'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR); |
|
719 | + 'selectiontype' => 'role', |
|
720 | + 'selectionid' => $moderatordefault, |
|
721 | + 'role' => BIGBLUEBUTTONBN_ROLE_MODERATOR); |
|
722 | 722 | } |
723 | 723 | return $participantlistarray; |
724 | 724 | } |
@@ -729,11 +729,11 @@ discard block |
||
729 | 729 | 'all' => get_string('mod_form_field_participant_list_type_all', 'bigbluebuttonbn'), |
730 | 730 | 'role' => get_string('mod_form_field_participant_list_type_role', 'bigbluebuttonbn'), |
731 | 731 | 'user' => get_string('mod_form_field_participant_list_type_user', 'bigbluebuttonbn'), |
732 | - ], |
|
732 | + ], |
|
733 | 733 | 'type_selected' => 'all', |
734 | 734 | 'options' => ['all' => '---------------'], |
735 | 735 | 'selected' => 'all', |
736 | - ]; |
|
736 | + ]; |
|
737 | 737 | } |
738 | 738 | |
739 | 739 | function bigbluebuttonbn_is_moderator($context, $participants, $userid = null, $userroles = null) { |
@@ -855,8 +855,8 @@ discard block |
||
855 | 855 | } |
856 | 856 | } |
857 | 857 | $parray = array('url' => $purl, 'name' => $pname, |
858 | - 'icon' => $picon, |
|
859 | - 'mimetype_description' => $pmimetypedescrip); |
|
858 | + 'icon' => $picon, |
|
859 | + 'mimetype_description' => $pmimetypedescrip); |
|
860 | 860 | return $parray; |
861 | 861 | } |
862 | 862 | |
@@ -930,7 +930,7 @@ discard block |
||
930 | 930 | $eventproperties['other'] = $options['other']; |
931 | 931 | } |
932 | 932 | $event = call_user_func_array('\mod_bigbluebuttonbn\event\bigbluebuttonbn_'.$eventtype.'::create', |
933 | - array($eventproperties)); |
|
933 | + array($eventproperties)); |
|
934 | 934 | $event->trigger(); |
935 | 935 | } |
936 | 936 | |
@@ -975,7 +975,7 @@ discard block |
||
975 | 975 | // Ping again and refresh the cache. |
976 | 976 | $meetinginfo = (array) bigbluebuttonbn_wrap_xml_load_file( |
977 | 977 | \mod_bigbluebuttonbn\locallib\bigbluebutton::action_url('getMeetingInfo', ['meetingID' => $meetingid]) |
978 | - ); |
|
978 | + ); |
|
979 | 979 | $cache->set($meetingid, array('creation_time' => time(), 'meeting_info' => json_encode($meetinginfo))); |
980 | 980 | return $meetinginfo; |
981 | 981 | } |
@@ -1176,8 +1176,8 @@ discard block |
||
1176 | 1176 | } |
1177 | 1177 | $id = 'playbacks-'.$recording['recordID']; |
1178 | 1178 | $recordingtypes = html_writer::start_tag('div', array('id' => $id, 'data-imported' => $dataimported, |
1179 | - 'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'], |
|
1180 | - 'title' => $title, $visibility => $visibility)); |
|
1179 | + 'data-recordingid' => $recording['recordID'], 'data-meetingid' => $recording['meetingID'], |
|
1180 | + 'title' => $title, $visibility => $visibility)); |
|
1181 | 1181 | foreach ($recording['playbacks'] as $playback) { |
1182 | 1182 | $onclick = 'M.mod_bigbluebuttonbn.recordings.recording_play(this);'; |
1183 | 1183 | $href = $CFG->wwwroot.'/mod/bigbluebuttonbn/bbb_view.php?action=playback&bn='.$bigbluebuttonbnid. |
@@ -1285,7 +1285,7 @@ discard block |
||
1285 | 1285 | 'onclick' => $onclick, |
1286 | 1286 | 'data-action' => $data['action'], |
1287 | 1287 | 'data-links' => bigbluebuttonbn_get_count_recording_imported_instances($recording['recordID']) |
1288 | - ); |
|
1288 | + ); |
|
1289 | 1289 | return $OUTPUT->action_icon('#', $icon, null, $linkattributes, false); |
1290 | 1290 | } |
1291 | 1291 | |
@@ -1402,7 +1402,7 @@ discard block |
||
1402 | 1402 | $texthead . $rowdata->activity . $texttail, $texthead . $rowdata->description . $texttail, |
1403 | 1403 | $rowdata->preview, $texthead . $rowdata->date_formatted . $texttail, |
1404 | 1404 | $rowdata->duration_formatted |
1405 | - ); |
|
1405 | + ); |
|
1406 | 1406 | if ($bbbsession['managerecordings']) { |
1407 | 1407 | $row->cells[] = $rowdata->actionbar; |
1408 | 1408 | } |
@@ -1664,8 +1664,8 @@ discard block |
||
1664 | 1664 | $activitytime = ''; |
1665 | 1665 | if ($time) { |
1666 | 1666 | $activitytime = calendar_day_representation($time).' '. |
1667 | - get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '. |
|
1668 | - calendar_time_representation($time); |
|
1667 | + get_string('mod_form_field_notification_msg_at', 'bigbluebuttonbn').' '. |
|
1668 | + calendar_time_representation($time); |
|
1669 | 1669 | } |
1670 | 1670 | |
1671 | 1671 | return $activitytime; |