ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ilObjCmiXapiAdministrationGUI Class Reference
+ Inheritance diagram for ilObjCmiXapiAdministrationGUI:
+ Collaboration diagram for ilObjCmiXapiAdministrationGUI:

Public Member Functions

 getAdminTabs ()
 
 executeCommand ()
 
- Public Member Functions inherited from ilObjectGUI
 executeCommand ()
 execute command More...
 
 withReferences ()
 determines wether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode ($a_mode=true)
 if true, a creation screen is displayed the current $_GET[ref_id] don't belong to the current class! the mode is determined in ilrepositorygui More...
 
 getCreationMode ()
 get creation mode More...
 
 prepareOutput ($a_show_subobjects=true)
 prepare output More...
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelDeleteObject ()
 cancel deletion of object More...
 
 cancelObject ()
 cancel action and go back to previous page public More...
 
 createObject ()
 create new object form More...
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 save object More...
 
 getDidacticTemplateVar ($a_type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $a_obj, $a_parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 edit object More...
 
 addExternalEditFormCustom (ilPropertyFormGUI $a_form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction ($a_cmd, $a_formaction="")
 get form action for command (command is method name without "Object", e.g. More...
 
 isVisible ($a_ref_id, $a_type)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 deleteObject ($a_error=false)
 Display deletion confirmation screen. More...
 
 cloneAllObject ()
 Clone single (not container object) Method is overwritten in ilContainerGUI. More...
 
 redirectAfterCreation ()
 Redirect after creation, see https://docu.ilias.de/goto_docu_wiki_wpage_5035_1357.html. More...
 
 addToDeskObject ()
 
 removeFromDeskObject ()
 

Data Fields

const TAB_ID_LRS_TYPES = 'tab_lrs_types'
 
const TAB_ID_PERMISSIONS = 'perm_settings'
 
const CMD_SHOW_LRS_TYPES_LIST = 'showLrsTypesList'
 
const CMD_SHOW_LRS_TYPE_FORM = 'showLrsTypeForm'
 
const CMD_SAVE_LRS_TYPE_FORM = 'saveLrsTypeForm'
 
const DEFAULT_CMD = self::CMD_SHOW_LRS_TYPES_LIST
 
- Data Fields inherited from ilObjectGUI
const COPY_WIZARD_NEEDS_PAGE = 1
 
 $objDefinition
 
 $tpl
 
 $tree
 
 $lng
 
 $data
 
 $object
 
 $ref_id
 
 $obj_id
 
 $maxcount
 
 $formaction
 
 $return_location
 
 $target_frame
 
 $tab_target_script
 
 $actions
 
 $sub_objects
 
 $omit_locator = false
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 

Protected Member Functions

 viewCmd ()
 
 showLrsTypesListCmd ()
 
 buildLrsTypesTableGUI ()
 
 buildLrsTypesToolbarGUI ()
 
 showLrsTypeFormCmd (ilPropertyFormGUI $form=null)
 
 initLrsType ()
 
 buildLrsTypeForm (ilCmiXapiLrsType $lrsType)
 
 saveLrsTypeFormCmd ()
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 Get object service. More...
 
 assignObject ()
 
 setTitleAndDescription ()
 called by prepare output More...
 
 initHeaderAction ($a_sub_type=null, $a_sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction ($a_list_gui)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 setTabs ()
 set admin tabs public More...
 
 setAdminTabs ()
 set admin tabs public More...
 
 setLocator ()
 set Locator More...
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator ($a_omit=true)
 
 addAdminLocatorItems ($a_do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 initCreationForms ($a_new_type)
 Init creation froms. More...
 
 getCreationFormsHTML (array $a_forms)
 Get HTML for creation forms (accordion) More...
 
 initCreateForm ($a_new_type)
 Init object creation form. More...
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 Show didactic template types. More...
 
 addDidacticTemplateOptions (array &$a_options)
 Add custom templates. More...
 
 afterSave (ilObject $a_new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 Init object edit form. More...
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 Get values for edit form. More...
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $a_form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $a_form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 initImportForm ($a_new_type)
 Init object import form. More...
 
 importFileObject ($parent_id=null, $a_catch_errors=true)
 Import. More...
 
 afterImport (ilObject $a_new_object)
 Post (successful) object import hook. More...
 
 setFormAction ($a_cmd, $a_formaction)
 set specific form action for command More...
 
 getReturnLocation ($a_cmd, $a_location="")
 get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation ($a_cmd, $a_location)
 set specific return location for command More...
 
 getTargetFrame ($a_cmd, $a_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame ($a_cmd, $a_target_frame)
 set specific target frame for command More...
 
 showPossibleSubObjects ()
 show possible subobjects (pulldown menu) More...
 
 getTemplateFile ($a_cmd, $a_type="")
 get a template blockfile format: tpl. More...
 
 getTabs ()
 get tabs abstract method. More...
 
 __showButton ($a_cmd, $a_text, $a_target='')
 
 hitsperpageObject ()
 
__initTableGUI ()
 
 __setTableGUIBasicData (&$tbl, &$result_set, $a_from="")
 standard implementation for tables use 'from' variable use different initial setting of table More...
 
 redirectToRefId ($a_ref_id, $a_cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current $_GET["ref_id"] value More...
 
 fillCloneTemplate ($a_tpl_varname, $a_type)
 Fill object clone template This method can be called from any object GUI class that wants to offer object cloning. More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 May be overwritten in subclasses. More...
 
 checkPermission ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission and redirect on error. More...
 
 checkPermissionBool ($a_perm, $a_cmd="", $a_type="", $a_ref_id=null)
 Check permission. More...
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 handleAutoRating (ilObject $a_new_obj)
 Activate rating automatically if parent container setting. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot ($a_raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode ($a_ref_id, $a_cmd="frameset")
 Goto repository root. More...
 
- Protected Attributes inherited from ilObjectGUI
 $ilErr
 
 $locator
 
 $user
 
 $access
 
 $rbacsystem
 
 $settings
 
 $rbacreview
 
 $toolbar
 
 $tmp_import_dir
 
 $tabs_gui = null
 
 $ctrl
 
 $object_service
 
 $favourites
 

Detailed Description

Definition at line 17 of file class.ilObjCmiXapiAdministrationGUI.php.

Member Function Documentation

◆ buildLrsTypeForm()

ilObjCmiXapiAdministrationGUI::buildLrsTypeForm ( ilCmiXapiLrsType  $lrsType)
protected

Definition at line 141 of file class.ilObjCmiXapiAdministrationGUI.php.

References $DIC, ilCmiXapiLrsType\AVAILABILITY_CREATE, ilCmiXapiLrsType\AVAILABILITY_EXISTING, ilCmiXapiLrsType\AVAILABILITY_NONE, ilCmiXapiLrsType\getAchieved(), ilCmiXapiLrsType\getAnswered(), ilCmiXapiLrsType\getAvailability(), ilCmiXapiLrsType\getCompleted(), ilCmiXapiLrsType\getDescription(), ilCmiXapiLrsType\getDuration(), ilCmiXapiLrsType\getExternalLrs(), ilCmiXapiLrsType\getFailed(), ilCmiXapiLrsType\getForcePrivacySettings(), ilCmiXapiLrsType\getHideData(), ilCmiXapiUser\getIliasUuid(), ilCmiXapiLrsType\getInitialized(), ilCmiXapiLrsType\getLrsEndpoint(), ilCmiXapiLrsType\getLrsKey(), ilCmiXapiLrsType\getLrsSecret(), ilCmiXapiLrsType\getNoSubstatements(), ilCmiXapiLrsType\getOnlyMoveon(), ilCmiXapiLrsType\getPassed(), ilCmiXapiLrsType\getPrivacyCommentDefault(), ilCmiXapiLrsType\getPrivacyIdent(), ilCmiXapiLrsType\getPrivacyName(), ilCmiXapiLrsType\getProgressed(), ilCmiXapiLrsType\getRemarks(), ilCmiXapiLrsType\getSatisfied(), ilCmiXapiLrsType\getTerminated(), ilCmiXapiLrsType\getTimestamp(), ilCmiXapiLrsType\getTitle(), ilCmiXapiLrsType\getTypeId(), ilCmiXapiLrsType\isBypassProxyEnabled(), ilCmiXapiLrsType\PRIVACY_IDENT_IL_UUID_EXT_ACCOUNT, ilCmiXapiLrsType\PRIVACY_IDENT_IL_UUID_LOGIN, ilCmiXapiLrsType\PRIVACY_IDENT_IL_UUID_RANDOM, ilCmiXapiLrsType\PRIVACY_IDENT_IL_UUID_SHA256, ilCmiXapiLrsType\PRIVACY_IDENT_IL_UUID_USER_ID, ilCmiXapiLrsType\PRIVACY_IDENT_REAL_EMAIL, ilCmiXapiLrsType\PRIVACY_NAME_FIRSTNAME, ilCmiXapiLrsType\PRIVACY_NAME_FULLNAME, ilCmiXapiLrsType\PRIVACY_NAME_LASTNAME, ilCmiXapiLrsType\PRIVACY_NAME_NONE, ilCheckboxInputGUI\setChecked(), ilFormPropertyGUI\setInfo(), and ilRadioOption\setValue().

Referenced by saveLrsTypeFormCmd(), and showLrsTypeFormCmd().

142  {
143  global $DIC; /* @var \ILIAS\DI\Container $DIC */
144 
145  $form = new ilPropertyFormGUI();
146  $form->setFormAction($DIC->ctrl()->getFormAction($this));
147 
148  if ($lrsType->getTypeId()) {
149  $form->setTitle($DIC->language()->txt('edit_lrs_type_form'));
150  $form->addCommandButton(self::CMD_SAVE_LRS_TYPE_FORM, $DIC->language()->txt('save'));
151  } else {
152  $form->setTitle($DIC->language()->txt('create_lrs_type_form'));
153  $form->addCommandButton(self::CMD_SAVE_LRS_TYPE_FORM, $DIC->language()->txt('create'));
154  }
155 
156  $form->addCommandButton(self::CMD_SHOW_LRS_TYPES_LIST, $DIC->language()->txt('cancel'));
157 
158  $hiddenId = new ilHiddenInputGUI('lrs_type_id');
159  $hiddenId->setValue($lrsType->getTypeId());
160  $form->addItem($hiddenId);
161 
162 
163  $item = new ilTextInputGUI($DIC->language()->txt('conf_title'), 'title');
164  $item->setValue($lrsType->getTitle());
165  $item->setInfo($DIC->language()->txt('info_title'));
166  $item->setRequired(true);
167  $item->setMaxLength(255);
168  $form->addItem($item);
169 
170  $item = new ilTextInputGUI($DIC->language()->txt('conf_description'), 'description');
171  $item->setValue($lrsType->getDescription());
172  $item->setInfo($DIC->language()->txt('info_description'));
173  $form->addItem($item);
174 
175  $item = new ilRadioGroupInputGUI($DIC->language()->txt('conf_availability'), 'availability');
176  $optionCreate = new ilRadioOption(
177  $DIC->language()->txt('conf_availability_' . ilCmiXapiLrsType::AVAILABILITY_CREATE),
179  );
180  $item->addOption($optionCreate);
181  $optionCreate = new ilRadioOption(
182  $DIC->language()->txt('conf_availability_' . ilCmiXapiLrsType::AVAILABILITY_EXISTING),
184  );
185  $item->addOption($optionCreate);
186  $optionCreate = new ilRadioOption(
187  $DIC->language()->txt('conf_availability_' . ilCmiXapiLrsType::AVAILABILITY_NONE),
189  );
190  $item->addOption($optionCreate);
191  $item->setValue($lrsType->getAvailability());
192  $item->setInfo($DIC->language()->txt('info_availability'));
193  $item->setRequired(true);
194  $form->addItem($item);
195 
196  $sectionHeader = new ilFormSectionHeaderGUI();
197  $sectionHeader->setTitle($DIC->language()->txt('lrs_authentication'));
198  $form->addItem($sectionHeader);
199 
200  $item = new ilTextInputGUI($DIC->language()->txt('conf_lrs_endpoint'), 'lrs_endpoint');
201  $item->setValue($lrsType->getLrsEndpoint());
202  $item->setInfo($DIC->language()->txt('info_lrs_endpoint'));
203  $item->setRequired(true);
204  $item->setMaxLength(255);
205  $form->addItem($item);
206 
207  $item = new ilTextInputGUI($DIC->language()->txt('conf_lrs_key'), 'lrs_key');
208  $item->setValue($lrsType->getLrsKey());
209  $item->setInfo($DIC->language()->txt('info_lrs_key'));
210  $item->setRequired(true);
211  $item->setMaxLength(128);
212  $form->addItem($item);
213 
214  $item = new ilTextInputGUI($DIC->language()->txt('conf_lrs_secret'), 'lrs_secret');
215  $item->setValue($lrsType->getLrsSecret());
216  $item->setInfo($DIC->language()->txt('info_lrs_secret'));
217  $item->setRequired(true);
218  $item->setMaxLength(128);
219  $form->addItem($item);
220 
221  $sectionHeader = new ilFormSectionHeaderGUI();
222  $sectionHeader->setTitle($DIC->language()->txt('sect_learning_progress_options'));
223  $form->addItem($sectionHeader);
224 
225  $cronjob = new ilCheckboxInputGUI($DIC->language()->txt('conf_cronjob_neccessary'), 'cronjob_neccessary');
226  $cronjob->setInfo($DIC->language()->txt('conf_cronjob_neccessary_info'));
227  $cronjob->setChecked($lrsType->isBypassProxyEnabled());
228  $form->addItem($cronjob);
229 
230  $sectionHeader = new ilFormSectionHeaderGUI();
231  $sectionHeader->setTitle('Privacy Settings');
232  $form->addItem($sectionHeader);
233 
234  $item = new ilRadioGroupInputGUI($DIC->language()->txt('conf_privacy_ident'), 'privacy_ident');
235  $op = new ilRadioOption(
236  $DIC->language()->txt('conf_privacy_ident_il_uuid_user_id'),
238  );
239  $op->setInfo($DIC->language()->txt('conf_privacy_ident_il_uuid_user_id_info'));
240  $item->addOption($op);
241  $op = new ilRadioOption(
242  $DIC->language()->txt('conf_privacy_ident_il_uuid_login'),
244  );
245  $op->setInfo($DIC->language()->txt('conf_privacy_ident_il_uuid_login_info'));
246  $item->addOption($op);
247  $op = new ilRadioOption(
248  $DIC->language()->txt('conf_privacy_ident_il_uuid_ext_account'),
250  );
251  $op->setInfo($DIC->language()->txt('conf_privacy_ident_il_uuid_ext_account_info'));
252  $item->addOption($op);
253  $op = new ilRadioOption(
254  $DIC->language()->txt('conf_privacy_ident_il_uuid_SHA256'),
256  );
257  $op->setInfo($DIC->language()->txt('conf_privacy_ident_il_uuid_SHA256_info'));
258  $item->addOption($op);
259  $op = new ilRadioOption(
260  $DIC->language()->txt('conf_privacy_ident_il_uuid_random'),
262  );
263  $op->setInfo($DIC->language()->txt('conf_privacy_ident_il_uuid_random_info'));
264  $item->addOption($op);
265  $op = new ilRadioOption(
266  $DIC->language()->txt('conf_privacy_ident_real_email'),
268  );
269  $op->setInfo($DIC->language()->txt('conf_privacy_ident_real_email_info'));
270  $item->addOption($op);
271  $item->setValue($lrsType->getPrivacyIdent());
272  $item->setInfo(
273  $DIC->language()->txt('conf_privacy_ident_info') . ' ' . ilCmiXapiUser::getIliasUuid()
274  );
275  $item->setRequired(false);
276  $form->addItem($item);
277 
278  $item = new ilRadioGroupInputGUI($DIC->language()->txt('conf_privacy_name'), 'privacy_name');
279  $op = new ilRadioOption($DIC->language()->txt('conf_privacy_name_none'), ilCmiXapiLrsType::PRIVACY_NAME_NONE);
280  $op->setInfo($DIC->language()->txt('conf_privacy_name_none_info'));
281  $item->addOption($op);
282  $op = new ilRadioOption($DIC->language()->txt('conf_privacy_name_firstname'), ilCmiXapiLrsType::PRIVACY_NAME_FIRSTNAME);
283  $op->setInfo($DIC->language()->txt('conf_privacy_name_firstname_info'));
284  $item->addOption($op);
285  $op = new ilRadioOption($DIC->language()->txt('conf_privacy_name_lastname'), ilCmiXapiLrsType::PRIVACY_NAME_LASTNAME);
286  $op->setInfo($DIC->language()->txt('conf_privacy_name_lastname_info'));
287  $item->addOption($op);
288  $op = new ilRadioOption($DIC->language()->txt('conf_privacy_name_fullname'), ilCmiXapiLrsType::PRIVACY_NAME_FULLNAME);
289  $op->setInfo($DIC->language()->txt('conf_privacy_name_fullname_info'));
290  $item->addOption($op);
291  $item->setValue($lrsType->getPrivacyName());
292  $item->setInfo($DIC->language()->txt('conf_privacy_name_info'));
293  $item->setRequired(false);
294  $form->addItem($item);
295 
296  $item = new ilCheckboxInputGUI($DIC->language()->txt('only_moveon_label'), 'only_moveon');
297  $item->setInfo($DIC->language()->txt('only_moveon_info'));
298  $item->setChecked($lrsType->getOnlyMoveon());
299 
300  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('achieved_label'), 'achieved');
301  $subitem->setInfo($DIC->language()->txt('achieved_info'));
302  $subitem->setChecked($lrsType->getAchieved());
303  $item->addSubItem($subitem);
304 
305  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('answered_label'), 'answered');
306  $subitem->setInfo($DIC->language()->txt('answered_info'));
307  $subitem->setChecked($lrsType->getAnswered());
308  $item->addSubItem($subitem);
309 
310  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('completed_label'), 'completed');
311  $subitem->setInfo($DIC->language()->txt('completed_info'));
312  $subitem->setChecked($lrsType->getCompleted());
313  $item->addSubItem($subitem);
314 
315  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('failed_label'), 'failed');
316  $subitem->setInfo($DIC->language()->txt('failed_info'));
317  $subitem->setChecked($lrsType->getFailed());
318  $item->addSubItem($subitem);
319 
320  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('initialized_label'), 'initialized');
321  $subitem->setInfo($DIC->language()->txt('initialized_info'));
322  $subitem->setChecked($lrsType->getInitialized());
323  $item->addSubItem($subitem);
324 
325  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('passed_label'), 'passed');
326  $subitem->setInfo($DIC->language()->txt('passed_info'));
327  $subitem->setChecked($lrsType->getPassed());
328  $item->addSubItem($subitem);
329 
330  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('progressed_label'), 'progressed');
331  $subitem->setInfo($DIC->language()->txt('progressed_info'));
332  $subitem->setChecked($lrsType->getProgressed());
333  $item->addSubItem($subitem);
334 
335  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('satisfied_label'), 'satisfied');
336  $subitem->setInfo($DIC->language()->txt('satisfied_info'));
337  $subitem->setChecked($lrsType->getSatisfied());
338  $item->addSubItem($subitem);
339 
340  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('terminated_label'), 'terminated');
341  $subitem->setInfo($DIC->language()->txt('terminated_info'));
342  $subitem->setChecked($lrsType->getTerminated());
343  $item->addSubItem($subitem);
344 
345  $form->addItem($item);
346 
347  $item = new ilCheckboxInputGUI($DIC->language()->txt('hide_data_label'), 'hide_data');
348  $item->setInfo($DIC->language()->txt('hide_data_info'));
349  $item->setChecked($lrsType->getHideData());
350 
351  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('timestamp_label'), 'timestamp');
352  $subitem->setInfo($DIC->language()->txt('timestamp_info'));
353  $subitem->setChecked($lrsType->getTimestamp());
354  $item->addSubItem($subitem);
355 
356  $subitem = new ilCheckboxInputGUI($DIC->language()->txt('duration_label'), 'duration');
357  $subitem->setInfo($DIC->language()->txt('duration_info'));
358  $subitem->setChecked($lrsType->getDuration());
359  $item->addSubItem($subitem);
360 
361  $form->addItem($item);
362 
363  $item = new ilCheckboxInputGUI($DIC->language()->txt('no_substatements_label'), 'no_substatements');
364  $item->setInfo($DIC->language()->txt('no_substatements_info'));
365  $item->setChecked($lrsType->getNoSubstatements());
366  $form->addItem($item);
367 
368  $item = new ilRadioGroupInputGUI($DIC->language()->txt('conf_privacy_setting_conf'), 'force_privacy_setting');
369  $op = new ilRadioOption($DIC->language()->txt('conf_privacy_setting_default'), 0);
370  $item->addOption($op);
371  $op = new ilRadioOption($DIC->language()->txt('conf_privacy_setting_force'), 1);
372  $item->addOption($op);
373  $item->setValue($lrsType->getForcePrivacySettings());
374  $form->addItem($item);
375 
376  $sectionHeader = new ilFormSectionHeaderGUI();
377  $sectionHeader->setTitle('Hints');
378  $form->addItem($sectionHeader);
379 
380  $item = new ilCheckboxInputGUI($DIC->language()->txt('conf_external_lrs'), 'external_lrs');
381  $item->setChecked($lrsType->getExternalLrs());
382  $item->setInfo($DIC->language()->txt('info_external_lrs'));
383  $form->addItem($item);
384 
385  $item = new ilTextAreaInputGUI($DIC->language()->txt('conf_privacy_comment_default'), 'privacy_comment_default');
386  $item->setInfo($DIC->language()->txt('info_privacy_comment_default'));
387  $item->setValue($lrsType->getPrivacyCommentDefault());
388  $item->setRows(5);
389  $form->addItem($item);
390 
391  $item = new ilTextAreaInputGUI($DIC->language()->txt('conf_remarks'), 'remarks');
392  $item->setInfo($DIC->language()->txt('info_remarks'));
393  $item->setValue($lrsType->getRemarks());
394  $item->setRows(5);
395  $form->addItem($item);
396 
397  return $form;
398  }
This class represents an option in a radio group.
This class represents a property form user interface.
This class represents a section header in a property form.
This class represents a checkbox property in a property form.
setInfo($a_info)
Set Information Text.
setChecked($a_checked)
Set Checked.
This class represents a hidden form property in a property form.
This class represents a property in a property form.
setValue($a_value)
Set Value.
This class represents a text area property in a property form.
$DIC
Definition: xapitoken.php:46
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ buildLrsTypesTableGUI()

