ILIAS
release_4-3 Revision
|
Class ilDataCollectionDatatype. More...
Public Member Functions | |
__construct ($a_id=0) | |
Constructor public. | |
getId () | |
Get field id. | |
setTitle ($a_title) | |
Set title. | |
getTitle () | |
Get title. | |
setStorageLocation ($a_id) | |
Set Storage Location. | |
getStorageLocation () | |
Get Storage Location. | |
getDbType () | |
doRead () | |
Read Datatype. | |
getProperties ($a_id) | |
Get all properties of a Datatype. | |
parseValue ($value, ilDataCollectionRecordField $record_field) | |
Function to parse incoming data from form input value $value. | |
parseExportValue ($value) | |
Function to parse incoming data from form input value $value. | |
parseHTML ($value, ilDataCollectionRecordField $record_field) | |
function parses stored value in database to a html output for eg. | |
parseFormInput ($value, ilDataCollectionRecordField $record_field) | |
function parses stored value to the variable needed to fill into the form for editing. |
Static Public Member Functions | |
static | getAllDatatypes () |
Get all possible Datatypes. | |
static | checkValidity ($type_id, $value) |
now only distinguishes between number and text values | |
static | getInputField (ilDataCollectionField $field) |
static | addFilterInputFieldToTable (ilDataCollectionField $field, ilTable2GUI &$table) |
addFilterInputFieldToTable This function adds the according filter item to the table gui passed as argument. | |
static | passThroughFilter (ilDataCollectionRecord $record, ilDataCollectionField $field, $filter) |
Data Fields | |
const | INPUTFORMAT_TEXT = 2 |
const | INPUTFORMAT_NUMBER = 1 |
const | INPUTFORMAT_REFERENCE = 3 |
const | INPUTFORMAT_BOOLEAN = 4 |
const | INPUTFORMAT_DATETIME = 5 |
const | INPUTFORMAT_FILE = 6 |
const | INPUTFORMAT_RATING = 7 |
const | INPUTFORMAT_ILIAS_REF = 8 |
const | INPUTFORMAT_MOB = 9 |
const | LINK_MAX_LENGTH = 30 |
Protected Attributes | |
$id | |
$title | |
$storageLocation | |
$dbType |
Class ilDataCollectionDatatype.
Definition at line 26 of file class.ilDataCollectionDatatype.php.
ilDataCollectionDatatype::__construct | ( | $a_id = 0 | ) |
Constructor public.
integer | datatype_id |
Definition at line 61 of file class.ilDataCollectionDatatype.php.
References doRead().
|
static |
addFilterInputFieldToTable This function adds the according filter item to the table gui passed as argument.
$field | ilDataCollectionField The field which should be filterable. |
&$table | ilTable2GUI The table you want the filter to be added to. |
Definition at line 276 of file class.ilDataCollectionDatatype.php.
References $lng, ilTable2GUI\addFilterItemByMetaType(), ilTable2GUI\FILTER_DATE_RANGE, ilTable2GUI\FILTER_NUMBER_RANGE, ilTable2GUI\FILTER_SELECT, ilTable2GUI\FILTER_TEXT, ilDataCollectionField\getDatatypeId(), ilDataCollectionCache\getFieldCache(), ilDataCollectionField\getFieldRef(), ilDataCollectionField\getId(), ilDataCollectionCache\getTableCache(), ilDataCollectionField\getTitle(), INPUTFORMAT_BOOLEAN, INPUTFORMAT_DATETIME, INPUTFORMAT_FILE, INPUTFORMAT_ILIAS_REF, INPUTFORMAT_MOB, INPUTFORMAT_NUMBER, INPUTFORMAT_RATING, INPUTFORMAT_REFERENCE, and INPUTFORMAT_TEXT.
Referenced by ilDataCollectionRecordListTableGUI\initFilter().
|
static |
now only distinguishes between number and text values
$type_id | int |
$value | mixed |
Definition at line 196 of file class.ilDataCollectionDatatype.php.
Referenced by ilDataCollectionField\checkValidity().
ilDataCollectionDatatype::doRead | ( | ) |
Read Datatype.
Definition at line 131 of file class.ilDataCollectionDatatype.php.
References $query, getId(), setStorageLocation(), and setTitle().
Referenced by __construct().
|
static |
Get all possible Datatypes.
Definition at line 150 of file class.ilDataCollectionDatatype.php.
References $query.
Referenced by ilDataCollectionFieldEditGUI\getValues(), and ilDataCollectionFieldEditGUI\initForm().
ilDataCollectionDatatype::getDbType | ( | ) |
Definition at line 123 of file class.ilDataCollectionDatatype.php.
References $dbType.
ilDataCollectionDatatype::getId | ( | ) |
Get field id.
Definition at line 75 of file class.ilDataCollectionDatatype.php.
References $id.
Referenced by doRead().
|
static |
$type_id | ||
ilDataCollectionField | $field |
Definition at line 221 of file class.ilDataCollectionDatatype.php.
References $lng, $title, ilDataCollectionField\getDatatypeId(), ilDataCollectionField\getDescription(), ilDataCollectionField\getId(), ilDataCollectionField\getLength(), ilDataCollectionField\getTextArea(), ilDataCollectionField\getTitle(), INPUTFORMAT_BOOLEAN, INPUTFORMAT_DATETIME, INPUTFORMAT_FILE, INPUTFORMAT_ILIAS_REF, INPUTFORMAT_MOB, INPUTFORMAT_NUMBER, INPUTFORMAT_RATING, INPUTFORMAT_REFERENCE, INPUTFORMAT_TEXT, ilFormPropertyGUI\setInfo(), ilDateTimeInputGUI\setStartYear(), and ilTextInputGUI\setValue().
Referenced by ilDataCollectionRecordEditGUI\initForm().
ilDataCollectionDatatype::getProperties | ( | $a_id | ) |
Get all properties of a Datatype.
int | $a_id | datatype_id |
Definition at line 173 of file class.ilDataCollectionDatatype.php.
References $query.
Referenced by ilDataCollectionFieldEditGUI\getValues(), ilDataCollectionFieldEditGUI\initForm(), and ilDataCollectionFieldEditGUI\save().
ilDataCollectionDatatype::getStorageLocation | ( | ) |
Get Storage Location.
Definition at line 115 of file class.ilDataCollectionDatatype.php.
References $storageLocation.
ilDataCollectionDatatype::getTitle | ( | ) |
Get title.
Definition at line 95 of file class.ilDataCollectionDatatype.php.
References $title.
ilDataCollectionDatatype::parseExportValue | ( | $value | ) |
Function to parse incoming data from form input value $value.
returns the strin/number/etc. to store in the database.
$value |
Definition at line 550 of file class.ilDataCollectionDatatype.php.
References $file, ilObject2\_exists(), ilObject2\_lookupType(), INPUTFORMAT_BOOLEAN, INPUTFORMAT_DATETIME, INPUTFORMAT_FILE, and INPUTFORMAT_MOB.
ilDataCollectionDatatype::parseFormInput | ( | $value, | |
ilDataCollectionRecordField | $record_field | ||
) |
function parses stored value to the variable needed to fill into the form for editing.
$value |
Definition at line 704 of file class.ilDataCollectionDatatype.php.
References ilObject2\_exists(), ilObject2\_lookupType(), ilDataCollectionRecordField\getField(), and ilDataCollectionField\PROPERTYID_TEXTAREA.
ilDataCollectionDatatype::parseHTML | ( | $value, | |
ilDataCollectionRecordField | $record_field | ||
) |
function parses stored value in database to a html output for eg.
the record list gui.
$value |
Definition at line 610 of file class.ilDataCollectionDatatype.php.
References $ilCtrl, ilObject2\_exists(), ilObjMediaObject\_getDirectory(), ilObject2\_lookupType(), ilDatePresentation\formatDate(), ilDataCollectionRecordField\getField(), ilUtil\getImagePath(), ilDataCollectionRecordField\getRecord(), IL_CAL_DATETIME, INPUTFORMAT_TEXT, and ilDataCollectionField\PROPERTYID_URL.
ilDataCollectionDatatype::parseValue | ( | $value, | |
ilDataCollectionRecordField | $record_field | ||
) |
Function to parse incoming data from form input value $value.
returns the strin/number/etc. to store in the database.
$value | ||
ilDataCollectionRecordField | $record_field |
Definition at line 425 of file class.ilDataCollectionDatatype.php.
References $file, $location, $title, ilObjMediaObject\_determineWidthHeight(), ilObjMediaObject\_getDirectory(), ilObjMediaObject\_resizeImage(), ilObjMediaObject\_saveUsage(), ilUtil\getASCIIFilename(), ilDataCollectionRecordField\getField(), ilMimeTypeUtil\getMimeType(), ilObjMediaObject\getMimeType(), ilDataCollectionRecordField\getRecord(), ilDataCollectionRecordField\getValue(), INPUTFORMAT_BOOLEAN, INPUTFORMAT_DATETIME, INPUTFORMAT_FILE, INPUTFORMAT_MOB, INPUTFORMAT_NUMBER, INPUTFORMAT_TEXT, ilUtil\moveUploadedFile(), ilDataCollectionField\PROPERTYID_HEIGHT, ilDataCollectionField\PROPERTYID_TEXTAREA, ilDataCollectionField\PROPERTYID_WIDTH, and ilUtil\renameExecutables().
|
static |
Definition at line 347 of file class.ilDataCollectionDatatype.php.
References $pass, ilObject2\_exists(), ilObject\_lookupObjId(), ilObject\_lookupTitle(), ilObject2\_lookupType(), ilDataCollectionField\getDatatypeId(), ilDataCollectionField\getId(), ilDataCollectionRecord\getRecordFieldValue(), INPUTFORMAT_BOOLEAN, INPUTFORMAT_DATETIME, INPUTFORMAT_FILE, INPUTFORMAT_ILIAS_REF, INPUTFORMAT_MOB, INPUTFORMAT_NUMBER, INPUTFORMAT_RATING, INPUTFORMAT_REFERENCE, and INPUTFORMAT_TEXT.
Referenced by ilDataCollectionRecord\passThroughFilter().
ilDataCollectionDatatype::setStorageLocation | ( | $a_id | ) |
Set Storage Location.
int | $a_id |
Definition at line 105 of file class.ilDataCollectionDatatype.php.
Referenced by doRead().
ilDataCollectionDatatype::setTitle | ( | $a_title | ) |
Set title.
string | $a_title |
Definition at line 85 of file class.ilDataCollectionDatatype.php.
Referenced by doRead().
|
protected |
Definition at line 31 of file class.ilDataCollectionDatatype.php.
Referenced by getDbType().
|
protected |
Definition at line 28 of file class.ilDataCollectionDatatype.php.
Referenced by getId().
|
protected |
Definition at line 30 of file class.ilDataCollectionDatatype.php.
Referenced by getStorageLocation().
|
protected |
Definition at line 29 of file class.ilDataCollectionDatatype.php.
Referenced by getInputField(), getTitle(), and parseValue().
const ilDataCollectionDatatype::INPUTFORMAT_BOOLEAN = 4 |
Definition at line 40 of file class.ilDataCollectionDatatype.php.
Referenced by addFilterInputFieldToTable(), getInputField(), ilDataCollectionTable\getPartialRecords(), ilDataCollectionFieldEditGUI\initForm(), parseExportValue(), parseValue(), and passThroughFilter().
const ilDataCollectionDatatype::INPUTFORMAT_DATETIME = 5 |
Definition at line 42 of file class.ilDataCollectionDatatype.php.
Referenced by ilDataCollectionStandardField\_getDatatypeForId(), ilDataCollectionStandardField\_getStandardFieldsAsArray(), addFilterInputFieldToTable(), ilDataCollectionField\checkValidity(), getInputField(), ilDataCollectionTable\getPartialRecords(), parseExportValue(), parseValue(), and passThroughFilter().
const ilDataCollectionDatatype::INPUTFORMAT_FILE = 6 |
Definition at line 44 of file class.ilDataCollectionDatatype.php.
Referenced by addFilterInputFieldToTable(), ilDataCollectionRecord\doDelete(), getInputField(), ilDataCollectionTable\getPartialRecords(), ilDataCollectionRecordEditGUI\initForm(), parseExportValue(), parseValue(), passThroughFilter(), and ilDataCollectionRecordField\setValue().
const ilDataCollectionDatatype::INPUTFORMAT_ILIAS_REF = 8 |
Definition at line 48 of file class.ilDataCollectionDatatype.php.
Referenced by addFilterInputFieldToTable(), ilDataCollectionRecordViewViewdefinition\getAvailablePlaceholders(), getInputField(), ilDataCollectionCache\getInstance(), ilDataCollectionTable\getPartialRecords(), and passThroughFilter().
const ilDataCollectionDatatype::INPUTFORMAT_MOB = 9 |
Definition at line 50 of file class.ilDataCollectionDatatype.php.
Referenced by addFilterInputFieldToTable(), ilDataCollectionField\checkValidity(), ilDataCollectionRecord\doDelete(), getInputField(), ilDataCollectionTable\getPartialRecords(), ilDataCollectionRecordEditGUI\getValues(), ilDataCollectionRecordEditGUI\initForm(), parseExportValue(), parseValue(), passThroughFilter(), and ilDataCollectionRecordEditGUI\save().
const ilDataCollectionDatatype::INPUTFORMAT_NUMBER = 1 |
Definition at line 36 of file class.ilDataCollectionDatatype.php.
Referenced by ilDataCollectionRecordListTableGUI\__construct(), ilDataCollectionStandardField\_getDatatypeForId(), ilDataCollectionStandardField\_getStandardFieldsAsArray(), addFilterInputFieldToTable(), getInputField(), ilDataCollectionTable\getPartialRecords(), parseValue(), and passThroughFilter().
const ilDataCollectionDatatype::INPUTFORMAT_RATING = 7 |
Definition at line 46 of file class.ilDataCollectionDatatype.php.
Referenced by addFilterInputFieldToTable(), getInputField(), ilDataCollectionCache\getInstance(), ilDataCollectionTable\getPartialRecords(), and passThroughFilter().
const ilDataCollectionDatatype::INPUTFORMAT_REFERENCE = 3 |
Definition at line 38 of file class.ilDataCollectionDatatype.php.
Referenced by addFilterInputFieldToTable(), ilDataCollectionField\cloneProperties(), ilObjDataCollection\cloneStructure(), ilDataCollectionRecordViewViewdefinition\getAvailablePlaceholders(), getInputField(), ilDataCollectionCache\getInstance(), ilDataCollectionTable\getPartialRecords(), ilDataCollectionRecordEditGUI\initForm(), ilDataCollectionFieldEditGUI\initForm(), and passThroughFilter().
const ilDataCollectionDatatype::INPUTFORMAT_TEXT = 2 |
Definition at line 34 of file class.ilDataCollectionDatatype.php.
Referenced by ilDataCollectionStandardField\_getDatatypeForId(), ilDataCollectionStandardField\_getStandardFieldsAsArray(), addFilterInputFieldToTable(), ilDataCollectionFieldEditGUI\checkInput(), ilDataCollectionField\checkValidity(), getInputField(), ilDataCollectionTable\getPartialRecords(), parseHTML(), parseValue(), and passThroughFilter().
const ilDataCollectionDatatype::LINK_MAX_LENGTH = 30 |
Definition at line 52 of file class.ilDataCollectionDatatype.php.