mirror of
https://github.com/Icinga/icingaweb2-module-director.git
synced 2025-07-31 01:34:12 +02:00
ObjectsController: API should ship full objects
This commit is contained in:
parent
25deed9c60
commit
23325d96f4
@ -106,10 +106,10 @@ abstract class ObjectsController extends ActionController
|
|||||||
$this->view->filterEditor = $table->getFilterEditor($this->getRequest());
|
$this->view->filterEditor = $table->getFilterEditor($this->getRequest());
|
||||||
|
|
||||||
if ($this->getRequest()->isApiRequest()) {
|
if ($this->getRequest()->isApiRequest()) {
|
||||||
|
$objects = array();
|
||||||
$objects = $this->db()->getDbAdapter()->fetchAll(
|
foreach ($dummy::loadAll($this->db) as $object) {
|
||||||
$table->getBaseQuery()->columns(array('object_name', 'object_type', 'disabled'))
|
$objects[] = $object->toPlainObject(false, true);
|
||||||
);
|
}
|
||||||
return $this->sendJson((object) array('objects' => $objects));
|
return $this->sendJson((object) array('objects' => $objects));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user