ilObjCmiXapiAdministrationGUI::buildLrsTypesTableGUI ( )
protected

Definition at line 93 of file class.ilObjCmiXapiAdministrationGUI.php.

Referenced by showLrsTypesListCmd().

94  {
95  $table = new ilCmiXapiLrsTypesTableGUI($this, self::CMD_SHOW_LRS_TYPES_LIST);
96  return $table;
97  }
+ Here is the caller graph for this function:

◆ buildLrsTypesToolbarGUI()

ilObjCmiXapiAdministrationGUI::buildLrsTypesToolbarGUI ( )
protected

Definition at line 99 of file class.ilObjCmiXapiAdministrationGUI.php.

References $DIC, ilObjectGUI\$toolbar, and ilLinkButton\getInstance().

Referenced by showLrsTypesListCmd().

100  {
101  global $DIC; /* @var \ILIAS\DI\Container $DIC */
102 
103  $createTypeButton = ilLinkButton::getInstance();
104  $createTypeButton->setCaption('btn_create_lrs_type');
105  $createTypeButton->setUrl($DIC->ctrl()->getLinkTarget($this, self::CMD_SHOW_LRS_TYPE_FORM));
106 
107  $toolbar = new ilToolbarGUI();
108  $toolbar->addButtonInstance($createTypeButton);
109 
110  return $toolbar;
111  }
$DIC
Definition: xapitoken.php:46
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ executeCommand()

ilObjCmiXapiAdministrationGUI::executeCommand ( )

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

References $DIC, and ilObjectGUI\prepareOutput().

50  {
51  global $DIC; /* @var \ILIAS\DI\Container $DIC */
52 
53  $DIC->language()->loadLanguageModule('cmix');
54 
55  $this->prepareOutput();
56 
57  switch ($DIC->ctrl()->getNextClass()) {
58  case 'ilpermissiongui':
59 
60  $DIC->tabs()->activateTab(self::TAB_ID_PERMISSIONS);
61 
62  $gui = new ilPermissionGUI($this);
63  $DIC->ctrl()->forwardCommand($gui);
64  break;
65 
66  default:
67 
68  $command = $DIC->ctrl()->getCmd(self::DEFAULT_CMD) . 'Cmd';
69  $this->{$command}();
70  }
71  }
prepareOutput($a_show_subobjects=true)
prepare output
$DIC
Definition: xapitoken.php:46
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
+ Here is the call graph for this function:

◆ getAdminTabs()

ilObjCmiXapiAdministrationGUI::getAdminTabs ( )

Definition at line 28 of file class.ilObjCmiXapiAdministrationGUI.php.

References $DIC.

29  {
30  global $DIC; /* @var \ILIAS\DI\Container $DIC */
31 
32  // lrs types tab
33 
34  $DIC->tabs()->addTab(
35  self::TAB_ID_LRS_TYPES,
36  $DIC->language()->txt(self::TAB_ID_LRS_TYPES),
37  $DIC->ctrl()->getLinkTargetByClass(self::class)
38  );
39 
40  // permissions tab
41 
42  $DIC->tabs()->addTab(
43  self::TAB_ID_PERMISSIONS,
44  $DIC->language()->txt(self::TAB_ID_PERMISSIONS),
45  $DIC->ctrl()->getLinkTargetByClass(ilPermissionGUI::class, 'perm')
46  );
47  }
$DIC
Definition: xapitoken.php:46

◆ initLrsType()

ilObjCmiXapiAdministrationGUI::initLrsType ( )
protected

Definition at line 128 of file class.ilObjCmiXapiAdministrationGUI.php.

References $_GET, and $_POST.

Referenced by saveLrsTypeFormCmd(), and showLrsTypeFormCmd().

129  {
130  if (isset($_POST['lrs_type_id']) && (int) $_POST['lrs_type_id']) {
131  return new ilCmiXapiLrsType((int) $_POST['lrs_type_id']);
132  }
133 
134  if (isset($_GET['lrs_type_id']) && (int) $_GET['lrs_type_id']) {
135  return new ilCmiXapiLrsType((int) $_GET['lrs_type_id']);
136  }
137 
138  return new ilCmiXapiLrsType();
139  }
$_GET["client_id"]
$_POST["username"]
+ Here is the caller graph for this function:

◆ saveLrsTypeFormCmd()

ilObjCmiXapiAdministrationGUI::saveLrsTypeFormCmd ( )
protected

Definition at line 400 of file class.ilObjCmiXapiAdministrationGUI.php.

References $DIC, buildLrsTypeForm(), initLrsType(), ilUtil\removeTrailingPathSeparators(), showLrsTypeFormCmd(), ilObjCmiXapi\updateByPassProxyFromLrsType(), and ilObjCmiXapi\updatePrivacySettingsFromLrsType().

400  : void
401  {
402  global $DIC; /* @var \ILIAS\DI\Container $DIC */
403 
404  $lrsType = $this->initLrsType();
405 
406  $form = $this->buildLrsTypeForm($lrsType);
407 
408  if (!$form->checkInput()) {
409  $this->showLrsTypeFormCmd($form);
410  return;
411  }
412 
413  $lrsType->setTitle($form->getInput("title"));
414  $lrsType->setDescription($form->getInput("description"));
415  $lrsType->setAvailability($form->getInput("availability"));
416 
417  $lrsType->setLrsEndpoint(
418  ilUtil::removeTrailingPathSeparators($form->getInput("lrs_endpoint"))
419  );
420 
421  $lrsType->setLrsKey($form->getInput("lrs_key"));
422  $lrsType->setLrsSecret($form->getInput("lrs_secret"));
423  $lrsType->setExternalLrs($form->getInput("external_lrs"));
424  $lrsType->setPrivacyIdent($form->getInput("privacy_ident"));
425  $lrsType->setPrivacyName($form->getInput("privacy_name"));
426  $lrsType->setPrivacyCommentDefault($form->getInput("privacy_comment_default"));
427  $lrsType->setRemarks($form->getInput("remarks"));
428 
429  $oldBypassProxyEnabled = $lrsType->isBypassProxyEnabled();
430  $newBypassProxyEnabled = $form->getInput("cronjob_neccessary");
431  $lrsType->setBypassProxyEnabled((bool) $newBypassProxyEnabled);
432  if ($newBypassProxyEnabled && $newBypassProxyEnabled != $oldBypassProxyEnabled) {
434  }
435 
436  $lrsType->setOnlyMoveon((bool)$form->getInput("only_moveon"));
437  $lrsType->setAchieved((bool)$form->getInput("achieved"));
438  $lrsType->setAnswered((bool)$form->getInput("answered"));
439  $lrsType->setCompleted((bool)$form->getInput("completed"));
440  $lrsType->setFailed((bool)$form->getInput("failed"));
441  $lrsType->setInitialized((bool)$form->getInput("initialized"));
442  $lrsType->setPassed((bool)$form->getInput("passed"));
443  $lrsType->setProgressed((bool)$form->getInput("progressed"));
444  $lrsType->setSatisfied((bool)$form->getInput("satisfied"));
445  $lrsType->setTerminated((bool)$form->getInput("terminated"));
446  $lrsType->setHideData((bool)$form->getInput("hide_data"));
447  $lrsType->setTimestamp((bool)$form->getInput("timestamp"));
448  $lrsType->setDuration((bool)$form->getInput("duration"));
449  $lrsType->setNoSubstatements((bool)$form->getInput("no_substatements"));
450 
451  $lrsType->setForcePrivacySettings((bool) $form->getInput("force_privacy_setting"));
452  if ($lrsType->getForcePrivacySettings()) {
454  }
455 
456  $lrsType->save();
457 
458  $DIC->ctrl()->redirect($this, self::CMD_SHOW_LRS_TYPES_LIST);
459  }
static updatePrivacySettingsFromLrsType(ilCmiXapiLrsType $lrsType)
static removeTrailingPathSeparators($path)
$DIC
Definition: xapitoken.php:46
static updateByPassProxyFromLrsType(ilCmiXapiLrsType $lrsType)
+ Here is the call graph for this function:

