30     protected \ILIAS\Exercise\InternalGUIService 
$gui;
    42         $this->
ctrl = $DIC->ctrl();
    43         $this->
toolbar = $DIC->toolbar();
    44         $this->
lng = $DIC->language();
    45         $this->tpl = $DIC[
"tpl"];
    46         $this->cat_id = $a_cat_id;
    47         $this->request = $DIC->exercise()->internal()->gui()->request();
    48         $this->gui = $DIC->exercise()->internal()->gui();
    56         $cmd = $ilCtrl->getCmd(
"view");
    58         switch ($next_class) {
    70     protected function view(): void
    77         $ilToolbar->setFormAction($ilCtrl->getFormAction($this, 
"add"));
    81         $ilToolbar->addStickyItem($types);
    84             $lng->
txt(
"exc_add_criteria"),
    86         )->submit()->toToolbar(
true);
   100         $req_positions = $this->request->getPositions();
   101         asort($req_positions);
   102         foreach (array_keys($req_positions) as 
$id) {
   103             if (array_key_exists($id, $all_cat)) {
   105                 $all_cat[
$id]->setPosition($pos);
   106                 $all_cat[
$id]->update();
   110         $this->tpl->setOnScreenMessage(
'success', $lng->
txt(
"settings_saved"), 
true);
   111         $ilCtrl->redirect($this, 
"view");
   120         $ids = $this->request->getCriteriaIds();
   121         if (count($ids) == 0) {
   123             $ilCtrl->redirect($this, 
"view");
   127         $confirmation_gui->setFormAction($ilCtrl->getFormAction($this, 
"delete"));
   128         $confirmation_gui->setHeaderText($lng->
txt(
"exc_criteria_deletion_confirmation"));
   129         $confirmation_gui->setCancel($lng->
txt(
"cancel"), 
"view");
   130         $confirmation_gui->setConfirm($lng->
txt(
"delete"), 
"delete");
   133             if (in_array($item->getId(), $ids)) {
   134                 $confirmation_gui->addItem(
"id[]", $item->getId(), $item->getTitle());
   138         $tpl->
setContent($confirmation_gui->getHTML());
   141     protected function delete(): 
void   146         $ids = $this->request->getCriteriaIds();
   147         if (count($ids) == 0) {
   148             $ilCtrl->redirect($this, 
"view");
   152             if (in_array($item->getId(), $ids)) {
   157         $this->tpl->setOnScreenMessage(
'success', $lng->
txt(
"settings_saved"), 
true);
   158         $ilCtrl->redirect($this, 
"view");
   173         $is_edit = (bool) $a_crit_obj->
getId();
   175             $form->setFormAction($ilCtrl->getFormAction($this, 
"create"));
   176             $form->setTitle($lng->
txt(
"exc_criteria_create_form"));
   177             $form->addCommandButton(
"create", $lng->
txt(
"create"));
   179             $form->setFormAction($ilCtrl->getFormAction($this, 
"update"));
   180             $form->setTitle($lng->
txt(
"exc_criteria_update_form"));
   181             $form->addCommandButton(
"update", $lng->
txt(
"save"));
   184         $form->addCommandButton(
"view", $lng->
txt(
"cancel"));
   188         $form->addItem($type);
   191         $title->setRequired(
true);
   192         $form->addItem($title);
   195         $form->addItem($desc);
   198         $form->addItem(
$req);
   210         $new_type = $this->request->getCriteriaType();
   215         $ilCtrl->setParameter($this, 
"type", $new_type);
   219             $a_form = $this->
initForm($crit_obj);
   242         $is_edit = (bool) $a_crit_obj->
getId();
   243         $ilCtrl->setParameter($this, 
"type", $this->request->getCriteriaType());
   244         $form = $this->
initForm($a_crit_obj);
   245         if ($form->checkInput()) {
   246             $a_crit_obj->
setTitle($form->getInput(
"title"));
   259             $this->tpl->setOnScreenMessage(
'success', $lng->
txt(
"settings_saved"), 
true);
   260             $ilCtrl->redirect($this, 
"view");
   263         $form->setValuesByPost();
   264         $this->{$is_edit ? 
"edit" : 
"add"}($form);
   271         $new_type = $this->request->getCriteriaType();
   284         $id = $this->request->getCritId();
   288                 $ilCtrl->setParameter($this, 
"crit_id", 
$id);
   293         $ilCtrl->redirect($this, 
"view");
   305             $a_form = $this->
initForm($crit_obj);
 setDescription(?string $a_value)
 
setRequired(bool $a_value)
 
importCustomForm(ilPropertyFormGUI $a_form)
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
ILIAS Exercise InternalGUIService $gui
 
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
 
redirect(object $a_gui_obj, string $a_cmd=null, string $a_anchor=null, bool $is_async=false)
 
__construct(int $a_cat_id)
 
setOnScreenMessage(string $type, string $a_txt, bool $a_keep=false)
Set a message to be displayed to the user. 
 
static getInstancesByParentId(int $a_parent_id)
 
setTitle(?string $a_value)
 
static getInstanceByType(string $a_type)
 
exportCustomForm(ilPropertyFormGUI $a_form)
 
catch(\Exception $e) $req
 
add(ilPropertyFormGUI $a_form=null)
 
getNextClass($a_gui_class=null)
 
setContent(string $a_html)
Sets content for standard template. 
 
edit(ilPropertyFormGUI $a_form=null)
 
This class represents a text area property in a property form. 
 
$id
plugin.php for ilComponentBuildPluginInfoObjectiveTest::testAddPlugins 
 
exportForm(ilExcCriteria $a_crit_obj, ilPropertyFormGUI $a_form)
 
initCustomForm(ilPropertyFormGUI $a_form)
 
initForm(ilExcCriteria $a_crit_obj)
 
ilGlobalTemplateInterface $tpl
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
Exercise gui request wrapper. 
 
importForm(ilExcCriteria $a_crit_obj)
 
static getInstanceById(int $a_id)