| ... | ... |
@@ -16,10 +16,16 @@ use Contao\CoreBundle\ContaoCoreBundle; |
| 16 | 16 |
use Contao\ManagerPlugin\Bundle\BundlePluginInterface; |
| 17 | 17 |
use Contao\ManagerPlugin\Bundle\Config\BundleConfig; |
| 18 | 18 |
use Contao\ManagerPlugin\Bundle\Parser\ParserInterface; |
| 19 |
+use Contao\ManagerPlugin\Routing\RoutingPluginInterface; |
|
| 20 |
+use Symfony\Component\Config\Loader\LoaderResolverInterface; |
|
| 21 |
+use Symfony\Component\HttpKernel\KernelInterface; |
|
| 19 | 22 |
use vonRotenberg\WeinanlieferungBundle\VonrotenbergWeinanlieferungBundle; |
| 20 | 23 |
|
| 21 |
-class Plugin implements BundlePluginInterface |
|
| 24 |
+class Plugin implements BundlePluginInterface, RoutingPluginInterface |
|
| 22 | 25 |
{
|
| 26 |
+ /** |
|
| 27 |
+ * {@inheritdoc}
|
|
| 28 |
+ */ |
|
| 23 | 29 |
public function getBundles(ParserInterface $parser): array |
| 24 | 30 |
{
|
| 25 | 31 |
return [ |
| ... | ... |
@@ -27,4 +33,13 @@ class Plugin implements BundlePluginInterface |
| 27 | 33 |
->setLoadAfter([ContaoCoreBundle::class]), |
| 28 | 34 |
]; |
| 29 | 35 |
} |
| 36 |
+ |
|
| 37 |
+ /** |
|
| 38 |
+ * {@inheritdoc}
|
|
| 39 |
+ */ |
|
| 40 |
+ public function getRouteCollection(LoaderResolverInterface $resolver, KernelInterface $kernel) |
|
| 41 |
+ {
|
|
| 42 |
+ $path = __DIR__.'/../../config/routing.yml'; |
|
| 43 |
+ return $resolver->resolve($path)->load($path); |
|
| 44 |
+ } |
|
| 30 | 45 |
} |
| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,30 @@ |
| 1 |
+<?php |
|
| 2 |
+ |
|
| 3 |
+declare(strict_types=1); |
|
| 4 |
+ |
|
| 5 |
+/* |
|
| 6 |
+ * This file is part of contao-weinanlieferung-bundle. |
|
| 7 |
+ * |
|
| 8 |
+ * (c) vonRotenberg |
|
| 9 |
+ * |
|
| 10 |
+ * @license commercial |
|
| 11 |
+ */ |
|
| 12 |
+ |
|
| 13 |
+namespace vonRotenberg\WeinanlieferungBundle\ContaoManager; |
|
| 14 |
+ |
|
| 15 |
+use Contao\CoreBundle\ContaoCoreBundle; |
|
| 16 |
+use Contao\ManagerPlugin\Bundle\BundlePluginInterface; |
|
| 17 |
+use Contao\ManagerPlugin\Bundle\Config\BundleConfig; |
|
| 18 |
+use Contao\ManagerPlugin\Bundle\Parser\ParserInterface; |
|
| 19 |
+use vonRotenberg\WeinanlieferungBundle\VonrotenbergWeinanlieferungBundle; |
|
| 20 |
+ |
|
| 21 |
+class Plugin implements BundlePluginInterface |
|
| 22 |
+{
|
|
| 23 |
+ public function getBundles(ParserInterface $parser): array |
|
| 24 |
+ {
|
|
| 25 |
+ return [ |
|
| 26 |
+ BundleConfig::create(VonrotenbergWeinanlieferungBundle::class) |
|
| 27 |
+ ->setLoadAfter([ContaoCoreBundle::class]), |
|
| 28 |
+ ]; |
|
| 29 |
+ } |
|
| 30 |
+} |