Rename ::extraColumns() to ::addColumns()

refs #4498
This commit is contained in:
Alexander A. Klimov 2015-05-18 16:29:33 +02:00
parent 52d1cb8c8f
commit 0bde465295
3 changed files with 6 additions and 6 deletions

View File

@ -94,7 +94,7 @@ class Monitoring_ListController extends Controller
'host_passive_checks_enabled',
'host_current_check_attempt',
'host_max_check_attempts'
), $this->extraColumns()));
), $this->addColumns()));
$this->filterQuery($query);
$this->applyRestriction('monitoring/hosts/filter', $query);
$this->view->hosts = $query;
@ -177,7 +177,7 @@ class Monitoring_ListController extends Controller
'service_passive_checks_enabled',
'current_check_attempt' => 'service_current_check_attempt',
'max_check_attempts' => 'service_max_check_attempts'
), $this->extraColumns());
), $this->addColumns());
$query = $this->backend->select()->from('serviceStatus', $columns);
$this->filterQuery($query);
$this->applyRestriction('monitoring/services/filter', $query);
@ -644,7 +644,7 @@ class Monitoring_ListController extends Controller
return $query;
}
protected function extraColumns()
protected function addColumns()
{
$columns = preg_split(
'~,~',
@ -652,7 +652,7 @@ class Monitoring_ListController extends Controller
-1,
PREG_SPLIT_NO_EMPTY
);
$this->view->extraColumns = $columns;
$this->view->addColumns = $columns;
return $columns;
}

View File

@ -92,7 +92,7 @@ if (count($hosts) === 0) {
<?php endif ?>
<p class="pluginoutput"><?= $this->escape($this->ellipsis($host->host_output, 10000)) ?></p>
</td>
<?php foreach($this->extraColumns as $col): ?>
<?php foreach($this->addColumns as $col): ?>
<td><?= $this->escape($host->$col) ?></td>
<?php endforeach ?>
</tr>

View File

@ -81,7 +81,7 @@ if (count($services) === 0) {
); ?><?php endif ?><br>
<p class="pluginoutput"><?= $this->escape($this->ellipsis($service->service_output, 10000)); ?></p>
</td>
<?php foreach($this->extraColumns as $col): ?>
<?php foreach($this->addColumns as $col): ?>
<td><?= $this->escape($service->$col) ?></td>
<?php endforeach ?>
</tr>