Commit 2c492707baf00d95bf2e5432109d779f335d169a
1 parent
d59d6ea6
Exists in
master
and in
29 other branches
ActionItem489: check if profile is a person
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@2125 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
1 changed file
with
10 additions
and
8 deletions
Show diff stats
app/views/blocks/profile_info.rhtml
@@ -23,14 +23,16 @@ | @@ -23,14 +23,16 @@ | ||
23 | <% end %> | 23 | <% end %> |
24 | </ul> | 24 | </ul> |
25 | 25 | ||
26 | -<div class="adr"> | ||
27 | -<%= | ||
28 | - [ [ profile.city, 'locality' ], | ||
29 | - [ profile.state, 'region' ], | ||
30 | - [ profile.country, 'country-name' ] | ||
31 | - ].map{ |s,c| s =~ /^\s*$/ ? nil : content_tag( 'span', s, :class => c ) }.compact.join ' - ' | ||
32 | -%> | ||
33 | -</div> | 26 | +<% if block.owner.person? %> |
27 | + <div class="adr"> | ||
28 | + <%= | ||
29 | + [ [ profile.city, 'locality' ], | ||
30 | + [ profile.state, 'region' ], | ||
31 | + [ profile.country, 'country-name' ] | ||
32 | + ].map{ |s,c| s =~ /^\s*$/ ? nil : content_tag( 'span', s, :class => c ) }.compact.join ' - ' | ||
33 | + %> | ||
34 | + </div> | ||
35 | +<% end %> | ||
34 | 36 | ||
35 | <div class="profile-info-options"> | 37 | <div class="profile-info-options"> |
36 | <%= render :file => 'blocks/profile_info_actions/' + block.owner.class.name.underscore %> | 38 | <%= render :file => 'blocks/profile_info_actions/' + block.owner.class.name.underscore %> |