mirror of
https://github.com/Icinga/icingaweb2-module-businessprocess.git
synced 2026-01-06 05:29:35 -05:00
ProcessController: do not show edit forms...
...even if requested refs #107
This commit is contained in:
parent
e6722d9024
commit
c4242f869b
1 changed files with 5 additions and 3 deletions
|
|
@ -201,20 +201,22 @@ class ProcessController extends Controller
|
|||
return;
|
||||
}
|
||||
|
||||
if ($action === 'add') {
|
||||
$canEdit = $bp->getMetadata()->canModify();
|
||||
|
||||
if ($action === 'add' && $canEdit) {
|
||||
$form = $this->loadForm('AddNode')
|
||||
->setProcess($bp)
|
||||
->setParentNode($node)
|
||||
->setSession($this->session())
|
||||
->handleRequest();
|
||||
} elseif ($action === 'delete') {
|
||||
} elseif ($action === 'delete' && $canEdit) {
|
||||
$form =$this->loadForm('DeleteNode')
|
||||
->setProcess($bp)
|
||||
->setNode($bp->getNode($this->params->get('deletenode')))
|
||||
->setParentNode($node)
|
||||
->setSession($this->session())
|
||||
->handleRequest();
|
||||
} elseif ($action === 'edit') {
|
||||
} elseif ($action === 'edit' && $canEdit) {
|
||||
$form =$this->loadForm('Process')
|
||||
->setProcess($bp)
|
||||
->setNode($bp->getNode($this->params->get('editnode')))
|
||||
|
|
|
|||
Loading…
Reference in a new issue