mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-22 21:34:29 +02:00
ObjectsController: fix 'add' link for apply rules
This commit is contained in:
parent
5457a0865f
commit
ee582b7106
@ -116,22 +116,27 @@ abstract class ObjectsController extends ActionController
|
|||||||
|
|
||||||
public function applyrulesAction()
|
public function applyrulesAction()
|
||||||
{
|
{
|
||||||
|
$type = $this->getType();
|
||||||
|
$tType = $this->translate(ucfirst($type));
|
||||||
$this
|
$this
|
||||||
->assertApplyRulePermission()
|
->assertApplyRulePermission()
|
||||||
->addObjectsTabs()
|
->addObjectsTabs()
|
||||||
->addTitle(
|
->addTitle(
|
||||||
$this->translate('All your %s Apply Rules'),
|
$this->translate('All your %s Apply Rules'),
|
||||||
$this->translate(ucfirst($this->getType()))
|
$tType
|
||||||
);
|
);
|
||||||
$this->actions()/*->add(
|
$this->actions()/*->add(
|
||||||
$this->getBackToDashboardLink()
|
$this->getBackToDashboardLink()
|
||||||
)*/->add(
|
)*/->add(
|
||||||
Link::create(
|
Link::create(
|
||||||
$this->translate('Add'),
|
$this->translate('Add'),
|
||||||
'director/service/add',
|
"director/$type/add",
|
||||||
['type' => 'apply_rule'],
|
['type' => 'apply_rule'],
|
||||||
[
|
[
|
||||||
'title' => $this->translate('Create a new Service Apply Rule'),
|
'title' => sprintf(
|
||||||
|
$this->translate('Create a new %s Apply Rule'),
|
||||||
|
$tType
|
||||||
|
),
|
||||||
'class' => 'icon-plus',
|
'class' => 'icon-plus',
|
||||||
'data-base-target' => '_next'
|
'data-base-target' => '_next'
|
||||||
]
|
]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user