atol 0.4 → 0.4.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.travis.yml +1 -1
- data/Gemfile.lock +2 -2
- data/README.md +2 -2
- data/lib/atol/request/post_document.rb +1 -1
- data/lib/atol/request/post_document/sell/body.rb +1 -1
- data/lib/atol/transaction/get_token.rb +0 -1
- data/lib/atol/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 9e009c1d0d842a48e5775c9944271c78a10bf63484eb9ef09e15df4ebbde32b2
|
4
|
+
data.tar.gz: 11896f87fc35898404c80e09b3f52a74c067d2127fc313398fdf5ab5f75c9a28
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 82ec658605b79be5c565443b50442795ea5577863da30c8802303febd34b56b7664d99be46a47525a732f8506497d24cce7dc346fbbcdbb23d25d2aaef49f42b
|
7
|
+
data.tar.gz: 11eacd2d1d7cd711f70a2d47201d36b60e99de94afa40f7c00307eace0eff1cfc570ebf9f83acfbea6b7b67258ae76164fc92a762ddfa4a3fc6376ca61dd732c
|
data/.travis.yml
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
atol (0.4)
|
4
|
+
atol (0.4.1)
|
5
5
|
anyway_config (~> 1.0)
|
6
6
|
|
7
7
|
GEM
|
@@ -9,7 +9,7 @@ GEM
|
|
9
9
|
specs:
|
10
10
|
addressable (2.5.2)
|
11
11
|
public_suffix (>= 2.0.2, < 4.0)
|
12
|
-
anyway_config (1.1
|
12
|
+
anyway_config (1.4.1)
|
13
13
|
ast (2.3.0)
|
14
14
|
coveralls (0.8.21)
|
15
15
|
json (>= 1.8, < 3)
|
data/README.md
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
![ruby-logo](https://www.ruby-lang.org/images/header-ruby-logo.png)
|
2
2
|
![atol-logo](http://www.atol.ru/site_styles/img/logo-red.png)
|
3
3
|
|
4
|
-
[![Gem Version](https://badge.fury.io/rb/atol.svg)](https://badge.fury.io/rb/atol) [![BuildStatus](https://travis-ci.org/
|
4
|
+
[![Gem Version](https://badge.fury.io/rb/atol.svg)](https://badge.fury.io/rb/atol) [![BuildStatus](https://travis-ci.org/sputnik8/atol-rb.png)](https://api.travis-ci.org/sputnik8/atol-rb.png) [![Maintainability](https://api.codeclimate.com/v1/badges/fb0179622d762c8157ba/maintainability)](https://codeclimate.com/github/sputnik8/atol-rb/maintainability) [![Coverage Status](https://coveralls.io/repos/github/sputnik8/atol-rb/badge.svg?branch=master)](https://coveralls.io/github/sputnik8/atol-rb?branch=master)
|
5
5
|
|
6
6
|
# atol-rb
|
7
7
|
|
@@ -9,7 +9,7 @@
|
|
9
9
|
|
10
10
|
##### Совместимость
|
11
11
|
|
12
|
-
Для корректной работы необходим интерпретатор Руби версии 2.
|
12
|
+
Для корректной работы необходим интерпретатор Руби версии 2.5. Пакет работает с версией протокола v4.
|
13
13
|
|
14
14
|
|
15
15
|
## Использование
|
@@ -26,7 +26,7 @@ module Atol
|
|
26
26
|
def call
|
27
27
|
http_client = @config.http_client
|
28
28
|
uri = URI("#{Atol::URL}/#{@config.group_code}/#{@operation}")
|
29
|
-
req_headers = HEADERS.merge(Token
|
29
|
+
req_headers = HEADERS.merge('Token' => @token)
|
30
30
|
req = http_client::Post.new(uri, req_headers)
|
31
31
|
req.body = @body
|
32
32
|
|
@@ -33,7 +33,7 @@ module Atol
|
|
33
33
|
result[:receipt][:attributes][:phone] = @phone unless @phone.empty?
|
34
34
|
result[:service][:callback_url] = @config.callback_url if @config.callback_url
|
35
35
|
|
36
|
-
total = @items.
|
36
|
+
total = @items.inject(0) { |sum, item| sum += item[:sum] }
|
37
37
|
|
38
38
|
result[:receipt][:total] = total
|
39
39
|
result[:receipt][:payments][0][:sum] = total
|
data/lib/atol/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: atol
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GeorgeGorbanev
|
@@ -144,7 +144,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
144
144
|
version: '0'
|
145
145
|
requirements: []
|
146
146
|
rubyforge_project:
|
147
|
-
rubygems_version: 2.
|
147
|
+
rubygems_version: 2.7.3
|
148
148
|
signing_key:
|
149
149
|
specification_version: 4
|
150
150
|
summary: ATOL KaaS client for Ruby
|