icingaweb2-module-businessp.../application/controllers/NodeController.php

36 lines
830 B
PHP
Raw Normal View History

<?php
2015-11-17 08:21:59 -05:00
namespace Icinga\Module\Businessprocess\Controllers;
2016-12-09 03:53:36 -05:00
use Icinga\Module\Businessprocess\Web\Controller;
2015-03-16 04:08:00 -04:00
use Icinga\Module\Businessprocess\Simulation;
use Icinga\Web\Url;
2015-03-16 04:08:00 -04:00
/*
config = <file>
process = <node>
*/
2015-11-17 08:21:59 -05:00
class NodeController extends Controller
{
2015-03-16 04:08:00 -04:00
// rename to config
public function editAction()
{
2015-03-16 04:08:00 -04:00
$bp = $this->loadModifiedBpConfig();
$node = $bp->getNode($this->getParam('node'));
$url = Url::fromPath(
'businessprocess/process/show?unlocked',
array('config' => $bp->getName())
2015-03-16 04:08:00 -04:00
);
$this->view->form = $this->loadForm('process')
2015-03-16 04:08:00 -04:00
->setProcess($bp)
->setSession($this->session())
->setNode($node)
->setSuccessUrl($url)
2015-03-16 04:08:00 -04:00
->handleRequest();
$this->view->node = $node;
}
}