spree_skroutz 1.1.0 → 1.1.1

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: 4d5e2d656f9e150399440ecd6f8b4e16fd17243567496fbf34d9b9fa2b10cd57
4
- data.tar.gz: ed0e2e6f0bac43ce156342a4ed8f411575963f3f241e474f151fef1349c6802f
3
+ metadata.gz: 5394f1db7c5d89f7ec1dd5607d30e0248c0df759f2445a773e37904568e6ac36
4
+ data.tar.gz: 4d4abdf6d863abae7ad7a7d0136b6d0ed3e2746d31074ccafe7f0d2cf9e7b354
5
5
  SHA512:
6
- metadata.gz: 98ab27ccc682d9c6004501e51adf0b10746346503412a4e6c62cba1ac8fbb5764814123710db37214c73467e67ff1bd859bcdef0716405b8e03a676058ba9525
7
- data.tar.gz: 50a8e3a8289a0e7218d55b93591406028ccc3f5155143397b3f2aa02fa5805782e295fb2f18272ed0e2d72b88cd273889979873f5ba217100f8a2454825bd9a6
6
+ metadata.gz: fdda074e62c392f2c7825404d1da9a5bfa350069083bbf78d99cad7e9682fa157b90c8ac5521ec9fea01202b100fcb52b331a64e571a94ab339a99951351c727
7
+ data.tar.gz: e5fbaa92f72de6b865e7bc3dcd08af094c3664cb474739f62065898afb7cb2a327992515d6b6856f5b44eda92cfb90e2e08d351b4e4e613f6343c5cf262ad5f8
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # SpreeSkroutz
1
+ # Spree Skroutz
2
2
 
