chord 0.0.10 → 0.0.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/lib/chord/version.rb +1 -1
- data/lib/chord.rb +14 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e84ec3facaf7f5f0165131be5b84c0cefa930fe9a200edd8207cba91fe63b88c
|
4
|
+
data.tar.gz: 35a2071e71c2e1b96451c1021d4732a6cf8b7b33e1a430c733ac03b9655bf557
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 80547fa3ad7a0e9d89550d3d71c6217ca159f9ec68132081b610e91fac59fd65c62da706091bbcf31105234e1f109272d5e0237cbe5881565fff8fc95d95c1f9
|
7
|
+
data.tar.gz: cbd177a6f5e39950cda3b14774da72430cdb16d4883f4d942f437ca21bed37d1988e82c26119087ee7d38eaad05e550324f9df1a209cadc2a736a18978d0c4e8
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,15 @@
|
|
2
2
|
|
3
3
|
Major changes for each release. Please see the Git log for complete list of changes.
|
4
4
|
|
5
|
+
## 0.0.12
|
6
|
+
|
7
|
+
* New endpoint to work around API bug.
|
8
|
+
* Auto-expand Order if needed for line items.
|
9
|
+
|
10
|
+
## 0.0.11
|
11
|
+
|
12
|
+
* Add LineItem model (rough/WIP).
|
13
|
+
|
5
14
|
## 0.0.10
|
6
15
|
|
7
16
|
* Don't allow public writing of @attributes.
|
data/lib/chord/version.rb
CHANGED
data/lib/chord.rb
CHANGED
@@ -174,7 +174,7 @@ module Chord
|
|
174
174
|
end
|
175
175
|
|
176
176
|
def subscriptions
|
177
|
-
self.class.get(base_url + "
|
177
|
+
self.class.get(base_url + "/subscriptions?q[user_id_in]=#{id}", http_options).parsed_response['subscriptions'].map{ |s| Chord::Subscription.new(s['id'], s) }
|
178
178
|
end
|
179
179
|
|
180
180
|
def find_subscription(subscription_id)
|
@@ -193,6 +193,11 @@ module Chord
|
|
193
193
|
'number'
|
194
194
|
end
|
195
195
|
|
196
|
+
def line_items
|
197
|
+
expand! if @attributes['line_items'].nil?
|
198
|
+
@attributes['line_items'].map{ |i| LineItem.new(i['id'], i) }
|
199
|
+
end
|
200
|
+
|
196
201
|
def complete?
|
197
202
|
state == 'complete'
|
198
203
|
end
|
@@ -226,6 +231,14 @@ module Chord
|
|
226
231
|
end
|
227
232
|
|
228
233
|
|
234
|
+
class LineItem < Base
|
235
|
+
|
236
|
+
def subscription?
|
237
|
+
subscription_line_items.size > 0
|
238
|
+
end
|
239
|
+
end
|
240
|
+
|
241
|
+
|
229
242
|
class Role < Base
|
230
243
|
|
231
244
|
def self.base_path
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chord
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Reisner
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-10-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|