xsys 0.16.0 → 0.16.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d55506187b2a86021d3de5934a78d9a62d3d48df
4
- data.tar.gz: 677e6f6b2df660a37214a5093dc94bfc6d456ec9
3
+ metadata.gz: 030def67848041ef03d9609e1e7a18b4f25b7e94
4
+ data.tar.gz: 7a4bb8ac63b4bafb048b815d8e8da05cbb96a3e0
5
5
  SHA512:
6
- metadata.gz: 4b5c4c21c9df09bdda39a349944fc4b3b7b204cc7bfb5ba369625190525597a404dea1ef85cf607f84f4b89c434b93b1c97fdf49c4ca03c06fdfe63fce39e76e
7
- data.tar.gz: b29637eae6c3bd474ac04808959bf71299995bba90100e877906041b59b1c9a04d36caf25984e0cd38bf98b8be4fcf39a6dcac43e4e90960f77197f644b4074a
6
+ metadata.gz: 9d82ebb9b542c53ffd391def3e0cb0353455c09e1836d401a8a36ba426737c2b0158044b9c6e8e20968d15823fe678eab481603cd2948650691f577790840aa4
7
+ data.tar.gz: 5f0debb76bdead18a912c488730cb4010b8f4e0a757cceb7994eff35dfb7c56fec5a9e58cf617d886f9b3abf8472336efa39d9492a80b2de9323fb396098357f
@@ -349,3 +349,7 @@
349
349
  ## v0.16
350
350
 
351
351
  * Added method to search stock reserves
352
+
353
+ ## v0.16.1
354
+
355
+ * Added method to get stock reserve
@@ -163,6 +163,16 @@ module Xsys
163
163
  end
164
164
  end
165
165
 
166
+ def self.get_stock_reserve(code)
167
+ response_body = get_request("/stock_reserves/#{code}")[:body]
168
+
169
+ if response_body == 'null'
170
+ nil
171
+ else
172
+ Model::StockReserve.new(response_body)
173
+ end
174
+ end
175
+
166
176
  def self.search_stock_reserves(filters={})
167
177
  get_request('/stock_reserves', filters)[:body].map { |x| Model::StockReserve.new(x) }
168
178
  end
@@ -1,3 +1,3 @@
1
1
  module Xsys
2
- VERSION = "0.16.0"
2
+ VERSION = "0.16.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xsys
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.16.0
4
+ version: 0.16.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matias Hick