summaryrefslogtreecommitdiff
path: root/app/views/users
diff options
context:
space:
mode:
authorStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-02-27 12:22:29 +0100
committerStefan Wintermeyer <stefan.wintermeyer@amooma.de>2013-02-27 12:22:29 +0100
commit67c1a0a951403a546250ea860a3e3d199cae2fce (patch)
treef86ec6cedf081a1a57005eca1661e9bead34e4de /app/views/users
parent5d8ce5f4775ac8bc5f523964e6e36f63ff3c4683 (diff)
parent211f558a86ae30cdd5b392ab1376e1393f97e22c (diff)
Merge branch 'develop'5.1-beta6
Diffstat (limited to 'app/views/users')
-rw-r--r--app/views/users/show.html.haml20
1 files changed, 14 insertions, 6 deletions
diff --git a/app/views/users/show.html.haml b/app/views/users/show.html.haml
index 0f6cc2c..8148005 100644
--- a/app/views/users/show.html.haml
+++ b/app/views/users/show.html.haml
@@ -29,22 +29,30 @@
= render :partial => 'shared/show_edit_destroy_part', :locals => { :parent => @tenant, :child => @user }
- @user.sip_accounts.each do |sip_account|
- - phone_number = sip_account.phone_numbers.order(:number).last
- - if phone_number && !phone_number.number.blank? && phone_number.number[0] != '+'
- %p
- %strong= sip_account.phone_numbers.order(:number).last.number
+ - phone_numbers = sip_account.phone_numbers.order(:position)
+ %p
+ - if phone_numbers[0]
+ %strong= phone_numbers[0].number
+ - else
+ %strong= sip_account.to_s
+ - if phone_numbers[1]
+ %strong= phone_numbers[1].number
+ - if phone_numbers[2]
+ %strong= phone_numbers[2].number
+ - if phone_numbers[3]
+ %strong ...
%p
=link_to t("call_histories.index.page_title"), sip_account_call_histories_path(sip_account)
%br
=link_to t("voicemail_messages.index.page_title"), sip_account_voicemail_messages_path(sip_account)
%br
- =link_to t("call_forwards.index.page_title"), phone_number_call_forwards_path(phone_number)
+ =link_to t("call_forwards.index.page_title"), sip_account_call_forwards_path(sip_account)
%br
=link_to t("voicemail_settings.index.page_title"), sip_account_voicemail_settings_path(sip_account)
%br
=link_to t("softkeys.index.page_title"), sip_account_softkeys_path(sip_account)
%br
- =link_to t("ringtones.show.page_title"), phone_number_ringtones_path(phone_number)
+ =link_to t("ringtones.show.page_title"), sip_account_ringtones_path(sip_account)
- if @user.conferences.any?
%p