I’m building a Shopware plugin with part storefront and part administration. The storefront part is working fine, but I can’t get the administration part to show up in the menu on the admin page with the administration:build command.
I followed the Shopware Docs and the Shopware course on how to do this. I matched them both but still no success. Might there be something I’m missing here? The name of the plugin is PCvue
This is my main.js
import './module/configurator';
This is my index.js
import „./page/configurator-component-list“;
import „./page/configurator-component-detail“;
import „./page/configurator-component-create“;
Shopware.Module.register(„configurator“, {
type: ‚plugin‘,
name: ‚Configurator‘,
color: ‚#ff3d58‘,
icon: ‚default-shopping-paper-bag-product‘,
title: ‚Configurator‘,
description: ‚Module for registering components‘,
routes: {
index: {
component: 'configurator-component-list',
path: 'index'
},
detail: {
component: 'configurator-component-detail',
path: 'detail/:id',
meta: {
parentPath: 'configurator.index'
}
},
create: {
component: 'configurator-component-create',
path: 'create',
meta: {
parentPath: 'configurator.index'
}
}
},
navigation: [{
label: 'Configurator',
color: '#ff3d58',
path: 'configurator.index',
icon: 'default-shopping-paper-bag-product',
parent: 'sw-catalogue',
position: 100
}],
});
And just in case there might be something wrong with my file tree, here it is
- administration
- src
- module
- configurator
- page (includes the different components of the plugin)
- index.js
- configurator
- main.js
- module
- src
- storefront
- src
Output of administration:build
Starting Execution of ‚administration:build‘ (‚/var/www/html/dev-ops/administration/actions/build.sh‘)
(1/3) Starting
bin/console bundle:dump
Cannot load Xdebug - it was already loaded
[OK] Dumped plugin configuration.
(2/3) Starting
PROJECT_ROOT=/var/www/html ENV_FILE=/var/www/html/.env npm run --prefix vendor/shopware/platform/src/Administration/Resources/app/administration/ build
> administration@1.0.0 build /var/www/html/vendor/shopware/platform/src/Administration/Resources/app/administration
> mode=production webpack
# Compiling with Webpack configuration
# Production mode is activated 🚀
# Plugin "Storefront": Injected successfully
# Plugin "PCvue": Injected successfully
Time: 50301ms
Entrypoint commons = static/js/runtime.js static/css/vendors-node.css static/js/vendors-node.js static/js/vendors-node.js.map static/js/commons.js
Entrypoint app = static/js/runtime.js static/css/vendors-node.css static/js/vendors-node.js static/js/vendors-node.js.map static/css/app.css static/js/app.js
Entrypoint storefront = static/js/runtime.js static/css/vendors-node.css static/js/vendors-node.js static/js/vendors-node.js.map static/css/storefront.css static/js/storefront.js
Entrypoint p-cvue = static/js/runtime.js static/js/p-cvue.js
3847 modules
(3/3) Starting
bin/console assets:install
Cannot load Xdebug - it was already loaded
Copying files for bundle: FrameworkBundle
Copying files for bundle: MonologBundle
Copying files for bundle: SwiftmailerBundle
Copying files for bundle: SensioFrameworkExtraBundle
Copying files for bundle: TwigBundle
Copying files for bundle: WebProfilerBundle
Copying files for bundle: DebugBundle
Copying files for bundle: EnqueueBundle
Copying files for bundle: EnqueueAdapterBundle
Copying files for bundle: Framework
Copying files for bundle: System
Copying files for bundle: Content
Copying files for bundle: Checkout
Copying files for bundle: Profiling
Copying files for bundle: Administration
Copying files for bundle: Docs
Copying files for bundle: Storefront
Copying files for bundle: Elasticsearch
Copying files for bundle: PCvue
Copying files for bundle: DbalKernelPluginLoader
[OK] Successfully copied all bundle files
Duration: 1m 1s
All commands successfully executed!