Small Business: Installation
Installing the Sylius plugin Small Business §19 UStG: Composer via Packeton, bundle, routes, setup command, update and uninstall in the right order.
Small Business: Installation
This documentation always describes the latest published version.
Live Demo: Try this and other plugins live — no installation, no risk: demo.markus-michalski.net
Composer
Private repositories are managed through Packeton (
https://packeton.markus-michalski.net). Credentials are provided after purchasing a license.
{ "repositories": [{ "type": "composer", "url": "https://packeton.markus-michalski.net" }] }
composer require mmd/sylius-kleinunternehmer-plugin
After composer require:
-
Register the bundle in
config/bundles.php(there is no Flex recipe):Mmd\SyliusKleinunternehmerPlugin\MmdSyliusKleinunternehmerPlugin::class => ['all' => true], -
Import the admin routes, for example in
config/routes/mmd_sylius_kleinunternehmer.yaml. Only this makes the route exist that the admin menu entry points to:mmd_sylius_kleinunternehmer_admin: resource: "@MmdSyliusKleinunternehmerPlugin/config/routes/admin.yaml" -
Run the setup command:
bin/console mmd:kleinunternehmer:setupThe command creates the tables
mmd_kleinunternehmer_settingsandmmd_kleinunternehmer_migrated_variant. It has no options of its own and does the following:- It runs only the open migrations of this plugin, not those of the app or other plugins.
- It is idempotent: without a new migration nothing happens, so you can safely run it again after every
composer update. - It checks that the routes from step 2 are imported and prints a snippet otherwise. It never writes to
config/itself. - If the plugin has open migrations and Sylius migrations are still open, it stops and asks you to run
bin/console doctrine:migrations:migratefirst. - It asks for confirmation interactively. In scripts, add
--no-interaction.
doctrine:migrations:migratestill works as an alternative.
There is no config/packages/*.yaml file for this plugin and no environment variables it reads.
The setup command does not touch your product prices. Switching existing products to the 0% tax category is a separate step, see Price migration.
First steps after installation
- Create a zone with the code
DEif it is missing (Admin → Configuration → Zones). - Open Admin → MMKreativ Plugins → Kleinunternehmer §19 UStG and activate the regulation, see Configuration.
- Migrate existing products, see Price migration.
Console commands
| Command | Purpose | When |
|---|---|---|
mmd:kleinunternehmer:setup |
Run this plugin's migrations, check the route import | After installation and after every update |
mmd:kleinunternehmer:migrate-prices |
Move prices to 0% or restore them | Once, when switching over, see Price migration |
You do not need to schedule either command.
Update
composer update mmd/sylius-kleinunternehmer-plugin
bin/console mmd:kleinunternehmer:setup
bin/console cache:clear
Uninstall
- If products should get their original tax category back, restore the prices first:
Note the rounding limit of restoring on the Price migration page.bin/console mmd:kleinunternehmer:migrate-prices --restore - Roll back the migrations while the bundle is still registered, one version at a time, newest first:
bin/console doctrine:migrations:execute --down "Mmd\SyliusKleinunternehmerPlugin\Migrations\Version20260829160426" bin/console doctrine:migrations:execute --down "Mmd\SyliusKleinunternehmerPlugin\Migrations\Version20260828132209" bin/console doctrine:migrations:execute --down "Mmd\SyliusKleinunternehmerPlugin\Migrations\Version20260828121602" - Remove the route import (
config/routes/mmd_sylius_kleinunternehmer.yaml) and the bundle entry inconfig/bundles.php. - Remove the package:
composer remove mmd/sylius-kleinunternehmer-plugin
The migrations only create the two tables. The 0% tax category
kleinunternehmer_zeroand its tax rate remain as regular Sylius data. If you delete them, do so only after no variant points to them any more.