-
Notifications
You must be signed in to change notification settings - Fork 341
Conference Call - List Calls, Join and Listen #346
base: master
Are you sure you want to change the base?
Conversation
The conference call applet now has the ability to optionally record a call when setting up the flow.
1. The standard conference call plugin now has a "Conference Calls" menu under the "Call Log" parent menu. 2. The conference calls page show you a list of all active conference calls plus gives you the option to Join or Listen to the call. The list is updated every 5 seconds and will add and remove entries. 3. Join Call - Clicking "Join" will immedately connect you to the call via your web browser, it beep when you enter or leave and let you full listen and talk on the call. 4. Listen - Clicking "Listen" will immedately connect you to the call viaw your web browser, it will not beep as you enter or leave and auto mute your voice so that you'll never be heard on the call. -- Note: Clicking Mute/Unmute will effectively do nothing if you clicked the listen link.
* @param string $beep | ||
* @return void | ||
*/ | ||
protected function join_conference($conference_name,$muted,$beep) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit pick: spaces after commas.
1. Changed upper case NULL to lower. 2. Added spaces after function parameter names. 3. Using the shared object OpenVBX::getAccount() instead of some other way. 4. Added the json content type header. 5. Changed die to exit. 6. Wrapped the jquery functions inside of jQuery(function($) {}; 7. Fixed some tabbing issues in the plugin.json file.
1. Moved all the javascript to its own conferences.js file. 2. Wrapped the javascript in a document.ready function like the script.js file in dial plugin. 3. Removed the jquery include. 4. Added the conferences.js file via a php include function.
1. Made the print of the conference call rows a little more readable. 2. Added thead and tbody like the usage plugin.
row += '<td>' + call.date_created + '</td>'; | ||
row += '<td>' + call.friendly_name + '</td>'; | ||
row += '<td>' + call.status + '</td>'; | ||
row += '<td><a onclick="join_call(\'' + call.friendly_name + '\');">Join</a></td>'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd still like all JS actions to be handled via listeners. We only really use onclick
for window.open
and I'd even like to go through and nuke all of those too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reason I didn't use $('#calls').on('click', '.listen', function(e) ... is because the version of jquery the project is using doesn't support the .on function. As best I can tell the project is using jquery v1.6.2 and the .on function wasn't added to jquery until v1.7. Version 1.7 was only released a few months after 1.6.2 so possibly upgrading jquery wouldn't be a breaking change. Let me know how you want to proceed.
I think my last suggestion is to move the conference page to a new folder in the standard plugin folder. Put it under {
"links": [{
"menu": "Logs",
"url": "logs/conferences",
"script": "pages/conference/conference-calls.php",
"label": "Conference Calls"
}],
} Though... its not really a log page because its really an active management page. So maybe the Thoughts? |
1. Moved the conference-calls.php and conferences.js to a new folder named pages. 2. Updated the plugin.json file to reflect the file moves plus changed the menu, url and label. 3. Renamed conference-calls.php to conferences.php. 4. Removed the usage of onclick from the conference.js page and changed it use a jquery click listener.
I believe I'm made all the changes you've requested. Let me know if you find anything else. |
|
||
$(document).ready(function(){ | ||
jQuery(function($) { | ||
$(function(){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Heh, just noticed this, but $(document).ready(function() {});
, jQuery(function($) {});
and $(function() {});
all do the same thing... so we've got 3 levels of code all waiting for DOMReady. Fortunately jQuery is smart enough to automatically fire event listeners for DOMReady if they're registered after the DOM is ready.
I've been going back and forth about including the manager page in OpenVBX core. Let me know what you think of this idea: I'll take all the changes made to existing OpenVBX files. Then you move the conference manager page to a stand alone plugin that gets included on http://www.openvbx.org/plugins/ This is cleaner to me for a couple of reasons:
|
I like your suggestion and I'm find to create a stand alone plugin if you pull in the changes to the core OpenVBX files. |
👍 this is a common enough usecase for conference calls that it should be part of the core. |
Yes @cromulus that's what I thought too. But I did understand @Gipetto concerns and if they'll add the basic conference calling features to the core application I can easily make this a standalone plugin. I guess I should really just open another PR with the dozen or so code changes to |
This new features gives the standard conference call plugin a new menu under the "Call Log" section which allows a user to see a list of all conference calls in-progress and gives the option to join or listen to the call. When the user clicks Join the browser client immediately connects them to the call, announces their entrance and exit with a beep and allows them to listen and speak. When the user chooses the Listen option their browser client immediately connects them to the call but does not announce their entry or exit and only allows the user to listen to the call.