akeneo 1.7.1 → 1.8.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: e7106ae925bd2cad04c32f0c7352c2d56dcff9ea011966a993b84701b0a10646
4
- data.tar.gz: a2af5399f0b6bdc968633af6f9271fa694588183d28b78ee27651bcb294d665b
3
+ metadata.gz: 0e2c55807f94475e39690f1ac2eb6782379f501a3c89e8fa6a45b8073199bd70
4
+ data.tar.gz: 332e8bf0c5ccb96d735e40bc602b48da245b0970e5dc9716c908feb8974638bc
5
5
  SHA512:
6
- metadata.gz: 6cb9c83524f92918b7a6aa40184788db6da2161101f5d6d313f29589dd36677e84b1beba8924e5d7ff5e39c29a669a73e8fadd4466ac81bf951db12cb8d74161
7
- data.tar.gz: da185c7637374c421ff0333940c33be170a9f101902e1a3679c136d72780e0000de65b6b4744a2792800b0fa419539dea10e204d1a410cc66b712878000d0bb3
6
+ metadata.gz: 7ea4ddf2d9aa56a77c05697140fdea805e349da2736ef7c8e90097eb0d6c6ae3c7e959375f0ea7df29e04abd464044ccabd4ce9dbeabef0a07e717e3fb40bab6
7
+ data.tar.gz: 0e7b75d0a365852842118be5c027ca7cbb7cb16c337feaadc0c76a137a114b29d95fd86953bef567e3a14e5c1571e275674d8351740dc6bff93391ae73bb2695
@@ -32,7 +32,7 @@ GEM
32
32
  powerpack (0.1.2)
33
33
  public_suffix (3.0.3)
34
34
  rainbow (3.0.0)
35
- rake (12.3.2)
35
+ rake (13.0.1)
36
36
  redis (4.1.2)
37
37
  rspec (3.8.0)
38
38
  rspec-core (~> 3.8.0)
@@ -5,7 +5,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
 
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = 'akeneo'
8
- spec.version = '1.7.1'
8
+ spec.version = '1.8.0'
9
9
  spec.authors = ['AWN Dev Team']
10
10
  spec.email = ['edv@awn.de']
11
11
 
@@ -43,6 +43,10 @@ module Akeneo
43
43
  product_service.create_or_update(code, options)
44
44
  end
45
45
 
46
+ def create_product(options:)
47
+ product_service.create(options)
48
+ end
49
+
46
50
  def create_or_update_product_model(code:, options:)
47
51
  product_model_service.create_or_update(code, options)
48
52
  end
@@ -44,6 +44,10 @@ module Akeneo
44
44
  patch_request("/products/#{code}", body: options.to_json)
45
45
  end
46
46
 
47
+ def create(options)
48
+ post_request('/products', body: options.to_json)
49
+ end
50
+
47
51
  def create_several(product_objects)
48
52
  patch_for_collection_request('/products', body: product_objects.to_json)
49
53
  end
@@ -68,6 +68,13 @@ module Akeneo
68
68
  )
69
69
  end
70
70
 
71
+ def post_request(path, options = {})
72
+ HTTParty.post(
73
+ build_url(path),
74
+ options.merge(headers: default_request_headers)
75
+ )
76
+ end
77
+
71
78
  def patch_for_collection_request(path, options = {})
72
79
  HTTParty.patch(
73
80
  build_url(path),
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: akeneo
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.1
4
+ version: 1.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - AWN Dev Team
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2019-07-23 00:00:00.000000000 Z
11
+ date: 2020-06-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake