recurly 2.18.32 → 2.18.34
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/recurly/adjustment.rb +13 -2
- data/lib/recurly/custom_field_definition.rb +14 -0
- data/lib/recurly/external_subscription.rb +2 -4
- data/lib/recurly/plan.rb +4 -0
- data/lib/recurly/transaction/errors.rb +4 -0
- data/lib/recurly/version.rb +1 -1
- data/lib/recurly.rb +1 -1
- metadata +3 -3
- data/lib/recurly/external_resource.rb +0 -11
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9760d9361ce3ff01fb7fdf89bc4138ec1b2103c8d0e76cd19f180fc708e975b7
|
4
|
+
data.tar.gz: f4cc5d1522cded81e6172b3664b226ec85d09c01b1dc378d7278d8158dfd3ccc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5d106b7ed9938da57a1133ca11dbb002c7f919fddeca10e4a22d22438720b777db55296c2d2c5d041752d23053badc1a96f7300bf8c4345413557b32619e518f
|
7
|
+
data.tar.gz: 167d7fe3dc8c6d8aeabb46839110ef3c2c59c2962ee25ffaf4f1a08021c1d91dff7857428831b80f8859d224d99fb65128a4a2869cd21b03c038db298a46eb35
|
data/README.md
CHANGED
@@ -14,7 +14,7 @@ Recurly is packaged as a Ruby gem. We recommend you install it with
|
|
14
14
|
[Bundler](http://gembundler.com/) by adding the following line to your Gemfile:
|
15
15
|
|
16
16
|
``` ruby
|
17
|
-
gem 'recurly', '~> 2.18.
|
17
|
+
gem 'recurly', '~> 2.18.34'
|
18
18
|
```
|
19
19
|
|
20
20
|
Recurly will automatically use [Nokogiri](http://nokogiri.org/) (for a nice
|
data/lib/recurly/adjustment.rb
CHANGED
@@ -26,7 +26,10 @@ module Recurly
|
|
26
26
|
# @return [ShippingAddress, nil]
|
27
27
|
has_one :shipping_address, class_name: :ShippingAddress, readonly: false
|
28
28
|
|
29
|
-
|
29
|
+
# @return [[CustomField], []]
|
30
|
+
has_many :custom_fields, class_name: :CustomField, readonly: false
|
31
|
+
|
32
|
+
define_attribute_methods %w[
|
30
33
|
uuid
|
31
34
|
state
|
32
35
|
description
|
@@ -65,7 +68,7 @@ module Recurly
|
|
65
68
|
avalara_transaction_type
|
66
69
|
avalara_service_type
|
67
70
|
refundable_total_in_cents
|
68
|
-
|
71
|
+
]
|
69
72
|
alias to_param uuid
|
70
73
|
|
71
74
|
# @return ["charge", "credit", nil] The type of adjustment.
|
@@ -81,6 +84,14 @@ module Recurly
|
|
81
84
|
super({ :currency => Recurly.default_currency }.merge attributes)
|
82
85
|
end
|
83
86
|
|
87
|
+
def changed_attributes
|
88
|
+
attrs = super
|
89
|
+
if custom_fields.any?(&:changed?)
|
90
|
+
attrs['custom_fields'] = custom_fields.select(&:changed?)
|
91
|
+
end
|
92
|
+
attrs
|
93
|
+
end
|
94
|
+
|
84
95
|
# Adjustments are only writeable through an {Account} instance.
|
85
96
|
embedded! true
|
86
97
|
end
|
@@ -4,15 +4,12 @@ module Recurly
|
|
4
4
|
# @return [Account]
|
5
5
|
belongs_to :account
|
6
6
|
|
7
|
-
# @return [ExternalResource]
|
8
|
-
has_one :external_resource
|
9
|
-
|
10
7
|
# @return [ExternalProductReference]
|
11
8
|
belongs_to :external_product_reference
|
12
9
|
|
13
10
|
define_attribute_methods %w(
|
14
11
|
account
|
15
|
-
|
12
|
+
external_id
|
16
13
|
external_product_reference
|
17
14
|
quantity
|
18
15
|
activated_at
|
@@ -22,6 +19,7 @@ module Recurly
|
|
22
19
|
last_purchased
|
23
20
|
auto_renew
|
24
21
|
app_identifier
|
22
|
+
state
|
25
23
|
)
|
26
24
|
|
27
25
|
# We do not expose PUT or POST in the v2 API.
|
data/lib/recurly/plan.rb
CHANGED
@@ -10,6 +10,9 @@ module Recurly
|
|
10
10
|
# @return [[PlanRampInterval], nil]
|
11
11
|
has_many :ramp_intervals, class_name: :PlanRampInterval
|
12
12
|
|
13
|
+
# @return [[CustomField], []]
|
14
|
+
has_many :custom_fields, class_name: :CustomField, readonly: false
|
15
|
+
|
13
16
|
define_attribute_methods %w(
|
14
17
|
plan_code
|
15
18
|
name
|
@@ -44,6 +47,7 @@ module Recurly
|
|
44
47
|
avalara_transaction_type
|
45
48
|
avalara_service_type
|
46
49
|
dunning_campaign_id
|
50
|
+
custom_fields
|
47
51
|
created_at
|
48
52
|
updated_at
|
49
53
|
)
|
data/lib/recurly/version.rb
CHANGED
data/lib/recurly.rb
CHANGED
@@ -22,7 +22,6 @@ module Recurly
|
|
22
22
|
require 'recurly/entitlement'
|
23
23
|
require 'recurly/external_product'
|
24
24
|
require 'recurly/external_product_reference'
|
25
|
-
require 'recurly/external_resource'
|
26
25
|
require 'recurly/external_subscription'
|
27
26
|
require 'recurly/helper'
|
28
27
|
require 'recurly/invoice'
|
@@ -56,6 +55,7 @@ module Recurly
|
|
56
55
|
require 'recurly/percentage_tier'
|
57
56
|
require 'recurly/currency_percentage_tier'
|
58
57
|
require 'recurly/sub_add_on_percentage_tier'
|
58
|
+
require 'recurly/custom_field_definition'
|
59
59
|
|
60
60
|
@subdomain = nil
|
61
61
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: recurly
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.18.
|
4
|
+
version: 2.18.34
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Recurly
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-02-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|
@@ -141,6 +141,7 @@ files:
|
|
141
141
|
- lib/recurly/credit_payment.rb
|
142
142
|
- lib/recurly/currency_percentage_tier.rb
|
143
143
|
- lib/recurly/custom_field.rb
|
144
|
+
- lib/recurly/custom_field_definition.rb
|
144
145
|
- lib/recurly/customer_permission.rb
|
145
146
|
- lib/recurly/delivery.rb
|
146
147
|
- lib/recurly/dunning_campaign.rb
|
@@ -149,7 +150,6 @@ files:
|
|
149
150
|
- lib/recurly/error.rb
|
150
151
|
- lib/recurly/external_product.rb
|
151
152
|
- lib/recurly/external_product_reference.rb
|
152
|
-
- lib/recurly/external_resource.rb
|
153
153
|
- lib/recurly/external_subscription.rb
|
154
154
|
- lib/recurly/gift_card.rb
|
155
155
|
- lib/recurly/helper.rb
|