4 require_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
27 public function getCreationForm()
40 $form->addItem($description);
42 return $this->addDefaultBehaviour($form);
52 foreach($values as $key => $value)
60 switch(strtolower(get_class($field)))
62 case 'ilcheckboxinputgui':
65 $field->setChecked(
true);
70 $field->setValue($value);
79 public function getSettingsForm()
92 $form->addItem($description);
95 $cb->
setInfo($lng->txt(
'anonymous_hint'));
98 $txt =
new ilTextInputGUI($lng->txt(
'autogen_usernames'),
'autogen_usernames');
100 $txt->setInfo($lng->txt(
'autogen_usernames_info'));
101 $form->addItem($txt);
103 $cb =
new ilCheckboxInputGUI($lng->txt(
'allow_custom_usernames'),
'allow_custom_usernames');
107 $form->addItem($cb_history);
109 $num_msg_history =
new ilNumberInputGUI($lng->txt(
'display_past_msgs'),
'display_past_msgs');
110 $num_msg_history->
setInfo($lng->txt(
'hint_display_past_msgs'));
111 $num_msg_history->setMinValue(0);
112 $num_msg_history->setMaxValue(100);
113 $form->addItem($num_msg_history);
115 $cb =
new ilCheckboxInputGUI($lng->txt(
'private_rooms_enabled'),
'private_rooms_enabled');
116 $cb->
setInfo($lng->txt(
'private_rooms_enabled_info'));
126 public function getFileUploadForm()
136 $file_input->setPostVar(
'file_to_upload');
137 $file_input->setTitle($lng->txt(
'upload'));
138 $form->addItem($file_input);
139 $form->addCommandButton(
'UploadFile-uploadFile', $lng->txt(
'submit'));
141 $form->setTarget(
'_blank');
168 public function getPeriodForm()
177 require_once
'Services/Form/classes/class.ilDateDurationInputGUI.php';
181 $duration->setEndText($lng->txt(
'duration_to'));
182 $duration->setShowTime(
true);
193 public function getUserChatNameSelectionForm(array $name_options)
203 $radio =
new ilRadioGroupInputGUI($lng->txt(
'select_custom_username'),
'custom_username_radio');
205 foreach($name_options as $key => $option)
208 $radio->addOption($opt);
211 $custom_opt =
new ilRadioOption($lng->txt(
'custom_username'),
'custom_username');
212 $radio->addOption($custom_opt);
214 $txt =
new ilTextInputGUI($lng->txt(
'custom_username'),
'custom_username_text');
218 if($ilUser->isAnonymous())
220 $radio->setValue(
'anonymousName');
224 $radio->setValue(
'fullname');
235 public function getSessionForm(array $sessions)
247 foreach($sessions as $session)
252 $options[$session[
'connected'] .
',' .
256 $list->setOptions($options);
257 $list->setRequired(
true);
268 public function getGeneralSettingsForm()
277 $address =
new ilTextInputGUI($lng->txt(
'chatserver_address'),
'address');
283 $port->setMaxValue(65535);
284 $port->setRequired(
true);
285 $port->setInfo($lng->txt(
'port_info'));
289 $priv_hosts =
new ilTextInputGUI($lng->txt(
'priv_hosts'),
'priv_hosts');
293 $keystore =
new ilTextInputGUI($lng->txt(
'keystore'),
'keystore');
297 $storepass =
new ilTextInputGUI($lng->txt(
'storepass'),
'storepass');
306 $protocol->addOption($http);
307 $protocol->addOption($https);
316 public function getClientSettingsForm()
329 $cb->
setInfo($lng->txt(
'hint_osd'));
334 $txt->setRequired(
true);
335 $txt->setInfo($lng->txt(
'hint_osd_interval'));
336 $cb->addSubItem($txt);
338 $cb1 =
new ilCheckboxInputGUI($lng->txt(
'play_invitation_sound'),
'play_invitation_sound');
339 $cb1->
setInfo($lng->txt(
'play_invitation_sound'));
340 $cb->addSubItem($cb1);
343 $cb->
setInfo($lng->txt(
'hint_enable_smilies'));
348 $name->setValidationRegexp(
'/^[a-z0-9_-]+$/i');
349 $name->setInfo($lng->txt(
'hint_unique_name'));
357 $user->
setInfo($lng->txt(
'soap_user_hint'));
358 $user->setRequired(
true);
363 $password->setRequired(
true);