diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index b6caaa6..ee64cda 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -328,9 +328,7 @@ module ApplicationHelper end - # displays a link to the profile homepage with its image (as generated by - # #profile_image) and its name below it. - def profile_image_link( profile, size=:portrait, tag='li' ) + def profile_sex_icon( profile ) if profile.class == Person sex = ( profile.sex ? profile.sex.to_s() : 'undef' ) title = ( sex == 'undef' ? _('non registered gender') : ( sex == 'male' ? _('Male') : _('Female') ) ) @@ -341,6 +339,12 @@ module ApplicationHelper else sex = '' end + sex + end + + # displays a link to the profile homepage with its image (as generated by + # #profile_image) and its name below it. + def profile_image_link( profile, size=:portrait, tag='li' ) if profile.class == Person name = profile.first_name city = content_tag 'span', content_tag( 'span', profile.city, :class => 'locality' ), :class => 'adr' @@ -352,7 +356,7 @@ module ApplicationHelper link_to( content_tag( 'span', profile_image( profile, size ), :class => 'profile-image' ) + content_tag( 'span', name, :class => ( profile.class == Person ? 'fn' : 'org' ) ) + - city + sex, + city + profile_sex_icon( profile ), profile.url, :class => 'profile_link url', :help => _('Click on this icon to go to the %s\'s home page') % profile.name ), diff --git a/app/views/blocks/profile_info.rhtml b/app/views/blocks/profile_info.rhtml index 5b0eeca..b44561e 100644 --- a/app/views/blocks/profile_info.rhtml +++ b/app/views/blocks/profile_info.rhtml @@ -1,6 +1,15 @@

<%= block.owner.name %>

-
<%= profile_image(block.owner, :thumb) %>
+
+
+ + <%= + profile_image(block.owner, :thumb) +"\n"+ + profile_sex_icon( profile ) + %> + +
+