Commit 8512674f250eb38cc198ea8073a3b83ebd8a7334

Authored by AntonioTerceiro
1 parent 99342898

ActionItem280: marking TODO to remove ugly hacks


git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@1686 3f533792-8f58-4932-b0fe-aaf55b0a4547
app/models/change_password.rb
1 1 # TODO: send an e-mail with a hash code to the task after the ChangePassword is creatd -> override messages from #Task
2 2  
  3 +# FIXME remove this workaround
3 4 class HumanName
4 5 def human_name
5 6 @name
... ... @@ -16,6 +17,7 @@ class ChangePassword < Task
16 17 self[:data] ||= {}
17 18 end
18 19  
  20 + # FIXME ugly workaround
19 21 self.columns_hash['login'] = HumanName.new _('Username')
20 22 self.columns_hash['email'] = HumanName.new _('e-Mail')
21 23  
... ...
app/models/user.rb
... ... @@ -7,6 +7,7 @@ class User < ActiveRecord::Base
7 7 N_('User|Password')
8 8 N_('User|Password confirmation')
9 9  
  10 + # FIXME ugly workaround
10 11 def self.human_attribute_name(attrib)
11 12 case attrib.to_sym
12 13 when :login: return _('Username')
... ...