21        $message = 
"Standard fields cannot be read from DB";
 
   31        $message = 
"Standard fields cannot be written to DB";
 
   48        $this->
setLocked($original_record->getLocked());
 
   49        $this->
setOrder($original_record->getOrder());
 
   50        $this->
setRequired($original_record->getRequired());
 
   51        $this->
setUnique($original_record->isUnique());
 
   79                "title" => 
$lng->txt(
"dcl_id"),
 
   80                "description" => 
$lng->txt(
"dcl_id_description"),
 
   85                "id" => 
"create_date",
 
   86                "title" => 
$lng->txt(
"dcl_creation_date"),
 
   87                "description" => 
$lng->txt(
"dcl_creation_date_description"),
 
   92                "id" => 
"last_update",
 
   93                "title" => 
$lng->txt(
"dcl_last_update"),
 
   94                "description" => 
$lng->txt(
"dcl_last_update_description"),
 
  100                "title" => 
$lng->txt(
"dcl_owner"),
 
  101                "description" => 
$lng->txt(
"dcl_owner_description"),
 
  106                "id" => 
"last_edit_by",
 
  107                "title" => 
$lng->txt(
"dcl_last_edited_by"),
 
  108                "description" => 
$lng->txt(
"dcl_last_edited_by_description"),
 
  114                'title' => 
$lng->txt(
'dcl_comments'),
 
  115                'description' => 
$lng->txt(
'dcl_comments_desc'),
 
  132        $stdFields = array();
 
  133        foreach (self::_getStandardFieldsAsArray() as $array) {
 
  137            $field->buildFromDBRecord($array);
 
  138            $stdFields[] = $field;
 
  159                'dcl_last_edited_by',
 
  163            $identifiers .= 
$ilDB->quote(
$id, 
'text') . 
',';
 
  165        $identifiers = rtrim($identifiers, 
',');
 
  167            'SELECT value FROM lng_data WHERE identifier IN (' . $identifiers
 
  171        while ($rec = 
$ilDB->fetchAssoc($sql)) {
 
  172            $titles[] = $rec[
'value'];
 
  188        foreach (array(
'dcl_owner') as 
$id) {
 
  189            $identifiers .= 
$ilDB->quote(
$id, 
'text') . 
',';
 
  191        $identifiers = rtrim($identifiers, 
',');
 
  193            'SELECT value, identifier FROM lng_data WHERE identifier IN (' 
  197        while ($rec = 
$ilDB->fetchAssoc($sql)) {
 
  198            $titles[$rec[
'identifier']][] = $rec[
'value'];
 
  213        foreach (self::_getStandardFieldsAsArray() as $field) {
 
  214            if ($field[
"id"] == $field_id) {
 
  233        foreach (self::_getStandardFieldsAsArray() as $fields_data) {
 
  234            if (
$id == $fields_data[
'id']) {
 
  275        if ($this->
getId() == 
'owner' || $this->
getId() == 
'last_edit_by') {
 
  276            $join_str = 
"LEFT JOIN usr_data AS sort_usr_data_{$this->getId()} ON (sort_usr_data_{$this->getId()}.usr_id = record.{$this->getId()})";
 
  277            $select_str = 
" sort_usr_data_{$this->getId()}.login AS field_{$this->getId()},";
 
  279            $select_str = 
" record.{$this->getId()} AS field_{$this->getId()},";
 
  282        $sql_obj->setSelectStatement($select_str);
 
  283        $sql_obj->setJoinStatement($join_str);
 
  285        if ($this->
getId() !== 
"comments") {
 
  286            $sql_obj->setOrderStatement(
"field_{$this->getId()} " . $direction);
 
  306        $where_additions = 
"";
 
  309            $join_str = 
"INNER JOIN usr_data AS filter_usr_data_{$this->getId()} ON (filter_usr_data_{$this->getId()}.usr_id = record.{$this->getId()} AND filter_usr_data_{$this->getId()}.login LIKE " 
  310                . 
$ilDB->quote(
"%$filter_value%", 
'text') . 
") ";
 
  313                $from = (isset($filter_value[
'from'])) ? $filter_value[
'from'] : 
null;
 
  314                $to = (isset($filter_value[
'to'])) ? $filter_value[
'to'] : 
null;
 
  315                if (is_numeric(
$from)) {
 
  316                    $where_additions .= 
" AND record.{$this->getId()} >= " 
  319                if (is_numeric($to)) {
 
  320                    $where_additions .= 
" AND record.{$this->getId()} <= " 
  321                        . 
$ilDB->quote($to, 
'integer');
 
  325                    $date_from = (isset($filter_value[
'from'])
 
  326                        && is_object($filter_value[
'from'])) ? $filter_value[
'from'] : 
null;
 
  327                    $date_to = (isset($filter_value[
'to'])
 
  328                        && is_object($filter_value[
'to'])) ? $filter_value[
'to'] : 
null;
 
  333                        $where_additions .= 
" AND (record.{$this->getId()} >= " 
  334                            . strip_tags(
$ilDB->quote($date_from, 
'date')) . 
")";
 
  337                        $where_additions .= 
" AND (record.{$this->getId()} <= " 
  338                            . strip_tags(
$ilDB->quote($date_to, 
'date')) . 
")";
 
  345        $sql_obj->setJoinStatement($join_str);
 
  346        $sql_obj->setWhereStatement($where_additions);
 
  357        if ($this->
getId() == 
'comments') {
 
  360        return parent::getSortField();
 
  369        if ($this->
getId() == 
'comments') {
 
  373        return parent::hasNumericSorting();
 
  383        return $this->
id != 
'comments' 
  395        parent::fillHeaderExcel($worksheet, 
$row, $col);
 
  396        if ($this->
getId() == 
'owner') {
 
  414        $value = $excel->getCell(
$row, $col);
 
An exception for terminatinating execution or to throw for unit testing.
Class ilDclBaseFieldModel.
setExportable($exportable)
updateTableFieldSetting()
update exportable and fieldorder
setRequired($a_required)
Set Required.
getTableId()
Get table id.
getDatatypeId()
Get datatype_id.
static getTableCache($table_id=0)
const INPUTFORMAT_DATETIME
Class ilDclRecordQueryObject.
Class ilDclBaseFieldModel.
getRecordQuerySortObject($direction="asc", $sort_by_status=false)
Returns a query-object for building the record-loader-sql-query.
fillHeaderExcel(ilExcel $worksheet, &$row, &$col)
static _getNonImportableStandardFieldTitles()
doCreate()
Create new field.
getValueFromExcel($excel, $row, $col)
static _isStandardField($field_id)
cloneStructure($original_record)
getRecordQueryFilterObject($filter_value="", ilDclBaseFieldModel $sort_field=null)
Returns a query-object for building the record-loader-sql-query.
static _getStandardFieldsAsArray()
static _getStandardFields($table_id)
static _getDatatypeForId($id)
gives you the datatype id of a specified standard field.
static _getImportableStandardFieldTitle()
setCell($a_row, $a_col, $a_value, $a_datatype=null)
Set cell value.
static _lookupId($a_user_str)
Lookup id by login.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
catch(Exception $e) $message