xdelivery 0.1.6 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/xdelivery.rb +2 -0
- data/lib/xdelivery/api/invoice_settings.rb +9 -0
- data/lib/xdelivery/api/orders.rb +1 -1
- data/lib/xdelivery/api/response/invoice_settings.rb +20 -0
- data/lib/xdelivery/client.rb +4 -0
- data/lib/xdelivery/version.rb +1 -1
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f7505c61730226f3cdf2b83f081d87f5229aee96
|
4
|
+
data.tar.gz: 1a7436d6092059754d66ec08eebc213af68f7e5b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0426f6199d154c21de0099785d25268d30bf96f49ffb3d19a7f7b341a0845cbf27a371717e866c8f0648fd7ff30a43ff6aba0337e009a90a4344fec54dd62347
|
7
|
+
data.tar.gz: 770aad3849dcf3e67aa5fc59b8c9a51a18ee8cb1072ef7ebf88c83b28388201cb9341d9a901754988dd6d0a4ed934eafdc896d546cd613e446ca939ea625b541
|
data/Gemfile.lock
CHANGED
data/lib/xdelivery.rb
CHANGED
@@ -7,10 +7,12 @@ require "xdelivery/api/orders"
|
|
7
7
|
require "xdelivery/api/sales"
|
8
8
|
require "xdelivery/api/products"
|
9
9
|
require "xdelivery/api/ping"
|
10
|
+
require "xdelivery/api/invoice_settings"
|
10
11
|
require "xdelivery/api/response/base"
|
11
12
|
require "xdelivery/api/response/orders"
|
12
13
|
require "xdelivery/api/response/products"
|
13
14
|
require "xdelivery/api/response/ping"
|
15
|
+
require "xdelivery/api/response/invoice_settings"
|
14
16
|
|
15
17
|
|
16
18
|
module Xdelivery
|
data/lib/xdelivery/api/orders.rb
CHANGED
@@ -12,7 +12,7 @@ module Xdelivery
|
|
12
12
|
]
|
13
13
|
|
14
14
|
INVOICE_COLUMNS = [
|
15
|
-
:create_type, :email, :company_code, :donate_code, :device_id, :device, :items
|
15
|
+
:create_type, :email, :company_code, :donate_code, :device_id, :device, :items, :invoice_setting_id
|
16
16
|
]
|
17
17
|
|
18
18
|
def add(params, invoice_params={})
|
@@ -0,0 +1,20 @@
|
|
1
|
+
module Xdelivery
|
2
|
+
module API
|
3
|
+
module Response
|
4
|
+
class InvoiceSettings < Base
|
5
|
+
|
6
|
+
Setting = Struct.new(:id, :title, :pay2go_merchant_id, :default_setting)
|
7
|
+
|
8
|
+
def status?
|
9
|
+
auth?
|
10
|
+
end
|
11
|
+
|
12
|
+
def settings
|
13
|
+
data.map do |setting|
|
14
|
+
Setting.new(setting['id'], setting['title'], setting['pay2go_merchant_id'], setting['default_setting'])
|
15
|
+
end
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
data/lib/xdelivery/client.rb
CHANGED
data/lib/xdelivery/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: xdelivery
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- eddie
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-
|
11
|
+
date: 2019-07-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -98,10 +98,12 @@ files:
|
|
98
98
|
- bin/setup
|
99
99
|
- lib/xdelivery.rb
|
100
100
|
- lib/xdelivery/api/base.rb
|
101
|
+
- lib/xdelivery/api/invoice_settings.rb
|
101
102
|
- lib/xdelivery/api/orders.rb
|
102
103
|
- lib/xdelivery/api/ping.rb
|
103
104
|
- lib/xdelivery/api/products.rb
|
104
105
|
- lib/xdelivery/api/response/base.rb
|
106
|
+
- lib/xdelivery/api/response/invoice_settings.rb
|
105
107
|
- lib/xdelivery/api/response/orders.rb
|
106
108
|
- lib/xdelivery/api/response/ping.rb
|
107
109
|
- lib/xdelivery/api/response/products.rb
|