summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorPeter Kozak <spag@golwen.net>2013-06-27 14:13:35 +0200
committerPeter Kozak <spag@golwen.net>2013-06-27 14:13:35 +0200
commitce6407538090b2f67a5c131f7d12253d1c02f860 (patch)
tree5bbf47efc274ddf1ce62db4f21b8a947c561a602 /app
parenta5916697ce2ab1f74833d19a36dbb0f71c7ed7f5 (diff)
parent29213546a4468aa4a853dee8091bbd556f7d0f51 (diff)
Merge branch 'develop' of github.com:amooma/GS5 into develop
Diffstat (limited to 'app')
-rw-r--r--app/serializers/switchboard_serializer.rb2
-rw-r--r--app/views/switchboards/show.html.erb5
2 files changed, 5 insertions, 2 deletions
diff --git a/app/serializers/switchboard_serializer.rb b/app/serializers/switchboard_serializer.rb
index c1cc0fe..7ad7792 100644
--- a/app/serializers/switchboard_serializer.rb
+++ b/app/serializers/switchboard_serializer.rb
@@ -1,7 +1,7 @@
class SwitchboardSerializer < ActiveModel::Serializer
embed :ids, :include => true
- attributes :id, :name, :blind_transfer_activated, :attended_transfer_activated
+ attributes :id, :name, :show_avatars, :blind_transfer_activated, :attended_transfer_activated
has_many :switchboard_entries
has_many :sip_accounts, :through => :switchboard_entries
has_many :phone_numbers
diff --git a/app/views/switchboards/show.html.erb b/app/views/switchboards/show.html.erb
index 61adde7..3bc4da4 100644
--- a/app/views/switchboards/show.html.erb
+++ b/app/views/switchboards/show.html.erb
@@ -26,12 +26,15 @@
{{/each}}
{{/if}}
+
{{#if switchboardEntrys.length}}
<ul class="thumbnails">
{{#each switchboardEntry in switchboardEntrys}}
<li class="span2">
<div class="thumbnail">
- {{avatar_img switchboardEntry.avatar_src}}
+ {{#if switchboardEntry.switchboard.show_avatars}}
+ {{avatar_img switchboardEntry.avatar_src}}
+ {{/if}}
<small>
<p></p>
{{#if switchboardEntry.name}}