Official Findologic plugin for Shopware 6.
Please see our Shopware 6 documentation.
-
Install the shopware-cli
-
Set up the test shop
- https://sw-cli.fos.gg/commands/project/
shopware-cli project create [folder] [version]
-
Install dependencies for tests
composer require --dev symfony/test-pack
-
Configure test database within the .env.test file (Create file if not present)
- If you want to use a docker database, run
docker-compose up -d
- If you want to use a docker database, run
-
Navigate to the plugins folder
cd custom/plugins
-
Clone this repository
git clone [email protected]:findologic/plugin-shopware-6.git
-
Install dependencies
cd plugin-shopware-6 && composer install
-
Navigate back to the shop root
cd ../../..
-
Refresh plugin list
bin/console plugin:refresh --env="test"
-
Install and activate the plugin
bin/console plugin:install FinSearch --activate --clearCache --env="test"
The Makefile
includes commands for all relevant tasks:
make storefront-lint
make administration-lint
make storefront-fix
make administration-fix
There are different configurations for administration and storefront. Depending on the current project, use the corresponding configuration.
- MySQL >= 8.0
- PHP >= 8.1
- Create a database user
app
with the passwordapp
, which should have permissions to create, update and delete all databases. - In the development templates root, initialize the test setup (run locally, outside the app container)
./psh.phar init
- Navigate to the plugin and run tests
cd custom/plugins/plugin-shopware-6 && composer test
Tests can also be run separately within the IDE. Simply ensure to set phpunit.xml.dist
as configuration file.
- npm
- node
- See Shopware 6 environment requirements minimal required versions.
- Navigate to the storefront folder
cd src/Resources/app/storefront
- Install dependencies
npm install
- Run unit-tests using jest
npm run test
After dependency installation all tests can also be run via the IDE without any additional configuration.
- Check out the offical guide on how to extend js storefront plugin.
- Create your plugin files inside
src/Resources/app/storefront/src/js/[your-plugin-name].plugin.js
- Register your extended plugin
- For a development build:
./psh.phar storefront:dev
- For a production build:
./psh.phar storefront:build
Please note:
- The build commands will create a minified JS file in
src/Resources/app/storefront/dist/storefront/js/[plugin-name].js
. - Before committing ensure that all files were built and added to your commit.
- Make sure to also commit the minified JavaScript files.
We are using some of our libraries that are especially relevant for this and other plugins. Note that these libraries already come with the plugin itself, so you do not need to install them yourself.
- findologic/libflexport Helps generating the shop's data feed aka. export. We use it to generate an XML based on the product data of the shop.
- findologic/shopware6-common Includes the basic logic for the export.
- findologic/findologic-api Handles requests to FINDOLOGIC. This includes everything from sending query parameters like selected filters, output attributes, to parsing the response with response objects.
In some cases you may want to export additional, custom export data. To still provide you plugin updates, we have an extension plugin. It overrides logic of the base plugin to reflect your own logic.
Use the FINDOLOGIC Shopware 6 extension plugin to customize your export. There are already pre-defined examples, that guide you on how you can customize certain entities, like attributes or properties.
- Update the changelogs
CHANGELOG_en-GB.md
andCHANGELOG_de-DE.md
. - Ensure that all changes, including the changelog changes have been merged into the
develop
branch. - Switch to the
develop
branch locally and pull the most recent changes.git checkout develop git pull
- Start the release process and follow the instructions.
composer release
- Ensure that the GitHub Actions release is successful.
- Upload it to Google Drive, by downloading the built zip file from the Releases page.
Upload it to the folder
Development/Plugins/Shopware/Shopware 6 DI & API Plugin
and move the old version toalte Versionen
. - Notify everyone in the
#releases
Slack channel.