killbill-client 0.5.9 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/killbill_client/models/resource.rb +6 -0
- data/lib/killbill_client/models/tenant.rb +2 -0
- data/lib/killbill_client/version.rb +2 -2
- metadata +28 -17
- checksums.yaml +0 -7
@@ -52,6 +52,11 @@ module KillBillClient
|
|
52
52
|
response.body
|
53
53
|
when %r{application/json}
|
54
54
|
record = from_json resource_class, response.body
|
55
|
+
if record.nil?
|
56
|
+
record = resource_class.new
|
57
|
+
record.uri = response.header['location']
|
58
|
+
end
|
59
|
+
|
55
60
|
session_id = extract_session_id(response)
|
56
61
|
record.instance_eval {
|
57
62
|
@clazz = resource_class
|
@@ -120,6 +125,7 @@ module KillBillClient
|
|
120
125
|
end #end unless attr_desc.nil? or data_elem.blank?
|
121
126
|
|
122
127
|
record.send("#{Utils.underscore name}=", value )
|
128
|
+
|
123
129
|
end #end data.each
|
124
130
|
|
125
131
|
record
|
@@ -3,6 +3,8 @@ module KillBillClient
|
|
3
3
|
class Tenant < TenantAttributes
|
4
4
|
KILLBILL_API_TENANTS_PREFIX = "#{KILLBILL_API_PREFIX}/tenants"
|
5
5
|
|
6
|
+
has_many :audit_logs, KillBillClient::Model::AuditLog
|
7
|
+
|
6
8
|
class << self
|
7
9
|
def find_by_id(tenant_id, options = {})
|
8
10
|
get "#{KILLBILL_API_TENANTS_PREFIX}/#{tenant_id}",
|
metadata
CHANGED
@@ -1,55 +1,62 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: killbill-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
|
+
prerelease:
|
5
6
|
platform: ruby
|
6
7
|
authors:
|
7
8
|
- Killbill core team
|
8
9
|
autorequire:
|
9
10
|
bindir: bin
|
10
11
|
cert_chain: []
|
11
|
-
date: 2014-01-
|
12
|
+
date: 2014-01-30 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: json
|
15
16
|
requirement: !ruby/object:Gem::Requirement
|
17
|
+
none: false
|
16
18
|
requirements:
|
17
|
-
- -
|
19
|
+
- - ~>
|
18
20
|
- !ruby/object:Gem::Version
|
19
21
|
version: 1.8.0
|
20
22
|
type: :runtime
|
21
23
|
prerelease: false
|
22
24
|
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
23
26
|
requirements:
|
24
|
-
- -
|
27
|
+
- - ~>
|
25
28
|
- !ruby/object:Gem::Version
|
26
29
|
version: 1.8.0
|
27
30
|
- !ruby/object:Gem::Dependency
|
28
31
|
name: rake
|
29
32
|
requirement: !ruby/object:Gem::Requirement
|
33
|
+
none: false
|
30
34
|
requirements:
|
31
|
-
- -
|
35
|
+
- - ! '>='
|
32
36
|
- !ruby/object:Gem::Version
|
33
37
|
version: 10.0.0
|
34
38
|
type: :development
|
35
39
|
prerelease: false
|
36
40
|
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
37
42
|
requirements:
|
38
|
-
- -
|
43
|
+
- - ! '>='
|
39
44
|
- !ruby/object:Gem::Version
|
40
45
|
version: 10.0.0
|
41
46
|
- !ruby/object:Gem::Dependency
|
42
47
|
name: rspec
|
43
48
|
requirement: !ruby/object:Gem::Requirement
|
49
|
+
none: false
|
44
50
|
requirements:
|
45
|
-
- -
|
51
|
+
- - ~>
|
46
52
|
- !ruby/object:Gem::Version
|
47
53
|
version: 2.12.0
|
48
54
|
type: :development
|
49
55
|
prerelease: false
|
50
56
|
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
51
58
|
requirements:
|
52
|
-
- -
|
59
|
+
- - ~>
|
53
60
|
- !ruby/object:Gem::Version
|
54
61
|
version: 2.12.0
|
55
62
|
description: An API client library for Kill Bill.
|
@@ -58,8 +65,8 @@ executables: []
|
|
58
65
|
extensions: []
|
59
66
|
extra_rdoc_files: []
|
60
67
|
files:
|
61
|
-
-
|
62
|
-
-
|
68
|
+
- .gitignore
|
69
|
+
- .travis.yml
|
63
70
|
- Gemfile
|
64
71
|
- README.md
|
65
72
|
- Rakefile
|
@@ -138,28 +145,32 @@ files:
|
|
138
145
|
homepage: http://www.killbilling.org
|
139
146
|
licenses:
|
140
147
|
- Apache License (2.0)
|
141
|
-
metadata: {}
|
142
148
|
post_install_message:
|
143
149
|
rdoc_options:
|
144
|
-
-
|
145
|
-
-
|
150
|
+
- --exclude
|
151
|
+
- .
|
146
152
|
require_paths:
|
147
153
|
- lib
|
148
154
|
required_ruby_version: !ruby/object:Gem::Requirement
|
155
|
+
none: false
|
149
156
|
requirements:
|
150
|
-
- -
|
157
|
+
- - ! '>='
|
151
158
|
- !ruby/object:Gem::Version
|
152
159
|
version: 1.8.6
|
153
160
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
161
|
+
none: false
|
154
162
|
requirements:
|
155
|
-
- -
|
163
|
+
- - ! '>='
|
156
164
|
- !ruby/object:Gem::Version
|
157
165
|
version: '0'
|
166
|
+
segments:
|
167
|
+
- 0
|
168
|
+
hash: -1019538039368057415
|
158
169
|
requirements: []
|
159
170
|
rubyforge_project:
|
160
|
-
rubygems_version:
|
171
|
+
rubygems_version: 1.8.25
|
161
172
|
signing_key:
|
162
|
-
specification_version:
|
173
|
+
specification_version: 3
|
163
174
|
summary: Kill Bill client library.
|
164
175
|
test_files:
|
165
176
|
- spec/killbill_client/model_relation_spec.rb
|
checksums.yaml
DELETED
@@ -1,7 +0,0 @@
|
|
1
|
-
---
|
2
|
-
SHA1:
|
3
|
-
metadata.gz: 3990b297c63c90cdcaef50fdd36fc999976db15d
|
4
|
-
data.tar.gz: c373818e0e196aace27b0fa31f0fef6aa807ecba
|
5
|
-
SHA512:
|
6
|
-
metadata.gz: aaca9fe0dbad554ed90e9ab2bc6238173f1b003b6b1cb92aafce2779a516d933148bc4e75b52689b24b292b6eafdc057589e765df034a8d4cf45cc24832c2469
|
7
|
-
data.tar.gz: b9c3215ed788b641f677df24de0b23db99f20fe05b06f65749f5ce068d37691da4145844e05eedb223d63c40b99aad081e63fa2b7218a27fa5a96d2e1dd1ebb9
|