Browse Source

Fix issue with BigBlueButton plugin and unique voiceBridge per conference room - refs #7669

Yannick Warnier 9 years ago
parent
commit
67943d194d
3 changed files with 12 additions and 2 deletions
  1. 6 0
      plugin/bbb/changelog.md
  2. 4 1
      plugin/bbb/lib/bbb.lib.php
  3. 2 1
      plugin/bbb/lib/bbb_plugin.class.php

+ 6 - 0
plugin/bbb/changelog.md

@@ -1,3 +1,9 @@
+version 2.3 - 2015-05-18
+------------------------
+Changes:
+* Added support for variable voiceBridge to be sent on meeting creation. See https://code.google.com/p/bigbluebutton/issues/detail?can=2&start=0&num=100&q=&colspec=ID%20Type%20Status%20Priority%20Milestone%20Owner%20Component%20Summary&groupby=&sort=&id=1186 and https://support.chamilo.org/issues/7669 for details.
+* Requires you to "ALTER TABLE plugin_bbb_meeting ADD COLUMN voice_bridge INT NOT NULL DEFAULT 1;"
+
 version 2.2 - 2014-10-15
 ------------------------
 Changes:

+ 4 - 1
plugin/bbb/lib/bbb.lib.php

@@ -133,6 +133,9 @@ class bbb
         // Generate a pseudo-global-unique-id to avoid clash of conferences on
         // the same BBB server with several Chamilo portals
         $params['remote_id'] = uniqid(true, true);
+        // Each simultaneous conference room needs to have a different
+        // voice_bridge composed of a 5 digits number, so generating a random one
+        $params['voice_bridge'] = rand(10000,99999);
 
         if ($this->debug) {
             error_log("enter create_meeting ".print_r($params, 1));
@@ -161,7 +164,7 @@ class bbb
                 'moderatorPw' => $moderatorPassword, 					// Match this value in getJoinMeetingURL() to join as moderator.
                 'welcomeMsg' => $welcomeMessage, 					// ''= use default. Change to customize.
                 'dialNumber' => '', 					// The main number to call into. Optional.
-                'voiceBridge' => '12345', 					// PIN to join voice. Required.
+                'voiceBridge' => $params['voice_bridge'], 					// PIN to join voice. Required.
                 'webVoice' => '', 						// Alphanumeric to join voice. Optional.
                 'logoutUrl' =>  $this->logout_url,
                 'maxParticipants' => $max, 				// Optional. -1 = unlimitted. Not supported in BBB. [number]

+ 2 - 1
plugin/bbb/lib/bbb_plugin.class.php

@@ -52,7 +52,8 @@ class BBBPlugin extends Plugin
                 welcome_msg VARCHAR(255) NOT NULL DEFAULT '',
                 session_id INT unsigned DEFAULT 0,
                 remote_id CHAR(30),
-                visibility TINYINT NOT NULL DEFAULT 1
+                visibility TINYINT NOT NULL DEFAULT 1,
+                voice_bridge INT NOT NULL DEFAULT 1
                 )";
         Database::query($sql);