ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
class.ilDclRatingFieldRepresentation.php
Go to the documentation of this file.
1 <?php
2 
10 {
11  public function getInputField(ilPropertyFormGUI $form, $record_id = 0)
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  }
20 
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  }
31 
32 
33  public function passThroughFilter(ilDclBaseRecordModel $record, $filter)
34  {
35  $value = $record->getRecordFieldValue($this->getField()->getId());
36  if (!$filter || $filter <= $value['avg']) {
37  return true;
38  }
39  return false;
40  }
41 }
This class represents a property form user interface.
addFilterItemByMetaType($id, $type=self::FILTER_TEXT, $a_optional=false, $caption=null)
Add filter by standard type.
setupInputField(ilFormPropertyGUI $input, ilDclBaseFieldModel $field)
Sets basic settings on field-input.
Class ilTable2GUI.
if(isset($_POST['submit'])) $form
This class represents a text property in a property form.
setupFilterInputField(ilFormPropertyGUI $input)
Set basic settings for filter-input-gui.
Create styles array
The data for the language used.
Class ilDclBaseRecordModel.
getRecordFieldValue($field_id)
Get Field Value.
getInputField(ilPropertyFormGUI $form, $record_id=0)
if(empty($password)) $table
Definition: pwgen.php:24
Class ilDclBaseFieldRepresentation.
passThroughFilter(ilDclBaseRecordModel $record, $filter)
if(!isset($_REQUEST['ReturnTo'])) if(!isset($_REQUEST['AuthId'])) $options
Definition: as_login.php:20