5 require_once
'class.ilDataCollectionRecordField.php';
6 require_once
'class.ilDataCollectionRecord.php';
7 require_once
'class.ilDataCollectionField.php';
8 require_once
'class.ilDataCollectionRecordViewGUI.php';
9 require_once(
"./Services/Link/classes/class.ilLink.php");
34 $this->dcl_obj_id = $dclTable->getCollectionObject()->getId();
43 public function getHTML(array $options = array()){
47 $record_field = $this;
55 if(!$ref_record->getTableId() || !$record_field->getField() || !$record_field->getField()->getTableId()){
58 $record_field->setValue(NULL);
59 $record_field->doUpdate();
63 $html = $ref_record->getRecordFieldHTML($record_field->getField()->getFieldRef());
65 if($options[
'link'][
'display']) {
68 $ref_table = $ref_record->getTableId();
70 $query =
"SELECT table_id FROM il_dcl_view WHERE table_id = ".$ref_table.
" AND type = ".$ilDB->quote(0,
"integer").
" AND formtype = ".$ilDB->quote(0,
"integer");
71 $set = $ilDB->query(
$query);
93 $record_field = $this;
100 $link_name = $ref_record->getRecordFieldHTML($record_field->getField()->getFieldRef());
103 $ilCtrl->setParameterByClass(
"ildatacollectionrecordviewgui",
"record_id", $ref_record->getId());
105 $html =
"<a href='". $ilCtrl->getLinkTargetByClass(
"ilDataCollectionRecordViewGUI",
"renderRecord").
"'>".$link_name.
"</a>";
118 return $ref_rec->getRecordField($this->
getField()->getFieldRef())->getExportValue();