3
3
  This is a Skroutz extension for [Spree Commerce](https://spreecommerce.org), an open‑source e-commerce platform built with Ruby on Rails. It adds the ability to provide products listings to Skroutz Martketplace.
4
4
 
@@ -6,51 +6,58 @@ This is a Skroutz extension for [Spree Commerce](https://spreecommerce.org), an
6
6
 
7
7
  ## Installation
8
8
 
9
- 1. Add this extension to your Gemfile:
9
+ 1. Add this extension to your Gemfile with this line:
10
10
 
11
11
  ```bash
12
12
  bundle add spree_skroutz
13
13
  ```
14
14
 
15
- 2. Restart your server.
15
+ 2. Restart your server
16
+
17
+ ## Usage
18
+
19
+ To use your Skroutz endpoint as a data source in Skroutz Merchants:
20
+
21
+ 1. **Deploy your endpoint**
22
+ Ensure your authentication and data endpoints are publicly accessible and return the required data format (e.g., XML, CSV, or JSON).
23
+ For this extension, your endpoint will typically be:
24
+ `https://yoursite.com/skroutz/products.xml`
25
+
26
+ 2. **Copy your endpoint URL**
27
+ This is the URL that Skroutz Merchants will fetch data from.
28
+
29
+ 3. **Add as a data feed in Skroutz Merchants**
30
+ - Go to [Skroutz Merchants](https://merchants.skroutz.gr/).
31
+ - In the header, click **Settings & tools**.
32
+ - Select **Data sources**.
33
+ - Click **Add product source**.
34
+ - Enter your endpoint URL (e.g., `https://yoursite.com/skroutz/products.xml`) as the feed source.
35
+ - Set fetch frequency and credentials if authentication is required.
16
36
 
17
37
  ## Developing
18
38
 
19
- 1. Create a dummy app:
39
+ 1. Create a dummy app
20
40
 
21
41
  ```bash
22
42
  bundle update
23
43
  bundle exec rake test_app
24
44
  ```
25
45
 
26
- 2. Add code.
46
+ 2. Add your new code
27
47
 
28
- 3. Run tests:
48
+ 3. Run tests
29
49
 
30
50
  ```bash
31
51
  bundle exec rspec
32
52
  ```
33
53
 
34
- When testing your application's integration you may use its factories:
54
+ When testing your applications integration with this extension you may use it's factories.
55
+ Simply add this require statement to your spec_helper:
35
56
 
36
57
  ```ruby
37
58
  require 'spree_skroutz/factories'
38
59
  ```
39
60
 
40
- ## Testing
41
-
42
- Generate the test app:
43
-
44
- ```bash
45
- bundle exec rake test_app
46
- ```
47
-
48
- Then run:
49
-
50
- ```bash
51
- bundle exec rspec
52
- ```
53
-
54
61
  ## Releasing a new version
55
62
 
56
63
  ```bash
@@ -1,2 +1 @@
1
1
  //= link_tree ../images
2
-
@@ -35,7 +35,7 @@ xml.mywebstore do
35
35
  xml.cdata! product_breadcrumb_taxons(product).map(&:name).join(' > ')
36
36
  end
37
37
 
38
- xml.tag! "price_with_vat", format('%.2f', product.display_amount.to_d)
38
+ xml.tag! "price_with_vat", format('%.2f', product.display_price.to_d)
39
39
 
40
40
  if product.tax_category.present?
41
41
  tax_rate = product.tax_category.tax_rates.first
@@ -46,9 +46,9 @@ xml.mywebstore do
46
46
 
47
47
  xml.tag! "availability", product.in_stock? ? "In stock" : "Out of stock"
48
48
 
49
- if product.brand.present?
49
+ if product.brand_taxon.present?
50
50
  xml.tag! "manufacturer" do
51
- xml.cdata! product.brand.name
51
+ xml.cdata! product.brand_taxon.name
52
52
  end
53
53
  end
54
54
 
@@ -81,7 +81,7 @@ xml.mywebstore do
81
81
  xml.tag! "variationid", variant.id
82
82
  xml.tag! "availability", variant.in_stock? ? "In stock" : "Out of stock"
83
83
  xml.tag! "ean", variant.barcode if variant.barcode.present?
84
- xml.tag! "price_with_vat", format('%.2f', variant.display_amount.to_d)
84
+ xml.tag! "price_with_vat", format('%.2f', variant.display_price.to_d)
85
85
 
86
86
  size = variant.option_values.select{|ov| ov.option_type.name.downcase == 'size' }
87
87
  .map(&:presentation)
@@ -1,3 +1,3 @@
1
1
  Rails.application.config.after_initialize do
2
- Rails.application.config.spree.integrations << Spree::Integrations::Skroutz
2
+ Spree.integrations << Spree::Integrations::Skroutz
3
3
  end
@@ -5,4 +5,4 @@ el:
5
5
  integrations:
6
6
  skroutz:
7
7
  title: Skroutz
8
- description: Το Skroutz είναι εργαλείο για καταχωρίσεις προϊόντων στο Skroutz Marketplace
8
+ description: Το Skroutz είναι εργαλείο για καταχωρίσεις προϊόντων στο Skroutz Merchants
@@ -5,4 +5,4 @@ en:
5
5
  integrations:
6
6
  skroutz:
7
7
  title: Skroutz
8
- description: Skroutz is a channel integration for product listings on Skroutz Marketplace
8
+ description: Skroutz is a channel integration for product listings on Skroutz Merchants
@@ -17,8 +17,8 @@ module SpreeSkroutz
17
17
  app.config.assets.precompile += %w[spree_skroutz_manifest]
18
18
  end
19
19
 
20
- initializer 'spree_skroutz.importmap', after: 'spree.admin.importmap' do |app|
21
- app.config.spree_admin.importmap.draw(root.join('config/importmap.rb'))
20
+ initializer 'spree_skroutz.importmap', before: 'importmap' do |app|
21
+ app.config.importmap.paths << root.join('config/importmap.rb')
22
22
  end
23
23
 
24
24
  def self.activate
@@ -1,5 +1,5 @@
1
1
  module SpreeSkroutz
2
- VERSION = '1.1.0'.freeze
2
+ VERSION = '1.1.1'.freeze
3
3
 
4
4
  def gem_version
5
5
  Gem::Version.new(VERSION)
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spree_skroutz
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - OlympusOne
@@ -15,42 +15,42 @@ dependencies:
15
15
  requirements:
16
16
  - - ">="
17
17
  - !ruby/object:Gem::Version
18
- version: 5.1.8
18
+ version: 5.2.0
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - ">="
24
24
  - !ruby/object:Gem::Version
25
- version: 5.1.8
25
+ version: 5.2.0
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: spree_storefront
28
28
  requirement: !ruby/object:Gem::Requirement
29
29
  requirements:
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 5.1.8
32
+ version: 5.2.0
33
33
  type: :runtime
34
34
  prerelease: false
35
35
  version_requirements: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - ">="
38
38
  - !ruby/object:Gem::Version
39
- version: 5.1.8
39
+ version: 5.2.0
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: spree_admin
42
42
  requirement: !ruby/object:Gem::Requirement
43
43
  requirements:
44
44
  - - ">="
45
45
  - !ruby/object:Gem::Version
46
- version: 5.1.8
46
+ version: 5.2.0
47
47
  type: :runtime
48
48
  prerelease: false
49
49
  version_requirements: !ruby/object:Gem::Requirement
50
50
  requirements:
51
51
  - - ">="
52
52
  - !ruby/object:Gem::Version
53
- version: 5.1.8
53
+ version: 5.2.0
54
54
  - !ruby/object:Gem::Dependency
55
55
  name: spree_extension
56
56
  requirement: !ruby/object:Gem::Requirement
@@ -79,7 +79,7 @@ dependencies:
79
79
  - - ">="
80
80
  - !ruby/object:Gem::Version
81
81
  version: '0'
82
- description: Adds the ability to provide products listings to Skroutz Marketplace.
82
+ description: Adds the ability to provide products listings to Skroutz Merchants.
83
83
  email: info@olympusone.com
84
84
  executables: []
85
85
  extensions: []
@@ -108,10 +108,10 @@ licenses:
108
108
  - AGPL-3.0-or-later
109
109
  metadata:
110
110
  bug_tracker_uri: https://github.com/olympusone/spree_skroutz/issues
111
- changelog_uri: https://github.com/olympusone/spree_skroutz/releases/tag/v1.1.0
111
+ changelog_uri: https://github.com/olympusone/spree_skroutz/releases/tag/v1.1.1
112
112
  documentation_uri: https://github.com/olympusone/spree_skroutz
113
113
  homepage_uri: https://github.com/olympusone/spree_skroutz
114
- source_code_uri: https://github.com/olympusone/spree_skroutz/tree/v1.1.0
114
+ source_code_uri: https://github.com/olympusone/spree_skroutz/tree/v1.1.1
115
115
  rdoc_options: []
116
116
  require_paths:
117
117
  - lib