◆ showLrsTypeFormCmd()

ilObjCmiXapiAdministrationGUI::showLrsTypeFormCmd ( ilPropertyFormGUI  $form = null)
protected

Definition at line 113 of file class.ilObjCmiXapiAdministrationGUI.php.

References $DIC, buildLrsTypeForm(), and initLrsType().

Referenced by saveLrsTypeFormCmd().

114  {
115  global $DIC; /* @var \ILIAS\DI\Container $DIC */
116 
117  $DIC->tabs()->activateTab(self::TAB_ID_LRS_TYPES);
118 
119  if ($form === null) {
120  $lrsType = $this->initLrsType();
121 
122  $form = $this->buildLrsTypeForm($lrsType);
123  }
124 
125  $DIC->ui()->mainTemplate()->setContent($form->getHTML());
126  }
$DIC
Definition: xapitoken.php:46
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ showLrsTypesListCmd()

ilObjCmiXapiAdministrationGUI::showLrsTypesListCmd ( )
protected

Definition at line 78 of file class.ilObjCmiXapiAdministrationGUI.php.

References $DIC, ilObjectGUI\$toolbar, buildLrsTypesTableGUI(), buildLrsTypesToolbarGUI(), and ilCmiXapiLrsTypeList\getTypesData().

Referenced by viewCmd().

