spree_skroutz 1.1.0 → 1.1.2
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 +4 -4
- data/README.md +29 -22
- data/app/assets/config/spree_skroutz_manifest.js +0 -1
- data/app/views/spree_skroutz/products.xml.builder +4 -4
- data/config/initializers/spree.rb +1 -1
- data/config/locales/el.yml +1 -1
- data/config/locales/en.yml +1 -1
- data/lib/spree_skroutz/engine.rb +2 -2
- data/lib/spree_skroutz/version.rb +1 -1
- metadata +11 -12
- data/LICENSE.md +0 -15
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f659c881a6d87e8baf537da89935fc68488846f1300654e1678f0a1d835dda58
|
|
4
|
+
data.tar.gz: 29b7bab46ebac06f6fabf31ba104c323758813325e6e636545494995eb23c758
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cd831849c752b273e8ab96feec3052260413f333399555bcc2873403515af047f116b4aa49ff7f2fe7bf51195586443eca399cd0bfed40e870fc5f2f1f26d8e4
|
|
7
|
+
data.tar.gz: 00b740d7e5e23b04fe4d9d3698b103cb5bb8c083e66432a73fd6be40893c8536ee77bc12553e1ef49fdf9df2cebdaaeb0da0617fb2222031e18dc24ec7d9aaf7
|
data/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
#
|
|
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
|
|
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
|
|
@@ -66,4 +73,4 @@ If you'd like to contribute, please take a look at the
|
|
|
66
73
|
[instructions](CONTRIBUTING.md) for installing dependencies and crafting a good
|
|
67
74
|
pull request.
|
|
68
75
|
|
|
69
|
-
Copyright (c)
|
|
76
|
+
Copyright (c) 2026 OlympusOne, released under the MIT License.
|
|
@@ -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.
|
|
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.
|
|
49
|
+
if product.brand_taxon.present?
|
|
50
50
|
xml.tag! "manufacturer" do
|
|
51
|
-
xml.cdata! product.
|
|
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.
|
|
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)
|
data/config/locales/el.yml
CHANGED
data/config/locales/en.yml
CHANGED
data/lib/spree_skroutz/engine.rb
CHANGED
|
@@ -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',
|
|
21
|
-
app.config.
|
|
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
|
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.
|
|
4
|
+
version: 1.1.2
|
|
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.
|
|
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.
|
|
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.
|
|
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.
|
|
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.
|
|
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.
|
|
53
|
+
version: 5.2.0
|
|
54
54
|
- !ruby/object:Gem::Dependency
|
|
55
55
|
name: spree_extension
|
|
56
56
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -79,13 +79,12 @@ dependencies:
|
|
|
79
79
|
- - ">="
|
|
80
80
|
- !ruby/object:Gem::Version
|
|
81
81
|
version: '0'
|
|
82
|
-
description: Adds the ability to provide products listings to Skroutz
|
|
82
|
+
description: Adds the ability to provide products listings to Skroutz Merchants.
|
|
83
83
|
email: info@olympusone.com
|
|
84
84
|
executables: []
|
|
85
85
|
extensions: []
|
|
86
86
|
extra_rdoc_files: []
|
|
87
87
|
files:
|
|
88
|
-
- LICENSE.md
|
|
89
88
|
- README.md
|
|
90
89
|
- Rakefile
|
|
91
90
|
- app/assets/config/spree_skroutz_manifest.js
|
|
@@ -105,13 +104,13 @@ files:
|
|
|
105
104
|
- lib/spree_skroutz/version.rb
|
|
106
105
|
homepage: https://github.com/olympusone/spree_skroutz
|
|
107
106
|
licenses:
|
|
108
|
-
-
|
|
107
|
+
- MIT
|
|
109
108
|
metadata:
|
|
110
109
|
bug_tracker_uri: https://github.com/olympusone/spree_skroutz/issues
|
|
111
|
-
changelog_uri: https://github.com/olympusone/spree_skroutz/releases/tag/v1.1.
|
|
110
|
+
changelog_uri: https://github.com/olympusone/spree_skroutz/releases/tag/v1.1.2
|
|
112
111
|
documentation_uri: https://github.com/olympusone/spree_skroutz
|
|
113
112
|
homepage_uri: https://github.com/olympusone/spree_skroutz
|
|
114
|
-
source_code_uri: https://github.com/olympusone/spree_skroutz/tree/v1.1.
|
|
113
|
+
source_code_uri: https://github.com/olympusone/spree_skroutz/tree/v1.1.2
|
|
115
114
|
rdoc_options: []
|
|
116
115
|
require_paths:
|
|
117
116
|
- lib
|
data/LICENSE.md
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# LICENSE
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 OlympusOne. All rights reserved.
|
|
4
|
-
|
|
5
|
-
This program is free software: you can redistribute it and/or modify it under the terms of the
|
|
6
|
-
GNU Affero General Public License as published by the Free Software Foundation, either
|
|
7
|
-
version 3 of the License, or any later version.
|
|
8
|
-
|
|
9
|
-
This program is distributed in the hope that it will be useful,
|
|
10
|
-
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
11
|
-
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
12
|
-
GNU Affero General Public License for more details.
|
|
13
|
-
|
|
14
|
-
You should have received a copy of the GNU Affero General Public License
|
|
15
|
-
along with this program. If not, see [https://www.gnu.org/licenses/](https://www.gnu.org/licenses/).
|