erp_integration 0.5.2 → 0.5.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ca1bd38eb31b94933e07d32c1dfb1878b734fef2d001a84e56cf788697afe666
4
- data.tar.gz: ed521ad8c1b95896aa152cbd113b63eda01ab49c47888270a4bfc5d6bf7b6662
3
+ metadata.gz: 4ef3df17fffd25f4bb3d44b59fa8a2a2b4495a4d159cb22e06b5fdb852422d19
4
+ data.tar.gz: b9368f71c9adf3b70324ca550370a607e40b97a18588f3719aa541f132debe81
5
5
  SHA512:
6
- metadata.gz: 0ef6a74cf99711e42a3d64c30e44ff2cd65a445ed0f714c6a60fba6a56f895103e51fc74cbb767f719bab90af73dda54120607d41a16a63599b7dacb80b04c07
7
- data.tar.gz: 818024cb6d381c71f883c8f5811eae27bfc29f9f2e245383c4600718651710abbc91f6021005182795e564a58f08fb4f825c1b957fd285e718363adcb3f36e28
6
+ metadata.gz: 208f536ae2693e7d7c0f9541b16d86341deaa8216de7511df93819e0729a71a03aaca4a9f76330707b3a08bb10f2a8b3760f313079fbb43c2bda3968e50ceb4f
7
+ data.tar.gz: 45d12d1855b3d3326072cf39ee1ad5cbde463ed7562bbb8d4fc7ab9c92832904b4834f66d3599a3d89a6d84e1cd854d35bea407ef865a5e8854182ac0c8b1451
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ module ErpIntegration
4
+ # The `ErpIntegration::BillOfMaterial` exposes an uniformed API for interaction with
5
+ # third-party ERP vendors.
6
+ class BillOfMaterial < Resource
7
+ attr_accessor :active, :attachments, :cost, :create_date, :create_uid, :id,
8
+ :inputs, :instructions, :is_built_on_the_fly, :location, :messages,
9
+ :metadata, :name, :output_products, :outputs, :private_notes, :products,
10
+ :public_notes, :quantity_buildable, :quantity_expected, :rec_blurb,
11
+ :rec_name, :routing, :state, :supervisor, :version, :warehouse, :work_center,
12
+ :write_date, :write_uid
13
+ end
14
+ end
@@ -22,11 +22,21 @@ module ErpIntegration
22
22
  # @return [String] The merchant ID for Fulfil.
23
23
  attr_accessor :fulfil_merchant_id
24
24
 
25
+ # Allows configuring an adapter for the `BillOfMaterial` resource. When
26
+ # none is configured, it will default to Fulfil.
27
+ # @return [Symbol] The configured adapter for the bill_of_material.
28
+ attr_writer :bill_of_material_adapter
29
+
25
30
  # Allows configuring an adapter for the `Product` resource. When none is
26
31
  # configured, it will default to Fulfil.
27
32
  # @return [Symbol] The configured adapter for the products.
28
33
  attr_writer :product_adapter
29
34
 
35
+ # Allows configuring an adapter for the `ProductionOrder` resource. When
36
+ # none is configured, it will default to Fulfil.
37
+ # @return [Symbol] The configured adapter for the production_order.
38
+ attr_writer :production_order_adapter
39
+
30
40
  # Allows configuring an adapter for the `PurchaseOrder` resource. When none is
31
41
  # configured, it will default to Fulfil.
32
42
  # @return [Symbol] The configured adapter for the purchase orders.
@@ -68,10 +78,18 @@ module ErpIntegration
68
78
  end
69
79
  end
70
80
 
81
+ def bill_of_material_adapter
82
+ @bill_of_material_adapter || :fulfil
83
+ end
84
+
71
85
  def product_adapter
72
86
  @product_adapter || :fulfil
73
87
  end
74
88
 
89
+ def production_order_adapter
90
+ @production_order_adapter || :fulfil
91
+ end
92
+
75
93
  def purchase_order_adapter
76
94
  @purchase_order_adapter || :fulfil
77
95
  end
