Automated attending js keeps checking if BBB session has started if session is required to have a moderator before users are let in. Once session is running, attendants are redirected.

Due to D7 JS API change automated this js-code is broken and BBB api call was also directed to api-[API].bbb.inc -file, which did not exist.

Both issues are fixed here and now JS code works.

Comments

rpsu’s picture

Status: Active » Needs review
StatusFileSize
new1.19 KB

patch file.

rpsu’s picture

Assigned: rpsu » Unassigned
Chipie’s picture

Status: Needs review » Needs work

Thank you for your patch.

I have applied your patch, but the attendee is not redirected, when the session is redirected. Any ideas?

Chipie’s picture

Status: Needs work » Needs review
StatusFileSize
new1.45 KB

I have wrapped the js script with


(function($) {
...
})(jQuery);

in order to have a high compatibility with other javascript libraries.

Chipie’s picture

Status: Needs review » Closed (fixed)

deployed to latest dev.

jvieille’s picture

This never worked for me (using D6)
I decided to tackle this issue and finally got it working

The script in D6 is wrapped in (function($) { .. })(jQuery); in the current dev (the D6 beta release does not work at all).
This does not seem to work for D6, probably only for D7.
I reverted back the js file to the original one and modified the "is_running" veriable by "running".

So in D6, replace in check_status.bbb.js

(function($) {
    Drupal.behaviors.bbbCheckStatus = {
        attach : function(context, settings) {
            Drupal.bbbCheckStatus();
            setInterval("Drupal.bbbCheckStatus();", 5000);
        }
    };
    Drupal.bbbCheckStatus = function() {
        var url = bbb_check_status_url;
        $.getJSON(url, function(data) {
            console.log(data);
            if (data.running == true) {
                location.href = location.href + '/meeting/attend';
            }
        });
    };
})(jQuery);

by

//$Id: check_status.bbb.js,v 1.1.2.1 2010/03/15 16:55:31 sanduhrs Exp $
Drupal.behaviors.bbbCheckStatusInit = function () {
  Drupal.bbbCheckStatus();
  setInterval("Drupal.bbbCheckStatus();", 5000);
}

Drupal.bbbCheckStatus = function () {
  var url = bbb_check_status_url;
  $.getJSON(url, function(data) {
    console.log(data);
    if (data.running == true) {
      location.href = location.href + '/meeting/attend';
    }
  });
}

Hope this helps

amstel’s picture

Version: 7.x-1.x-dev » 6.x-1.x-dev
Issue summary: View changes

#6 worked for me as well in latest Drupal 6 dev version. Thanks!