3 declare(strict_types=1);
42 private \ILIAS\DI\Container
$dic;
51 $this->main_tpl = $DIC->ui()->mainTemplate();
65 switch ($DIC->ctrl()->getNextClass()) {
67 $command = $DIC->ctrl()->getCmd(self::DEFAULT_CMD) .
'Cmd';
89 $this->main_tpl->setContent($form->getHTML());
99 if (!$form->checkInput()) {
100 $form->setValuesByPost();
107 $this->main_tpl->setOnScreenMessage(
'success', $this->dic->language()->txt(
'registration_saved_successfully'),
true);
118 $form->setFormAction($this->dic->ctrl()->getFormAction($this, self::CMD_SHOW_FORM));
121 $form->setTitle($this->dic->language()->txt(
'form_create_registration'));
122 $form->addCommandButton(self::CMD_SAVE_FORM, $this->dic->language()->txt(
'btn_create_registration'));
124 $form->setTitle($this->dic->language()->txt(
'form_change_registration'));
125 $form->addCommandButton(self::CMD_SAVE_FORM, $this->dic->language()->txt(
'btn_change_registration'));
128 $form->addCommandButton(self::CMD_CANCEL, $this->dic->language()->txt(
'cancel'));
130 $userIdent =
new ilEMailInputGUI($this->dic->language()->txt(
'field_user_ident'),
'user_ident');
131 $userIdent->
setInfo($this->dic->language()->txt(
'field_user_ident_info'));
132 $userIdent->setRequired(
true);
133 $userIdent->setValue($this->cmixUser->getUsrIdent());
134 $form->addItem($userIdent);
141 return strlen($this->cmixUser->getUsrIdent());
146 $this->cmixUser->setUsrIdent($form->
getInput(
'user_ident'));
147 $this->cmixUser->save();
showFormCmd(ilPropertyFormGUI $form=null)
__construct(ilObjCmiXapi $object)
ilCmiXapiRegistrationGUI constructor.
ilGlobalTemplateInterface $main_tpl
saveRegistration(ilPropertyFormGUI $form)