diff options
Diffstat (limited to 'config/appconfig.php')
-rw-r--r-- | config/appconfig.php | 26 |
1 files changed, 23 insertions, 3 deletions
diff --git a/config/appconfig.php b/config/appconfig.php index 89c02a1de..e738b22cd 100644 --- a/config/appconfig.php +++ b/config/appconfig.php @@ -13,11 +13,11 @@ namespace OCA\News\Config; -use OCP\INavigationManager; -use OCP\IURLGenerator; +use \OCP\INavigationManager; +use \OCP\IURLGenerator; use \OCP\Backgroundjob; use \OCP\Util; - +use \OCP\App; // Used to parse app.json file, should be in core at some point class AppConfig { @@ -98,6 +98,17 @@ class AppConfig { /** + * Registers all config options + */ + public function registerAll() { + $this->registerNavigation(); + $this->registerBackgroundJobs(); + $this->registerHooks(); + $this->registerAdmin(); + } + + + /** * Parses the navigation and creates a navigation entry if needed */ public function registerNavigation() { @@ -120,6 +131,15 @@ class AppConfig { } + /** + * Registers admin pages + */ + public function registerAdmin() { + if ($this->config['admin']) { + App::registerAdmin($this->config['id'], 'admin/admin'); + } + } + /** * Registers all jobs in the config |