- content_for :title, t("sip_accounts.show.page_title") %table.table.table-striped %tbody %tr %td %strong= t('sip_accounts.show.caller_name') + ":" %td = @sip_account.caller_name %tr %td %strong= t('sip_accounts.show.auth_name') + ":" %td = @sip_account.auth_name %tr %td %strong= t('sip_accounts.show.password') + ":" %td = @sip_account.password %tr %td %strong= t('sip_accounts.show.call_waiting') + ":" %td = @sip_account.call_waiting == true ? t('simple_form.yes') : t('simple_form.no') %tr %td %strong= t('sip_accounts.show.clir') + ":" %td = @sip_account.clir == true ? t('simple_form.yes') : t('simple_form.no') %tr %td %strong= t('sip_accounts.show.clip_no_screening') + ":" %td = @sip_account.clip_no_screening %tr %td %strong= t('sip_accounts.show.hotdeskable') + ":" %td = @sip_account.hotdeskable == true ? t('simple_form.yes') : t('simple_form.no') - if @sip_account.registration.try(:network_ip) && @sip_account.registration.try(:network_port) %tr %td %strong= t('sip_accounts.show.registration') + ":" %td = "#{@sip_account.registration.network_ip}:#{@sip_account.registration.network_port}" - if @sip_account.registration.try(:expires) %tr %td %strong= t('sip_accounts.show.expires') + ":" %td = "#{@sip_account.registration.try(:expires) - Time.now.to_i} s" - if @sip_account.registration.try(:user_agent) %tr %td %strong= t('sip_accounts.show.user_agent') + ":" %td = @sip_account.registration.try(:user_agent) = render :partial => 'shared/show_edit_destroy_part', :locals => { :parent => @sip_account.sip_accountable, :child => @sip_account } - if @register_protocols.count > 0 %p %strong= t('sip_accounts.show.call_protocols') + ':' %p - @register_protocols.each do |protocol, url| %a.btn.btn-small.btn-default{ :href => '', :onclick => "navigator.registerProtocolHandler(\"#{protocol}\", \"#{url}\", \"#{@sip_account.to_s}\");" } %i.icon-plus = t("sip_accounts.show.register_#{protocol}_protocol") %p %strong= t('ringtones.name') + ':' - if @sip_account.ringtones.count > 0 = @sip_account.ringtones.first = render :partial => 'shared/show_edit_destroy_part', :locals => { :parent => @sip_account, :child => @sip_account.ringtones.first } - else = render :partial => 'shared/create_link', :locals => { :parent => @sip_account, :child_class => Ringtone } - if @sip_account.phone_numbers.count > 0 || can?(:create, @sip_account.phone_numbers.build) %h2= t('phone_numbers.index.page_title') - if @sip_account.phone_numbers.count > 0 = render "phone_numbers/index_core", :phone_numbers => @sip_account.phone_numbers %br = render :partial => 'shared/create_link', :locals => { :parent => @sip_account, :child_class => PhoneNumber } - if @sip_account.call_forwards.count > 0 || can?(:create, @sip_account.call_forwards.build) %h2= t('call_forwards.index.page_title') - if @sip_account.call_forwards.count > 0 = render "call_forwards/index_core", :call_forwards => @sip_account.call_forwards %br = render :partial => 'shared/create_link', :locals => { :parent => @sip_account, :child_class => CallForward } - if @sip_account.softkeys.count > 0 || can?(:create, @sip_account.softkeys.build) %h2= t("softkeys.index.page_title") - if @sip_account.softkeys.count > 0 = render "softkeys/index_core", :softkeys => @sip_account.softkeys %br = render :partial => 'shared/create_link', :locals => { :parent => @sip_account, :child_class => Softkey } - if @sip_account.calls.count > 0 %h2= t("calls.index.page_title") = render "calls/index_core", :calls => @sip_account.calls, :parent => @sip_account - if (can?(:read, AcdAgent) && @sip_account.acd_agents.count > 0) || can?(:create, @sip_account.acd_agents.build) %h2= t('acd_agents.index.page_title') - if @sip_account.acd_agents.count > 0 = render "acd_agents/index_core", :acd_agents => @sip_account.acd_agents %br = render :partial => 'shared/create_link', :locals => { :parent => @sip_account, :child_class => AcdAgent }