summaryrefslogtreecommitdiff
path: root/app/controllers
diff options
context:
space:
mode:
authorPeter Kozak <spag@golwen.net>2013-03-27 10:34:21 +0100
committerPeter Kozak <spag@golwen.net>2013-03-27 10:34:21 +0100
commit09f6490dc92d9685afa5f77563ea8c230c450211 (patch)
tree82679dc0ceaa28997a80b188717b1ff59a483b67 /app/controllers
parent3a20974d9403877ffa9a720efd999df49a1733bf (diff)
subscribe to default voicemail account
Diffstat (limited to 'app/controllers')
-rw-r--r--app/controllers/config_snom_controller.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/app/controllers/config_snom_controller.rb b/app/controllers/config_snom_controller.rb
index 8db1d57..b692693 100644
--- a/app/controllers/config_snom_controller.rb
+++ b/app/controllers/config_snom_controller.rb
@@ -260,9 +260,13 @@ class ConfigSnomController < ApplicationController
:name => sip_account.auth_name,
:realname => 'Call',
:idle_text => sip_account.caller_name,
- :mailbox => "<sip:#{sip_account.auth_name}@#{sip_account.host}>",
:expiry => expiry_seconds,
}
+
+ if sip_account.voicemail_account
+ snom_sip_account[:mailbox] = "<sip:#{sip_account.voicemail_account.name}@#{sip_account.host}>"
+ end
+
@sip_accounts.push(snom_sip_account)
sip_account_index = @sip_accounts.length
sip_account.softkeys.order(:position).each do |softkey|