From 49f43090b214c4346a114922696b7d9d96d2c02e Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Wed, 18 May 2016 22:07:49 -0400 Subject: Added plugin controller (WIP) --- app/Controller/PluginController.php | 38 +++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 app/Controller/PluginController.php (limited to 'app/Controller/PluginController.php') diff --git a/app/Controller/PluginController.php b/app/Controller/PluginController.php new file mode 100644 index 00000000..8d5628f1 --- /dev/null +++ b/app/Controller/PluginController.php @@ -0,0 +1,38 @@ +response->html($this->helper->layout->plugin('plugin/show', array( + 'plugins' => $this->pluginLoader->plugins, + 'title' => t('Installed Plugins'), + ))); + } + + /** + * Display list of available plugins + */ + public function directory() + { + $plugins = $this->httpClient->getJson(PLUGIN_API_URL); + + $this->response->html($this->helper->layout->plugin('plugin/directory', array( + 'plugins' => $plugins, + 'title' => t('Plugin Directory'), + ))); + } +} -- cgit v1.2.3