DivanteLtd / shopware2vuestorefront

First Progressive Web App for Shopware 6. Made with ❤️ by Vue Storefront

Home Page:https://vuestorefront.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Indexer product template using missing fields

jeremy-seipelt opened this issue · comments

I looked at the product data retrieved by the indexer and it seems it tries to use missing fields.

The awaited object properties

{ id, autoIncrement, description, descriptionLong, price, name, ean, cover, stock, datasheet, createdAt, updatedAt, attributeIds}

Looking at the data from a fresh sw6 installation an autoIncrement is not returned and missing for the template.

It seems the autoIncrement uses actual ID of the product, was autoIncrement used before, was it removed from the newest SW6 release?

VS Elastic implementation is just accepting the plain JSON; some of these fields are mapped to Vue Storefront properties; please feel free to create Pull Request adding all the awaited fields to the syncing mechanism

Problem is that when autoIncrement is missing, the whole reindex doesnt work.
Because of autoIncrement.toString(). I am just asking myself what your VS is awaiting inside the autoIncrement, because its used for the ids and url.

I am just wondering why I run into so much issues, did you test the whole installation process with a fresh installation of Shopware 6?

Hi @jeremy-seipelt sure we did (test it), but the Shopware itself evolves and probably we need to make a better job pursuing these changes :) We'll be updating the docs within next 2 weeks

@jeremy-seipelt we need to provide an id of the product in order to index product data properly. ID (integer) is being used as a _id in elasticsearch index and mapping is designed to get this ID. We didn't check what would happen if we use something else, sku for instance.
Shopware API is being developed continuously and we need to catch up the latest changes. It might be possible to use any other unique value set to product entity and use it as a ID (integer) while indexing?

@mkucmus ok good to know.
Is there a step I am missing in the README ? After everything is done, the pwa is still showing the magento demo data. I asked on slack but I am getting ignored atm. I have no errors atm so I dont get where its messing stuff up.