mirror of
https://github.com/Icinga/icingadb-web.git
synced 2026-05-28 04:36:06 -04:00
(Multi)QuickActions: Hide Process check button when related feature command is disabled
This commit is contained in:
parent
c4a8f4748f
commit
63379898ac
2 changed files with 6 additions and 1 deletions
|
|
@ -120,6 +120,7 @@ class MultiselectQuickActions extends BaseHtmlElement
|
|||
$unacknowledged = "{$this->getColumnPrefix()}_problems_unacknowledged";
|
||||
$acks = "{$this->getColumnPrefix()}_acknowledged";
|
||||
$activeChecks = "{$this->getColumnPrefix()}_active_checks_enabled";
|
||||
$passiveChecks = "{$this->getColumnPrefix()}_passive_checks_enabled";
|
||||
|
||||
if (
|
||||
$this->summary->$unacknowledged > $this->summary->$acks
|
||||
|
|
@ -233,6 +234,7 @@ class MultiselectQuickActions extends BaseHtmlElement
|
|||
|
||||
if (
|
||||
$this->allowToProcessCheckResults
|
||||
&& $this->summary->$passiveChecks > 0
|
||||
&& $this->isGrantedOnType(
|
||||
'icingadb/command/process-check-result',
|
||||
$this->type,
|
||||
|
|
|
|||
|
|
@ -104,7 +104,10 @@ class QuickActions extends BaseHtmlElement
|
|||
);
|
||||
}
|
||||
|
||||
if ($this->isGrantedOn('icingadb/command/process-check-result', $this->object)) {
|
||||
if (
|
||||
$this->object->passive_checks_enabled
|
||||
&& $this->isGrantedOn('icingadb/command/process-check-result', $this->object)
|
||||
) {
|
||||
$this->assembleAction(
|
||||
'processCheckresult',
|
||||
t('Process check result'),
|
||||
|
|
|
|||
Loading…
Reference in a new issue