19declare(strict_types=1);
38 protected \ILIAS\DI\Container
$dic;
50 $this->
lng = $DIC->language();
51 $this->
ctrl = $DIC->ctrl();
52 $this->tpl =
$DIC[
"tpl"];
54 $this->
lng->loadLanguageModule(
"content");
55 $this->
lng->loadLanguageModule(
"search");
57 $this->refId =
$DIC->http()->wrapper()->query()->retrieve(
'ref_id',
$DIC->refinery()->kindlyTo()->int());
69 if ($this->call_by_reference) {
83 $ilToolbar =
$DIC->toolbar();
84 $ilTabs =
$DIC->tabs();
89 $ilTabs->setSubTabActive(
'general');
92 $ilToolbar->addComponent($this->
object->getViewButton());
97 $this->tpl->setContent($this->
form->getHTML());
107 $this->
form->setTitle($this->
lng->txt(
"cont_lm_properties"));
110 $this->
object->checkMasteryScoreValues();
114 $ti->setMaxLength(200);
115 $this->
form->addItem($ti);
121 $this->
form->addItem($ti);
126 $this->
form->addItem($ne);
130 $ne->setValue($this->
object->getModuleVersion());
131 $ne->setInfo($this->
lng->txt(
"cont_sc_version_info"));
132 $this->
form->addItem($ne);
138 $sh->setTitle($this->
lng->txt(
"activation"));
139 $this->
form->addItem($sh);
143 $cb->setInfo($this->
lng->txt(
"cont_online_info"));
144 $this->
form->addItem($cb);
151 $sh->setTitle($this->
lng->txt(
"cont_presentation"));
152 $this->
form->addItem($sh);
156 $op0->setInfo($this->
lng->txt(
"cont_open_normal_info"));
157 $radg->addOption($op0);
159 $op1->setInfo($this->
lng->txt(
"cont_open_iframe_info"));
160 $radg->addOption($op1);
162 $op2->setInfo($this->
lng->txt(
"cont_open_window_info"));
163 $radg->addOption($op2);
167 $ni->setMaxLength(4);
169 $op1->addSubItem($ni);
171 $ni->setMaxLength(4);
173 $op2->addSubItem($ni);
176 $ni->setMaxLength(4);
178 $ni->setInfo($this->
lng->txt(
"cont_width_height_info"));
179 $op1->addSubItem($ni);
181 $ni->setMaxLength(4);
183 $ni->setInfo($this->
lng->txt(
"cont_width_height_info"));
184 $op2->addSubItem($ni);
186 $this->
form->addItem($radg);
191 $cb->setInfo($this->
lng->txt(
"cont_auto_last_visited_info"));
192 $this->
form->addItem($cb);
197 $cb->setInfo($this->
lng->txt(
"cont_sc_auto_continue_info"));
198 $this->
form->addItem($cb);
201 $obj_service->commonSettings()->legacyForm($this->
form, $this->
object)->addTileImage();
207 $sh->setTitle($this->
lng->txt(
"cont_scorm_options"));
208 $this->
form->addItem($sh);
212 $op0 =
new ilRadioOption($this->
lng->txt(
"cont_sc_less_mode_normal"),
"normal");
213 $op0->setInfo($this->
lng->txt(
"cont_sc_less_mode_normal_info"));
214 $radg->addOption($op0);
215 $op1 =
new ilRadioOption($this->
lng->txt(
"cont_sc_less_mode_browse"),
"browse");
216 $op1->setInfo($this->
lng->txt(
"cont_sc_less_mode_browse_info"));
217 $radg->addOption($op1);
222 "n" => $this->
lng->txt(
"cont_sc_auto_review_no"),
223 "y" => $this->lng->txt(
"cont_sc_auto_review_completed_or_passed"),
228 $op0->addSubItem($si);
230 $this->
form->addItem($radg);
233 if ($this->
object->getMasteryScoreValues() !=
"") {
235 $ni->setMaxLength(3);
237 $ni->setInfo($this->
lng->txt(
"cont_mastery_score_12_info") .
' ' . $this->object->getMasteryScoreValues());
238 $this->
form->addItem($ni);
245 $sh->setTitle($this->
lng->txt(
"cont_rte_settings"));
246 $this->
form->addItem($sh);
251 $cb->setInfo($this->
lng->txt(
"cont_sc_usession_info"));
252 $this->
form->addItem($cb);
257 $cb->setInfo($this->
lng->txt(
"cont_interactions_info_12"));
258 $this->
form->addItem($cb);
263 $cb->setInfo($this->
lng->txt(
"cont_objectives_info"));
264 $this->
form->addItem($cb);
269 $cb->setInfo($this->
lng->txt(
"cont_time_from_lms_info"));
270 $this->
form->addItem($cb);
275 $cb->setInfo($this->
lng->txt(
"cont_check_values_info"));
276 $this->
form->addItem($cb);
281 $cb->setInfo($this->
lng->txt(
"cont_auto_suspend_info"));
282 $this->
form->addItem($cb);
286 0 => $this->
lng->txt(
"cont_sc_id_setting_user_id"),
287 1 => $this->lng->txt(
"cont_sc_id_setting_user_login"),
288 2 => $this->lng->txt(
"cont_sc_id_setting_user_id_plus_ref_id"),
289 3 => $this->lng->txt(
"cont_sc_id_setting_user_login_plus_ref_id"),
290 4 => $this->lng->txt(
"cont_sc_id_setting_user_id_plus_obj_id"),
291 5 => $this->lng->txt(
"cont_sc_id_setting_user_login_plus_obj_id")
295 $si->setInfo($this->
lng->txt(
"cont_sc_id_setting_info"));
296 $this->
form->addItem($si);
300 0 => $this->
lng->txt(
"cont_sc_name_setting_last_firstname"),
301 1 => $this->lng->txt(
"cont_sc_name_setting_first_lastname"),
302 2 => $this->lng->txt(
"cont_sc_name_setting_fullname"),
303 3 => $this->lng->txt(
"cont_sc_name_setting_salutation_lastname"),
304 4 => $this->lng->txt(
"cont_sc_name_setting_first_name"),
305 9 => $this->lng->txt(
"cont_sc_name_setting_no_name")
309 $si->setInfo($this->
lng->txt(
"cont_sc_name_setting_info"));
310 $this->
form->addItem($si);
316 $sh->setTitle($this->
lng->txt(
"cont_debugging"));
317 $this->
form->addItem($sh);
322 if ($this->
object->getDebugActivated() ==
false) {
323 $cb->setDisabled(
true);
324 $cb->setInfo($this->
lng->txt(
"cont_debug_deactivated"));
326 $cb->setInfo($this->
lng->txt(
"cont_debug_deactivate12"));
328 $this->
form->addItem($cb);
329 $this->
form->addCommandButton(
"saveProperties", $this->
lng->txt(
"save"));
330 $this->
form->setFormAction($this->
ctrl->getFormAction($this));
340 $values[
"Fobject_title"] = $this->
object->getTitle();
341 $values[
"Fobject_description"] = $this->
object->getLongDescription();
342 if (!$this->
object->getOfflineStatus()) {
343 $values[
"cobj_online"] =
true;
346 $values[
"open_mode"] = $this->
object->getOpenMode();
347 $values[
"width_0"] = $this->
object->getWidth();
348 $values[
"width_1"] = $this->
object->getWidth();
349 $values[
"height_0"] = $this->
object->getHeight();
350 $values[
"height_1"] = $this->
object->getHeight();
351 $values[
"cobj_auto_last_visited"] = $this->
object->getAuto_last_visited();
352 $values[
"auto_continue"] = $this->
object->getAutoContinue();
353 $values[
"lesson_mode"] = $this->
object->getDefaultLessonMode();
354 $values[
"auto_review"] = $this->
object->getAutoReviewChar();
355 $values[
"mastery_score"] = $this->
object->getMasteryScore();
356 $values[
"cobj_session"] = $this->
object->getSession();
357 $values[
"cobj_interactions"] = $this->
object->getInteractions();
358 $values[
"cobj_objectives"] = $this->
object->getObjectives();
359 $values[
"cobj_time_from_lms"] = $this->
object->getTime_from_lms();
360 $values[
"cobj_check_values"] = $this->
object->getCheck_values();
361 $values[
"cobj_auto_suspend"] = $this->
object->getAutoSuspend();
362 $values[
"id_setting"] = $this->
object->getIdSetting();
363 $values[
"name_setting"] = $this->
object->getNameSetting();
364 $values[
"cobj_debug"] = $this->
object->getDebug();
365 $this->
form->setValuesByArray($values);
374 $ilTabs =
$DIC->tabs();
376 $ilTabs->setSubTabActive(
'cont_sc_new_version');
382 $this->
form->setTitle($this->
lng->txt(
"import_sahs_new"));
384 $this->
form->setDescription($this->
lng->txt(
"import_sahs_info"));
389 $this->
form->addItem($ne);
393 $options[
""] = $this->
lng->txt(
"cont_select_from_upload_dir");
395 foreach ($files as $file) {
396 $file = htmlspecialchars($file, ENT_QUOTES,
"utf-8");
404 $radg->addOption($op0);
405 $op1 =
new ilRadioOption($this->
lng->txt(
"cont_choose_upload_dir"),
"upload_dir");
406 $radg->addOption($op1);
407 $radg->setValue(
"local");
410 $fi->setRequired(
true);
411 $op0->addSubItem($fi);
415 $op1->addSubItem($si);
417 $this->
form->addItem($radg);
420 $fi->setRequired(
true);
421 $this->
form->addItem($fi);
423 $this->
form->addCommandButton(
"newModuleVersionUpload", $this->
lng->txt(
"upload"));
424 $this->
form->addCommandButton(
"cancel", $this->
lng->txt(
"cancel"));
425 $this->
form->setFormAction($DIC->ctrl()->getFormAction($this,
"newModuleVersionUpload"));
426 $DIC[
'tpl']->setContent($this->
form->getHTML());
432 $umf = get_cfg_var(
"upload_max_filesize");
434 $pms = get_cfg_var(
"post_max_size");
437 $multiplier_a = array(
"K" => 1024,
"M" => 1024 * 1024,
"G" => 1024 * 1024 * 1024);
442 if (count($umf_parts) == 2) {
443 $umf = $umf_parts[0] * $multiplier_a[$umf_parts[1]];
445 if (count($pms_parts) == 2) {
446 $pms = $pms_parts[0] * $multiplier_a[$pms_parts[1]];
450 $max_filesize = min($umf, $pms);
452 if (!$max_filesize) {
453 $max_filesize = max($umf, $pms);
457 return $max_filesize = sprintf(
"%.1f MB", $max_filesize / 1024 / 1024);
467 $rbacsystem =
$DIC->access();
470 $unzip = PATH_TO_UNZIP;
471 $tocheck =
"imsmanifest.xml";
474 if (!$rbacsystem->checkAccess(
"write",
"", $this->refId)) {
475 $ilErr->raiseError($this->
lng->txt(
"no_create_permission"),
$ilErr->WARNING);
476 } elseif ($_FILES[
"scormfile"][
"name"]) {
478 $source = $_FILES[
"scormfile"][
"tmp_name"];
479 if (($source ===
'none') || (!$source)) {
480 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"upload_error_file_not_found"),
true);
484 } elseif (
$DIC->http()->wrapper()->post()->has(
'uploaded_file')) {
485 $uploadedFile =
$DIC->http()->wrapper()->post()->retrieve(
'uploaded_file',
$DIC->refinery()->kindlyTo()->string());
488 $ilErr->raiseError($this->
lng->txt(
"upload_error_file_not_found"),
$ilErr->MESSAGE);
494 $source_is_copy =
true;
496 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"upload_error_file_not_found"),
true);
503 $pathinfo = pathinfo($source);
504 $dir = $pathinfo[
"dirname"];
505 $file = $pathinfo[
"basename"];
513 $tmp_file = $dir .
"/" . $this->refId .
"." . $tocheck;
516 $new_manifest = file_get_contents($tmp_file);
522 $old_manifest = file_get_contents($this->
object->getDataDirectory() .
"/" . $tocheck);
525 $check =
'/xmlns="http:\/\/www.imsglobal.org\/xsd\/imscp_v1p1"/';
526 $replace =
"xmlns=\"http://www.imsproject.org/xsd/imscp_rootv1p1p2\"";
527 $reload_manifest = preg_replace(
$check, $replace, $new_manifest);
530 if (strcmp($new_manifest, $old_manifest) == 0 || strcmp(mb_convert_encoding($new_manifest,
"UTF-8", mb_detect_encoding($new_manifest)), $old_manifest) == 0 ||
531 strcmp($reload_manifest, $old_manifest) == 0 || strcmp(mb_convert_encoding($reload_manifest,
"UTF-8", mb_detect_encoding($reload_manifest)), $old_manifest) == 0) {
534 $module_version = $this->
object->getModuleVersion() + 1;
536 if ($_FILES[
"scormfile"][
"name"]) {
538 $file_path = $this->
object->getDataDirectory() .
"/" . $_FILES[
"scormfile"][
"name"] .
"." . $module_version;
539 $file_path = str_replace(
".zip." . $module_version,
"." . $module_version .
".zip", $file_path);
542 $_FILES[
"scormfile"][
"tmp_name"],
543 $_FILES[
"scormfile"][
"name"],
548 $uploadedFile =
$DIC->http()->wrapper()->post()->retrieve(
'uploaded_file',
$DIC->refinery()->kindlyTo()->string());
549 $file_path = $this->
object->getDataDirectory() .
"/" . $uploadedFile .
"." . $module_version;
550 $file_path = str_replace(
".zip." . $module_version,
"." . $module_version .
".zip", $file_path);
556 $DIC->legacyArchives()->unzip($file_path,
null,
true);
560 $this->
object->setModuleVersion($module_version);
561 $this->
object->update();
564 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"cont_new_module_added"),
true);
565 ilUtil::redirect(
"ilias.php?baseClass=ilSAHSEditGUI&ref_id=" . $this->refId);
569 if (isset($source_is_copy)) {
573 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"cont_invalid_new_module"),
true);
584 if ($this->
form->checkInput()) {
585 $this->
object->setTitle($this->dic->http()->wrapper()->post()->retrieve(
'Fobject_title', $this->dic->refinery()->kindlyTo()->string()));
586 $this->
object->setDescription($this->dic->http()->wrapper()->post()->retrieve(
'Fobject_description', $this->dic->refinery()->kindlyTo()->string()));
588 if ($this->dic->http()->wrapper()->post()->has(
'mastery_score')) {
589 $sMasteryScore = $this->dic->http()->wrapper()->post()->retrieve(
'mastery_score', $this->dic->refinery()->kindlyTo()->string());
590 if ($sMasteryScore !==
"") {
591 $this->
object->setMasteryScore((
int) $sMasteryScore);
593 $this->
object->setMasteryScore(
null);
597 $t_height = $this->
object->getHeight();
598 if ($this->dic->http()->wrapper()->post()->retrieve(
'height_0', $this->dic->refinery()->kindlyTo()->int()) != $this->object->getHeight()) {
599 $t_height = $this->dic->http()->wrapper()->post()->retrieve(
'height_0', $this->dic->refinery()->kindlyTo()->int());
601 if ($this->dic->http()->wrapper()->post()->retrieve(
'height_1', $this->dic->refinery()->kindlyTo()->int()) != $this->object->getHeight()) {
602 $t_height = $this->dic->http()->wrapper()->post()->retrieve(
'height_1', $this->dic->refinery()->kindlyTo()->int());
605 $t_width = $this->
object->getWidth();
606 if ($this->dic->http()->wrapper()->post()->retrieve(
'width_0', $this->dic->refinery()->kindlyTo()->int()) != $this->object->getWidth()) {
607 $t_width = $this->dic->http()->wrapper()->post()->retrieve(
'width_0', $this->dic->refinery()->kindlyTo()->int());
609 if ($this->dic->http()->wrapper()->post()->retrieve(
'width_1', $this->dic->refinery()->kindlyTo()->int()) != $this->object->getWidth()) {
610 $t_width = $this->dic->http()->wrapper()->post()->retrieve(
'width_1', $this->dic->refinery()->kindlyTo()->int());
613 $this->
object->setOfflineStatus(!($this->dic->http()->wrapper()->post()->has(
'cobj_online')));
615 $this->
object->setOpenMode($this->dic->http()->wrapper()->post()->retrieve(
'open_mode', $this->dic->refinery()->kindlyTo()->int()));
616 $this->
object->setWidth($t_width);
617 $this->
object->setHeight($t_height);
618 $this->
object->setAuto_last_visited($this->dic->http()->wrapper()->post()->has(
'cobj_auto_last_visited'));
619 $this->
object->setAutoContinue($this->dic->http()->wrapper()->post()->has(
'auto_continue'));
621 $this->
object->setDefaultLessonMode($this->dic->http()->wrapper()->post()->retrieve(
'lesson_mode', $this->dic->refinery()->kindlyTo()->string()));
622 $this->
object->setAutoReview(
ilUtil::yn2tf($this->dic->http()->wrapper()->post()->retrieve(
'auto_review', $this->dic->refinery()->kindlyTo()->string())));
623 $this->
object->setSession($this->dic->http()->wrapper()->post()->has(
'cobj_session'));
624 $this->
object->setInteractions($this->dic->http()->wrapper()->post()->has(
'cobj_interactions'));
625 $this->
object->setObjectives($this->dic->http()->wrapper()->post()->has(
'cobj_objectives'));
626 $this->
object->setTime_from_lms($this->dic->http()->wrapper()->post()->has(
'cobj_time_from_lms'));
627 $this->
object->setCheck_values($this->dic->http()->wrapper()->post()->has(
'cobj_check_values'));
628 $this->
object->setAutoSuspend($this->dic->http()->wrapper()->post()->has(
'cobj_auto_suspend'));
629 $this->
object->setDebug($this->dic->http()->wrapper()->post()->has(
'cobj_debug'));
630 $this->
object->setIdSetting($this->dic->http()->wrapper()->post()->retrieve(
'id_setting', $this->dic->refinery()->kindlyTo()->int()));
631 $this->
object->setNameSetting($this->dic->http()->wrapper()->post()->retrieve(
'name_setting', $this->dic->refinery()->kindlyTo()->int()));
632 $this->
object->update();
635 $obj_service->commonSettings()->legacyForm($this->
form, $this->
object)->saveTileImage();
637 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"msg_obj_modified"),
true);
638 $this->
ctrl->redirect($this,
"properties");
647 $ilTabs =
$DIC->tabs();
650 $ilTabs->setTabActive(
"cont_tracking_data");
651 $ilTabs->setSubTabActive(
"cont_tracking_bysco");
653 $reports = array(
'exportSelectedCore',
'exportSelectedInteractions',
'exportSelectedObjectives',
'exportSelectedRaw');
654 $scoSelected =
"all";
655 if ($this->dic->http()->wrapper()->query()->has(
'scoSelected')) {
656 $scoSelected =
ilUtil::stripSlashes($this->dic->http()->wrapper()->query()->retrieve(
'scoSelected', $this->dic->refinery()->kindlyTo()->string()));
658 if ($this->dic->http()->wrapper()->post()->has(
'scoSelected')) {
659 $scoSelected =
ilUtil::stripSlashes($this->dic->http()->wrapper()->post()->retrieve(
'scoSelected', $this->dic->refinery()->kindlyTo()->string()));
661 $this->
ctrl->setParameter($this,
'scoSelected', $scoSelected);
664 if ($this->dic->http()->wrapper()->query()->has(
'report')) {
665 $report =
ilUtil::stripSlashes($this->dic->http()->wrapper()->query()->retrieve(
'report', $this->dic->refinery()->kindlyTo()->string()));
667 if ($this->dic->http()->wrapper()->post()->has(
'report')) {
668 $report =
ilUtil::stripSlashes($this->dic->http()->wrapper()->post()->retrieve(
'report', $this->dic->refinery()->kindlyTo()->string()));
670 $this->
ctrl->setParameter($this,
'report', $report);
672 $filter->parse($scoSelected, $report, $reports);
673 if ($report ===
"choose") {
674 $this->tpl->setContent($filter->form->getHTML());
676 $scosSelected = array();
677 if ($scoSelected !==
"all") {
678 $scosSelected[] = $scoSelected;
680 $scos = $this->
object->getTrackedItems();
681 foreach ($scos as $row) {
682 $scosSelected[] = (
int) $row->getId();
687 $this->tpl->setContent($filter->form->getHTML() . $tbl->getHTML());
699 $ilTabs =
$DIC->tabs();
700 $ilAccess =
$DIC->access();
702 $ilTabs->setTabActive(
'cont_tracking_data');
704 if ($ilAccess->checkAccess(
"read_learning_progress",
"", $this->refId)) {
706 $ilTabs->setSubTabActive(
'cont_tracking_byuser');
708 $reports = array(
'exportSelectedSuccess',
'exportSelectedCore',
'exportSelectedInteractions',
'exportSelectedObjectives',
'exportSelectedRaw');
710 $userSelected =
"all";
711 if ($this->dic->http()->wrapper()->query()->has(
'userSelected')) {
712 $userSelected =
ilUtil::stripSlashes($this->dic->http()->wrapper()->query()->retrieve(
'userSelected', $this->dic->refinery()->kindlyTo()->string()));
714 if ($this->dic->http()->wrapper()->post()->has(
'userSelected')) {
715 $userSelected =
ilUtil::stripSlashes($this->dic->http()->wrapper()->post()->retrieve(
'userSelected', $this->dic->refinery()->kindlyTo()->string()));
717 $this->
ctrl->setParameter($this,
'userSelected', $userSelected);
720 if ($this->dic->http()->wrapper()->query()->has(
'report')) {
721 $report =
ilUtil::stripSlashes($this->dic->http()->wrapper()->query()->retrieve(
'report', $this->dic->refinery()->kindlyTo()->string()));
723 if ($this->dic->http()->wrapper()->post()->has(
'report')) {
724 $report =
ilUtil::stripSlashes($this->dic->http()->wrapper()->post()->retrieve(
'report', $this->dic->refinery()->kindlyTo()->string()));
726 $this->
ctrl->setParameter($this,
'report', $report);
728 $filter->parse($userSelected, $report, $reports);
729 if ($report ===
"choose") {
730 $this->tpl->setContent($filter->form->getHTML());
732 $usersSelected = array();
733 if ($userSelected !==
"all") {
734 $usersSelected[] = $userSelected;
737 foreach ($users as
$user) {
743 $scosSelected = array();
744 $scos = $this->
object->getTrackedItems();
745 foreach ($scos as $row) {
746 $scosSelected[] = (
int) $row->getId();
749 $this->tpl->setContent($filter->form->getHTML() . $tbl->getHTML());
751 } elseif ($ilAccess->checkAccess(
"edit_learning_progress",
"", $this->refId)) {
763 $ilAccess =
$DIC->access();
765 if ($ilAccess->checkAccess(
"edit_learning_progress",
"", $this->refId)) {
767 if (!$privacy->enabledSahsProtocolData()) {
768 $ilErr->raiseError($this->
lng->txt(
'permission_denied'),
$ilErr->MESSAGE);
772 $ilTabs =
$DIC->tabs();
773 $ilToolbar =
$DIC->toolbar();
774 $ilToolbar->addButton(
775 $this->
lng->txt(
'import'),
776 $this->ctrl->getLinkTarget($this,
'trackingImportForm')
778 $ilToolbar->addButton(
779 $this->
lng->txt(
'cont_export_all'),
780 $this->ctrl->getLinkTarget($this,
'exportAll')
784 $ilTabs->setTabActive(
'cont_tracking_data');
785 $ilTabs->setSubTabActive(
'cont_tracking_modify');
788 $this->tpl->setContent($tbl->getHTML());
798 $tbl->writeFilterToSession();
824 if (!
$DIC->http()->wrapper()->post()->has(
'user')) {
830 $cgui->setFormAction($this->
ctrl->getFormAction($this));
831 $cgui->setHeaderText($this->
lng->txt(
"info_delete_sure"));
832 $cgui->setCancel($this->
lng->txt(
"cancel"),
"cancelDeleteTracking");
833 $cgui->setConfirm($this->
lng->txt(
"confirm"),
"confirmedDeleteTracking");
834 foreach ($DIC->http()->wrapper()->post()->retrieve(
'user',
$DIC->refinery()->kindlyTo()->listOf(
$DIC->refinery()->kindlyTo()->int())) as
$id) {
841 $cgui->addItem(
"user[]", (
string)
$id, $caption);
845 $this->tpl->setContent($cgui->getHTML());
854 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"msg_cancel"),
true);
855 $this->
ctrl->redirect($this,
"modifyTrackingItems");
863 $this->
object->deleteTrackingDataOfUsers($this->post_wrapper->retrieve(
'user', $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->int())));
864 $this->
ctrl->redirect($this,
"modifyTrackingItems");
873 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"msg_cancel"),
true);
874 $this->
ctrl->redirect($this,
"properties");
886 $success = $this->
object->importTrackingData($source[
'tmp_name']);
889 $this->tpl->setOnScreenMessage(
'info',
'Tracking data imported',
true);
890 $this->
ctrl->redirect($this,
"showTrackingItems");
893 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
'err_check_input'));
898 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
'err_check_input'));
910 $ilTabs =
$DIC->tabs();
912 $ilTabs->clearTargets();
913 $ilTabs->setBackTarget($this->
lng->txt(
'back'), $this->ctrl->getLinkTarget($this,
'showTrackingItems'));
932 $csv->setRequired(
true);
933 $csv->setSuffixes(array(
'csv'));
944 $this->
object->exportSelected(
true);
953 if (!$this->post_wrapper->has(
'user')) {
956 $this->tpl->setOnScreenMessage(
'info', $this->
lng->txt(
"no_checkbox"),
true);
957 $this->
ctrl->redirect($this,
'modifyTrackingItems');
959 $this->
object->exportSelected(
false, $this->post_wrapper->retrieve(
'user', $this->refinery->kindlyTo()->listOf($this->refinery->kindlyTo()->int())));
971 $ilTabs =
$DIC->tabs();
972 $ilCtrl =
$DIC->ctrl();
973 $ilAccess =
$DIC->access();
975 if ($ilAccess->checkAccess(
"read_learning_progress",
"", $this->refId)) {
976 $ilTabs->addSubTabTarget(
977 "cont_tracking_byuser",
978 $this->
ctrl->getLinkTarget($this,
"showTrackingItems"),
983 $ilTabs->addSubTabTarget(
984 "cont_tracking_bysco",
985 $this->
ctrl->getLinkTarget($this,
"showTrackingItemsBySco"),
990 if ($ilAccess->checkAccess(
"edit_learning_progress",
"", $this->refId)) {
991 $ilTabs->addSubTabTarget(
992 "cont_tracking_modify",
993 $this->
ctrl->getLinkTarget($this,
"modifyTrackingItems"),
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class ilCtrl provides processing control methods.
static rename(string $a_source, string $a_target)
static renameExecutables(string $a_dir)
static moveUploadedFile(string $a_file, string $a_name, string $a_target, bool $a_raise_errors=true, string $a_mode="move_uploaded")
move uploaded file
This class represents a non editable value in a property form.
static _lookupSubType(int $a_obj_id)
lookup subtype id (scorm, )
Class ilObjSCORMLearningModuleGUI.
resetUserTableFilter()
Reset table filter.
initPropertiesForm()
Init properties form.
initTrackingImportForm()
Init import form.
__construct($data, int $id, bool $call_by_reference, bool $prepare_output=true)
Constructor.
exportAll()
Show export section for all users.
exportSelectionUsers()
Export selection for selected users.
assignObject()
assign scorm object to scorm gui object
properties()
scorm module properties
deleteTrackingForUser()
display deletion confirmation screen
cancel()
overwrite..jump back to trackingdata not parent
newModuleVersion()
upload new version of module
showTrackingItems()
Show tracking table.
confirmedDeleteTracking()
importTracking()
gui functions for GUI export
cancelDeleteTracking()
cancel deletion of export files
trackingImportForm()
Show import form.
getPropertiesFormValues()
Get values for properties form.
Class ilObjSCORMLearningModule.
ilObjectService $object_service
static _lookupObjectId(int $ref_id)
static _exists(int $id, bool $reference=false, ?string $type=null)
checks if an object exists in object_data
This class represents an option in a radio group.
Class ilSCORMTrackingItemsPerScoFilterGUI.
Class ilSCORMTrackingItemsPerUserFilterGUI.
Class ilSCORMTrackingItemsTableGUI.
static escapeShellArg(string $a_arg)
This class represents a text area property in a property form.
This class represents a text property in a property form.
static getParticipantsForObject(int $a_ref_id)
Get participant ids for given object.
static _copyUploadFile(string $a_file, string $a_target, bool $a_raise_errors=true)
static _checkUploadFile(string $a_file)
static _getUploadDirectory()
static stripSlashes(string $a_str, bool $a_strip_html=true, string $a_allow="")
static yn2tf(string $a_yn)
static redirect(string $a_script)
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
form(?array $class_path, string $cmd, string $submit_caption="")
PREG_SPLIT_NO_EMPTY PREG_SPLIT_DELIM_CAPTURE