ledger_sync-quickbooks_online 0.1.1 → 0.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/gem-workflow.yml +63 -0
- data/Gemfile.lock +48 -43
- data/bin/quickbooks_online_oauth_server.rb +1 -1
- data/ledger_sync-quickbooks_online.gemspec +1 -1
- data/lib/ledger_sync/quickbooks_online/deposit_line_detail/deserializer.rb +3 -4
- data/lib/ledger_sync/quickbooks_online/deserializer.rb +1 -1
- data/lib/ledger_sync/quickbooks_online/payment/deserializer.rb +1 -0
- data/lib/ledger_sync/quickbooks_online/version.rb +1 -1
- metadata +11 -11
- data/.coveralls.yml +0 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b5a2f6fae3ba434cb7b4bcb7cb825cd61f905af61b91bc5fd982f04d379df003
|
4
|
+
data.tar.gz: 43970c4ede08f3d78cc042a07669bd144041907c0c9db3fc250e2642f5d7eec9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3b9086fefe691baf7dceeeb59fa1239c321b552ab7f0063ad2f1b0198317fddbab76992823ffa2e7a57ecbdec79ba3725a86385596c9dbbd1b4217e59da79c12
|
7
|
+
data.tar.gz: '0970d549a7c7dd80d47643d9db36dea9c1a4aae7f72948e4da55fb4c65b6895b2e0e18cf19d8409ca90a7a05d1a8f9b8650710e92e040d1f2f002bc31ccb9891'
|
@@ -0,0 +1,63 @@
|
|
1
|
+
name: Test and Deploy
|
2
|
+
on: [push, pull_request]
|
3
|
+
jobs:
|
4
|
+
rubocop:
|
5
|
+
strategy:
|
6
|
+
matrix:
|
7
|
+
ruby-version: [2.6.3, 2.6.6, 2.7.1]
|
8
|
+
runs-on: [ubuntu-latest]
|
9
|
+
steps:
|
10
|
+
- uses: actions/checkout@v2
|
11
|
+
with:
|
12
|
+
persist-credentials: false
|
13
|
+
fetch-depth: 0
|
14
|
+
- name: Ruby Setup and Bundle
|
15
|
+
uses: ruby/setup-ruby@v1
|
16
|
+
with:
|
17
|
+
ruby-version: ${{ matrix.ruby-version }}
|
18
|
+
bundler-cache: true
|
19
|
+
- run: bundle exec rubocop
|
20
|
+
rspec:
|
21
|
+
strategy:
|
22
|
+
matrix:
|
23
|
+
ruby-version: [2.6.3, 2.6.6, 2.7.1]
|
24
|
+
runs-on: [ubuntu-latest]
|
25
|
+
steps:
|
26
|
+
- uses: actions/checkout@v2
|
27
|
+
with:
|
28
|
+
persist-credentials: false
|
29
|
+
fetch-depth: 0
|
30
|
+
- name: Ruby Setup and Bundle
|
31
|
+
uses: ruby/setup-ruby@v1
|
32
|
+
with:
|
33
|
+
ruby-version: ${{ matrix.ruby-version }}
|
34
|
+
bundler-cache: true
|
35
|
+
- name: rspec and report to coveralls
|
36
|
+
env:
|
37
|
+
COVERALLS_REPO_TOKEN: ${{ github.event_name == 'push' && secrets.COVERALLS_REPO_TOKEN }}
|
38
|
+
run: bundle exec rspec --order rand
|
39
|
+
publish:
|
40
|
+
runs-on: ubuntu-latest
|
41
|
+
needs: ['rubocop', 'rspec']
|
42
|
+
if: startsWith(github.ref, 'refs/tags/')
|
43
|
+
steps:
|
44
|
+
- name: Checkout
|
45
|
+
uses: actions/checkout@v2
|
46
|
+
with:
|
47
|
+
persist-credentials: false
|
48
|
+
fetch-depth: 0
|
49
|
+
- name: Ruby Setup and Bundle
|
50
|
+
uses: ruby/setup-ruby@v1
|
51
|
+
with:
|
52
|
+
ruby-version: 2.6.6
|
53
|
+
bundler-cache: true
|
54
|
+
- name: Publish to RubyGems
|
55
|
+
run: |
|
56
|
+
mkdir -p $HOME/.gem
|
57
|
+
touch $HOME/.gem/credentials
|
58
|
+
chmod 0600 $HOME/.gem/credentials
|
59
|
+
printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
|
60
|
+
gem build *.gemspec
|
61
|
+
gem push *.gem
|
62
|
+
env:
|
63
|
+
GEM_HOST_API_KEY: "${{ secrets.RUBY_GEM_KEY }}"
|
data/Gemfile.lock
CHANGED
@@ -1,17 +1,17 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
ledger_sync-quickbooks_online (0.
|
4
|
+
ledger_sync-quickbooks_online (0.2.5)
|
5
5
|
dotenv
|
6
|
-
ledger_sync (
|
6
|
+
ledger_sync (>= 2.0.1)
|
7
7
|
oauth2
|
8
8
|
|
9
9
|
GEM
|
10
10
|
remote: https://rubygems.org/
|
11
11
|
specs:
|
12
|
-
activemodel (6.1.
|
13
|
-
activesupport (= 6.1.
|
14
|
-
activesupport (6.1.
|
12
|
+
activemodel (6.1.3.2)
|
13
|
+
activesupport (= 6.1.3.2)
|
14
|
+
activesupport (6.1.3.2)
|
15
15
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
16
16
|
i18n (>= 1.6, < 2)
|
17
17
|
minitest (>= 5.1)
|
@@ -19,14 +19,14 @@ GEM
|
|
19
19
|
zeitwerk (~> 2.3)
|
20
20
|
addressable (2.7.0)
|
21
21
|
public_suffix (>= 2.0.2, < 5.0)
|
22
|
-
ast (2.4.
|
23
|
-
awesome_print (1.
|
22
|
+
ast (2.4.2)
|
23
|
+
awesome_print (1.9.2)
|
24
24
|
bump (0.9.0)
|
25
25
|
byebug (11.1.3)
|
26
26
|
childprocess (4.0.0)
|
27
|
-
climate_control (0.
|
27
|
+
climate_control (1.0.1)
|
28
28
|
colorize (0.8.1)
|
29
|
-
concurrent-ruby (1.1.
|
29
|
+
concurrent-ruby (1.1.8)
|
30
30
|
coveralls (0.8.23)
|
31
31
|
json (>= 1.8, < 3)
|
32
32
|
simplecov (~> 0.16.1)
|
@@ -36,20 +36,20 @@ GEM
|
|
36
36
|
crack (0.4.5)
|
37
37
|
rexml
|
38
38
|
diff-lcs (1.4.4)
|
39
|
-
docile (1.
|
39
|
+
docile (1.4.0)
|
40
40
|
dotenv (2.7.6)
|
41
|
-
dry-configurable (0.12.
|
41
|
+
dry-configurable (0.12.1)
|
42
42
|
concurrent-ruby (~> 1.0)
|
43
43
|
dry-core (~> 0.5, >= 0.5.0)
|
44
44
|
dry-container (0.7.2)
|
45
45
|
concurrent-ruby (~> 1.0)
|
46
46
|
dry-configurable (~> 0.1, >= 0.1.3)
|
47
|
-
dry-core (0.
|
47
|
+
dry-core (0.6.0)
|
48
48
|
concurrent-ruby (~> 1.0)
|
49
49
|
dry-equalizer (0.3.0)
|
50
50
|
dry-inflector (0.2.0)
|
51
51
|
dry-initializer (3.0.4)
|
52
|
-
dry-logic (1.
|
52
|
+
dry-logic (1.2.0)
|
53
53
|
concurrent-ruby (~> 1.0)
|
54
54
|
dry-core (~> 0.5, >= 0.5)
|
55
55
|
dry-schema (1.5.6)
|
@@ -60,11 +60,10 @@ GEM
|
|
60
60
|
dry-initializer (~> 3.0)
|
61
61
|
dry-logic (~> 1.0)
|
62
62
|
dry-types (~> 1.4)
|
63
|
-
dry-types (1.
|
63
|
+
dry-types (1.5.1)
|
64
64
|
concurrent-ruby (~> 1.0)
|
65
65
|
dry-container (~> 0.3)
|
66
|
-
dry-core (~> 0.
|
67
|
-
dry-equalizer (~> 0.3)
|
66
|
+
dry-core (~> 0.5, >= 0.5)
|
68
67
|
dry-inflector (~> 0.1, >= 0.1.2)
|
69
68
|
dry-logic (~> 1.0, >= 1.0.2)
|
70
69
|
dry-validation (1.5.6)
|
@@ -76,24 +75,32 @@ GEM
|
|
76
75
|
dry-schema (~> 1.5, >= 1.5.2)
|
77
76
|
factory_bot (6.1.0)
|
78
77
|
activesupport (>= 5.0.0)
|
79
|
-
faraday (1.
|
78
|
+
faraday (1.4.2)
|
79
|
+
faraday-em_http (~> 1.0)
|
80
|
+
faraday-em_synchrony (~> 1.0)
|
81
|
+
faraday-excon (~> 1.1)
|
80
82
|
faraday-net_http (~> 1.0)
|
83
|
+
faraday-net_http_persistent (~> 1.1)
|
81
84
|
multipart-post (>= 1.2, < 3)
|
82
|
-
ruby2_keywords
|
85
|
+
ruby2_keywords (>= 0.0.4)
|
83
86
|
faraday-detailed_logger (2.3.0)
|
84
87
|
faraday (>= 0.8, < 2)
|
85
|
-
faraday-
|
88
|
+
faraday-em_http (1.0.0)
|
89
|
+
faraday-em_synchrony (1.0.0)
|
90
|
+
faraday-excon (1.1.0)
|
91
|
+
faraday-net_http (1.0.1)
|
92
|
+
faraday-net_http_persistent (1.1.0)
|
86
93
|
faraday_middleware (1.0.0)
|
87
94
|
faraday (~> 1.0)
|
88
95
|
fingerprintable (1.2.1)
|
89
96
|
colorize
|
90
97
|
hashdiff (1.0.1)
|
91
|
-
i18n (1.8.
|
98
|
+
i18n (1.8.10)
|
92
99
|
concurrent-ruby (~> 1.0)
|
93
100
|
iniparse (1.5.0)
|
94
101
|
json (2.5.1)
|
95
|
-
jwt (2.2.
|
96
|
-
ledger_sync (
|
102
|
+
jwt (2.2.3)
|
103
|
+
ledger_sync (2.0.1)
|
97
104
|
activemodel
|
98
105
|
colorize
|
99
106
|
dry-schema (~> 1.5.4)
|
@@ -108,15 +115,13 @@ GEM
|
|
108
115
|
rack (~> 2.2.3)
|
109
116
|
resonad
|
110
117
|
simply_serializable (>= 1.5.1)
|
111
|
-
|
112
|
-
minitest (5.14.2)
|
118
|
+
minitest (5.14.4)
|
113
119
|
multi_json (1.15.0)
|
114
120
|
multi_xml (0.6.0)
|
115
121
|
multipart-post (2.1.1)
|
116
|
-
nokogiri (1.11.
|
117
|
-
mini_portile2 (~> 2.5.0)
|
122
|
+
nokogiri (1.11.7-x86_64-darwin)
|
118
123
|
racc (~> 1.4)
|
119
|
-
oauth2 (1.4.
|
124
|
+
oauth2 (1.4.7)
|
120
125
|
faraday (>= 0.8, < 2.0)
|
121
126
|
jwt (>= 1.0, < 3.0)
|
122
127
|
multi_json (~> 1.3)
|
@@ -127,7 +132,7 @@ GEM
|
|
127
132
|
childprocess (>= 0.6.3, < 5)
|
128
133
|
iniparse (~> 1.4)
|
129
134
|
parallel (1.20.1)
|
130
|
-
parser (3.0.
|
135
|
+
parser (3.0.1.1)
|
131
136
|
ast (~> 2.4.1)
|
132
137
|
pd_ruby (0.2.3)
|
133
138
|
colorize
|
@@ -136,9 +141,9 @@ GEM
|
|
136
141
|
rack (2.2.3)
|
137
142
|
rainbow (3.0.0)
|
138
143
|
rake (13.0.3)
|
139
|
-
regexp_parser (2.
|
144
|
+
regexp_parser (2.1.1)
|
140
145
|
resonad (1.4.0)
|
141
|
-
rexml (3.2.
|
146
|
+
rexml (3.2.5)
|
142
147
|
rspec (3.10.0)
|
143
148
|
rspec-core (~> 3.10.0)
|
144
149
|
rspec-expectations (~> 3.10.0)
|
@@ -148,23 +153,23 @@ GEM
|
|
148
153
|
rspec-expectations (3.10.1)
|
149
154
|
diff-lcs (>= 1.2.0, < 2.0)
|
150
155
|
rspec-support (~> 3.10.0)
|
151
|
-
rspec-mocks (3.10.
|
156
|
+
rspec-mocks (3.10.2)
|
152
157
|
diff-lcs (>= 1.2.0, < 2.0)
|
153
158
|
rspec-support (~> 3.10.0)
|
154
|
-
rspec-support (3.10.
|
155
|
-
rubocop (1.
|
159
|
+
rspec-support (3.10.2)
|
160
|
+
rubocop (1.15.0)
|
156
161
|
parallel (~> 1.10)
|
157
|
-
parser (>=
|
162
|
+
parser (>= 3.0.0.0)
|
158
163
|
rainbow (>= 2.2.2, < 4.0)
|
159
164
|
regexp_parser (>= 1.8, < 3.0)
|
160
165
|
rexml
|
161
|
-
rubocop-ast (>= 1.
|
166
|
+
rubocop-ast (>= 1.5.0, < 2.0)
|
162
167
|
ruby-progressbar (~> 1.7)
|
163
|
-
unicode-display_width (>= 1.4.0, <
|
164
|
-
rubocop-ast (1.
|
165
|
-
parser (>=
|
168
|
+
unicode-display_width (>= 1.4.0, < 3.0)
|
169
|
+
rubocop-ast (1.6.0)
|
170
|
+
parser (>= 3.0.1.1)
|
166
171
|
ruby-progressbar (1.11.0)
|
167
|
-
ruby2_keywords (0.0.
|
172
|
+
ruby2_keywords (0.0.4)
|
168
173
|
simplecov (0.16.1)
|
169
174
|
docile (~> 1.1)
|
170
175
|
json (>= 1.8, < 3)
|
@@ -175,14 +180,14 @@ GEM
|
|
175
180
|
sync (0.5.0)
|
176
181
|
term-ansicolor (1.7.1)
|
177
182
|
tins (~> 1.0)
|
178
|
-
thor (1.0
|
179
|
-
tins (1.
|
183
|
+
thor (1.1.0)
|
184
|
+
tins (1.29.1)
|
180
185
|
sync
|
181
186
|
tzinfo (2.0.4)
|
182
187
|
concurrent-ruby (~> 1.0)
|
183
|
-
unicode-display_width (
|
188
|
+
unicode-display_width (2.0.0)
|
184
189
|
vcr (6.0.0)
|
185
|
-
webmock (3.
|
190
|
+
webmock (3.13.0)
|
186
191
|
addressable (>= 2.3.6)
|
187
192
|
crack (>= 0.3.2)
|
188
193
|
hashdiff (>= 0.4.0, < 2.0.0)
|
@@ -54,7 +54,7 @@ while (session = server.accept) # rubocop:disable Lint/UnreachableLoop
|
|
54
54
|
# 2
|
55
55
|
_path, query = full_path.split('?')
|
56
56
|
|
57
|
-
params =
|
57
|
+
params = query.split('&').map { |e| e.split('=') }.to_h if query.present?
|
58
58
|
|
59
59
|
client.set_credentials_from_oauth_code(
|
60
60
|
code: params.fetch('code'),
|
@@ -40,7 +40,7 @@ Gem::Specification.new do |spec|
|
|
40
40
|
spec.add_development_dependency('vcr', '>= 0')
|
41
41
|
spec.add_development_dependency('webmock', '>= 0')
|
42
42
|
spec.add_runtime_dependency('dotenv')
|
43
|
-
spec.add_runtime_dependency('ledger_sync', '
|
43
|
+
spec.add_runtime_dependency('ledger_sync', '>= 2.0.1')
|
44
44
|
# spec.add_runtime_dependency('nokogiri', '>= 0')
|
45
45
|
spec.add_runtime_dependency('oauth2', '>= 0')
|
46
46
|
end
|
@@ -19,10 +19,9 @@ module LedgerSync
|
|
19
19
|
value = hash.fetch('Entity', nil)
|
20
20
|
|
21
21
|
unless value.nil?
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
ledger_id: value['value']
|
22
|
+
Customer.new(
|
23
|
+
ledger_id: value['value'],
|
24
|
+
DisplayName: value['name']
|
26
25
|
)
|
27
26
|
end
|
28
27
|
end
|
@@ -45,7 +45,7 @@ module LedgerSync
|
|
45
45
|
resource: merged_resource
|
46
46
|
)
|
47
47
|
|
48
|
-
resource_hash_from_ledger =
|
48
|
+
resource_hash_from_ledger = resources_from_ledger.map { |e| [e.ledger_id, e] }.to_h
|
49
49
|
|
50
50
|
# Using original resource since it is overwritten by keyword arg
|
51
51
|
merged_value = resource.send(deserializer_attribute.resource_attribute_dot_parts.first).map do |referenced|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ledger_sync-quickbooks_online
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Modern Treasury
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-06-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: awesome_print
|
@@ -210,16 +210,16 @@ dependencies:
|
|
210
210
|
name: ledger_sync
|
211
211
|
requirement: !ruby/object:Gem::Requirement
|
212
212
|
requirements:
|
213
|
-
- - "
|
213
|
+
- - ">="
|
214
214
|
- !ruby/object:Gem::Version
|
215
|
-
version:
|
215
|
+
version: 2.0.1
|
216
216
|
type: :runtime
|
217
217
|
prerelease: false
|
218
218
|
version_requirements: !ruby/object:Gem::Requirement
|
219
219
|
requirements:
|
220
|
-
- - "
|
220
|
+
- - ">="
|
221
221
|
- !ruby/object:Gem::Version
|
222
|
-
version:
|
222
|
+
version: 2.0.1
|
223
223
|
- !ruby/object:Gem::Dependency
|
224
224
|
name: oauth2
|
225
225
|
requirement: !ruby/object:Gem::Requirement
|
@@ -243,8 +243,8 @@ executables: []
|
|
243
243
|
extensions: []
|
244
244
|
extra_rdoc_files: []
|
245
245
|
files:
|
246
|
-
- ".coveralls.yml"
|
247
246
|
- ".env.test"
|
247
|
+
- ".github/workflows/gem-workflow.yml"
|
248
248
|
- ".gitignore"
|
249
249
|
- ".overcommit.yml"
|
250
250
|
- ".rubocop.yml"
|
@@ -434,7 +434,7 @@ files:
|
|
434
434
|
homepage: https://www.ledgersync.dev
|
435
435
|
licenses: []
|
436
436
|
metadata: {}
|
437
|
-
post_install_message:
|
437
|
+
post_install_message:
|
438
438
|
rdoc_options: []
|
439
439
|
require_paths:
|
440
440
|
- lib
|
@@ -449,8 +449,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
449
449
|
- !ruby/object:Gem::Version
|
450
450
|
version: '0'
|
451
451
|
requirements: []
|
452
|
-
rubygems_version: 3.
|
453
|
-
signing_key:
|
452
|
+
rubygems_version: 3.1.6
|
453
|
+
signing_key:
|
454
454
|
specification_version: 4
|
455
455
|
summary: Sync common objects to accounting software.
|
456
456
|
test_files: []
|
data/.coveralls.yml
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
service_name: travis-ci
|