ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilMembershipRegistrationSettingsGUI Class Reference

Registration settings. More...

+ Inheritance diagram for ilMembershipRegistrationSettingsGUI:
+ Collaboration diagram for ilMembershipRegistrationSettingsGUI:

Public Member Functions

 __construct (ilObjectGUI $gui_object, ilObject $object, array $a_options)
 
 setFormValues (ilPropertyFormGUI $form)
 Set form values. More...
 
 getCurrentObject ()
 
 getCurrentGUI ()
 
 getOptions ()
 
 addMembershipFormElements (ilPropertyFormGUI $form, string $a_parent_post='')
 

Protected Member Functions

 txt (string $a_lang_key)
 Translate type specific. More...
 

Protected Attributes

ilLanguage $lng
 

Private Attributes

ilObject $object
 
ilObjectGUI $gui_object
 
array $options = []
 

Detailed Description

Registration settings.

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
Version
$Id$

Definition at line 27 of file class.ilMembershipRegistrationSettingsGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilMembershipRegistrationSettingsGUI::__construct ( ilObjectGUI  $gui_object,
ilObject  $object,
array  $a_options 
)

Reimplemented in ilSessionMembershipRegistrationSettingsGUI.

Definition at line 34 of file class.ilMembershipRegistrationSettingsGUI.php.

35 {
36 global $DIC;
37
38 $this->lng = $DIC->language();
39 $this->gui_object = $gui_object;
40 $this->object = $object;
41 $this->options = $a_options;
42 }
global $DIC
Definition: shib_login.php:26

References $DIC, $gui_object, $object, and ILIAS\Repository\lng().

+ Here is the call graph for this function:

Member Function Documentation

◆ addMembershipFormElements()

ilMembershipRegistrationSettingsGUI::addMembershipFormElements ( ilPropertyFormGUI  $form,
string  $a_parent_post = '' 
)
final

Definition at line 64 of file class.ilMembershipRegistrationSettingsGUI.php.

64 : void
65 {
66 // Registration type
67 $reg_type = new ilRadioGroupInputGUI($this->txt('reg_type'), 'registration_type');
68 //$reg_type->setValue($this->object->getRegistrationType());
69
71 $opt_dir = new ilRadioOption(
72 $this->txt('reg_direct'),
74 );
75 $opt_dir->setInfo($this->txt('reg_direct_info'));
76 $reg_type->addOption($opt_dir);
77
78 // cannot participate
79 $cannot_participate = new ilCheckboxInputGUI(
80 $this->txt('reg_cannot_participate'),
81 'show_cannot_participate_direct'
82 );
83 $cannot_participate->setInfo($this->txt('reg_cannot_participate_info'));
84 $cannot_participate->setValue("1");
85 $opt_dir->addSubItem($cannot_participate);
86 }
88 $opt_pass = new ilRadioOption(
89 $this->txt('reg_pass'),
91 );
92 $pass = new ilTextInputGUI($GLOBALS['DIC']['lng']->txt("password"), 'password');
93 $pass->setInfo($this->txt('reg_password_info'));
94 #$pass->setValue($this->object->getPassword());
95 $pass->setSize(10);
96 $pass->setMaxLength(32);
97 $opt_pass->addSubItem($pass);
98 $reg_type->addOption($opt_pass);
99 }
100
102 $opt_req = new ilRadioOption(
103 $this->txt('reg_request'),
105 $this->txt('reg_request_info')
106 );
107 $reg_type->addOption($opt_req);
108
109 // cannot participate
110 $cannot_participate = new ilCheckboxInputGUI(
111 $this->txt('reg_cannot_participate'),
112 'show_cannot_participate_request'
113 );
114 $cannot_participate->setInfo($this->txt('reg_cannot_participate_info'));
115 $cannot_participate->setValue("1");
116 $opt_req->addSubItem($cannot_participate);
117 }
119 $opt_tutor = new ilRadioOption(
120 $this->txt('reg_tutor'),
122 $this->txt('reg_tutor_info')
123 );
124 $reg_type->addOption($opt_tutor);
125 }
127 $opt_deact = new ilRadioOption(
128 $this->txt('reg_disabled'),
130 $this->txt('reg_disabled_info')
131 );
132 $reg_type->addOption($opt_deact);
133 }
134
135 // Add to form
136 $form->addItem($reg_type);
137
139 // max member
140 $lim = new ilCheckboxInputGUI($this->txt('reg_max_members_short'), 'registration_membership_limited');
141 $lim->setValue("1");
142
143 $max = new ilTextInputGUI($this->txt('reg_max_members'), 'registration_max_members');
144 #$max->setValue($this->object->getMaxMembers() ? $this->object->getMaxMembers() : '');
145 //$max->setTitle($this->lng->txt('members'));
146 $max->setSize(3);
147 $max->setMaxLength(4);
148 $max->setInfo($this->txt('reg_max_members_info'));
149 $lim->addSubItem($max);
150
151 $wait = new ilRadioGroupInputGUI($this->txt('reg_waiting_list'), 'waiting_list');
152
153 $option = new ilRadioOption($this->txt('reg_waiting_list_none'), "0");
154 $wait->addOption($option);
155
156 $option = new ilRadioOption($this->txt('reg_waiting_list_no_autofill'), "1");
157 $option->setInfo($this->txt('reg_waiting_list_no_autofill_info'));
158 $wait->addOption($option);
159
160 $option = new ilRadioOption($this->txt('reg_waiting_list_autofill'), "2");
161 $option->setInfo($this->txt('reg_waiting_list_autofill_info'));
162 $wait->addOption($option);
163
164 $lim->addSubItem($wait);
165
166 $form->addItem($lim);
167 }
168
169 $notificationCheckbox = new ilCheckboxInputGUI(
170 $this->txt('registration_notification'),
171 'registration_notification'
172 );
173 $notificationCheckbox->setInfo($this->txt('registration_notification_info'));
174
175 $notificationOption = new ilRadioGroupInputGUI($this->txt('notification_option'), 'notification_option');
176 $notificationOption->setRequired(true);
177
178 $inheritOption = new ilRadioOption(
181 );
182 $inheritOption->setInfo($this->txt('notification_option_inherit_info'));
183 $notificationOption->addOption($inheritOption);
184
185 $manualOption = new ilRadioOption(
188 );
189 $manualOption->setInfo($this->txt('notification_option_manual_info'));
190 $notificationOption->addOption($manualOption);
191
192 $notificationCheckbox->addSubItem($notificationOption);
193 $form->addItem($notificationCheckbox);
194
195 $this->setFormValues($form);
196 }
This class represents a checkbox property in a property form.
setFormValues(ilPropertyFormGUI $form)
Set form values.
txt(string $a_lang_key)
Translate type specific.
This class represents a property in a property form.
This class represents an option in a radio group.
This class represents a text property in a property form.
$GLOBALS["DIC"]
Definition: wac.php:54

