New Bounty for Ethan on 57i's. Queue Login / Logout App
I just proposed a new app for Ethan:
Right now queue login and logouts are a pain in the rear. I'd like to see an app like the meetme or parking app:
You hit the button, see avaialable queues, your status on them. You can scroll and choose a queue to login or logout of.
Anyone want to help out with a contribution? I'm in for $500 (and bragging rights for thinking of it. Maybe I can get some free hours out of TB support from Chris)
-Darren
I would certainly love the opportunity to take a look at developing this. There is also the call screening functionality for FreePBX is done and only has $350 in bounties left:
http://trixbox.org/forums/trixbox-forums/trixbox-projects/call-sc...
I have completed this and given it to Darren for review. It turned out to be quite a bit more difficult than I anticipated. I'm looking for some of you queue users to step up and contribute to the bounty. I'm hoping to get another $250, but hopefully $500.
Here's how the application works:
Push the Queues button and receive a list of the queues on your system showing realtime stats (callers in queue, hold time, abandoned).
Choose a queue and it allows you to enter your agent number (which can also be defined statically in the configuration URL).
Once it knows your agent number, it queries the queue to see if that agent is logged in. If logged in, the agent can log out. If not logged in, the agent can login. If the queue has a password it will require the agent to enter the password.
All of this is done through the phone interface, requiring no DTMF interaction.
Per the initial specs, it works on the Aastra 5i series, however I can make it work on the 9133i/9143i and 480i phones. Those compatibilities will be included for the total bounty of $1,000 ($500 more). What more could you ask for? A super queue application that works on an entry level $120 handset....perfect for the large call center you just sold or are attempting to sell right now.
Ethan
You Rock man how cool are you at doing this XML stuff. Wen my comany makes more money that I can afford. I will send you some money to help in any one you like. I hope by the end of July to August to be out of the RED. /clap /clap
Michael
PS ehtans read you mail I asked you a few questions on the upcomming training program at digium.
There has been some progress on this application. After not getting paid the initial bounty after spending gobs of time on this thing, someone finally came along and contributed towards the work. Despite never receiving the initially promised bounty, the bounty is now partially met. Four more $100 bounties, two more $200 bounties or one $400 bounties and it will be released.
I have made significant improvements to the application. It now supports agents.conf configurations of queues for a.) agent-queue associations and permissions and b.) individual agent passwords. It also supports the standard queue setup with a global queue password (or not). The most interesting enhancement is the ability for an agent to pause themselves. This way, your agents can have the extra time they may need to finish updating a customer record in the CRM or go to the bathroom or whatever without actually logging out of the queue. The button also lights the LED when an agent is logged into a queue.
Lastly, I have created screenshots of the app. They are available at http://www.schmoozecom.com/queues_button.html. The screenshots are of a 57i, however the application is fully functional (minus queue statistics and led indication) on the 9133i.
Thanks to the bounties contributed, this application is now available for the community.
Download and Installation:
cd /var/www/html/aastra/asterisk
wget http://public.schmoozecom.com/queues.php.tar.gz
tar -xzvf queues.php.tar.gz
Button Setup:
Dynamic Agent (agent must enter their agent number each time):
Add an XML button with a value of http://<server>/aastra/asterisk/queues.php?key=<key>
Replace <server> with your IP and <key> with the key you are configuring (for example, softkey1, prgkey2, or topsoftkey3).
Static Agent (one agent per phone):
Add an XML button with a value of http://<server>/aastra/asterisk/queues.php?agent=$$SIPUSERNAME&key=<key>
Replace <server> with your IP and <key> with the key you are configuring (for example, softkey1, prgkey2, or topsoftkey3).
Queues Utilizing agents.conf Configuration:
Please note that according to Philippe, the FreePBX project lead, this is an unsupported configuration of FreePBX and may lead to problems with transferring and other issues. Only use the agents.conf configuration if you know what you are doing.
If you utilize agents.conf to define queue memebers and configure FreePBX with A1001 where 1001 is the member, you need to put the script in a special mode so a.) agents are restricted to the queues they are configured to be a member of and b.) agents are authenticated with their individual credentials in the agents.conf configuration versus any global queue password you may have setup in FreePBX.
To switch the script into agents.conf mode, change line 51 to read $agents_conf = true;
If you experience any general problems or problems with specific models of Aastra phones, please report back. This application should theoretically work on almost any Aastra model being tested on the 55i, 57i and 9133i models.
Note:
This application is tested working on the aastra-xml-scripts package version 2.0.0 and the latest 2.1.1. It may not work with earlier versions of the aastra-xml-scripts package.
It would probably work on pro with some effort since it uses asterisk manager commands which should be portable to any asterisk based distribution. The problem is there isn't a very large pro base so the bounty system wouldn't really work. It is something I could only approach hourly which could get expensive depending on unknowns.
I hate being the first person not getting it to work. I followed the instructions and checked the logs. The php file is requested from the server. Then i get "Cannot display" on the phonedisplay.
So i made a look to see if all the include files was requested. But i can't find the file DB.php? Im running Trixbox 2.6.1.13 and Aastra xml script 2.1.1. I don't know if this file is dropped, missing, or should be included with the script?
Regards
Chris
*EDIT* My bad about the DB.php, but i still don't get it working *EDIT*
There must be something missing or something I'm not doing correctly. I have been trying to evaluate this on my test server and am unable to get it to work:
Environment: PIAF 1.3 (Asterisk 1.4.21.2 / FreePBX 2.5)
aastra-xml-scripts-2.1.1-1.noarch.rpm
Test Phones: 55i and 57i (firmware 2.3.1)
I have checked all file permissions. (Asterisk is owner and execute permissions are in place). When I hit the "Queues" button on either 55i or 57i nothing happens. I have tried tailing /var/log/httpd/access_log and /var/log/httpd/error_log. When the button is pushed nothing is logged (any other button push produces logging). The same with /var/log/asterisk/full.
I have setup one test queue with one static agent and verified that it works. (Queue 2100 Queue Name = Sales)
softkey8 type: xml softkey8 label: Queues softkey8 values: http://x.x.x.x:80/aastra/asterisk/queues.php?agent=$$SIPUSERNAME$$&key=softkey8 softkey8 states: idle connected
Ok thought I'd answer my own post in case someone else runs into this:
I have had this same problem with the following phones: 480i, 9143i, 55i and 57i
When I push the button nothing happens (nothing in the httpd logs or asterisk logs) -- Clue #1
I have verified the mac.cfg of each file as shown above. Now when I go into the web interface of the phone I see the problem. Underneath the "Softkeys Configuration" you have the following Columns:
KEY TYPE LABEL VALUE
Well on the phones there is nothing listed for my "Queues" button's value in the web interface.
It should have:
http://x.x.x.x:80/aastra/asterisk/queues.php?agent=$$SIPUSERNAME$$&key=softkey8
When I manually place this in the web interface..... Presto!!! The queue button works as it should. So I do not understand why it will not accept the new settings from either the XML auto provisioning or from manually editing the corresponding "mac.cfg" file in /tftpboot . Seems to be a bug somewhere.
Can you post the relevant parts of your mac.cfg? I have it working in an auto-provisioning setup. Usually when I see mac.cfg button configurations not working it is because the button identifier is not configured properly. For instance, the 57i top buttons are referenced as topsoftkey1, 2, 3, etc while the 55i's are referenced as prgkey1, 2, 3, etc. The 9133 buttons are all prgkey1, 2, etc. The 55i and 57i bottom buttons are referenced as softkey1, 2, 3, etc.
So the following works for my 55i and 57i:
softkey9 label: Queues softkey9 value: http://10.x.x.x/aastra/asterisk/queues.php?agent=$$SIPUSERNAME$$&key=softkey9 softkey9 states: idle
Also, and this is completely irrelevant to the discussion of provisioning, but I want to point out that you can configure the button with agent=$$SIPUSERNAME or you can leave this part out and agents will be forced to enter their Agent ID. Because of this flexibility, if you have a call center that has shift workers sharing phones, you can support dynamic agents logging into those phones.
Here is one from a 55i
sip line1 auth name: 304 sip line1 password: xxxxxxxxx sip line1 user name: 304 sip line1 display name: Test Account sip line1 screen name: Test Account sip line1 proxy ip: 10.0.0.200 sip line1 proxy port: 5060 sip line1 registrar ip: 10.0.0.200 sip line1 registrar port: 5060 sip line1 vmail: *97 sip line1 mode: 0 action uri startup: action uri incoming: http://10.0.0.200:80/aastra/asterisk/incoming.php?number=$$REMOTENUMBER$$&name=$$INCOMINGNAME$$&user=$$SIPUSERNAME$$ sip xml notify event: 1 action uri xml sip notify: http://10.0.0.200:80/aastra/asterisk/sync.php?action=check&user=$$SIPUSERNAME$$ xml application URI: <a href="http://10.0.0.200:80/aastra/menu/mymenu.php?menu_source=menu1&menu_user=304&user=304" title="http://10.0.0.200:80/aastra/menu/mymenu.php?menu_source=menu1&menu_user=304&user=304">http://10.0.0.200:80/aastra/menu/mymenu.php?menu_source=menu1&men...</a> xml application title: Applications xml get timeout: 30 sip allow auto answer: 1 sip intercom mute mic: 0 time zone name: US-Central time zone code: CST directed call pickup: 1 directed call pickup prefix: ** auto offhook: 1 sip line1 screen name 2: Ext. 304 action uri registered: http://10.0.0.200:80/aastra/asterisk/sync.php?action=register&user=$$SIPUSERNAME$$ action uri onhook: http://10.0.0.200:80/aastra/asterisk/onhook.php?number=$$REMOTENUMBER$$&name=$$INCOMINGNAME$$&user=$$SIPUSERNAME$$ action uri poll: http://10.0.0.200:80/aastra/asterisk/sync.php?action=check&user=$$SIPUSERNAME$$ action uri poll interval: 1800 sip intercom type: 2 sip intercom prefix code: *80 sip intercom line: 1 prgkey1 type: xml prgkey1 label: Night Mode prgkey1 value: http://10.0.0.200:80/aastra/asterisk/daynight.php?user=$$SIPUSERNAME$$&key=prgkey1&daynight_index=1 prgkey2 type: icom prgkey2 label: Intercom prgkey3 type: speeddial prgkey3 label: Tr VMail prgkey3 value: *+ prgkey3 line: 5 prgkey4 type: callers prgkey4 label: Callers prgkey5 type: speeddial prgkey5 label: Call Park prgkey5 value: "##70#" prgkey5 line: 5 prgkey6 type: xml prgkey6 label: Groups prgkey6 value: http://10.0.0.200:80/aastra/asterisk/groups.php?user=$$SIPUSERNAME$$ softkey1 type: xml softkey1 label: DND softkey1 value: http://10.0.0.200:80/aastra/asterisk/dnd.php?user=$$SIPUSERNAME$$ softkey1 states: idle softkey2 type: xml softkey2 label: Call Fwd softkey2 value: http://10.0.0.200:80/aastra/asterisk/cfwd.php?user=$$SIPUSERNAME$$ softkey2 states: idle softkey3 type: xml softkey3 label: Voice Mail softkey3 value: http://10.0.0.200:80/aastra/asterisk/vmail.php?ext=$$SIPUSERNAME$$ softkey3 states: idle softkey4 type: xml softkey4 label: Parkd Call softkey4 value: <a href="http://10.0.0.200:80/aastra/asterisk/park.php" title="http://10.0.0.200:80/aastra/asterisk/park.php">http://10.0.0.200:80/aastra/asterisk/park.php</a> softkey4 states: idle softkey5 type: xml softkey5 label: Away softkey5 value: http://10.0.0.200:80/aastra/asterisk/away.php?user=$$SIPUSERNAME$$&key=softkey5 softkey6 type: xml softkey6 label: Directory softkey6 value: <a href="http://10.0.0.200:80/aastra/asterisk/directory.php" title="http://10.0.0.200:80/aastra/asterisk/directory.php">http://10.0.0.200:80/aastra/asterisk/directory.php</a> softkey6 states: idle connected softkey7 type: xml softkey7 label: Speed Dial softkey7 value: <a href="http://10.0.0.200:80/aastra/directory/speed.php" title="http://10.0.0.200:80/aastra/directory/speed.php">http://10.0.0.200:80/aastra/directory/speed.php</a> softkey7 states: idle connected softkey8 type: xml softkey8 label: Queues softkey8 values: http://10.0.0.200:80/aastra/asterisk/queues.php?agent=$$SIPUSERNAME$$&key=softkey8 softkey8 states: idle softkey9 type: xml softkey9 label: Meet-me softkey9 value: http://10.0.0.200:80/aastra/asterisk/meetme.php?ext=$$SIPUSERNAME$$ softkey9 states: idle connected softkey10 type: xml softkey10 label: Music softkey10 value: http://10.0.0.200:80/aastra/asterisk/music.php?user=$$SIPUSERNAME$$ softkey10 states: idle softkey11 type: services softkey11 label: Services softkey20 type: xml softkey20 label: Logout softkey20 value: http://10.0.0.200:80/aastra/asterisk/logout.php?user=$$SIPUSERNAME$$ softkey20 states: idle
Not sure why the "href's" show up above as they are not in the original that I copied from.
Thanks,
Will
Everything looks right.
Try this: copy a URL line from one of the buttons you know works and paste it to replace the url for the queues, then make sure to change it to queues.php and drop in the agent and key variables. For some reason, I've seen in the past where hidden characters can do crazy things like this. In fact I just saw it 10 minutes ago and as soon as I copy/pasted from a working park of the config and rebooted the phone it worked fine.
I'm starting to think there are a few problems with the latest firmware and XML scripts.... I can reproduce this problem on both Trixbox and PIAF platforms.... Anytime that I use this key and map it to "softkey8" nothing happens and the URL fails to map if you view it from the web interface. It seems to be centered around "softkey8" as I changed the order of the Meet-Me key from softkey9 to softkey8 and vice versa with the Queues button.
Now queues mapped to softkey9 work fine, however "Meet-Me" mapped to softkey8 does nothing. I'm not sure if the "context" problem seen in other threads is part of the issue, but suppose it is possible.
***Update***
Ok turns out I had a spelling error in my button layout. The last section I had spelled "values" instead of "value"
softkey8 values: (wrong)
softkey8 value: (correct)
Sometimes it is the simplest of things that will make us rack our brains.....
Did you get my logs Ethan? I'll sent you a PM. I'll post them here again.
access_log
192.168.1.8 - - [29/Oct/2008:15:10:03 +0100] "GET /aastra/asterisk/queues.php?agent=600&key=topsoftkey7 HTTP/1.0" 200 - "-" "Aastra57i MAC:00-08-5D-1A-98-84 V:2.3.1.26-SIP"
error_log
It's empty.. Nothing regarding the button press.
Im using xml-script 2.1.1 and Aastra 57i phones with expansionboards
I'll post my Aastra config for that buttons as well
topsoftkey7 label: Queues
topsoftkey7 value: http://192.168.1.2:80/aastra/asterisk/queues.php?agent=$$SIPUSERNAME$$&key=topsoftkey7
topsoftkey7 type: xml
topsoftkey7 states: idle connected
This is what i get when i run the script from PHP
[trixbox1.localdomain asterisk]# php queues.php?agent=600&key=topsoftkey7
[2] 6852
[1] Exit 127 queues.php?agent=600
[trixbox1.localdomain asterisk]# Could not open input file: queues.php?agent=600
From a browser it's just blank.
When I only run the queue.php it doesn't display or do anything. I can set you up with a temp account Ethan but I rather not waste your time. I'll do a little more digging (the only way i can learn) and if get totaly stuck in the mud you are welcome to give a helping hand.


Member Since:
2007-02-14