one meeting per room

This commit is contained in:
Josh
2018-05-14 14:28:18 -04:00
parent 0f8a4734b2
commit 1ddc3172eb
13 changed files with 126 additions and 149 deletions

View File

@ -1,29 +0,0 @@
$(document).on("turbolinks:load", function() {
var action = $("body").data('action');
var controller = $("body").data('controller');
// If the user is on the waiting screen.
if (controller == 'meetings' && action == 'wait') {
setTimeout(refresh, 10000);
}
});
// Send a request to the meeting wait endpoint.
// This checks if the meeting is running on the
// server and will auto join the user if it is.
var refresh = function() {
$.ajax({
url: window.location.pathname,
type: 'POST',
data: {
unauthenticated_join_name: $('#unauthenticated_join_name_').val()
},
headers: {
'Content-Type': 'application/x-www-form-urlencoded'
}
});
setTimeout(refresh, 10000);
}

View File

@ -1,3 +0,0 @@
# Place all the behaviors and hooks related to the matching controller here.
# All this logic will automatically be available in application.js.
# You can use CoffeeScript in this file: http://coffeescript.org/

View File

@ -0,0 +1,27 @@
$(document).on("turbolinks:load", function() {
var action = $("body").data('action');
var controller = $("body").data('controller');
// If the user is on the waiting screen.
if (controller == 'rooms' && action == 'wait') {
setTimeout(refresh, 10000);
}
});
// Send a request to the meeting wait endpoint.
// This checks if the meeting is running on the
// server and will auto join the user if it is.
var refresh = function() {
$.ajax({
url: window.location.pathname,
type: 'POST',
data: {
unauthenticated_join_name: $('#unauthenticated_join_name_').val()
},
headers: {
'Content-Type': 'application/x-www-form-urlencoded'
}
});
setTimeout(refresh, 10000);
}