Commit ee96319346a3aa00ef6a24db51e9f9ab7b21e480

Authored by Daniela Feitosa
1 parent d250d007

ActionItem1078: ProfileImageBlock was not displaying block title

app/models/profile_image_block.rb
... ... @@ -10,10 +10,6 @@ class ProfileImageBlock < Block
10 10 _('This block presents the profile image.')
11 11 end
12 12  
13   - def default_title
14   - owner.name
15   - end
16   -
17 13 def content
18 14 block = self
19 15 s = show_name
... ...
app/views/blocks/profile_image.rhtml
1 1 <div class="vcard">
2 2  
  3 +<p><%= block.title %></p>
  4 +
3 5 <div class="profile-big-image">
4 6 <div class="profile-big-image-inner1">
5 7 <span class="profile-big-image-inner2">
... ... @@ -11,7 +13,7 @@
11 13 </div>
12 14  
13 15 <% if show_name %>
14   - <p><%= block.owner.name %></p>
  16 + <p><%= block.owner.short_name %></p>
15 17 <% end %>
16 18  
17 19 <% if !user.nil? and user.has_permission?('edit_profile', profile) %>
... ...
test/unit/profile_image_block_test.rb
... ... @@ -13,8 +13,7 @@ class ProfileImageBlockTest &lt; Test::Unit::TestCase
13 13 instance_eval(& block.content)
14 14 end
15 15  
16   - should 'not be editable' do
  16 + should 'be editable' do
17 17 assert ProfileImageBlock.new.editable?
18 18 end
19   -
20 19 end
... ...