Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Numericality validator. #3

Closed
8 tasks done
esbanarango opened this issue May 21, 2015 · 0 comments
Closed
8 tasks done

Improve Numericality validator. #3

esbanarango opened this issue May 21, 2015 · 0 comments
Assignees

Comments

@esbanarango
Copy link
Owner

This validator should accept the same options as the Active Record Numericality validator.

  • only_integer
  • greater_than - Specifies the value must be greater than the supplied value. The default error message for this option is "must be greater than %{count}".
  • greater_than_or_equal_to - Specifies the value must be greater than or equal to the supplied value. The default error message for this option is "must be greater than or equal to %{count}".
  • equal_to - Specifies the value must be equal to the supplied value. The default error message for this option is "must be equal to %{count}".
  • less_than - Specifies the value must be less than the supplied value. The default error message for this option is "must be less than %{count}".
  • less_than_or_equal_to - Specifies the value must be less than or equal the supplied value. The default error message for this option is "must be less than or equal to %{count}".
  • odd - Specifies the value must be an odd number if set to true. The default error message for this option is "must be odd".
  • even - Specifies the value must be an even number if set to true. The default error message for this option is "must be even".
@esbanarango esbanarango self-assigned this May 21, 2015
@esbanarango esbanarango added this to the Production version 1.0 milestone May 21, 2015
esbanarango added a commit that referenced this issue Oct 6, 2015
esbanarango added a commit that referenced this issue Oct 6, 2015
esbanarango added a commit that referenced this issue Oct 6, 2015
esbanarango added a commit that referenced this issue Oct 6, 2015
esbanarango added a commit that referenced this issue Oct 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant