From bc4e559c08616de312906903a1c89eb74d09ffd7 Mon Sep 17 00:00:00 2001 From: Stefan Wintermeyer Date: Sat, 22 Dec 2012 12:32:36 +0100 Subject: GUI improvement for new acd agents. --- app/controllers/acd_agents_controller.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'app/controllers') diff --git a/app/controllers/acd_agents_controller.rb b/app/controllers/acd_agents_controller.rb index 1d119b3..4c08f68 100644 --- a/app/controllers/acd_agents_controller.rb +++ b/app/controllers/acd_agents_controller.rb @@ -28,6 +28,8 @@ class AcdAgentsController < ApplicationController @acd_agent.name = "#{t('acd_agents.name')} #{i}" @acd_agent.status = 'active' @acd_agent.calls_answered = 0 + + @available_sip_accounts = SipAccount.all - @automatic_call_distributor.acd_agents.where(:destination_type => 'SipAccount').map{|acd_agent| acd_agent.destination} end def create @@ -41,6 +43,8 @@ class AcdAgentsController < ApplicationController def edit @acd_agent = AcdAgent.find(params[:id]) + + @available_sip_accounts = SipAccount.all end def update -- cgit v1.2.3