From bd23899bf9cfbbf7e6b137dfdc5bbef30a7ff988 Mon Sep 17 00:00:00 2001 From: Dennis Eichhorn Date: Wed, 19 Sep 2018 21:34:04 +0200 Subject: [PATCH] Split controllers per application --- .../BackendController.php | 57 +----------- Controller/Controller.php | 86 +++++++++++++++++++ 2 files changed, 89 insertions(+), 54 deletions(-) rename Controller.php => Controller/BackendController.php (81%) create mode 100644 Controller/Controller.php diff --git a/Controller.php b/Controller/BackendController.php similarity index 81% rename from Controller.php rename to Controller/BackendController.php index 5ba4191..5d35450 100644 --- a/Controller.php +++ b/Controller/BackendController.php @@ -12,7 +12,7 @@ */ declare(strict_types=1); -namespace Modules\Navigation; +namespace Modules\Navigation\Controller; use Modules\Navigation\Models\Navigation; use Modules\Navigation\Models\NavigationType; @@ -31,59 +31,8 @@ use phpOMS\Module\WebInterface; * @link http://website.orange-management.de * @since 1.0.0 */ -final class Controller extends ModuleAbstract implements WebInterface +class BackendController extends Controller { - - /** - * Module path. - * - * @var string - * @since 1.0.0 - */ - public const MODULE_PATH = __DIR__; - - /** - * Module version. - * - * @var string - * @since 1.0.0 - */ - public const MODULE_VERSION = '1.0.0'; - - /** - * Module name. - * - * @var string - * @since 1.0.0 - */ - public const MODULE_NAME = 'Navigation'; - - /** - * Module id. - * - * @var int - * @since 1.0.0 - */ - public const MODULE_ID = 1000500000; - - /** - * Providing. - * - * @var string[] - * @since 1.0.0 - */ - protected static $providing = [ - ]; - - /** - * Dependencies. - * - * @var string[] - * @since 1.0.0 - */ - protected static $dependencies = [ - ]; - /** * Create mid navigation * @@ -154,7 +103,7 @@ final class Controller extends ModuleAbstract implements WebInterface continue; } - $path = __DIR__ . '/../..' . $path . '.' . $response->getHeader()->getL11n()->getLanguage() . '.lang.php'; + $path = __DIR__ . '/../../..' . $path . '.' . $response->getHeader()->getL11n()->getLanguage() . '.lang.php'; /** @noinspection PhpIncludeInspection */ $lang = include $path; diff --git a/Controller/Controller.php b/Controller/Controller.php new file mode 100644 index 0000000..bdaeac1 --- /dev/null +++ b/Controller/Controller.php @@ -0,0 +1,86 @@ +