Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | [ci skip] Little bit doc code improvement. | Santosh Wadghule | 2014-07-14 | 1 | -1/+1 |
| | |||||
* | Adds explanation of :base attribute to errors.add | David Underwood | 2014-03-27 | 1 | -0/+7 |
| | | | [ci skip] | ||||
* | Fix ActiveModel::Errors#has_key? return value | Adrien Coquio | 2014-01-22 | 1 | -1/+1 |
| | |||||
* | Change all "can not"s to the correct "cannot". | T.J. Schuck | 2014-01-03 | 1 | -20/+20 |
| | |||||
* | Fix few typos and improve markup at some levels | Robin Dupret | 2013-12-24 | 1 | -2/+2 |
| | |||||
* | Fix: documentation for ActiveModel::Errors | Ryoji Yoshioka | 2013-08-05 | 1 | -4/+4 |
| | |||||
* | fix typo in ActiveModel::Error docs [ci skip] | Steven Yang | 2013-06-30 | 1 | -1/+1 |
| | |||||
* | make default value for `:message` on `AM::Errors` explicit. | Yves Senn | 2013-06-22 | 1 | -4/+2 |
| | |||||
* | Convert ActiveModel to 1.9 hash syntax. | Patrick Robertson | 2013-05-01 | 1 | -9/+9 |
| | | | | | I also attempted to fix other styleguide violations such as { a: :b } over {a: :b} and foo(b: 'bar') over foo( b: 'bar' ). | ||||
* | Improve changelog entry for ActiveModel::Errors#full_messages_for [ci skip] | Carlos Antonio da Silva | 2013-03-30 | 1 | -2/+0 |
| | | | | Add a working example of how to use this new method. | ||||
* | Add a method full_messages_for to the Errors class | shock_one | 2013-03-24 | 1 | -0/+14 |
| | |||||
* | Revert the change at ActiveModel::Errors#add_on_blank and fix in the | Rafael Mendonça França | 2012-12-26 | 1 | -7/+1 |
| | | | | | | | | | | | right place. The EachValidator#validate already handle :allow_blank and :allow_nil, correctly. Closes #8622. Fix #8621. | ||||
* | Tests and fix for validates_presence of :allow_nil, :allow_blank | Colin Kelley | 2012-12-26 | 1 | -1/+7 |
| | | | | | Conflicts: activemodel/lib/active_model/errors.rb | ||||
* | Remove ActiveModel::Errors#add_on_present method. | Rafael Mendonça França | 2012-12-21 | 1 | -13/+0 |
| | | | | | | | | We don't need to define a new method in ActiveMode::Errors for each validatior. See https://github.com/rails/rails/commit/d72a07f1d1478db9daed847eadb35bfd840674f6#commitcomment-2325333 | ||||
* | Add `ActiveModel::Validations::AbsenceValidator`, a validator to check the ↵ | Roberto Vasquez Angel | 2012-12-15 | 1 | -0/+13 |
| | | | | | | absence of attributes. Add `ActiveModel::Errors#add_on_present` method. Adds error messages to present attributes. | ||||
* | Replace comments' non-breaking spaces with spaces | claudiob | 2012-12-04 | 1 | -3/+3 |
| | | | | | | | | | | Sometimes, on Mac OS X, programmers accidentally press Option+Space rather than just Space and don’t see the difference. The problem is that Option+Space writes a non-breaking space (0XA0) rather than a normal space (0x20). This commit removes all the non-breaking spaces inadvertently introduced in the comments of the code. | ||||
* | use Array() instead flatten | Vasiliy Ermolovich | 2012-11-05 | 1 | -2/+2 |
| | | | | | * move ActiveModel::Errors tests to errors_test.rb * add spec coverage for add_on_empty and add_on_blank | ||||
* | fix output messages - docs [ci skip] | Francesco Rodriguez | 2012-10-22 | 1 | -16/+16 |
| | |||||
* | convert comments to 1.9 hash syntax | AvnerCohen | 2012-10-22 | 1 | -11/+11 |
| | |||||
* | minor edits in AM documentation [ci skip] | Francesco Rodriguez | 2012-10-21 | 1 | -1/+1 |
| | |||||
* | AM::Validation#validates: ability to pass custom exception to `:strict` option | Bogdan Gusiev | 2012-08-06 | 1 | -2/+6 |
| | |||||
* | Merge branch 'master' of github.com:lifo/docrails | Vijay Dev | 2012-08-04 | 1 | -0/+13 |
|\ | | | | | | | | | | | Conflicts: activemodel/lib/active_model/secure_password.rb activerecord/lib/active_record/associations/collection_proxy.rb | ||||
| * | add example to ActiveModel::StrictValidationFailed [ci skip] | Francesco Rodriguez | 2012-07-28 | 1 | -0/+13 |
| | | |||||
* | | load active_support/core_ext/object/blank in active_support/rails | Xavier Noria | 2012-08-02 | 1 | -1/+0 |
|/ | |||||
* | Merge branch 'master' of github.com:lifo/docrails | Vijay Dev | 2012-06-30 | 1 | -60/+131 |
|\ | | | | | | | | | Conflicts: activemodel/lib/active_model/errors.rb | ||||
| * | fix punctuation in activemodel/errors [ci skip] | Francesco Rodriguez | 2012-06-25 | 1 | -1/+1 |
| | | |||||
| * | add description ActiveModel::StrictValidationField [ci skip] | Francesco Rodriguez | 2012-06-23 | 1 | -0/+10 |
| | | |||||
| * | update ActiveModel::Errors#include? documentation [ci skip] | Francesco Rodriguez | 2012-06-22 | 1 | -1/+1 |
| | | |||||
| * | add documentation and examples to ActiveModel::Errors [ci skip] | Francesco Rodriguez | 2012-06-22 | 1 | -4/+26 |
| | | |||||
| * | update ActiveModel::Errors documentation and minor fixes [ci skip] | Francesco Rodriguez | 2012-06-22 | 1 | -60/+99 |
| | | |||||
* | | add :nodoc: to internal implementations [ci skip] | Francesco Rodriguez | 2012-06-22 | 1 | -1/+1 |
| | | |||||
* | | change param name to improve documentation | Francesco Rodriguez | 2012-06-22 | 1 | -2/+2 |
|/ | | | | | | | | | | | | | | | The keys of the error messages are actually attribute names. It makes the documentation easier to understand: # Returns +true+ if the error messages include an error for the given # +attribute+, +false+ otherwise. # # person.errors.messages # => { :name => ["can not be nil"] } # person.errors.include?(:name) # => true # person.errors.include?(:age) # => false def include?(attribute) (v = messages[attribute]) && v.any? end | ||||
* | Refactor AMo::Errors | Carlos Antonio da Silva | 2012-04-27 | 1 | -7/+7 |
| | | | | | * Use merge!, remove reverse_merge * Use case statement instead of is_a? checks | ||||
* | Fix confusing example in ActiveModel::Errors | Thibaut Courouble | 2012-04-17 | 1 | -2/+2 |
| | |||||
* | Updated/changed useless tr/gsubs | Jurriaan Pruis | 2012-04-03 | 1 | -1/+1 |
| | |||||
* | AM::Errors: allow :full_messages parameter for #as_json | Bogdan Gusiev | 2012-02-20 | 1 | -3/+14 |
| | |||||
* | replacing ordered hash to ruby hash | prasath | 2012-02-08 | 1 | -4/+3 |
| | |||||
* | Generate strict validation error messages with attribute name | Carlos Antonio da Silva | 2012-02-01 | 1 | -1/+1 |
| | |||||
* | Fix translate_error reference for Error#add documentation | Jonathan del Strother | 2012-01-25 | 1 | -1/+1 |
| | |||||
* | Remove redundant #to_sym | Paweł Kondzior | 2012-01-16 | 1 | -1/+1 |
| | |||||
* | Fix ActiveModel::Errors#dup | Paweł Kondzior | 2012-01-16 | 1 | -0/+5 |
| | | | | | | | | | Since ActiveModel::Errors instance keeps all error messages as hash we should duplicate this object as well. Previously ActiveModel::Errors was a subclass of ActiveSupport::OrderedHash, which results in different behavior on `dup`, this may result in regression for people relying on it. | ||||
* | Add ActiveModel::Errors#delete, which was not available after move to use ↵ | Piotr Sarnacki | 2012-01-16 | 1 | -0/+5 |
| | | | | delegation | ||||
* | removed unnessary require active_support/core_ext/array_wrap | Karunakar (Ruby) | 2012-01-06 | 1 | -1/+0 |
| | |||||
* | Fixed bug when error message is an empty string. | Antonio Roberto | 2011-12-16 | 1 | -1/+2 |
| | |||||
* | Merge branch 'master' of github.com:lifo/docrails | Vijay Dev | 2011-10-20 | 1 | -3/+2 |
|\ | |||||
| * | Removed mention of deprecated ActiveModel::Errors#on | Martin Svalin | 2011-10-19 | 1 | -3/+2 |
| | | |||||
* | | New #added? method on ActiveModel::Errors | Martin Svalin | 2011-10-19 | 1 | -7/+23 |
| | | | | | | The #added? method makes it possible to check if a specific error has been added, using the same parameters as for #add. | ||||
* | | ActiveModel::Errors#generate_message without i18n_scope, and more test cases ↵ | Martin Svalin | 2011-10-17 | 1 | -4/+8 |
|/ | | | | for #add | ||||
* | Add ability to get an individual full error message + test for full_messages. | Lawrence Pit | 2011-09-09 | 1 | -14/+17 |
| | |||||
* | add has_key? to ActiveModel::Errors | Damien Mathieu | 2011-09-06 | 1 | -0/+1 |
| |