@@ -0,0 +1,13 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative '../api_resource'
4
+
5
+ module ErpIntegration
6
+ module Fulfil
7
+ module Resources
8
+ class BillOfMaterial < ApiResource
9
+ self.model_name = 'production.bom'
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,13 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative '../api_resource'
4
+
5
+ module ErpIntegration
6
+ module Fulfil
7
+ module Resources
8
+ class ProductionOrder < ApiResource
9
+ self.model_name = 'production'
10
+ end
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,19 @@
1
+ # frozen_string_literal: true
2
+
3
+ module ErpIntegration
4
+ # The `ErpIntegration::ProductionOrder` exposes an uniformed API for interaction with
5
+ # third-party ERP vendors.
6
+ class ProductionOrder < Resource
7
+ attr_accessor :allow_partial_done, :attachments, :bom, :byproduct_cost, :company,
8
+ :company_currency_digits, :cost, :create_date, :create_uid, :effective_date,
9
+ :effective_start_date, :from_location, :inputs, :inventory_cost, :inventory_cost_cache,
10
+ :labor_cost, :labor_cost_cache, :last_modification, :location, :messages, :metadata, :number,
11
+ :on_hold, :origin, :outputs, :outsourced_work_cost, :outsourced_work_cost_cache, :picked_at,
12
+ :picker, :picking_status, :planned_date, :planned_start_date, :priority, :private_notes, :product,
13
+ :product_code, :production_batch, :public_notes, :purchase_lines, :quantity, :quantity_done,
14
+ :quantity_remaining, :rec_blurb, :description, :id, :subtitle, :thumbnail, :title, :rec_name,
15
+ :reference, :reporting_date, :routing, :sales_order_number, :sales_order_reference, :shipments,
16
+ :state, :supervisor, :to_location, :tsv, :unit_digits, :uom, :uom_category, :warehouse, :work_center,
17
+ :works, :write_date, :write_uid
18
+ end
19
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ErpIntegration
4
- VERSION = '0.5.2'
4
+ VERSION = '0.5.3'
5
5
  end
@@ -20,7 +20,9 @@ require_relative 'erp_integration/fulfil/client'
20
20
  # The `ErpIntegration` integrates Mejuri with third-party ERP vendors.
21
21
  module ErpIntegration
22
22
  # Resources
23
+ autoload :BillOfMaterial, 'erp_integration/bill_of_material'
23
24
  autoload :Product, 'erp_integration/product'
25
+ autoload :ProductionOrder, 'erp_integration/production_order'
24
26
  autoload :PurchaseOrder, 'erp_integration/purchase_order'
25
27
  autoload :PurchaseOrderLine, 'erp_integration/purchase_order_line'
26
28
  autoload :PurchaseRequest, 'erp_integration/purchase_request'
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.5.2
4
+ version: 0.5.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stefan Vermaas
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-10-26 00:00:00.000000000 Z
11
+ date: 2021-10-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -224,7 +224,7 @@ dependencies:
224
224
  - - '='
225
225
  - !ruby/object:Gem::Version
226
226
  version: 1.19.2
227
- description:
227
+ description:
228
228
  email:
229
229
  - stefan@knowndecimal.com
230
230
  executables: []
@@ -259,13 +259,16 @@ files:
259
259
  - bin/setup
260
260
  - erp_integration.gemspec
261
261
  - lib/erp_integration.rb
262
+ - lib/erp_integration/bill_of_material.rb
262
263
  - lib/erp_integration/configuration.rb
263
264
  - lib/erp_integration/errors.rb
264
265
  - lib/erp_integration/fulfil/api_resource.rb
265
266
  - lib/erp_integration/fulfil/client.rb
266
267
  - lib/erp_integration/fulfil/query.rb
267
268
  - lib/erp_integration/fulfil/query_methods.rb
269
+ - lib/erp_integration/fulfil/resources/bill_of_material.rb
268
270
  - lib/erp_integration/fulfil/resources/product.rb
271
+ - lib/erp_integration/fulfil/resources/production_order.rb
269
272
  - lib/erp_integration/fulfil/resources/purchase_order.rb
270
273
  - lib/erp_integration/fulfil/resources/purchase_order_line.rb
271
274
  - lib/erp_integration/fulfil/resources/purchase_request.rb
@@ -276,6 +279,7 @@ files:
276
279
  - lib/erp_integration/fulfil/where_clause.rb
277
280
  - lib/erp_integration/middleware/error_handling.rb
278
281
  - lib/erp_integration/product.rb
282
+ - lib/erp_integration/production_order.rb
279
283
  - lib/erp_integration/purchase_order.rb
280
284
  - lib/erp_integration/purchase_order_line.rb
281
285
  - lib/erp_integration/purchase_request.rb
@@ -293,7 +297,7 @@ metadata:
293
297
  homepage_uri: https://www.github.com/mejuri-inc/erp-integration
294
298
  source_code_uri: https://www.github.com/mejuri-inc/erp-integration
295
299
  changelog_uri: https://www.github.com/mejuri-inc/erp-integration/blob/main/CHANGELOG.md
296
- post_install_message:
300
+ post_install_message:
297
301
  rdoc_options: []
298
302
  require_paths:
299
303
  - lib
@@ -309,7 +313,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
309
313
  version: '0'
310
314
  requirements: []
311
315
  rubygems_version: 3.2.22
312
- signing_key:
316
+ signing_key:
313
317
  specification_version: 4
314
318
  summary: Connects Mejuri with third-party ERP vendors
315
319
  test_files: []