zaikio-warehouse 0.2.5 → 0.3.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1f01f8be0e19be448f0d2be8e58569ea4abf9305b82ba563f31b900b65073d26
|
4
|
+
data.tar.gz: da417c6747ed9344a7f05ce127ed19309928810942cd3038279f56f567405fc6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cd03a249550178a06346064262dbbbda345dc0f53bb5f05a4aa149e2e4e3e004b63418995b9ee84a97455b4085f2d82506800fd97d28b098277501a399ea8c3c
|
7
|
+
data.tar.gz: 5af5f9f0c1f2a77db17d38ed5688dd0b1a3d708bb32550d9aa4461890cd8cea225121c50a7de4e563b9b83108b4cee285331aa454368b5b2acb8573fddd8ad01
|
data/CHANGELOG.md
CHANGED
@@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
7
7
|
|
8
8
|
## [Unreleased]
|
9
9
|
|
10
|
+
## [0.3.0] - 2023-06-29
|
11
|
+
|
12
|
+
- Add `call_off_agreement` assoctiation to GCO `LineItem`
|
13
|
+
- Reflect API changes in `CallOffAgreement`
|
14
|
+
|
10
15
|
## [0.2.5] - 2023-06-26
|
11
16
|
|
12
17
|
- Fixed relative class names in `CallOff`
|
@@ -42,7 +47,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
42
47
|
- Update and reuse `zaikio-client-helpers` logic to support `Zaikio::Client.with_token`
|
43
48
|
- Initial release
|
44
49
|
|
45
|
-
[Unreleased]: https://github.com/zaikio/zaikio-warehouse-ruby/compare/v0.
|
50
|
+
[Unreleased]: https://github.com/zaikio/zaikio-warehouse-ruby/compare/v0.3.0..HEAD
|
51
|
+
[0.3.0]: https://github.com/zaikio/zaikio-warehouse-ruby/compare/v0.2.5..v0.3.0
|
46
52
|
[0.2.5]: https://github.com/zaikio/zaikio-warehouse-ruby/compare/v0.2.4..v0.2.5
|
47
53
|
[0.2.4]: https://github.com/zaikio/zaikio-warehouse-ruby/compare/v0.2.3..v0.2.4
|
48
54
|
[0.2.3]: https://github.com/zaikio/zaikio-warehouse-ruby/compare/v0.2.2..v0.2.3
|
@@ -4,16 +4,17 @@ module Zaikio
|
|
4
4
|
module Warehouse
|
5
5
|
# See https://docs.zaikio.com/api/warehouse/warehouse.html#/SKUs/get_skus__sku_id__call_off_agreement
|
6
6
|
class CallOffAgreement < Base
|
7
|
-
uri "
|
7
|
+
uri "materials/:material_id/call_off_agreements/(:id)"
|
8
8
|
include_root_in_json :call_off_agreement
|
9
9
|
|
10
|
-
attributes :contract_number, :expires_on, :expired_on, :expires_after_amount_called_off,
|
11
|
-
:
|
10
|
+
attributes :contract_number, :expires_on, :expired_on, :expires_after_amount_called_off, :customer_id,
|
11
|
+
:sales_price_per_base_unit, :sales_price_per_base_unit_currency, :deletable, :created_at, :updated_at
|
12
12
|
|
13
|
-
has_one :
|
13
|
+
has_one :material, uri: nil, class_name: "Zaikio::Warehouse::Material"
|
14
|
+
has_one :customer, uri: nil, class_name: "Zaikio::Warehouse::Contact"
|
14
15
|
|
15
16
|
def reload
|
16
|
-
self.attributes = self.class.where(
|
17
|
+
self.attributes = self.class.where(material_id: material.id).find(id).attributes
|
17
18
|
end
|
18
19
|
end
|
19
20
|
end
|
@@ -23,6 +23,7 @@ module Zaikio
|
|
23
23
|
attributes :quantity, :created_at, :updated_at, :picked_at
|
24
24
|
|
25
25
|
has_one :sku, uri: nil, class_name: "Zaikio::Warehouse::SKU"
|
26
|
+
has_one :call_off_agreement, uri: nil, class_name: "Zaikio::Warehouse::CallOffAgreement"
|
26
27
|
has_one :picked_by, uri: nil, class_name: "Zaikio::Warehouse::Person"
|
27
28
|
end
|
28
29
|
|
@@ -22,6 +22,8 @@ module Zaikio
|
|
22
22
|
has_many :material_reservations,
|
23
23
|
uri: "materials/:material_id/material_reservations",
|
24
24
|
class_name: "Zaikio::Warehouse::MaterialReservation"
|
25
|
+
has_many :call_off_agreements, uri: "materials/:material_id/call_off_agreements",
|
26
|
+
class_name: "Zaikio::Warehouse::CallOffAgreement"
|
25
27
|
|
26
28
|
def merge(into_material_or_material_id)
|
27
29
|
self.class.request(:post, "#{collection_name}/#{id}/merge_into/#{into_material_or_material_id.to_param}")
|
data/lib/zaikio/warehouse/sku.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: zaikio-warehouse
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Zaikio GmbH
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-06-
|
12
|
+
date: 2023-06-29 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|