erp_integration 0.31.0 → 0.32.0

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
  SHA256:
3
- metadata.gz: 1d0074006354a9ad9fcccfdb36d1c9a0b39fe8df0ab30a70a4b448f7e6a0df48
4
- data.tar.gz: 9e9fc4556694e3a5d9b778f86790ef3402d794d53174636a598c7a2010854665
3
+ metadata.gz: 68d6ab5f0b8acef6529a34e21cd851993017341ad68c7c1fb1dfb1ccd2762edd
4
+ data.tar.gz: b2ee68b1369e4cc4eee5bb479cae9f12eee26f0d892db7a4b1e93e7fa7c3c31c
5
5
  SHA512:
6
- metadata.gz: 7ab43b58b98d98bf43ec75a7a89e4dffc75b309799f83a2f5b803d15ab0e690df8084adae8b1702804e32d3575c74a93da2bf00d63e4572c3024fcb7ed24d58b
7
- data.tar.gz: 9f4aa6467c0207ddb5ca5647a1f70452d4e297f94ccf5207c382d92d71d4e4c23b92e553abffd1692a45d7dcccb5ec8b04f4a04015ba69eae4da814220dbb0ff
6
+ metadata.gz: 0b1b421b5dd434a0a5607a78ffc5935a65c5f6c867bd964547689cf1a90fcccfb991aad1fcc04d36090bdbc32ac8b9da6ba25efee8264dc7e83f13c5bf5c70ca
7
+ data.tar.gz: 329629ed3de09845cd3c9eeb1114f3ca96d245bea2970f423e5e74efe501ca2b1d2bfe48044ad97ed652a254bc561e2f66193a7c59193913d64379f10f3e6b85
@@ -40,5 +40,12 @@ module ErpIntegration
40
40
  def create_package(id, options)
41
41
  self.class.adapter.create_package(id, options)
42
42
  end
43
+
44
+ # Mark a {CustomerShipmentRetun} as received.
45
+ #
46
+ # @param id [Integer] The ID of the {CustomerShipmentReturn}.
47
+ def receive!(id)
48
+ self.class.adapter.receive!(id)
49
+ end
43
50
  end
44
51
  end
@@ -25,6 +25,13 @@ module ErpIntegration
25
25
  def create_package(id, options)
26
26
  client.put("model/#{model_name}/#{id}", options)
27
27
  end
28
+
29
+ def receive!(id)
30
+ client.put("model/#{model_name}/#{id}/receive")
31
+ true
32
+ rescue Faraday::ParsingError
33
+ true
34
+ end
28
35
  end
29
36
  end
30
37
  end
@@ -34,5 +34,9 @@ module ErpIntegration
34
34
  def process
35
35
  self.class.adapter.process(id)
36
36
  end
37
+
38
+ def shipped?
39
+ state == 'done'
40
+ end
37
41
  end
38
42
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ErpIntegration
4
- VERSION = '0.31.0'
4
+ VERSION = '0.32.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: erp_integration
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.31.0
4
+ version: 0.32.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefan Vermaas
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-04-28 00:00:00.000000000 Z
11
+ date: 2023-05-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -345,7 +345,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
345
345
  - !ruby/object:Gem::Version
346
346
  version: '0'
347
347
  requirements: []
348
- rubygems_version: 3.3.3
348
+ rubygems_version: 3.2.22
349
349
  signing_key:
350
350
  specification_version: 4
351
351
  summary: Connects Mejuri with third-party ERP vendors