mirror of
https://github.com/internetee/registry.git
synced 2025-08-03 16:32:04 +02:00
Revert "Registry 569"
This commit is contained in:
parent
9565f23e68
commit
4786dbb943
50 changed files with 323 additions and 2463 deletions
|
@ -1,13 +0,0 @@
|
|||
class Iso8601Validator < ActiveModel::EachValidator
|
||||
def validate_each(record, attribute, value)
|
||||
if options[:date_only]
|
||||
record.errors.add(attribute, :invalid_iso8601_date) unless value =~ date_format
|
||||
end
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def date_format
|
||||
/\d{4}-\d{2}-\d{2}/
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue