19declare(strict_types=1);
23 public function getHTML(
bool $link =
true, array $options = []): string
28 if (!$value || $value ==
"-") {
32 if (!is_array($value)) {
38 foreach ($value as $k => $v) {
43 $value = array_values($value);
50 $ref_table = $ref_record->getTable();
51 $ref_id = $this->
http->wrapper()->query()->retrieve(
'ref_id', $this->
refinery->kindlyTo()->int());
52 if ($v !==
null && $v !==
'' && $v !==
'-') {
53 $view = $ref_record->getTable()->getFirstTableViewId($this->
user->getId(),
true);
63 return implode(
'<br>', $items);
68 $this->
ctrl->setParameterByClass(ilDclDetailedViewGUI::class,
"table_id", $record->
getTableId());
69 $this->
ctrl->setParameterByClass(ilDclDetailedViewGUI::class,
"record_id", $record->
getId());
70 $this->
ctrl->setParameterByClass(ilDclDetailedViewGUI::class,
"tableview_id", $view);
71 $html = $this->
factory->link()->standard(
73 $this->ctrl->getLinkTargetByClass(
74 ilDclDetailedViewGUI::class,
79 return $this->
renderer->render($html);
88 if (!$value || $value == []) {
const PROP_REFERENCE_LINK
setValue($value, bool $omit_parsing=false)
Set value for record field.
doUpdate()
Update object in database.
getRecordFieldHTML($field_id, array $options=[])
ilDclBaseRecordFieldModel $record_field
getRecordField()
Get Record Field.
static getRecordCache(?int $record_id)
getLinkHTML(ilDclBaseRecordModel $record, int $view)
parseFormInput($value)
function parses stored value to the variable needed to fill into the form for editing.
getHTML(bool $link=true, array $options=[])
Outputs html of a certain field.
static http()
Fetches the global http state from ILIAS.