validates_russian 0.0.9 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -1
- data/lib/validates_russian/version.rb +1 -1
- data/lib/validators/bik_format_validator.rb +1 -0
- data/spec/validators/bik_format_spec.rb +1 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: de37de7e412401b4d9c142e22ea9ae420ccca77b
|
4
|
+
data.tar.gz: 6748e144d35c50d42fe20705ff7fe829d2c0249c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7ed5b062e211951c80192e8fad2aa3cb9192e5bad1cc65117a1b8bc90dbddadcfe105c65ff7f6fd9bf41ea5680d269bbbb16190de085f07e215182516b022b61
|
7
|
+
data.tar.gz: e1cff7a6f374ad2c6f67c14440a67803c63dd08b39b6a7c507736f084e8a62f8b9a726ad8e3f5d8720c8c7fa79554cec46f564a3a446be0e124914cc0c42b9f8
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
class BikFormatValidator < ValidatesRussian::Validator
|
2
2
|
validates_using do |bik|
|
3
3
|
next false unless bik =~ /^\d+$/
|
4
|
+
next false unless bik.length == 9
|
4
5
|
next false unless bik[0..1] == '04'
|
5
6
|
next false unless ValidatesRussian::OKATO_REGION_NUMBERS.include?(bik[2..3])
|
6
7
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: validates_russian
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Antonov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-11-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activemodel
|
@@ -133,7 +133,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
133
133
|
version: '0'
|
134
134
|
requirements: []
|
135
135
|
rubyforge_project:
|
136
|
-
rubygems_version: 2.4.
|
136
|
+
rubygems_version: 2.4.6
|
137
137
|
signing_key:
|
138
138
|
specification_version: 4
|
139
139
|
summary: validates specific russian values
|