commit 6f634f7f3512b9161708470e1daa0a1c1d55cdef Author: Dennis Eichhorn Date: Fri Aug 31 15:21:59 2018 +0200 fixes #13 fixes #38 fixes #103 only dummy implementation diff --git a/Admin/Install/Navigation.install.json b/Admin/Install/Navigation.install.json new file mode 100644 index 0000000..87aee49 --- /dev/null +++ b/Admin/Install/Navigation.install.json @@ -0,0 +1,33 @@ +[ + { + "id": 1007101001, + "pid": "/backend", + "type": 2, + "subtype": 1, + "name": "Investment", + "uri": "/{/lang}/backend/controlling/investment/dashboard?{?}", + "target": "self", + "icon": null, + "order": 1, + "from": "InvestmentManagement", + "permission": { "type": null, "element": null }, + "parent": 1002801001, + "children": [ + { + "id": 1007102001, + "pid": "/backend/controlling/investment", + "type": 3, + "subtype": 1, + "name": "Dashboard", + "uri": "/{/lang}/backend/controlling/investment/dashboard?{?}", + "target": "self", + "icon": null, + "order": 1, + "from": "InvestmentManagement", + "permission": { "type": null, "element": null }, + "parent": 1007101001, + "children": [] + } + ] + } +] diff --git a/Admin/Install/Navigation.php b/Admin/Install/Navigation.php new file mode 100644 index 0000000..7234fb8 --- /dev/null +++ b/Admin/Install/Navigation.php @@ -0,0 +1,47 @@ +get()->getType()) { + case DatabaseType::MYSQL: + break; + } + } +} diff --git a/Admin/Routes/Web/Backend.php b/Admin/Routes/Web/Backend.php new file mode 100644 index 0000000..7289580 --- /dev/null +++ b/Admin/Routes/Web/Backend.php @@ -0,0 +1,20 @@ + [ + [ + 'dest' => '\Modules\InvestmentManagement\Controller:viewInvestmentDashboard', + 'verb' => RouteVerb::GET, + 'permission' => [ + 'module' => Controller::MODULE_NAME, + 'type' => PermissionType::READ, + 'state' => PermissionState::INVESTMENT, + ], + ], + ], +]; diff --git a/Admin/Status.php b/Admin/Status.php new file mode 100644 index 0000000..48c62db --- /dev/null +++ b/Admin/Status.php @@ -0,0 +1,32 @@ +app, $request, $response); + $view->setTemplate('/Modules/InvestmentManagement/Theme/Backend/investment-dashboard'); + $view->addData('nav', $this->app->moduleManager->get('Navigation')->createNavigationMid(1004601001, $request, $response)); + + return $view; + } +} diff --git a/Models/PermissionState.php b/Models/PermissionState.php new file mode 100644 index 0000000..99705a2 --- /dev/null +++ b/Models/PermissionState.php @@ -0,0 +1,30 @@ + [ + 'Investment' => 'Investment', + 'Dashboard' => 'Dashboard', +]]; diff --git a/Theme/Backend/Lang/en.lang.php b/Theme/Backend/Lang/en.lang.php new file mode 100644 index 0000000..75169c0 --- /dev/null +++ b/Theme/Backend/Lang/en.lang.php @@ -0,0 +1,14 @@ + [ +]]; diff --git a/Theme/Backend/investment-dashboard.tpl.php b/Theme/Backend/investment-dashboard.tpl.php new file mode 100644 index 0000000..559f971 --- /dev/null +++ b/Theme/Backend/investment-dashboard.tpl.php @@ -0,0 +1,13 @@ +getData('nav')->render(); diff --git a/info.json b/info.json new file mode 100644 index 0000000..b2f4612 --- /dev/null +++ b/info.json @@ -0,0 +1,45 @@ +{ + "name": { + "id": 1007100000, + "internal": "InvestmentManagement", + "external": "Investment Management" + }, + "category": "Finance", + "version": "1.0.0", + "requirements": { + "phpOMS": "1.0.0", + "phpOMS-db": "1.0.0" + }, + "creator": { + "name": "Orange Management", + "website": "www.spl1nes.com" + }, + "description": "Investment Management module.", + "directory": "InvestmentManagement", + "dependencies": { + "Controlling": "*" + }, + "providing": { + "Navigation": "*" + }, + "load": [ + { + "pid": [ + "/backend/controlling/investment" + ], + "type": 4, + "for": 0, + "from": "InvestmentManagement", + "file": "InvestmentManagement" + }, + { + "pid": [ + "/backend" + ], + "type": 5, + "from": "InvestmentManagement", + "for": "Navigation", + "file": "Navigation" + } + ] +}