diff options
author | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-03-12 11:23:57 +0100 |
---|---|---|
committer | Stefan Wintermeyer <stefan.wintermeyer@amooma.de> | 2013-03-12 11:23:57 +0100 |
commit | b16aeeccff8de5fd579d79a48740df7a3e34e7bc (patch) | |
tree | bb2ddcb29c6a465d73a3010437bdd076d11360c9 /app/controllers/config_snom_controller.rb | |
parent | 3c5a0511d228fb3dc00ae860ade1b8ff032cc42f (diff) | |
parent | 40b2feb99d75074319f371087c521df198527266 (diff) |
Merge branch 'develop' of github.com:amooma/GS5 into develop
Diffstat (limited to 'app/controllers/config_snom_controller.rb')
-rw-r--r-- | app/controllers/config_snom_controller.rb | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/app/controllers/config_snom_controller.rb b/app/controllers/config_snom_controller.rb index eb94038..ae58ab8 100644 --- a/app/controllers/config_snom_controller.rb +++ b/app/controllers/config_snom_controller.rb @@ -281,7 +281,30 @@ class ConfigSnomController < ApplicationController when 'log_in' @softkeys.push({:context => sip_account_index, :label => softkey.label, :data => "speed f-li-#{softkey.number}"}) when 'conference' - @softkeys.push({:context => sip_account_index, :label => softkey.label, :data => "blf <sip:#{softkey.number}@#{sip_account.host}>|f-ta-"}) + conference = softkey.softkeyable + if conference.class == Conference + @softkeys.push({ + :context => sip_account_index, + :function => softkey.softkey_function.name, + :label => softkey.label, + :softkey => softkey, + :general_type => t("softkeys.functions.#{softkey.softkey_function.name}"), + :subscription => { + :to => "sip:conference#{conference.id}@#{sip_account.host}", + :for => "sip:conference#{conference.id}@#{sip_account.host}", + }, + :actions => [{ + :type => :dial, + :target => "f-ta-#{softkey.number}", + :when => 'on press', + :states => 'connected,holding', + },{ + :type => :dial, + :target => softkey.number, + :when => 'on press', + }], + }) + end when 'parking_stall' parking_stall = softkey.softkeyable if parking_stall.class == ParkingStall |