huginn_bigcommerce_product_agent 1.8.0 → 1.9.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: 8bbd3a133d224fea3726d9b0f8b86803957e919e225e983be8ac3a1c7c027312
|
4
|
+
data.tar.gz: 202e2165d11044d4f44e722aa39e61224b819b344304e73e3c9e888c0a20153a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 87204345ec8502a89ac61b5de9bf21f8daf8ab34b3b22cb2563e6a55b90da6239e2dc92d096caf4e9b8e08b2591286ac3f4b8b36a6ba07efecafdbafdf3d93bb
|
7
|
+
data.tar.gz: abe689235f182acf5c2eb977d9179af9b7431a1537435093a140e54e16b1981bb901fa02ec2bdc8e3469c96fab3d314474f63714caa835d878edcb375223f781
|
data/lib/client/variant.rb
CHANGED
@@ -15,10 +15,9 @@ module BigcommerceProductAgent
|
|
15
15
|
begin
|
16
16
|
response = client.put(uri, payload.to_json)
|
17
17
|
return response.body['data']
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
end
|
18
|
+
rescue Faraday::Error::ClientError => e
|
19
|
+
raise e, "\n#{e.message}\nFailed to upsert variant with payload = #{payload.to_json}\n", e.backtrace
|
20
|
+
end
|
22
21
|
end
|
23
22
|
|
24
23
|
def get_by_skus(skus, include = %w[custom_fields modifiers])
|
@@ -152,6 +152,7 @@ module Agents
|
|
152
152
|
# Ignatius Press -- some products have the same name and must be disambiguated.
|
153
153
|
# ...by adding a list of the product types (hardback, paperback, etc.) to their names
|
154
154
|
if boolify(options['should_disambiguate'])
|
155
|
+
product['page_title'] = product['name']
|
155
156
|
product['name'] += " |~ " + product['model'].map { |m|
|
156
157
|
m['additionalProperty'].find { |p|
|
157
158
|
p['propertyID'] == 'option'
|
@@ -46,6 +46,7 @@ module BigcommerceProductAgent
|
|
46
46
|
preorder_release_date: product['releaseDate'] && product['releaseDate'].to_datetime ? product['releaseDate'].to_datetime.strftime("%FT%T%:z") : nil,
|
47
47
|
preorder_message: self.get_availability(product) == 'preorder' ? product['availability'] : '',
|
48
48
|
is_preorder_only: self.get_availability(product) == 'preorder' ? true : false,
|
49
|
+
page_title: product['page_title'] || '',
|
49
50
|
}
|
50
51
|
result[:upc] = product['gtin12'] if product['gtin12']
|
51
52
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: huginn_bigcommerce_product_agent
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jacob Spizziri
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-07-
|
11
|
+
date: 2020-07-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|