ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
class.ilDclDetailedViewDefinition.php
Go to the documentation of this file.
1<?php
2
3/* Copyright (c) 1998-2009 ILIAS open source, Extended GPL, see docs/LICENSE */
4
5include_once("./Services/COPage/classes/class.ilPageObject.php");
6
19
20 const PARENT_TYPE = 'dclf';
21
25 protected $active = false;
29 protected $table_id;
33 protected static $record_view_cache = array();
34
40 function getParentType() {
41 return self::PARENT_TYPE;
42 }
43
51 public function getAvailablePlaceholders() {
52 $all = array();
53
54 require_once("./Modules/DataCollection/classes/Table/class.ilDclTable.php");
55 require_once("./Modules/DataCollection/classes/TableView/class.ilDclTableView.php");
56 $tableview = new ilDclTableView($this->getId());
57 $table_id = $tableview->getTableId();
59 $fields = $objTable->getRecordFields();
60 $standardFields = $objTable->getStandardFields();
61
62 foreach ($fields as $field) {
63 $all[] = "[" . $field->getTitle() . "]";
64
65 if ($field->getDatatypeId() == ilDclDatatype::INPUTFORMAT_REFERENCE) {
66 $all[] = '[dclrefln field="' . $field->getTitle() . '"][/dclrefln]';
67 }
68 // SW 14.10.2015 http://www.ilias.de/mantis/view.php?id=16874
69 // if ($field->getDatatypeId() == ilDclDatatype::INPUTFORMAT_ILIAS_REF) {
70 // $all[] = '[dcliln field="' . $field->getTitle() . '"][/dcliln]';
71 // }
72 }
73
74 foreach ($standardFields as $field) {
75 $all[] = "[" . $field->getId() . "]";
76 }
77
78 return $all;
79 }
80
81 public static function exists($id)
82 {
83 return parent::_exists(self::PARENT_TYPE, $id);
84 }
85
86 public static function isActive($id)
87 {
88 return parent::_lookupActive($id, self::PARENT_TYPE);
89 }
90}
91
92?>
An exception for terminatinating execution or to throw for unit testing.
static getTableCache($table_id=0)
Class ilDclDetailedViewDefinition.
getAvailablePlaceholders()
Get all placeholders for table id.
Class ilDclTableView.
Class ilPageObject.