ILIAS  trunk Revision v11.0_alpha-1866-gfa368f7776e
All Data Structures Namespaces Files Functions Variables Enumerations Enumerator Modules Pages
ilDclIliasReferenceRecordFieldModel Class Reference
+ Inheritance diagram for ilDclIliasReferenceRecordFieldModel:
+ Collaboration diagram for ilDclIliasReferenceRecordFieldModel:

Public Member Functions

 __construct (ilDclBaseRecordModel $record, ilDclBaseFieldModel $field)
 
 getStatus ()
 
 getValueForRepresentation ()
 
 getExportValue ()
 
- Public Member Functions inherited from ilDclBaseRecordFieldModel
 __construct (ilDclBaseRecordModel $record, ilDclBaseFieldModel $field)
 
 doCreate ()
 Creates an Id and a database entry. More...
 
 doUpdate ()
 Update object in database. More...
 
 delete ()
 Delete record field in database. More...
 
 getValue ()
 
 getValueForRepresentation ()
 
 serializeData ($value)
 Serialize data before storing to db. More...
 
 deserializeData ($value)
 Deserialize data before applying to field. More...
 
 setValue ($value, bool $omit_parsing=false)
 Set value for record field. More...
 
 setValueFromForm (ilPropertyFormGUI $form)
 
 getFormulaValue ()
 
 parseExportValue ($value)
 Function to parse incoming data from form input value $value. More...
 
 getValueFromExcel (ilExcel $excel, int $row, int $col)
 
 parseValue ($value)
 Function to parse incoming data from form input value $value. More...
 
 getExportValue ()
 
 fillExcelExport (ilExcel $worksheet, int &$row, int &$col)
 
 getPlainText ()
 
 getSortingValue (bool $link=true)
 
 addHiddenItemsToConfirmation (ilConfirmationGUI $confirmation)
 
 parseSortingValue ($value, bool $link=true)
 Returns sortable value for the specific field-types. More...
 
 cloneStructure (ilDclBaseRecordFieldModel $old_record_field)
 
 afterClone ()
 
 getField ()
 
 getId ()
 
 getRecord ()
 
 getRecordRepresentation ()
 
 setRecordRepresentation (ilDclBaseRecordRepresentation $record_representation)
 
 getFieldRepresentation ()
 
 setFieldRepresentation (ilDclBaseFieldRepresentation $field_representation)
 

Protected Attributes

int $dcl_obj_id
 
- Protected Attributes inherited from ilDclBaseRecordFieldModel
int $id = null
 
ilDclBaseFieldModel $field
 
ilDclBaseRecordModel $record
 
ilDclBaseRecordRepresentation $record_representation = null
 
ilDclBaseFieldRepresentation $field_representation = null
 
 $value
 
ilObjUser $user
 
ilCtrl $ctrl
 
ilDBInterface $db
 
ilLanguage $lng
 
ILIAS HTTP Services $http
 
ILIAS Refinery Factory $refinery
 

Additional Inherited Members

- Protected Member Functions inherited from ilDclBaseRecordFieldModel
 doRead ()
 Read object data from database. More...
 
 loadValue ()
 Load the value. More...
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilDclIliasReferenceRecordFieldModel::__construct ( ilDclBaseRecordModel  $record,
ilDclBaseFieldModel  $field 
)

Definition at line 25 of file class.ilDclIliasReferenceRecordFieldModel.php.

References ILIAS\GlobalScreen\Provider\__construct(), ilDclBaseRecordFieldModel\getField(), and ilDclCache\getTableCache().

26  {
27  parent::__construct($record, $field);
28 
29  $dclTable = ilDclCache::getTableCache($this->getField()->getTableId());
30  $this->dcl_obj_id = $dclTable->getCollectionObject()->getId();
31  }
static getTableCache(?int $table_id=null)
__construct(Container $dic, ilPlugin $plugin)
+ Here is the call graph for this function:

Member Function Documentation

◆ getExportValue()

ilDclIliasReferenceRecordFieldModel::getExportValue ( )

Definition at line 59 of file class.ilDclIliasReferenceRecordFieldModel.php.

References ilDclBaseRecordFieldModel\$value, ilLink\_getStaticLink(), ilDclBaseRecordFieldModel\getValue(), and ILIAS\Repository\int().

59  : string
60  {
61  $value = (int) $this->getValue();
62  if ($value <= 0) {
63  return '';
64  }
66  }
+ Here is the call graph for this function:

◆ getStatus()

ilDclIliasReferenceRecordFieldModel::getStatus ( )

Definition at line 33 of file class.ilDclIliasReferenceRecordFieldModel.php.

References ilObject\_lookupObjectId(), ilDclBaseRecordFieldModel\getValue(), null, and ILIAS\Repository\user().

33  : ?stdClass
34  {
35  $obj_ref = $this->getValue();
36  if (!$obj_ref) {
37  return null;
38  }
39  $usr_id = $this->user->getId();
40  $obj_id = ilObject2::_lookupObjectId($obj_ref);
41  $query = " SELECT status_changed, status
42  FROM ut_lp_marks
43  WHERE usr_id = " . $usr_id . " AND obj_id = " . $obj_id;
44 
45  return $this->db->fetchObject($this->db->query($query));
46  }
while($session_entry=$r->fetchRow(ilDBConstants::FETCHMODE_ASSOC)) return null
static _lookupObjectId(int $ref_id)
+ Here is the call graph for this function:

◆ getValueForRepresentation()

ilDclIliasReferenceRecordFieldModel::getValueForRepresentation ( )

Definition at line 48 of file class.ilDclIliasReferenceRecordFieldModel.php.

References $ref_id, ilObject\_lookupObjectId(), ilObject\_lookupTitle(), and ilDclBaseRecordFieldModel\getValue().

48  : string
49  {
50  $ref_id = $this->getValue();
51 
52  if ($ref_id) {
54  } else {
55  return "";
56  }
57  }
$ref_id
Definition: ltiauth.php:65
static _lookupTitle(int $obj_id)
static _lookupObjectId(int $ref_id)
+ Here is the call graph for this function:

Field Documentation

◆ $dcl_obj_id

int ilDclIliasReferenceRecordFieldModel::$dcl_obj_id
protected

The documentation for this class was generated from the following file: