NavigationController: Add new parameters to all view script's links
refs #10246
This commit is contained in:
parent
4b76115399
commit
1c44a3306b
|
@ -182,7 +182,6 @@ class NavigationController extends Controller
|
|||
|
||||
$removeForm = new Form();
|
||||
$removeForm->setUidDisabled();
|
||||
$removeForm->setAction(Url::fromPath('navigation/unshare'));
|
||||
$removeForm->addElement('hidden', 'name', array(
|
||||
'decorators' => array('ViewHelper')
|
||||
));
|
||||
|
|
|
@ -27,7 +27,10 @@
|
|||
<td><?= $this->qlink(
|
||||
$name,
|
||||
'navigation/edit',
|
||||
array('name' => $name),
|
||||
array(
|
||||
'name' => $name,
|
||||
'type' => $item->type
|
||||
),
|
||||
array(
|
||||
'title' => sprintf($this->translate('Edit navigation item %s'), $name)
|
||||
)
|
||||
|
@ -39,7 +42,10 @@
|
|||
<td><?= $this->qlink(
|
||||
'',
|
||||
'navigation/remove',
|
||||
array('name' => $name),
|
||||
array(
|
||||
'name' => $name,
|
||||
'type' => $item->type
|
||||
),
|
||||
array(
|
||||
'icon' => 'trash',
|
||||
'title' => sprintf($this->translate('Remove navigation item %s'), $name)
|
||||
|
|
|
@ -1,4 +1,8 @@
|
|||
<?php if (! $this->compact): ?>
|
||||
<?php
|
||||
|
||||
use Icinga\Web\Url;
|
||||
|
||||
if (! $this->compact): ?>
|
||||
<div class="controls">
|
||||
<?= $this->tabs; ?>
|
||||
<?= $this->sortBox; ?>
|
||||
|
@ -26,6 +30,8 @@
|
|||
'navigation/edit',
|
||||
array(
|
||||
'name' => $name,
|
||||
'type' => $item->type,
|
||||
'owner' => $item->owner,
|
||||
'referrer' => 'shared'
|
||||
),
|
||||
array(
|
||||
|
@ -48,7 +54,12 @@
|
|||
)
|
||||
); ?></td>
|
||||
<?php else: ?>
|
||||
<td data-base-target="_self"><?= $removeForm->setDefault('name', $name); ?></td>
|
||||
<td data-base-target="_self"><?= $removeForm
|
||||
->setDefault('name', $name)
|
||||
->setAction(Url::fromPath(
|
||||
'navigation/unshare',
|
||||
array('type' => $item->type, 'owner' => $item->owner)
|
||||
)); ?></td>
|
||||
<?php endif ?>
|
||||
</tr>
|
||||
<?php endforeach ?>
|
||||
|
|
Loading…
Reference in New Issue