References $GLOBALS, ilPropertyFormGUI\addItem(), getOptions(), ilSessionConstants\NOTIFICATION_INHERIT_OPTION, ilSessionConstants\NOTIFICATION_MANUAL_OPTION, ilMembershipRegistrationSettings\REGISTRATION_LIMITED_USERS, setFormValues(), txt(), ilMembershipRegistrationSettings\TYPE_DIRECT, ilMembershipRegistrationSettings\TYPE_NONE, ilMembershipRegistrationSettings\TYPE_PASSWORD, ilMembershipRegistrationSettings\TYPE_REQUEST, and ilMembershipRegistrationSettings\TYPE_TUTOR.

+ Here is the call graph for this function:

◆ getCurrentGUI()

ilMembershipRegistrationSettingsGUI::getCurrentGUI ( )

Definition at line 54 of file class.ilMembershipRegistrationSettingsGUI.php.

55 {
56 return $this->gui_object;
57 }
Class ilObjectGUI Basic methods of all Output classes.

References $gui_object.

◆ getCurrentObject()

ilMembershipRegistrationSettingsGUI::getCurrentObject ( )

Definition at line 49 of file class.ilMembershipRegistrationSettingsGUI.php.

49 : ilObject
50 {
51 return $this->object;
52 }
Class ilObject Basic functions for all objects.

References $object.

Referenced by ilSessionMembershipRegistrationSettingsGUI\setFormValues(), and txt().

+ Here is the caller graph for this function:

◆ getOptions()

ilMembershipRegistrationSettingsGUI::getOptions ( )

Definition at line 59 of file class.ilMembershipRegistrationSettingsGUI.php.

References $options.

Referenced by addMembershipFormElements().

+ Here is the caller graph for this function:

◆ setFormValues()

ilMembershipRegistrationSettingsGUI::setFormValues ( ilPropertyFormGUI  $form)
abstract

Set form values.

Reimplemented in ilSessionMembershipRegistrationSettingsGUI.

Referenced by addMembershipFormElements().

+ Here is the caller graph for this function:

◆ txt()

ilMembershipRegistrationSettingsGUI::txt ( string  $a_lang_key)
protected

Translate type specific.

Definition at line 201 of file class.ilMembershipRegistrationSettingsGUI.php.

201 : string
202 {
203 $prefix = $this->getCurrentObject()->getType();
204 return $this->lng->txt($prefix . '_' . $a_lang_key);
205 }

References getCurrentObject(), and ILIAS\Repository\lng().

Referenced by addMembershipFormElements().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $gui_object

ilObjectGUI ilMembershipRegistrationSettingsGUI::$gui_object
private

◆ $lng

ilLanguage ilMembershipRegistrationSettingsGUI::$lng
protected

◆ $object

ilObject ilMembershipRegistrationSettingsGUI::$object
private

◆ $options

array ilMembershipRegistrationSettingsGUI::$options = []
private

Definition at line 32 of file class.ilMembershipRegistrationSettingsGUI.php.

Referenced by getOptions().


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