35 $this->lng = $DIC->language();
36 $this->logger = $DIC->logger()->usr();
37 $this->plugin_admin = $DIC[
'ilPluginAdmin'];
46 if (self::$instance) {
47 return self::$instance;
49 return self::$instance =
new self();
63 include_once
'./Services/User/classes/class.ilUDFDefinitionPlugin.php';
65 $types[$plugin->getDefinitionType()] = $plugin->getDefinitionTypeName();
77 if ($plugin->getDefinitionType() ==
$a_type) {
93 include_once
'./Services/User/classes/class.ilUDFDefinitionPlugin.php';
95 $this->plugin_admin->getActivePluginsForSlot(
101 $plug = $this->plugin_admin->getPluginObject(
123 switch ($definition[
'field_type']) {
126 $definition[
'field_name'],
127 'udf_' . $definition[
'field_id']
129 $fprop->setDisabled(!$a_changeable);
130 $fprop->setValue($a_default_value);
132 $fprop->setMaxLength(255);
133 $fprop->setRequired($definition[
'required'] ?
true :
false);
138 $definition[
'field_name'],
139 'udf_' . $definition[
'field_id']
141 $fprop->setDisabled(!$a_changeable);
142 $fprop->setValue($a_default_value);
143 $fprop->setUseRte(
true);
144 $fprop->setRequired($definition[
'required'] ?
true :
false);
149 $definition[
'field_name'],
150 'udf_' . $definition[
'field_id']
152 $fprop->setDisabled(!$a_changeable);
154 include_once
'./Services/User/classes/class.ilUserDefinedFields.php';
157 $fprop->setOptions($user_defined_fields->fieldValuesToSelectArray($definition[
'field_values']));
158 $fprop->setValue($a_default_value);
159 $fprop->setRequired($definition[
'required'] ?
true :
false);
165 if ($plugin->getDefinitionType() == $definition[
'field_type']) {
166 $fprop = $plugin->getFormPropertyForDefinition($definition, $a_changeable, $a_default_value);
static _getInstance()
Get instance.
getFormPropertyForDefinition($definition, $a_changeable=true, $a_default_value=null)
Get form property for definition.
getPluginForType($a_type)
Get plugin for udf type.
getUDFTypes()
Get udf types.
static getInstance()
Get instance.
UDF type deefinition plugin.
getActivePlugins()
Get plugins for fields.
This class represents a text property in a property form.
Description of class class.
This class represents a text area property in a property form.