79  {
80  global $DIC; /* @var \ILIAS\DI\Container $DIC */
81 
82  $DIC->tabs()->activateTab(self::TAB_ID_LRS_TYPES);
83 
85 
86  $table = $this->buildLrsTypesTableGUI();
87 
88  $table->setData(ilCmiXapiLrsTypeList::getTypesData(true));
89 
90  $DIC->ui()->mainTemplate()->setContent($toolbar->getHTML() . $table->getHTML());
91  }
static getTypesData($a_extended=false, $a_availability=null)
Get basic data array of all types (without field definitions)
$DIC
Definition: xapitoken.php:46
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ viewCmd()

ilObjCmiXapiAdministrationGUI::viewCmd ( )
protected

Definition at line 73 of file class.ilObjCmiXapiAdministrationGUI.php.

References showLrsTypesListCmd().

+ Here is the call graph for this function:

Field Documentation

◆ CMD_SAVE_LRS_TYPE_FORM

const ilObjCmiXapiAdministrationGUI::CMD_SAVE_LRS_TYPE_FORM = 'saveLrsTypeForm'

Definition at line 24 of file class.ilObjCmiXapiAdministrationGUI.php.

◆ CMD_SHOW_LRS_TYPE_FORM

const ilObjCmiXapiAdministrationGUI::CMD_SHOW_LRS_TYPE_FORM = 'showLrsTypeForm'

◆ CMD_SHOW_LRS_TYPES_LIST

const ilObjCmiXapiAdministrationGUI::CMD_SHOW_LRS_TYPES_LIST = 'showLrsTypesList'

Definition at line 22 of file class.ilObjCmiXapiAdministrationGUI.php.

◆ DEFAULT_CMD

const ilObjCmiXapiAdministrationGUI::DEFAULT_CMD = self::CMD_SHOW_LRS_TYPES_LIST

Definition at line 26 of file class.ilObjCmiXapiAdministrationGUI.php.

◆ TAB_ID_LRS_TYPES

const ilObjCmiXapiAdministrationGUI::TAB_ID_LRS_TYPES = 'tab_lrs_types'

Definition at line 19 of file class.ilObjCmiXapiAdministrationGUI.php.

◆ TAB_ID_PERMISSIONS

const ilObjCmiXapiAdministrationGUI::TAB_ID_PERMISSIONS = 'perm_settings'

Definition at line 20 of file class.ilObjCmiXapiAdministrationGUI.php.


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