ILIAS  trunk Revision v12.0_alpha-1221-g4e438232683
class.ilDashObjectsTableRenderer.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
22{
23 public function __construct(protected readonly object $parent_gui)
24 {
25 }
26
27 public function render(array $groupedItems): string
28 {
29 $cnt = 0;
30 $html = '';
31 foreach ($groupedItems as $group) {
32 $items = $group->getItems();
33 if (count($items) > 0) {
34 $table = new ilDashObjectsTableGUI($this->parent_gui, 'render', $cnt++);
35 $table->setTitle($group->getLabel());
36 $table->setData($group->getItems());
37 $html .= $table->getHTML();
38 }
39 }
40 return $html;
41 }
42}
__construct(protected readonly object $parent_gui)