Skip to content
This repository was archived by the owner on May 28, 2023. It is now read-only.

Commit 5ccd302

Browse files
authored
Merge pull request #1 from DivanteLtd/master
Sync with upstream master
2 parents d086c88 + b419892 commit 5ccd302

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+8699
-9190
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,6 @@ src/config.json
1111
config/local.json
1212
var/magento2-sample-data/
1313
.migrate
14+
*.iml
15+
/docker/elasticsearch/data/
16+
!/docker/elasticsearch/data/.gitkeep

.travis.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
sudo: required
2+
language: node_js
3+
4+
cache:
5+
yarn: true
6+
directories:
7+
- node_modules
8+
9+
install:
10+
- yarn
11+
12+
jobs:
13+
include:
14+
- &build
15+
stage: Build
16+
script:
17+
- yarn lint
18+
- yarn build
19+
node_js: '10'
20+
21+
- <<: *build
22+
node_js: '8'
23+

CHANGELOG.md

Lines changed: 58 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,70 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [1.10.0] - 2019.08.12
8+
9+
### Added
10+
- Typescript support - @ResuBaka (#210, #242)
11+
- Multi Stock Inventory (Magento MSI) support - @aleron75, @dimasch (#226)
12+
- Import of magento 2 cms pages and blocks to the full import - @toh82 (#235)
13+
- Information about magento 2 cms pages and blocks import to the readme - @toh82 (#235)
14+
- Introduce orderNumber to order creation endpoint - @Flyingmana (#251)
15+
- Optional Redis Auth functionality. - @rain2o (#267)
16+
- Extensions have ability to modify Elasticsearch results. - @grimasod (#269)
17+
- Refactored Travis build config - @Tjitse-E (#273)
18+
- Multistore support for `magento1`-platform using `magento1-vsbridge` - @cewald (#276)
19+
20+
### Changed
21+
- Sharp dependency has been updated. *It might require reinstalling yarn dependencies* - @lukeromanowicz
22+
- Replaced index property value `not_analyzed` with `true` for `options` field in attribute schema - @adityasharma7 (#334)
23+
24+
### Fixed
25+
- Missing `res` and `req` parameters are now passed to ProductProcessor - @jahvi (#218)
26+
- Moving of graphql files to the dist folder - @ResuBaka (#242)
27+
- Moving of schema files to the dist folder - @ResuBaka (#244)
28+
- Missing assetPath config for magento1 - @ResuBaka (#245)
29+
- New payload for magento1 stock check endpoint - @cewald (#261)
30+
- `yarn dev:inspect` command and extract nodemon config to nodemon.json - @Tjitse-E, @cewald (#272, #279)
31+
- Include Magento Currency Code in mage2vs import and productsdelta if available - @rain2o (#281)
32+
- Better handling of HTTP error codes provided by API client - @pkarw (#3151)
33+
34+
## [1.9.6] - 2019.07.11
35+
- Dependencies update to avoid lodash security issues.
36+
37+
## [1.9.5] - 2019.06.17
38+
- Dependencies update to avoid js-yaml security issues.
39+
40+
## [1.9.4] - 2019.06.03
41+
- Extension schemas in `src/models` are not required anymore - @EmilsM, @lukeromanowicz (#259, #263)
42+
43+
## [1.9.3] - 2019.05.27
44+
- Change min postal code length in user profile to 3 so it's sames as in orders - @lukeromanowicz (#253)
45+
46+
## [1.9.2] - 2019.05.20
47+
- Fix failing o2m when parsing order schema - @lukeromanowicz (#248)
48+
49+
## [1.9.1] - 2019.05.10
50+
- Mount ElasticSearch data to `docker/elasticsearch/data` directory - @dimasch, @lukeromanowicz (#237, #241)
51+
- Fix product schema and importer in migration process - @lukeromanowicz (#239)
52+
53+
## [1.9.0] - 2019.05.06
54+
- Changed location of magento1 platform js client. Moved from `src/platform/magento1/module` to [magento1-vsbridge-client](https://github.com/DivanteLtd/magento1-vsbridge-client) - @mtarld (#195)
55+
- Update Babel from 6 to 7 - @lukeromanowicz (#202)
56+
- Support unicode characters in order requests - @lukeromanowicz (#201)
57+
- TravisCI configured for building and linting - @lukeromanowicz (#204)
58+
- Use Redis database from configuration in mage2vs - @Cyclonecode (#211)
59+
- Requests with invalid body result in HTTP code 400 instead of 500 - @AndreiBelokopytov (#220)
60+
- `src/models/order.schema.json` was moved to `src/models/order.schema.js` to support regex transformation - @lukeromanowicz (#201)
61+
62+
## [1.8.4] - 2019.04.17
63+
- Use encrypted token for user authentication - @pkarw (#215)
64+
765
## [1.8.3] - 2019.03.05
866
- Use store id from configuration in `mage2vs import` - @boehsermoe (#179)
967

1068
## [1.8.2] - 2019.03.04
1169
- Magento 1 bridge client - @afirlejczyk (#190)
1270
- configurable ElasticSearch `apiVersion` - @Resubaka (#192)
1371

14-
1572
## [1.8.1] - 2019.02.11
1673
- Fixed `apiVersion` property for ElasticSearch driver - now it's available thru `config/*.json` - @mdanilowicz (#185)

README.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Besides a big improvement for the shopping experience, we also want to create a
1919
- Docker and Docker Compose
2020

2121
Already included in `vue-storefront-api` Docker image (required locally, if you do not use containerization):
22-
- Node.js 8.x or higher
22+
- Node.js 10.x or higher
2323
- Yarn
2424

2525
## Installation
@@ -82,7 +82,7 @@ This backend is using ElasticSearch data formats popularized by [ElasticSuite fo
8282
Please use data migration mechanism provided to manipulate Redis, ElasticSearch or kue. Details: https://github.com/DivanteLtd/vue-storefront-api/tree/master/doc
8383

8484
## Adding custom modules with own dependencies (Yarn only)
85-
When adding custom [Extensions to the API](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/Extending%20vue-storefront-api.md) you might want to define some dependencies inside them. Thanks to [Yarn workspaces](https://yarnpkg.com/lang/en/docs/workspaces/) dependecies defined inside your custom module will be intaled when you execute `yarn` at project root level, so it's way esier and faster than installing all modules dependcies separetly.
85+
When adding custom [Extensions to the API](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/Extending%20vue-storefront-api.md) you might want to define some dependencies inside them. Thanks to [Yarn workspaces](https://yarnpkg.com/lang/en/docs/workspaces/) dependencies defined inside your custom module will be installed when you execute `yarn` at project root level, so it's way easier and faster than installing all modules dependencies separately.
8686

8787
To do this, define the `package.json` with your dependencies in your custom module:
8888
- `src/api/extensions/{your-custom-extension}/package.json`
@@ -103,13 +103,8 @@ After setting the `config.magento2.api` section using Yours Magento2 oauth crede
103103

104104
```json
105105
"magento2": {
106-
"url": "http://magento2.demo-1.xyz.com",
107106
"imgUrl": "http://localhost:8080/media/catalog/product",
108107
"assetPath": "/../var/magento2-sample-data/pub/media",
109-
"magentoUserName": "",
110-
"magentoUserPassword": "",
111-
"httpUserName": "",
112-
"httpUserPassword": "",
113108
"api": {
114109
"url": "http://demo-magento2.vuestorefront.io/rest",
115110
"consumerKey": "byv3730rhoulpopcq64don8ukb8lf2gq",
@@ -131,6 +126,12 @@ You can run the following command to execute the full import:
131126
```bash
132127
yarn mage2vs import --store-code=de
133128
```
129+
130+
Import of CMS blocks and pages is also performed by the full import. If the CMS API extension ((SnowdogApps/magento2-cms-api)[https://github.com/SnowdogApps/magento2-cms-api]) was not installed in magento 2, it's recommended to skip the CMS import commands.
131+
132+
```bash
133+
yarn mage2vs import --skip-blocks --skip-pages
134+
```
134135

135136
## Executing delta indexer
136137

babel.config.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
module.exports = {
2+
presets: [
3+
[
4+
'@babel/preset-env', {
5+
targets: {
6+
node: "8"
7+
}
8+
}
9+
]
10+
]
11+
};

config/custom-environment-variables.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"redis": {
1111
"host": "REDIS_HOST",
1212
"port": "REDIS_PORT",
13-
"db": "REDIS_DB"
13+
"db": "REDIS_DB",
14+
"auth": "REDIS_AUTH"
1415
}
1516
}

config/default.json

Lines changed: 24 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,18 @@
3535
"redis": {
3636
"host": "localhost",
3737
"port": 6379,
38-
"db": 0
38+
"db": 0,
39+
"auth": false
3940
},
4041
"kue": {},
4142
"availableStores": [
4243
"de",
4344
"it"
4445
],
46+
"msi": {
47+
"enabled": false,
48+
"defaultStockId": 1
49+
},
4550
"storeViews": {
4651
"multistore": true,
4752
"mapStoreUrlsFor": [
@@ -50,19 +55,22 @@
5055
],
5156
"de": {
5257
"storeCode": "de",
53-
"disabled": true,
58+
"disabled": false,
5459
"storeId": 3,
5560
"name": "German Store",
5661
"url": "/de",
5762
"elasticsearch": {
5863
"host": "localhost:8080/api/catalog",
5964
"index": "vue_storefront_catalog_de"
6065
},
66+
"msi": {
67+
"stockId": 2
68+
},
6169
"tax": {
6270
"defaultCountry": "DE",
6371
"defaultRegion": "",
6472
"calculateServerSide": true,
65-
"sourcePriceIncludesTax": false
73+
"sourcePriceIncludesTax": false
6674
},
6775
"i18n": {
6876
"fullCountryName": "Germany",
@@ -77,14 +85,17 @@
7785
},
7886
"it": {
7987
"storeCode": "it",
80-
"disabled": true,
88+
"disabled": false,
8189
"storeId": 4,
8290
"name": "Italian Store",
8391
"url": "/it",
8492
"elasticsearch": {
8593
"host": "localhost:8080/api/catalog",
8694
"index": "vue_storefront_catalog_it"
8795
},
96+
"msi": {
97+
"stockId": 2
98+
},
8899
"tax": {
89100
"defaultCountry": "IT",
90101
"defaultRegion": "",
@@ -126,7 +137,8 @@
126137
"mailchimp-subscribe",
127138
"example-magento-api",
128139
"cms-data",
129-
"mail-service"
140+
"mail-service",
141+
"example-processor"
130142
],
131143
"extensions": {
132144
"mailchimp": {
@@ -144,16 +156,16 @@
144156
},
145157
"targetAddressWhitelist": ["contributors@vuestorefront.io"],
146158
"secretString": "__THIS_IS_SO_SECRET__"
159+
},
160+
"example-processor": {
161+
"resultProcessors": {
162+
"product": "my-product-processor"
163+
}
147164
}
148165
},
149166
"magento2": {
150-
"url": "http://demo-magento2.vuestorefront.io/",
151167
"imgUrl": "http://demo-magento2.vuestorefront.io/media/catalog/product",
152168
"assetPath": "/../var/magento2-sample-data/pub/media",
153-
"magentoUserName": "",
154-
"magentoUserPassword": "",
155-
"httpUserName": "",
156-
"httpUserPassword": "",
157169
"api": {
158170
"url": "http://demo-magento2.vuestorefront.io/rest",
159171
"consumerKey": "byv3730rhoulpopcq64don8ukb8lf2gq",
@@ -163,8 +175,8 @@
163175
}
164176
},
165177
"magento1": {
166-
"url": "http://magento-demo.local",
167178
"imgUrl": "http://magento-demo.local/media/catalog/product",
179+
"assetPath": "",
168180
"magentoUserName": "",
169181
"magentoUserPassword": "",
170182
"httpUserName": "",
@@ -178,7 +190,6 @@
178190
}
179191
},
180192
"imageable": {
181-
"namespace": "",
182193
"maxListeners": 512,
183194
"imageSizeLimit": 1024,
184195
"whitelist": {
@@ -197,8 +208,7 @@
197208
"queue": 2,
198209
"process": 4
199210
},
200-
"simd": true,
201-
"keepDownloads": true
211+
"simd": true
202212
},
203213
"entities": {
204214
"category": {

config/elastic.schema.attribute.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@
1010
"properties": {
1111
"value": {
1212
"type": "text",
13-
"index": "not_analyzed"
13+
"index": true
1414
}
1515
}
1616
}
1717
}
18-
}
18+
}

config/elastic.schema.product.extension.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@
66
"has_options": {"type": "integer"} ,
77
"Size_options": {"type": "keyword"},
88
"Color_options": {"type": "keyword"}
9-
}
9+
}
1010
}

config/elastic.schema.product.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,9 @@
7373
"eco_collection": {"type": "integer"},
7474
"eco_collection_options": {"type": "integer"},
7575
"erin_recommends": {"type": "integer"},
76-
"tax_class_id": {"type": "integer"}
76+
"tax_class_id": {"type": "integer"},
77+
"gender": {"type": "integer"},
78+
"material": {"type": "integer"},
79+
"category_gear": {"type": "integer"}
7780
}
7881
}

0 commit comments

Comments
 (0)