5 include_once
'./Services/Tracking/classes/class.ilLearningProgressBaseGUI.php';
6 include_once
'./Services/Tracking/classes/class.ilLPObjSettings.php';
34 switch($this->ctrl->getNextClass())
49 $this->tpl->addBlockFile(
'ADM_CONTENT',
'adm_content',
'tpl.lp_obj_settings.html',
'Services/Tracking');
52 $this->tpl->setVariable(
'PROP_FORM',$form->getHTML());
53 $this->tpl->setVariable(
'COLLECTION_TABLE',$this->
getTableByMode());
64 include_once
'./Services/Form/classes/class.ilPropertyFormGUI.php';
66 $form->setTitle($this->lng->txt(
'tracking_settings'));
67 $form->setFormAction($this->ctrl->getFormAction($this));
72 $mod->setValue($this->obj_settings->getMode());
75 foreach($this->obj_settings->getValidModes() as $mode_key => $mode_name)
82 $opt->setValue($mode_key);
83 $mod->addOption($opt);
90 $vis->setMaxLength(4);
91 $vis->setInfo(sprintf($this->lng->txt(
'trac_visits_info'),
93 $vis->setRequired(
true);
94 $vis->setValue($this->obj_settings->getVisits());
95 $opt->addSubItem($vis);
123 $form->addCommandButton(
'saveSettings', $this->lng->txt(
'save'));
135 if($form->checkInput())
137 $this->obj_settings->setMode((
int) $form->getInput(
'modus'));
138 $this->obj_settings->setVisits($form->getInput(
'visits'));
139 $this->obj_settings->update();
146 $this->ctrl->redirect($this,
'show');
149 $form->setValuesByPost();
152 $this->tpl->addBlockFile(
'ADM_CONTENT',
'adm_content',
'tpl.lp_obj_settings.html',
'Services/Tracking');
153 $this->tpl->setVariable(
'PROP_FORM',$form->getHTML());
154 $this->tpl->setVariable(
'COLLECTION_TABLE',$this->
getTableByMode());
164 include_once
'./Services/Tracking/classes/class.ilLPCollectionSettingsTableGUI.php';
165 switch($this->obj_settings->getMode())
171 $table->setMode($this->obj_settings->getMode());
173 return $table->getHTML();
191 $this->ctrl->redirect($this,
'show');
193 if(count(
$_POST[
'item_ids']))
195 include_once
'Services/Tracking/classes/class.ilLPCollections.php';
199 include_once(
"./Services/Tracking/classes/class.ilLPStatusWrapper.php");
203 $this->ctrl->redirect($this,
'show');
215 $this->ctrl->redirect($this,
'show');
218 if(count(
$_POST[
'item_ids']))
220 include_once
'Services/Tracking/classes/class.ilLPCollections.php';
224 include_once(
"./Services/Tracking/classes/class.ilLPStatusWrapper.php");
228 $this->ctrl->redirect($this,
'show');
236 if(!count((array)
$_POST[
'item_ids']))
239 $this->ctrl->redirect($this,
'show');
243 include_once
'./Services/Tracking/classes/class.ilLPCollections.php';
247 include_once(
"./Services/Tracking/classes/class.ilLPStatusWrapper.php");
251 $this->ctrl->redirect($this,
'show');
259 if(!count((array)
$_POST[
'item_ids']))
262 $this->ctrl->redirect($this,
'show');
265 include_once
'./Services/Tracking/classes/class.ilLPCollections.php';
269 include_once(
"./Services/Tracking/classes/class.ilLPStatusWrapper.php");
273 $this->ctrl->redirect($this,
'show');
281 if(!is_array((array)
$_POST[
'grp']))
284 $this->ctrl->redirect($this,
'show');
288 include_once
'./Services/Tracking/classes/class.ilLPCollections.php';
292 include_once(
"./Services/Tracking/classes/class.ilLPStatusWrapper.php");
296 $this->ctrl->redirect($this,
'show');
298 catch(UnexpectedValueException $e) {
301 $this->ctrl->redirect($this,
'show');