api-moip-assinaturas 0.2.10 → 0.2.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/api_moip_assinaturas.gemspec +1 -1
- data/lib/moip/locale/en.yml +5 -3
- data/lib/moip/models/customer.rb +3 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MDAwMmM0YTQzNzg0YmQ5NTQxMjEwNzBkN2Q2YWI1NDhiMWFhZDRmMw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZDU5MWFjZjc5MGVkMWUzZTRmOWQxZGFhOTc4MWM2ZDM0NjMwNjgwMQ==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MDMzZjhmNmRlZDJkODdjMTBiYTUxMWE1N2YyZTM5OTVjYjQ0MDY0YTRkNjYx
|
10
|
+
NjYwNGE5MTc2MGQ5ZGE4ZjdiZGM3OTY1Y2ZiNDgyNzM1NGViOGFmZDViYTVm
|
11
|
+
YjVhMmRhZGI4NDZmYmY2OGQyOWE4NDdmZmE2OTdjOWI5ODYxNGE=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ODEwYWQ3MTNlM2UzZGVlNjhjMjFmYTZlN2UwYTEzNmY1ZjkzMTA1ODhmNGNk
|
14
|
+
NDc4YTFjOGEyMzNlZmI2YjcwYjljYjc4N2IyZGQ5ZjRiMDBkMzNmMGE3MjQx
|
15
|
+
ZmU1MzRjYzhkMWQ5Y2FiZjUyOWIzNzYwZDUxZDVlZjkwNWU3Zjg=
|
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
|
|
3
3
|
|
4
4
|
Gem::Specification.new do |s|
|
5
5
|
s.name = 'api-moip-assinaturas'
|
6
|
-
s.version = '0.2.
|
6
|
+
s.version = '0.2.11'
|
7
7
|
s.date = '2013-07-02'
|
8
8
|
s.summary = "Moip Assinaturas by Pixxel"
|
9
9
|
s.description = "Gem desenvolvida para atender aos requisitos do moip api de assinaturas"
|
data/lib/moip/locale/en.yml
CHANGED
data/lib/moip/models/customer.rb
CHANGED
@@ -12,7 +12,7 @@ class Moip::Customer < Moip::Model
|
|
12
12
|
:phone_number, :birthdate_day, :birthdate_month,
|
13
13
|
:birthdate_year, :presence => true
|
14
14
|
|
15
|
-
validates_format_of :email, :with => /\A([^@\s]+)@((?:[-a-z0-9]+\.)+[a-z]{2,})\Z/i, :message => I18n.t("invalid_format")
|
15
|
+
validates_format_of :email, :with => /\A([^@\s]+)@((?:[-a-z0-9]+\.)+[a-z]{2,})\Z/i, :message => I18n.t("moip.errors.invalid_format")
|
16
16
|
|
17
17
|
validate :validates_presence_of_address, :validates_presence_of_billing_info
|
18
18
|
|
@@ -53,7 +53,7 @@ class Moip::Customer < Moip::Model
|
|
53
53
|
end
|
54
54
|
|
55
55
|
def validates_presence_of_address
|
56
|
-
self.errors.add :address, I18n.t("presence_of_address") and return if @address.nil?
|
56
|
+
self.errors.add :address, I18n.t("moip.errors.presence_of_address") and return if @address.nil?
|
57
57
|
|
58
58
|
if @address.valid?
|
59
59
|
true
|
@@ -63,7 +63,7 @@ class Moip::Customer < Moip::Model
|
|
63
63
|
end
|
64
64
|
|
65
65
|
def validates_presence_of_billing_info
|
66
|
-
self.errors.add :billing_info, I18n.t("presence_of_billing_info") and return if @billing_info.nil?
|
66
|
+
self.errors.add :billing_info, I18n.t("moip.errors.presence_of_billing_info") and return if @billing_info.nil?
|
67
67
|
|
68
68
|
if @billing_info.valid?
|
69
69
|
true
|