ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilDclRatingFieldRepresentation Class Reference

Class ilDclDateTimeREpresentation. More...

+ Inheritance diagram for ilDclRatingFieldRepresentation:
+ Collaboration diagram for ilDclRatingFieldRepresentation:

Public Member Functions

 getInputField (ilPropertyFormGUI $form, $record_id=0)
 
 addFilterInputFieldToTable (ilTable2GUI $table)
 
 passThroughFilter (ilDclBaseRecordModel $record, $filter)
 
- Public Member Functions inherited from ilDclBaseFieldRepresentation
 __construct (ilDclBaseFieldModel $field)
 
 addFilterInputFieldToTable (ilTable2GUI $table)
 Add filter input to TableGUI. More...
 
 passThroughFilter (ilDclBaseRecordModel $record, $filter)
 Checks if a filter affects a record. More...
 
 parseSortingValue ($value, $link=true)
 
 getInputField (ilPropertyFormGUI $form, $record_id=0)
 Returns field-input. More...
 
 addFieldCreationForm ($form, ilObjDataCollection $dcl, $mode="create")
 Adds the options for the field-types to the field-creation form. More...
 
 getPropertyInputFieldId ($property)
 Return post-var for property-fields. More...
 
 getField ()
 Return BaseFieldModel. More...
 

Additional Inherited Members

- Protected Member Functions inherited from ilDclBaseFieldRepresentation
 setupFilterInputField (ilFormPropertyGUI $input)
 Set basic settings for filter-input-gui. More...
 
 setupInputField (ilFormPropertyGUI $input, ilDclBaseFieldModel $field)
 Sets basic settings on field-input. More...
 
 getFilterInputFieldValue ( $input)
 
 buildFieldCreationInput (ilObjDataCollection $dcl, $mode='create')
 Build the creation-input-field. More...
 
- Protected Attributes inherited from ilDclBaseFieldRepresentation
 $field
 
 $lng
 
 $ctrl
 

Detailed Description

Class ilDclDateTimeREpresentation.

Author
Michael Herren mh@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch
Version
1.0.0

Definition at line 9 of file class.ilDclRatingFieldRepresentation.php.

Member Function Documentation

◆ addFilterInputFieldToTable()

ilDclRatingFieldRepresentation::addFilterInputFieldToTable ( ilTable2GUI  $table)

Definition at line 21 of file class.ilDclRatingFieldRepresentation.php.

References $options, ilTable2GUI\addFilterItemByMetaType(), array, ilTable2GUI\FILTER_SELECT, ilDclBaseFieldRepresentation\getField(), ilDclBaseFieldRepresentation\getFilterInputFieldValue(), and ilDclBaseFieldRepresentation\setupFilterInputField().

22  {
23  $input = $table->addFilterItemByMetaType("filter_" . $this->getField()->getId(), ilTable2GUI::FILTER_SELECT, false, $this->getField()->getId());
24  $options = array("" => $this->lng->txt("dcl_any"), 1 => ">1", 2 => ">2", 3 => ">3", 4 => ">4", 5 => "5");
25  $input->setOptions($options);
26 
27  $this->setupFilterInputField($input);
28 
29  return $this->getFilterInputFieldValue($input);
30  }
addFilterItemByMetaType($id, $type=self::FILTER_TEXT, $a_optional=false, $caption=null)
Add filter by standard type.
setupFilterInputField(ilFormPropertyGUI $input)
Set basic settings for filter-input-gui.
Create styles array
The data for the language used.
if(!isset($_REQUEST['ReturnTo'])) if(!isset($_REQUEST['AuthId'])) $options
Definition: as_login.php:20
+ Here is the call graph for this function:

◆ getInputField()

ilDclRatingFieldRepresentation::getInputField ( ilPropertyFormGUI  $form,
  $record_id = 0 
)

Definition at line 11 of file class.ilDclRatingFieldRepresentation.php.

References ilDclBaseFieldRepresentation\getField(), and ilDclBaseFieldRepresentation\setupInputField().

12  {
13  $input = new ilTextInputGUI($this->getField()->getTitle(), 'field_' . $this->getField()->getId());
14  $input->setValue($this->lng->txt("dcl_editable_in_table_gui"));
15  $input->setDisabled(true);
16  $this->setupInputField($input, $this->getField());
17 
18  return $input;
19  }
setupInputField(ilFormPropertyGUI $input, ilDclBaseFieldModel $field)
Sets basic settings on field-input.
This class represents a text property in a property form.
+ Here is the call graph for this function:

◆ passThroughFilter()

ilDclRatingFieldRepresentation::passThroughFilter ( ilDclBaseRecordModel  $record,
  $filter 
)

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

References ilDclBaseFieldRepresentation\getField(), and ilDclBaseRecordModel\getRecordFieldValue().

34  {
35  $value = $record->getRecordFieldValue($this->getField()->getId());
36  if (!$filter || $filter <= $value['avg']) {
37  return true;
38  }
39  return false;
40  }
getRecordFieldValue($field_id)
Get Field Value.
+ Here is the call graph for this function:

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