mirror of
https://github.com/Icinga/icingaweb2-module-businessprocess.git
synced 2026-01-08 14:39:33 -05:00
process/show: add dummy edit mode
This commit is contained in:
parent
1dfd67a15e
commit
b50e8a082c
3 changed files with 15 additions and 0 deletions
|
|
@ -32,6 +32,11 @@ class Bpapp_ProcessController extends Controller
|
|||
$bp->setSimulationMode();
|
||||
$this->addSimulation($bp);
|
||||
}
|
||||
|
||||
if ($this->params->get('edit')) {
|
||||
$bp->setEditMode();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public function sourceAction()
|
||||
|
|
|
|||
9
application/views/scripts/editlink.phtml
Normal file
9
application/views/scripts/editlink.phtml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
<?php if ($this->bp->isEditMode()): ?>
|
||||
<?php if ($this->bp->hasBeenChanged()): ?>
|
||||
<a href="<?= $this->url()->without('edit') ?>" title="<?= $this->escape('Store modifications') ?>"><?= $this->icon('ok') ?></a>
|
||||
<?php endif ?>
|
||||
<a href="<?= $this->url()->without('edit') ?>" title="<?= $this->escape('Dismiss modifications') ?>"><?= $this->icon('cancel') ?></a>
|
||||
<?php else: ?>
|
||||
<a href="<?= $this->url()->with('edit', true) ?>" title="<?= $this->escape('Modify this process') ?>"><?= $this->icon('wrench') ?></a>
|
||||
<?php endif ?>
|
||||
|
||||
|
|
@ -3,6 +3,7 @@
|
|||
<h1><?= $this->escape($this->title) ?>
|
||||
<a href="<?= $this->url()->with('mode', 'toplevel') ?>" title="<?= $this->escape('Switch to toplevel view') ?>"><?= $this->icon('dashboard') ?></a>
|
||||
<?= $this->render('simulationlink.phtml') ?>
|
||||
<?= $this->render('editlink.phtml') ?>
|
||||
</h1>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue