diff options
author | Daniel Rodríguez Troitiño <drodrigueztroitino@yahoo.es> | 2010-03-15 19:11:46 +0100 |
---|---|---|
committer | wycats <wycats@gmail.com> | 2010-03-27 01:56:20 -0700 |
commit | 334983eca042b5016d3d79d7ed5761b60ba871ed (patch) | |
tree | 222e778ebbc77d33a2483a561f9420451761e348 /actionpack/lib/action_view | |
parent | 3172db12e4e7f6abab8ddd25f7911d29a5b65ea0 (diff) | |
download | rails-334983eca042b5016d3d79d7ed5761b60ba871ed.tar.gz rails-334983eca042b5016d3d79d7ed5761b60ba871ed.tar.bz2 rails-334983eca042b5016d3d79d7ed5761b60ba871ed.zip |
Recovers error_messages for ActiveRecordInstanceTag. [#4078 state:resolved]
Signed-off-by: wycats <wycats@gmail.com>
Diffstat (limited to 'actionpack/lib/action_view')
-rw-r--r-- | actionpack/lib/action_view/helpers/active_model_helper.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/actionpack/lib/action_view/helpers/active_model_helper.rb b/actionpack/lib/action_view/helpers/active_model_helper.rb index e3db2923f7..bbe8609e91 100644 --- a/actionpack/lib/action_view/helpers/active_model_helper.rb +++ b/actionpack/lib/action_view/helpers/active_model_helper.rb @@ -295,6 +295,10 @@ module ActionView end end + def error_message + object.errors[@method_name] + end + def column_type object.send(:column_for_attribute, @method_name).type end |