Removed Github configuration from ProjectController / ProjectForm and added it to a new settings area.
This commit is contained in:
parent
cc86e85adb
commit
2a47b08fec
10 changed files with 332 additions and 88 deletions
|
|
@ -47,6 +47,10 @@ class PluginController extends \PHPCI\Controller
|
|||
|
||||
public function index()
|
||||
{
|
||||
if (!$_SESSION['user']->getIsAdmin()) {
|
||||
throw new \Exception('You do not have permission to do that.');
|
||||
}
|
||||
|
||||
$this->view->canWrite = is_writable(APPLICATION_PATH . 'composer.json');
|
||||
$this->view->canInstall = $this->canInstall;
|
||||
$this->view->required = $this->required;
|
||||
|
|
@ -60,6 +64,10 @@ class PluginController extends \PHPCI\Controller
|
|||
|
||||
public function remove()
|
||||
{
|
||||
if (!$_SESSION['user']->getIsAdmin()) {
|
||||
throw new \Exception('You do not have permission to do that.');
|
||||
}
|
||||
|
||||
$package = $this->getParam('package', null);
|
||||
$json = $this->getComposerJson();
|
||||
|
||||
|
|
@ -81,6 +89,10 @@ class PluginController extends \PHPCI\Controller
|
|||
|
||||
public function install()
|
||||
{
|
||||
if (!$_SESSION['user']->getIsAdmin()) {
|
||||
throw new \Exception('You do not have permission to do that.');
|
||||
}
|
||||
|
||||
$package = $this->getParam('package', null);
|
||||
$version = $this->getParam('version', '*');
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue