mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-31 01:34:12 +02:00
QuickTable: use plain object renderer
This commit is contained in:
parent
28862ccb12
commit
0febe231ab
@ -11,6 +11,7 @@ use Icinga\Data\Filter\Filter;
|
|||||||
use Icinga\Data\Selectable;
|
use Icinga\Data\Selectable;
|
||||||
use Icinga\Data\Paginatable;
|
use Icinga\Data\Paginatable;
|
||||||
use Icinga\Exception\QueryException;
|
use Icinga\Exception\QueryException;
|
||||||
|
use Icinga\Module\Director\PlainObjectRenderer;
|
||||||
use Icinga\Web\Request;
|
use Icinga\Web\Request;
|
||||||
use Icinga\Web\Url;
|
use Icinga\Web\Url;
|
||||||
use Icinga\Web\Widget;
|
use Icinga\Web\Widget;
|
||||||
@ -92,10 +93,10 @@ abstract class QuickTable implements Paginatable
|
|||||||
if ($value === null) {
|
if ($value === null) {
|
||||||
if ($val === null) {
|
if ($val === null) {
|
||||||
$value = '-';
|
$value = '-';
|
||||||
} elseif (is_array($val)) {
|
} elseif (is_array($val) || $val instanceof stdClass) {
|
||||||
$value = nl2br($this->view()->escape(implode("\n", $val)));
|
$value = '<pre>'
|
||||||
} elseif ($val instanceof stdClass) {
|
. $this->view()->escape(PlainObjectRenderer::render($val))
|
||||||
$value = '<pre>' . $this->view()->escape(print_r($val, 1)) . '</pre>';
|
. '</pre>';
|
||||||
} else {
|
} else {
|
||||||
$value = $this->view()->escape($val);
|
$value = $this->view()->escape($val);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user