Commit ceaeac454bdce03b5fcc73dc89f3dc203f6131d4
1 parent
f0c23c25
Exists in
master
and in
23 other branches
ActionItem556: use display_name instead of first_name
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@2286 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
3 changed files
with
1 additions
and
10 deletions
Show diff stats
app/models/person.rb
| ... | ... | @@ -86,11 +86,6 @@ class Person < Profile |
| 86 | 86 | end |
| 87 | 87 | end |
| 88 | 88 | |
| 89 | - def first_name | |
| 90 | - re = '[-+*_\s\'´"]' | |
| 91 | - self.name.gsub(/^#{re}*/,'').split(/#{re}/)[0] | |
| 92 | - end | |
| 93 | - | |
| 94 | 89 | has_and_belongs_to_many :favorite_enterprises, :class_name => 'Enterprise', :join_table => 'favorite_enteprises_people' |
| 95 | 90 | |
| 96 | 91 | def email_addresses | ... | ... |
app/models/user.rb
app/views/shared/user_menu.rhtml
| ... | ... | @@ -9,7 +9,7 @@ |
| 9 | 9 | (current_user.person.image)? |
| 10 | 10 | current_user.person.image.public_filename(:icon) : "/images/icons-bar/photo.png" |
| 11 | 11 | %>" alt="<%= current_user.name %> Icon-Photo" title="" height="20" border="0"/> |
| 12 | - <span><%= _("%s's Menu") % current_user.first_name %> </span> | |
| 12 | + <span><%= _("%s's Menu") % current_user.display_name %> </span> | |
| 13 | 13 | </div> |
| 14 | 14 | |
| 15 | 15 | <div id="user_menu_ul"> | ... | ... |