ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilLPStatus Class Reference

Abstract class ilLPStatus for all learning progress modes E.g ilLPStatusManual, ilLPStatusObjectives ... More...

+ Inheritance diagram for ilLPStatus:
+ Collaboration diagram for ilLPStatus:

Public Member Functions

 __construct ($a_obj_id)
 
 _updateStatus ($a_obj_id, $a_usr_id, $a_obj=null, $a_percentage=false, $a_force_raise=false)
 New status handling (st: status, nr: accesses, p: percentage, t: time spent, m: mark) More...
 
 determinePercentage ($a_obj_id, $a_usr_id, $a_obj=null)
 Determine percentage. More...
 
 determineStatus ($a_obj_id, $a_usr_id, $a_obj=null)
 Determine status. More...
 
 refreshStatus ($a_obj_id, $a_users=null)
 Refresh status. More...
 

Static Public Member Functions

static _getCountNotAttempted ($a_obj_id)
 
static _getNotAttempted ($a_obj_id)
 
static _getCountInProgress ($a_obj_id)
 
static _getInProgress ($a_obj_id)
 
static _getCountCompleted ($a_obj_id)
 
static _getCompleted ($a_obj_id)
 
static _getFailed ($a_obj_id)
 
static _getCountFailed ()
 
static _getStatusInfo ($a_obj_id)
 
static _getTypicalLearningTime ($a_obj_id)
 
static checkStatusForObject ($a_obj_id, $a_users=false)
 This function checks whether the status for a given number of users is dirty and must be recalculated. More...
 
static writeStatus ($a_obj_id, $a_user_id, $a_status, $a_percentage=false, $a_force_per=false)
 Write status for user and object. More...
 
static setInProgressIfNotAttempted ($a_obj_id, $a_user_id)
 This function shoudl be clalled for normal "read events". More...
 
static setAllDirty ()
 Sets all status to dirty. More...
 
static setDirty ($a_obj_id)
 Sets status of an object to dirty. More...
 
static _lookupStatus ($a_obj_id, $a_user_id, $a_create=true)
 Lookup status. More...
 
static _lookupPercentage ($a_obj_id, $a_user_id)
 Lookup percentage. More...
 
static _hasUserCompleted ($a_obj_id, $a_user_id)
 Lookup user object completion. More...
 
static _lookupStatusChanged ($a_obj_id, $a_user_id)
 Lookup status changed. More...
 
static _lookupCompletedForObject ($a_obj_id, $a_user_ids=null)
 Get completed users for object. More...
 
static _lookupFailedForObject ($a_obj_id, $a_user_ids=null)
 Get failed users for object. More...
 
static _lookupInProgressForObject ($a_obj_id, $a_user_ids=null)
 Get in progress users for object. More...
 
static preloadListGUIData ($a_obj_ids)
 
static getListGUIStatus ($a_obj_id, $a_image_only=true)
 

Data Fields

 $obj_id = null
 
 $db = null
 
const LP_STATUS_NOT_ATTEMPTED = 'trac_no_attempted'
 
const LP_STATUS_IN_PROGRESS = 'trac_in_progress'
 
const LP_STATUS_COMPLETED = 'trac_completed'
 
const LP_STATUS_FAILED = 'trac_failed'
 
const LP_STATUS_NOT_ATTEMPTED_NUM = 0
 
const LP_STATUS_IN_PROGRESS_NUM = 1
 
const LP_STATUS_COMPLETED_NUM = 2
 
const LP_STATUS_FAILED_NUM = 3
 
const LP_STATUS_REGISTERED = 'trac_registered'
 
const LP_STATUS_NOT_REGISTERED = 'trac_not_registered'
 
const LP_STATUS_PARTICIPATED = 'trac_participated'
 
const LP_STATUS_NOT_PARTICIPATED = 'trac_not_participated'
 

Static Public Attributes

static $list_gui_cache
 

Static Protected Member Functions

static raiseEvent ($a_obj_id, $a_usr_id, $a_status, $a_percentage)
 
static _lookupStatusForObject ($a_obj_id, $a_status, $a_user_ids=null)
 Get users with given status for object. More...
 
static validateLPForObjects ($a_user_id, $a_obj_ids, $a_parent_ref_id)
 Process given objects for lp-relevance. More...
 
static checkLPModesForObjects ($a_obj_ids, array &$a_coll_obj_ids)
 Process lp modes for given objects. More...
 
static getLPStatusForObjects ($a_user_id, $a_obj_ids)
 Get LP status for given objects (and user) More...
 

Detailed Description

Abstract class ilLPStatus for all learning progress modes E.g ilLPStatusManual, ilLPStatusObjectives ...

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
Version
$Id$

Definition at line 15 of file class.ilLPStatus.php.

Constructor & Destructor Documentation

◆ __construct()

ilLPStatus::__construct (   $a_obj_id)

Reimplemented in ilLPStatusCollection, ilLPStatusEvent, ilLPStatusExerciseReturned, ilLPStatusManual, ilLPStatusManualByTutor, ilLPStatusObjectives, ilLPStatusSCORM, ilLPStatusSCORMPackage, ilLPStatusTestFinished, ilLPStatusTestPassed, ilLPStatusTypicalLearningTime, and ilLPStatusVisits.

Definition at line 38 of file class.ilLPStatus.php.

39 {
40 global $DIC;
41
42 $ilDB = $DIC['ilDB'];
43
44 $this->obj_id = $a_obj_id;
45 $this->db = $ilDB;
46 }
global $DIC
Definition: saml.php:7
global $ilDB

References $DIC, and $ilDB.

Member Function Documentation

◆ _getCompleted()

◆ _getCountCompleted()

static ilLPStatus::_getCountCompleted (   $a_obj_id)
static

Reimplemented in ilLPStatusIndividualAssessment, and ilLPStatusStudyProgramme.

Definition at line 68 of file class.ilLPStatus.php.

69 {
70 return 0;
71 }

◆ _getCountFailed()

static ilLPStatus::_getCountFailed ( )
static

Reimplemented in ilLPStatusIndividualAssessment.

Definition at line 83 of file class.ilLPStatus.php.

84 {
85 return 0;
86 }

◆ _getCountInProgress()

static ilLPStatus::_getCountInProgress (   $a_obj_id)
static

Reimplemented in ilLPStatusIndividualAssessment, and ilLPStatusStudyProgramme.

Definition at line 58 of file class.ilLPStatus.php.

59 {
60 return 0;
61 }

◆ _getCountNotAttempted()

static ilLPStatus::_getCountNotAttempted (   $a_obj_id)
static

Reimplemented in ilLPStatusIndividualAssessment.

Definition at line 48 of file class.ilLPStatus.php.

49 {
50 return 0;
51 }

◆ _getFailed()

static ilLPStatus::_getFailed (   $a_obj_id)
static

◆ _getInProgress()

◆ _getNotAttempted()

static ilLPStatus::_getNotAttempted (   $a_obj_id)
static

◆ _getStatusInfo()

static ilLPStatus::_getStatusInfo (   $a_obj_id)
static

◆ _getTypicalLearningTime()

static ilLPStatus::_getTypicalLearningTime (   $a_obj_id)
static

Reimplemented in ilLPStatusCollection.

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

94 {
95 include_once 'Services/MetaData/classes/class.ilMDEducational.php';
97 }
static _getTypicalLearningTimeSeconds($a_rbac_id, $a_obj_id=0)

References ilMDEducational\_getTypicalLearningTimeSeconds().

+ Here is the call graph for this function:

◆ _hasUserCompleted()

static ilLPStatus::_hasUserCompleted (   $a_obj_id,
  $a_user_id 
)
static

Lookup user object completion.

Parameters
int$a_obj_id
int$a_user_id
Returns
bool

Definition at line 621 of file class.ilLPStatus.php.

622 {
623 return (self::_lookupStatus($a_obj_id, $a_user_id) == self::LP_STATUS_COMPLETED_NUM);
624 }

Referenced by ilConditionHandler\_checkCondition(), ilTimingCache\_showWarning(), ilObjSAHSLearningModuleAccess\checkCondition(), ilObjStudyProgramme\getCompletedCourses(), ilCertificateMigrationJob\getScormCertificates(), ilObjLearningSequence\isCompletedByUser(), ilContainerStartObjects\isFullfilled(), and ilCourseStart\isFullfilled().

+ Here is the caller graph for this function:

◆ _lookupCompletedForObject()

static ilLPStatus::_lookupCompletedForObject (   $a_obj_id,
  $a_user_ids = null 
)
static

Get completed users for object.

Parameters
int$a_obj_id
array$a_user_ids
Returns
array

Reimplemented in ilLPStatusCollection, ilLPStatusEvent, ilLPStatusExerciseReturned, ilLPStatusManualByTutor, and ilLPStatusObjectives.

Definition at line 704 of file class.ilLPStatus.php.

705 {
706 return self::_lookupStatusForObject($a_obj_id, self::LP_STATUS_COMPLETED_NUM, $a_user_ids);
707 }
static _lookupStatusForObject($a_obj_id, $a_status, $a_user_ids=null)
Get users with given status for object.

References _lookupStatusForObject().

Referenced by ilTimingsUser\lookupTimings().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _lookupFailedForObject()

static ilLPStatus::_lookupFailedForObject (   $a_obj_id,
  $a_user_ids = null 
)
static

Get failed users for object.

Parameters
int$a_obj_id
array$a_user_ids
Returns
array

Reimplemented in ilLPStatusCollection, ilLPStatusEvent, ilLPStatusExerciseReturned, ilLPStatusManual, ilLPStatusManualByTutor, and ilLPStatusObjectives.

Definition at line 716 of file class.ilLPStatus.php.

717 {
718 return self::_lookupStatusForObject($a_obj_id, self::LP_STATUS_FAILED_NUM, $a_user_ids);
719 }

References _lookupStatusForObject().

+ Here is the call graph for this function:

◆ _lookupInProgressForObject()

static ilLPStatus::_lookupInProgressForObject (   $a_obj_id,
  $a_user_ids = null 
)
static

Get in progress users for object.

Parameters
int$a_obj_id
array$a_user_ids
Returns
array

Reimplemented in ilLPStatusCollection, ilLPStatusEvent, ilLPStatusExerciseReturned, ilLPStatusManualByTutor, and ilLPStatusObjectives.

Definition at line 728 of file class.ilLPStatus.php.

729 {
730 return self::_lookupStatusForObject($a_obj_id, self::LP_STATUS_IN_PROGRESS_NUM, $a_user_ids);
731 }

References _lookupStatusForObject().

+ Here is the call graph for this function:

◆ _lookupPercentage()

static ilLPStatus::_lookupPercentage (   $a_obj_id,
  $a_user_id 
)
static

Lookup percentage.

Parameters
int$a_obj_idobject id
int$a_user_iduser id

Definition at line 597 of file class.ilLPStatus.php.

598 {
599 global $DIC;
600
601 $ilDB = $DIC['ilDB'];
602
603 $set = $ilDB->query(
604 "SELECT percentage FROM ut_lp_marks WHERE " .
605 " status_dirty = " . $ilDB->quote(0, "integer") .
606 " AND usr_id = " . $ilDB->quote($a_user_id, "integer") .
607 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
608 );
609 if ($rec = $ilDB->fetchAssoc($set)) {
610 return $rec["percentage"];
611 }
612 }

References $DIC, and $ilDB.

Referenced by ilLearningProgressBaseGUI\__appendLPDetails(), ilLTIAppEventListener\doCronUpdate(), ilObjSCORMLearningModule\importRaw(), and ilContainerContentGUI\renderCard().

+ Here is the caller graph for this function:

◆ _lookupStatus()

static ilLPStatus::_lookupStatus (   $a_obj_id,
  $a_user_id,
  $a_create = true 
)
static

Lookup status.

Parameters
int$a_obj_idobject id
int$a_user_iduser id
bool$a_create

Definition at line 562 of file class.ilLPStatus.php.

563 {
564 global $DIC;
565
566 $ilDB = $DIC['ilDB'];
567
568 $set = $ilDB->query(
569 "SELECT status FROM ut_lp_marks WHERE " .
570 " status_dirty = " . $ilDB->quote(0, "integer") .
571 " AND usr_id = " . $ilDB->quote($a_user_id, "integer") .
572 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
573 );
574 if ($rec = $ilDB->fetchAssoc($set)) {
575 return $rec["status"];
576 } elseif ((bool) $a_create) {
577 include_once("./Services/Tracking/classes/class.ilLPStatusWrapper.php");
578 ilLPStatusWrapper::_updateStatus($a_obj_id, $a_user_id);
579 $set = $ilDB->query(
580 "SELECT status FROM ut_lp_marks WHERE " .
581 " status_dirty = " . $ilDB->quote(0, "integer") .
582 " AND usr_id = " . $ilDB->quote($a_user_id, "integer") .
583 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
584 );
585 if ($rec = $ilDB->fetchAssoc($set)) {
586 return $rec["status"];
587 }
588 }
589 }
static _updateStatus($a_obj_id, $a_usr_id, $a_obj=null, $a_percentage=false, $a_force_raise=false)
Update status.

References $DIC, $ilDB, and ilLPStatusWrapper\_updateStatus().

Referenced by ilLearningProgressBaseGUI\__readStatus(), ilObjSAHSLearningModuleAccess\checkCondition(), ilObjCourse\checkLPStatusSync(), ilLTIAppEventListener\doCronUpdate(), ilCourseLPBadge\evaluate(), ilObjLearningSequenceGUI\executeCommand(), ilLearnerProgressDB\getLearningProgressFor(), getLPStatusForObjects(), ilLearnerProgressDB\getLPStatusRefresher(), ilSoapSCORMAdministration\getSCORMCompletionStatus(), ilObjSCORMInitData\getStatus(), ilObjSCORMLearningModule\importRaw(), ilLearningProgressBaseGUI\initEditUserForm(), ilCertificateLPStatusHelper\lookUpStatus(), and ilTestPassFinishTasks\updateLearningProgressAfterPassFinishedIsWritten().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _lookupStatusChanged()

static ilLPStatus::_lookupStatusChanged (   $a_obj_id,
  $a_user_id 
)
static

Lookup status changed.

Parameters
int$a_obj_idobject id
int$a_user_iduser id

Definition at line 632 of file class.ilLPStatus.php.

633 {
634 global $DIC;
635
636 $ilDB = $DIC['ilDB'];
637
638 $set = $ilDB->query(
639 "SELECT status_changed FROM ut_lp_marks WHERE " .
640 " status_dirty = " . $ilDB->quote(0, "integer") .
641 " AND usr_id = " . $ilDB->quote($a_user_id, "integer") .
642 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
643 );
644 if ($rec = $ilDB->fetchAssoc($set)) {
645 return $rec["status_changed"];
646 } else {
647 include_once("./Services/Tracking/classes/class.ilLPStatusWrapper.php");
648 ilLPStatusWrapper::_updateStatus($a_obj_id, $a_user_id);
649 $set = $ilDB->query(
650 "SELECT status_changed FROM ut_lp_marks WHERE " .
651 " status_dirty = " . $ilDB->quote(0, "integer") .
652 " AND usr_id = " . $ilDB->quote($a_user_id, "integer") .
653 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
654 );
655 if ($rec = $ilDB->fetchAssoc($set)) {
656 return $rec["status_changed"];
657 }
658 }
659 }

References $DIC, $ilDB, and ilLPStatusWrapper\_updateStatus().

Referenced by ilCertificateAdapter\getUserCompletionDate(), ilCertificateLPStatusHelper\lookupStatusChanged(), and ilCertificateMigrationJob\run().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _lookupStatusForObject()

static ilLPStatus::_lookupStatusForObject (   $a_obj_id,
  $a_status,
  $a_user_ids = null 
)
staticprotected

Get users with given status for object.

Parameters
int$a_obj_id
int$a_status
array$a_user_ids
Returns
array

Definition at line 669 of file class.ilLPStatus.php.

670 {
671 global $DIC;
672
673 $ilDB = $DIC['ilDB'];
674
675 $sql = "SELECT usr_id, status, status_dirty FROM ut_lp_marks" .
676 " WHERE obj_id = " . $ilDB->quote($a_obj_id, "integer") .
677 " AND status = " . $ilDB->quote($a_status, "integer");
678 if ($a_user_ids) {
679 $sql .= " AND " . $ilDB->in("usr_id", $a_user_ids, "", "integer");
680 }
681
682 $set = $ilDB->query($sql);
683 $res = array();
684 while ($rec = $ilDB->fetchAssoc($set)) {
685 if ($res["status_dirty"]) {
686 // update status and check again
687 if (self::_lookupStatus($a_obj_id, $rec["usr_id"]) != $a_status) {
688 continue;
689 }
690 }
691 $res[] = $rec["usr_id"];
692 }
693
694 return $res;
695 }
foreach($_POST as $key=> $value) $res

References $DIC, $ilDB, and $res.

Referenced by _lookupCompletedForObject(), ilLPStatusCollection\_lookupCompletedForObject(), ilLPStatusEvent\_lookupCompletedForObject(), ilLPStatusExerciseReturned\_lookupCompletedForObject(), ilLPStatusManualByTutor\_lookupCompletedForObject(), ilLPStatusObjectives\_lookupCompletedForObject(), _lookupFailedForObject(), ilLPStatusCollection\_lookupFailedForObject(), ilLPStatusExerciseReturned\_lookupFailedForObject(), _lookupInProgressForObject(), ilLPStatusCollection\_lookupInProgressForObject(), ilLPStatusEvent\_lookupInProgressForObject(), ilLPStatusExerciseReturned\_lookupInProgressForObject(), ilLPStatusManualByTutor\_lookupInProgressForObject(), and ilLPStatusObjectives\_lookupInProgressForObject().

+ Here is the caller graph for this function:

◆ _updateStatus()

ilLPStatus::_updateStatus (   $a_obj_id,
  $a_usr_id,
  $a_obj = null,
  $a_percentage = false,
  $a_force_raise = false 
)

New status handling (st: status, nr: accesses, p: percentage, t: time spent, m: mark)

Learning progress:

Added determine Status to:

Updating the status:

- ilLearningProgress->_tracProgress() added to:

  • ilLPStatusWrapper::_updateStatus($a_obj_id, $a_user_id); added to: – ilInfoScreenGUI->saveProgress() – ilLMPresentation->ilPage() – ilLPListOfObjectsGUI->updateUser() – ilCourseObjectiveResult->reset() – ilCourseObjectiveResult->__updatePassed() – ilEventParticipants->updateUser() – ilEventParticipants->_updateParticipation() – ilEventParticipants->_register() – ilEventParticipants->_unregister() – ilExerciseMembers->assignMember() – ilExerciseMembers->deassignMember() – ilExerciseMembers->ilClone() – ilExerciseMembers->writeStatus() – ilExerciseMembers->writeReturned() – ilSCORM13Player->writeGObjective() – ilObjSCORM2004LearningModule->deleteTrackingDataOfUsers() – ilObjSCORM2004LearningModule->importSuccess() – ilObjSCORM2004LearningModuleGUI->confirmedDeleteTracking() – ilSCORM13Player->removeCMIData() – ilSCORM13Player->setCMIData() – ilObjSCORMLearningModule->importSuccess() – ilObjSCORMLearningModule->importRaw() – ilObjSCORMLearningModuleGUI->confirmedDelete() – ilObjSCORMLearningModuleGUI->decreaseAttempt() – ilObjSCORMTracking->store() – ilObjSCORMTracking-> _insertTrackData() – ilSCORMPresentationGUI->increase_attemptAndsave_module_version() – ilTestScoringGUI->setPointsManual() – ilTestSession->increaseTestPass() – ilTestSession->saveToDb()
  • ilLPStatusWrapper::_refreshStatus($a_ojb_id); aufgenommen in: – ilCourseObjective->add() – ilCourseObjective->delete() – ilCourseObjective->deleteAll() – ilExerciseMembers->delete() – ilSCORM13Package->removeCMIData() – ilAICCCourse->delete() – ilAICCUnit->delete() – ilObjAICCLearningModule->delete() – ilSCORMItem->delete() – ilLPStatusWrapper->update() – ilLPListOfSettingsGUI->assign() – ilLPListOfSettingsGUI->deassign() – ilLPListOfSettingsGUI->groupMaterials() – ilLPListOfSettingsGUI->releaseMaterials() – ilObjTestGUI->confirmDeleteAllUserResultsObject @TODO move to ilObjTest but this can ba called for each single question – ilConditionHandlerGUI->updateCondition()
  • external time/access values for read events ilChangeEvent::_recordReadEvent($a_obj_id, $a_user_id, false, $attempts, $time); – ilObjSCORMTracking->_syncReadEvent in ilObjSCORMTracking->store() (add to refresh) – ilSCORM2004Tracking->_syncReadEvent in ilSCORM13Player->setCMIData() Write status
Parameters

return

Definition at line 203 of file class.ilLPStatus.php.

204 {
206 $log->debug(sprintf(
207 "obj_id: %s, user id: %s, object: %s",
208 $a_obj_id,
209 $a_usr_id,
210 (is_object($a_obj) ? get_class($a_obj) : 'null')
211 ));
212
213 $status = $this->determineStatus($a_obj_id, $a_usr_id, $a_obj);
214 $percentage = $this->determinePercentage($a_obj_id, $a_usr_id, $a_obj);
215 $changed = self::writeStatus($a_obj_id, $a_usr_id, $status, $percentage);
216
217 // ak: I don't think that this is a good way to fix 15529, we should not
218 // raise the event, if the status does not change imo.
219 // for now the changes in the next line just prevent the event being raised twice
220 if (!$changed && (bool) $a_force_raise) { // #15529
221 self::raiseEvent($a_obj_id, $a_usr_id, $status, $percentage);
222 }
223 }
determineStatus($a_obj_id, $a_usr_id, $a_obj=null)
Determine status.
determinePercentage($a_obj_id, $a_usr_id, $a_obj=null)
Determine percentage.
static raiseEvent($a_obj_id, $a_usr_id, $a_status, $a_percentage)
static writeStatus($a_obj_id, $a_user_id, $a_status, $a_percentage=false, $a_force_per=false)
Write status for user and object.
static getLogger($a_component_id)
Get component logger.
$log
Definition: sabredav.php:21

References $changed, $log, determinePercentage(), determineStatus(), ilLoggerFactory\getLogger(), raiseEvent(), and writeStatus().

+ Here is the call graph for this function:

◆ checkLPModesForObjects()

static ilLPStatus::checkLPModesForObjects (   $a_obj_ids,
array &  $a_coll_obj_ids 
)
staticprotected

Process lp modes for given objects.

Parameters
array$a_obj_ids
Returns
array

Definition at line 767 of file class.ilLPStatus.php.

768 {
769 $valid = array();
770
771 // all lp modes with collections (gathered separately)
772 include_once "Services/Tracking/classes/collection/class.ilLPCollection.php";
774
775 include_once "Services/Tracking/classes/class.ilLPObjSettings.php";
776
777 // check if objects have LP activated at all (DB entries)
778 $existing = ilLPObjSettings::_lookupDBModeForObjects($a_obj_ids);
779 foreach ($existing as $obj_id => $obj_mode) {
780 if ($obj_mode != ilLPObjSettings::LP_MODE_DEACTIVATED) {
782
783 if (in_array($obj_mode, $coll_modes)) {
784 $a_coll_obj_ids[] = $obj_id;
785 }
786 }
787 }
788
789 // missing objects in DB (default mode)
790 include_once "Services/Object/classes/class.ilObjectLP.php";
791 if (sizeof($existing) != sizeof($a_obj_ids)) {
792 foreach (array_diff($a_obj_ids, $existing) as $obj_id) {
794 $mode = $olp->getCurrentMode();
796 // #11141
797 unset($valid[$obj_id]);
798 } elseif ($mode != ilLPObjSettings::LP_MODE_UNDEFINED) {
800
801 if (in_array($mode, $coll_modes)) {
802 $a_coll_obj_ids[] = $obj_id;
803 }
804 }
805 }
806 unset($existing);
807 }
808
809 return array_values($valid);
810 }
static _lookupDBModeForObjects(array $a_obj_ids)
static getInstance($a_obj_id)
$valid

References $obj_id, $valid, ilLPObjSettings\_lookupDBModeForObjects(), ilLPCollection\getCollectionModes(), ilObjectLP\getInstance(), ilLPObjSettings\LP_MODE_DEACTIVATED, and ilLPObjSettings\LP_MODE_UNDEFINED.

Referenced by preloadListGUIData().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ checkStatusForObject()

static ilLPStatus::checkStatusForObject (   $a_obj_id,
  $a_users = false 
)
static

This function checks whether the status for a given number of users is dirty and must be recalculated.

"Missing" records are not inserted!

Parameters

return

Definition at line 255 of file class.ilLPStatus.php.

256 {
257 global $DIC;
258
259 $ilDB = $DIC['ilDB'];
260
261 //@todo: there maybe the need to add extra handling for sessions here, since the
262 // "in progress" status is time dependent here. On the other hand, if they registered
263 // to the session, they already accessed the course and should have a "in progress"
264 // anyway. But the status on the session itself may not be correct.
265
266 $sql = "SELECT usr_id FROM ut_lp_marks WHERE " .
267 " obj_id = " . $ilDB->quote($a_obj_id, "integer") . " AND " .
268 " status_dirty = " . $ilDB->quote(1, "integer");
269 if (is_array($a_users) && count($a_users) > 0) {
270 $sql .= " AND " . $ilDB->in("usr_id", $a_users, false, "integer");
271 }
272 $set = $ilDB->query($sql);
273 $dirty = false;
274 if ($rec = $ilDB->fetchAssoc($set)) {
275 $dirty = true;
276 }
277
278 // check if any records are missing
279 $missing = false;
280 if (!$dirty && is_array($a_users) && count($a_users) > 0) {
281 $set = $ilDB->query("SELECT count(usr_id) cnt FROM ut_lp_marks WHERE " .
282 " obj_id = " . $ilDB->quote($a_obj_id, "integer") . " AND " .
283 $ilDB->in("usr_id", $a_users, false, "integer"));
284 $r = $ilDB->fetchAssoc($set);
285 if ($r["cnt"] < count($a_users)) {
286 $missing = true;
287 }
288 }
289
290 // refresh status, if records are dirty or missing
291 if ($dirty || $missing) {
292 require_once "Services/Tracking/classes/class.ilLPStatusFactory.php"; // #13330
293 $trac_obj = ilLPStatusFactory::_getInstance($a_obj_id);
294 $trac_obj->refreshStatus($a_obj_id, $a_users);
295 }
296 }
static _getInstance($a_obj_id, $a_mode=null)
$r
Definition: example_031.php:79

References $DIC, $ilDB, $r, and ilLPStatusFactory\_getInstance().

Referenced by ilTrQuery\refreshObjectsStatus().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ determinePercentage()

ilLPStatus::determinePercentage (   $a_obj_id,
  $a_usr_id,
  $a_obj = null 
)

Determine percentage.

Parameters

return

Reimplemented in ilLPStatusPlugin, ilLPStatusSCORM, ilLPStatusSCORMPackage, ilLPStatusTestPassed, ilLPStatusTypicalLearningTime, ilLPStatusVisitedPages, and ilLPStatusVisits.

Definition at line 231 of file class.ilLPStatus.php.

232 {
233 return false;
234 }

Referenced by _updateStatus(), and refreshStatus().

+ Here is the caller graph for this function:

◆ determineStatus()

◆ getListGUIStatus()

static ilLPStatus::getListGUIStatus (   $a_obj_id,
  $a_image_only = true 
)
static

Definition at line 902 of file class.ilLPStatus.php.

903 {
904 if ($a_image_only) {
905 $image = '';
906 if (isset(self::$list_gui_cache[$a_obj_id]["image"])) {
907 $image = self::$list_gui_cache[$a_obj_id]["image"];
908 }
909
910 return $image;
911 }
912 return self::$list_gui_cache[$a_obj_id];
913 }

Referenced by ilObjectListGUI\determineProperties(), and ilContainerContentGUI\renderCard().

+ Here is the caller graph for this function:

◆ getLPStatusForObjects()

static ilLPStatus::getLPStatusForObjects (   $a_user_id,
  $a_obj_ids 
)
staticprotected

Get LP status for given objects (and user)

Parameters
int$a_user_id
array$a_obj_ids
Returns
array

Definition at line 819 of file class.ilLPStatus.php.

820 {
821 global $DIC;
822
823 $ilDB = $DIC['ilDB'];
824
825 $res = array();
826
827 // get user lp data
828 $sql = "SELECT status, status_dirty, obj_id FROM ut_lp_marks" .
829 " WHERE " . $ilDB->in("obj_id", $a_obj_ids, "", "integer") .
830 " AND usr_id = " . $ilDB->quote($a_user_id, "integer");
831 $set = $ilDB->query($sql);
832 while ($row = $ilDB->fetchAssoc($set)) {
833 if (!$row["status_dirty"]) {
834 $res[$row["obj_id"]] = $row["status"];
835 } else {
836 $res[$row["obj_id"]] = self::_lookupStatus($row["obj_id"], $a_user_id);
837 }
838 }
839
840 // process missing user entries (same as dirty entries, see above)
841 foreach ($a_obj_ids as $obj_id) {
842 if (!isset($res[$obj_id])) {
843 $res[$obj_id] = self::_lookupStatus($obj_id, $a_user_id);
844 if ($res[$obj_id] === null) {
846 }
847 }
848 }
849
850 return $res;
851 }
static _lookupStatus($a_obj_id, $a_user_id, $a_create=true)
Lookup status.
const LP_STATUS_NOT_ATTEMPTED_NUM
$row

References $DIC, $ilDB, $obj_id, $res, $row, _lookupStatus(), and LP_STATUS_NOT_ATTEMPTED_NUM.

Referenced by preloadListGUIData().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ preloadListGUIData()

static ilLPStatus::preloadListGUIData (   $a_obj_ids)
static

Definition at line 853 of file class.ilLPStatus.php.

854 {
855 global $DIC;
856
857 $ilUser = $DIC['ilUser'];
858 $lng = $DIC['lng'];
859
860 $user_id = $ilUser->getId();
861
862 $res = array();
863
864 include_once("Services/Tracking/classes/class.ilObjUserTracking.php");
865 if ($ilUser->getId() != ANONYMOUS_USER_ID &&
869 // -- validate
870
871 // :TODO: we need the parent ref id, but this is awful
872 $a_obj_ids = self::validateLPForObjects($user_id, $a_obj_ids, (int) $_GET["ref_id"]);
873
874 // we are not handling the collections differently yet
875 $coll_obj_ids = array();
876 $a_obj_ids = self::checkLPModesForObjects($a_obj_ids, $coll_obj_ids);
877
878
879 // -- gather
880
881 $res = self::getLPStatusForObjects($user_id, $a_obj_ids);
882
883
884 // -- render
885
886 // value to icon
887 $lng->loadLanguageModule("trac");
888 include_once("./Services/Tracking/classes/class.ilLearningProgressBaseGUI.php");
889 foreach ($res as $obj_id => $status) {
892 $res[$obj_id] = [
893 "image" => ilUtil::img($path, $text),
894 "status" => $status
895 ];
896 }
897 }
898
899 self::$list_gui_cache = $res;
900 }
$path
Definition: aliased.php:25
$_GET["client_id"]
static checkLPModesForObjects($a_obj_ids, array &$a_coll_obj_ids)
Process lp modes for given objects.
static getLPStatusForObjects($a_user_id, $a_obj_ids)
Get LP status for given objects (and user)
static validateLPForObjects($a_user_id, $a_obj_ids, $a_parent_ref_id)
Process given objects for lp-relevance.
static _getStatusText($a_status, $a_lng=null)
Get status alt text.
static _getImagePathForStatus($a_status)
Get image path for status.
static _enabledLearningProgress()
check wether learing progress is enabled or not
static img($a_src, $a_alt=null, $a_width="", $a_height="", $a_border=0, $a_id="", $a_class="")
Build img tag.
$lng
$ilUser
Definition: imgupload.php:18
$text
Definition: errorreport.php:18

References $_GET, $DIC, $ilUser, $lng, $obj_id, $path, $res, $text, ilObjUserTracking\_enabledLearningProgress(), ilLearningProgressBaseGUI\_getImagePathForStatus(), ilLearningProgressBaseGUI\_getStatusText(), ilObjUserTracking\_hasLearningProgressLearner(), ilObjUserTracking\_hasLearningProgressListGUI(), checkLPModesForObjects(), getLPStatusForObjects(), ilUtil\img(), and validateLPForObjects().

Referenced by ilObjectListGUIPreloader\preload().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ raiseEvent()

static ilLPStatus::raiseEvent (   $a_obj_id,
  $a_usr_id,
  $a_status,
  $a_percentage 
)
staticprotected

Definition at line 298 of file class.ilLPStatus.php.

299 {
300 global $DIC;
301
302 $ilAppEventHandler = $DIC['ilAppEventHandler'];
303
305 $log->debug("obj_id: " . $a_obj_id . ", user id: " . $a_usr_id . ", status: " .
306 $a_status . ", percentage: " . $a_percentage);
307
308 $ilAppEventHandler->raise("Services/Tracking", "updateStatus", array(
309 "obj_id" => $a_obj_id,
310 "usr_id" => $a_usr_id,
311 "status" => $a_status,
312 "percentage" => $a_percentage
313 ));
314 }

References $DIC, $log, and ilLoggerFactory\getLogger().

Referenced by _updateStatus(), and writeStatus().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ refreshStatus()

ilLPStatus::refreshStatus (   $a_obj_id,
  $a_users = null 
)

Refresh status.

Parameters

return

Reimplemented in ilLPStatusSCORM, and ilLPStatusSCORMPackage.

Definition at line 322 of file class.ilLPStatus.php.

323 {
324 include_once("./Services/Tracking/classes/class.ilLPStatusWrapper.php");
325 $not_attempted = ilLPStatusWrapper::_getNotAttempted($a_obj_id);
326 foreach ($not_attempted as $user_id) {
327 $percentage = $this->determinePercentage($a_obj_id, $user_id);
328 if (self::writeStatus($a_obj_id, $user_id, self::LP_STATUS_NOT_ATTEMPTED_NUM, $percentage, true)) {
329 //self::raiseEvent($a_obj_id, $user_id, self::LP_STATUS_NOT_ATTEMPTED_NUM, $percentage);
330 }
331 }
332 $in_progress = ilLPStatusWrapper::_getInProgress($a_obj_id);
333 foreach ($in_progress as $user_id) {
334 $percentage = $this->determinePercentage($a_obj_id, $user_id);
335 if (self::writeStatus($a_obj_id, $user_id, self::LP_STATUS_IN_PROGRESS_NUM, $percentage, true)) {
336 //self::raiseEvent($a_obj_id, $user_id, self::LP_STATUS_IN_PROGRESS_NUM, $percentage);
337 }
338 }
339 $completed = ilLPStatusWrapper::_getCompleted($a_obj_id);
340 foreach ($completed as $user_id) {
341 $percentage = $this->determinePercentage($a_obj_id, $user_id);
342 if (self::writeStatus($a_obj_id, $user_id, self::LP_STATUS_COMPLETED_NUM, $percentage, true)) {
343 //self::raiseEvent($a_obj_id, $user_id, self::LP_STATUS_COMPLETED_NUM, $percentage);
344 }
345 }
347 foreach ($failed as $user_id) {
348 $percentage = $this->determinePercentage($a_obj_id, $user_id);
349 if (self::writeStatus($a_obj_id, $user_id, self::LP_STATUS_FAILED_NUM, $percentage, true)) {
350 //self::raiseEvent($a_obj_id, $user_id, self::LP_STATUS_FAILED_NUM, $percentage);
351 }
352 }
353 if ($a_users) {
354 $missing_users = array_diff($a_users, $not_attempted + $in_progress + $completed + $failed);
355 if ($missing_users) {
356 foreach ($missing_users as $user_id) {
357 ilLPStatusWrapper::_updateStatus($a_obj_id, $user_id);
358 }
359 }
360 }
361 }
$failed
Definition: Utf8Test.php:85
static _getNotAttempted($a_obj_id)
Static function to read the number of user who have the status 'not_attempted'.
static _getCompleted($a_obj_id)
Static function to read the users who have the status 'completed'.
static _getInProgress($a_obj_id)
Static function to read users who have the status 'in_progress'.
static _getFailed($a_obj_id)
Static function to read the users who have the status 'completed'.

References $failed, ilLPStatusWrapper\_getCompleted(), ilLPStatusWrapper\_getFailed(), ilLPStatusWrapper\_getInProgress(), ilLPStatusWrapper\_getNotAttempted(), ilLPStatusWrapper\_updateStatus(), and determinePercentage().

+ Here is the call graph for this function:

◆ setAllDirty()

static ilLPStatus::setAllDirty ( )
static

Sets all status to dirty.

For testing puproses.

Parameters

return

Definition at line 524 of file class.ilLPStatus.php.

525 {
526 global $DIC;
527
528 $ilDB = $DIC['ilDB'];
529
530 $ilDB->manipulate(
531 "UPDATE ut_lp_marks SET " .
532 " status_dirty = " . $ilDB->quote(1, "integer")
533 );
534 }

References $DIC, and $ilDB.

◆ setDirty()

static ilLPStatus::setDirty (   $a_obj_id)
static

Sets status of an object to dirty.

Parameters
integerobject id
Returns

Definition at line 542 of file class.ilLPStatus.php.

543 {
544 global $DIC;
545
546 $ilDB = $DIC['ilDB'];
547
548 $ilDB->manipulate(
549 "UPDATE ut_lp_marks SET " .
550 " status_dirty = " . $ilDB->quote(1, "integer") .
551 " WHERE obj_id = " . $ilDB->quote($a_obj_id, "integer")
552 );
553 }

References $DIC, and $ilDB.

◆ setInProgressIfNotAttempted()

static ilLPStatus::setInProgressIfNotAttempted (   $a_obj_id,
  $a_user_id 
)
static

This function shoudl be clalled for normal "read events".

The "in progress" status is only written, if current status is "NOT ATTEMPTED"

Definition at line 487 of file class.ilLPStatus.php.

488 {
489 global $DIC;
490
491 $ilDB = $DIC['ilDB'];
492
493 // #11513
494
495 $needs_update = false;
496
497 $set = $ilDB->query(
498 "SELECT usr_id, status FROM ut_lp_marks WHERE " .
499 " obj_id = " . $ilDB->quote($a_obj_id, "integer") . " AND " .
500 " usr_id = " . $ilDB->quote($a_user_id, "integer")
501 );
502 if ($rec = $ilDB->fetchAssoc($set)) {
503 // current status is not attempted, so we need to update
504 if ($rec["status"] == self::LP_STATUS_NOT_ATTEMPTED_NUM) {
505 $needs_update = true;
506 }
507 } else {
508 // no ut_lp_marks yet, we should update
509 $needs_update = true;
510 }
511
512 if ($needs_update) {
513 require_once "Services/Tracking/classes/class.ilLPStatusWrapper.php";
514 ilLPStatusWrapper::_updateStatus($a_obj_id, $a_user_id);
515 }
516 }

References $DIC, $ilDB, and ilLPStatusWrapper\_updateStatus().

Referenced by ilLearningProgress\_tracProgress().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ validateLPForObjects()

static ilLPStatus::validateLPForObjects (   $a_user_id,
  $a_obj_ids,
  $a_parent_ref_id 
)
staticprotected

Process given objects for lp-relevance.

Parameters
int$a_user_id
array$a_obj_ids
int$a_parent_ref_id
Returns
arraye

Definition at line 746 of file class.ilLPStatus.php.

747 {
748 $lp_invalid = array();
749
750 include_once "Services/Object/classes/class.ilObjectLP.php";
751 $memberships = ilObjectLP::getLPMemberships($a_user_id, $a_obj_ids, $a_parent_ref_id);
752 foreach ($memberships as $obj_id => $status) {
753 if (!$status) {
754 $lp_invalid[] = $obj_id;
755 }
756 }
757
758 return array_diff($a_obj_ids, $lp_invalid);
759 }
static getLPMemberships($a_usr_id, array $a_obj_ids, $a_parent_ref_id=null, $a_mapped_ref_ids=false)
Get all objects where given user is member (from LP POV)

References $obj_id, and ilObjectLP\getLPMemberships().

Referenced by preloadListGUIData().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ writeStatus()

static ilLPStatus::writeStatus (   $a_obj_id,
  $a_user_id,
  $a_status,
  $a_percentage = false,
  $a_force_per = false 
)
static

Write status for user and object.

Parameters

return bool

Definition at line 369 of file class.ilLPStatus.php.

370 {
371 global $DIC;
372
373 $ilDB = $DIC['ilDB'];
374
376 $log->debug("obj_id: " . $a_obj_id . ", user id: " . $a_user_id . ", status: " .
377 $a_status . ", percentage: " . $a_percentage . ", force: " . $a_force_per);
378
379 $update_collections = false;
380
381 // get status in DB
382 $set = $ilDB->query(
383 "SELECT usr_id,status,status_dirty FROM ut_lp_marks WHERE " .
384 " obj_id = " . $ilDB->quote($a_obj_id, "integer") . " AND " .
385 " usr_id = " . $ilDB->quote($a_user_id, "integer")
386 );
387 $rec = $ilDB->fetchAssoc($set);
388
389 // update
390 if ($rec) {
391 // status has changed: update
392 if ($rec["status"] != $a_status) {
393 $ret = $ilDB->manipulate(
394 "UPDATE ut_lp_marks SET " .
395 " status = " . $ilDB->quote($a_status, "integer") . "," .
396 " status_changed = " . $ilDB->now() . "," .
397 " status_dirty = " . $ilDB->quote(0, "integer") .
398 " WHERE usr_id = " . $ilDB->quote($a_user_id, "integer") .
399 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
400 );
401 if ($ret != 0) {
402 $update_collections = true;
403 }
404 }
405 // status has not changed: reset dirty flag
406 elseif ($rec["status_dirty"]) {
407 $ilDB->manipulate(
408 "UPDATE ut_lp_marks SET " .
409 " status_dirty = " . $ilDB->quote(0, "integer") .
410 " WHERE usr_id = " . $ilDB->quote($a_user_id, "integer") .
411 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
412 );
413 }
414 }
415 // insert
416 else {
417 /*
418 $ilDB->manipulate("INSERT INTO ut_lp_marks ".
419 "(status, status_changed, usr_id, obj_id, status_dirty) VALUES (".
420 $ilDB->quote($a_status, "integer").",".
421 $ilDB->now().",".
422 $ilDB->quote($a_user_id, "integer").",".
423 $ilDB->quote($a_obj_id, "integer").",".
424 $ilDB->quote(0, "integer").
425 ")");
426 */
427
428 // #13783
429 $ilDB->replace(
430 "ut_lp_marks",
431 array(
432 "obj_id" => array("integer", $a_obj_id),
433 "usr_id" => array("integer", $a_user_id)
434 ),
435 array(
436 "status" => array("integer", $a_status),
437 "status_changed" => array("timestamp", date("Y-m-d H:i:s")), // was $ilDB->now()
438 "status_dirty" => array("integer", 0)
439 )
440 );
441
442 $update_collections = true;
443 }
444
445 // update percentage
446 if ($a_percentage !== false || $a_force_per) {
447 $a_percentage = max(0, (int) $a_percentage);
448 $a_percentage = min(100, $a_percentage);
449 $ret = $ilDB->manipulate(
450 "UPDATE ut_lp_marks SET " .
451 " percentage = " . $ilDB->quote($a_percentage, "integer") .
452 " WHERE usr_id = " . $ilDB->quote($a_user_id, "integer") .
453 " AND obj_id = " . $ilDB->quote($a_obj_id, "integer")
454 );
455 }
456
457 // update collections
458 if ($update_collections) {
459 // a change occured - remove existing cache entry
460 include_once("./Services/Tracking/classes/class.ilLPStatusWrapper.php");
461 ilLPStatusWrapper::_removeStatusCache($a_obj_id, $a_user_id);
462
463 $set = $ilDB->query("SELECT ut_lp_collections.obj_id obj_id FROM " .
464 "object_reference JOIN ut_lp_collections ON " .
465 "(object_reference.obj_id = " . $ilDB->quote($a_obj_id, "integer") .
466 " AND object_reference.ref_id = ut_lp_collections.item_id)");
467 while ($rec = $ilDB->fetchAssoc($set)) {
468 if (in_array(ilObject::_lookupType($rec["obj_id"]), array("crs", "grp", "fold"))) {
469 // just to make sure - remove existing cache entry
470 ilLPStatusWrapper::_removeStatusCache($rec["obj_id"], $a_user_id);
471
472 ilLPStatusWrapper::_updateStatus($rec["obj_id"], $a_user_id);
473 }
474 }
475
476 self::raiseEvent($a_obj_id, $a_user_id, $a_status, $a_percentage);
477 }
478
479 return $update_collections;
480 }
static _removeStatusCache($a_obj_id, $a_usr_id)
static _lookupType($a_id, $a_reference=false)
lookup object type
$ret
Definition: parser.php:6

References $DIC, $ilDB, $log, $ret, ilObject\_lookupType(), ilLPStatusWrapper\_removeStatusCache(), ilLPStatusWrapper\_updateStatus(), ilLoggerFactory\getLogger(), and raiseEvent().

Referenced by _updateStatus(), ilLPStatusSCORM\refreshStatus(), ilLPStatusSCORMPackage\refreshStatus(), ilObjSCORMTracking\syncGlobalStatus(), and ilSCORM2004StoreData\syncGlobalStatus().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Field Documentation

◆ $db

ilLPStatus::$db = null

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

◆ $list_gui_cache

ilLPStatus::$list_gui_cache
static

Definition at line 21 of file class.ilLPStatus.php.

◆ $obj_id

ilLPStatus::$obj_id = null

◆ LP_STATUS_COMPLETED

◆ LP_STATUS_COMPLETED_NUM

const ilLPStatus::LP_STATUS_COMPLETED_NUM = 2

Definition at line 30 of file class.ilLPStatus.php.

Referenced by ilLPObjectStatisticsLPTableGUI\__construct(), ilLearningProgressBaseGUI\__readStatus(), ilLearningProgressBaseGUI\_getImagePathForStatus(), ilLearningProgressBaseGUI\_getStatusText(), ilLMExplorerGUI\checkLPIcon(), ilObjCourse\checkLPStatusSync(), ilLPStatusTestPassed\determineLpStatus(), ilLPStatusCollection\determineStatus(), ilLPStatusCollectionManual\determineStatus(), ilLPStatusCollectionMobs\determineStatus(), ilLPStatusCollectionTLT\determineStatus(), ilLPStatusEvent\determineStatus(), ilLPStatusExerciseReturned\determineStatus(), ilLPStatusIndividualAssessment\determineStatus(), ilLPStatusManual\determineStatus(), ilLPStatusManualByTutor\determineStatus(), ilLPStatusQuestions\determineStatus(), ilLPStatusSCORM\determineStatus(), ilLPStatusSCORMPackage\determineStatus(), ilLPStatusStudyProgramme\determineStatus(), ilLPStatusSurveyFinished\determineStatus(), ilLPStatusTestFinished\determineStatus(), ilLPStatusTypicalLearningTime\determineStatus(), ilLPStatusVisitedPages\determineStatus(), ilLPStatusVisits\determineStatus(), ilCourseLPBadge\evaluate(), ilCertificateCourseLearningProgressEvaluation\evaluate(), ilTrSummaryTableGUI\fillHeaderCSV(), ilTrSummaryTableGUI\fillHeaderExcel(), ilLPProgressTableGUI\fillRow(), ilTrMatrixTableGUI\fillRow(), ilTrObjectUsersPropsTableGUI\fillRow(), ilLPMarks\getCompletionsOfUser(), ilLPObjectStatisticsLPTableGUI\getGraph(), ilTrSummaryTableGUI\getItems(), ilTrMatrixTableGUI\getItems(), ilObjLearningSequence\getLPCompletionStates(), ilLOUserResults\getObjectiveStatusForLP(), ilTrQuery\getObjectsDataForUser(), ilSoapSCORMAdministration\getSCORMCompletionStatus(), ilLOUserResults\getSummarizedObjectiveStatusForLP(), ilTrQuery\getUserObjectiveMatrix(), ilCourseAppEventListener\handleEvent(), ilBadgeAppEventListener\handleEvent(), ilSkillAppEventListener\handleEvent(), ilCertificateAppEventListener\handleLPUpdate(), ilObjSCORM2004LearningModule\importSuccess(), ilObjSCORMLearningModule\importSuccess(), ilLearningProgressGUI\initCollectionManualForm(), ilLearningProgressBaseGUI\initEditUserForm(), ilMStListCoursesTableGUI\initFilter(), ilMStShowUserCoursesTableGUI\initFilter(), ilTrObjectUsersPropsTableGUI\initFilter(), ilTrSummaryTableGUI\initFilter(), ilStudyProgrammeLeafMock\markCompletedFor(), ilStudyProgrammeAppEventListener\onServiceTrackingUpdateStatus(), ilContainerContentGUI\renderCard(), ilLearningProgressGUI\showtlt(), ilCertificateCourseLearningProgressEvaluationTest\testAllCoursesAreCompletedOnLPChange(), ilStudyProgrammeLPTest\testMarkAccredited(), ilCertificateCourseLearningProgressEvaluationTest\testOnlyOneCourseIsCompletedOnLPChange(), ilStudyProgrammeLPTest\testUnmarkAccredited(), and ilLTIAppEventListener\tryOutcomeService().

◆ LP_STATUS_FAILED

◆ LP_STATUS_FAILED_NUM

◆ LP_STATUS_IN_PROGRESS

◆ LP_STATUS_IN_PROGRESS_NUM

const ilLPStatus::LP_STATUS_IN_PROGRESS_NUM = 1

Definition at line 29 of file class.ilLPStatus.php.

Referenced by ilLPObjectStatisticsLPTableGUI\__construct(), ilLearningProgressBaseGUI\__readStatus(), ilLearningProgressBaseGUI\_getImagePathForStatus(), ilLPStatusObjectives\_getStatusInfo(), ilLearningProgressBaseGUI\_getStatusText(), ilLMExplorerGUI\checkLPIcon(), ilLPStatusCollection\determineStatus(), ilLPStatusCollectionManual\determineStatus(), ilLPStatusCollectionMobs\determineStatus(), ilLPStatusCollectionTLT\determineStatus(), ilLPStatusEvent\determineStatus(), ilLPStatusExerciseReturned\determineStatus(), ilLPStatusIndividualAssessment\determineStatus(), ilLPStatusManual\determineStatus(), ilLPStatusManualByTutor\determineStatus(), ilLPStatusObjectives\determineStatus(), ilLPStatusQuestions\determineStatus(), ilLPStatusSCORM\determineStatus(), ilLPStatusSCORMPackage\determineStatus(), ilLPStatusStudyProgramme\determineStatus(), ilLPStatusSurveyFinished\determineStatus(), ilLPStatusTestFinished\determineStatus(), ilLPStatusTestPassed\determineStatus(), ilLPStatusTypicalLearningTime\determineStatus(), ilLPStatusVisitedPages\determineStatus(), ilLPStatusVisits\determineStatus(), ilLPStatusTestPassed\determineStatusForScoreLastPassTests(), ilIndividualAssessmentLPInterface\determineStatusOfMember(), ilTrSummaryTableGUI\fillHeaderCSV(), ilTrSummaryTableGUI\fillHeaderExcel(), ilLPObjectStatisticsLPTableGUI\getGraph(), ilTrSummaryTableGUI\getItems(), ilTrMatrixTableGUI\getItems(), ilLOUserResults\getObjectiveStatusForLP(), ilTrQuery\getObjectsDataForUser(), ilSoapSCORMAdministration\getSCORMCompletionStatus(), ilLOUserResults\getSummarizedObjectiveStatusForLP(), ilTrQuery\getUserObjectiveMatrix(), ilObjSCORM2004LearningModule\importSuccess(), ilObjSCORMLearningModule\importSuccess(), ilMStListCoursesTableGUI\initFilter(), ilMStShowUserCoursesTableGUI\initFilter(), ilLPObjectStatisticsLPTableGUI\initFilter(), ilTrObjectUsersPropsTableGUI\initFilter(), ilTrSummaryTableGUI\initFilter(), ilLearningProgressGUI\showtlt(), ilStudyProgrammeLPTest\testInitialLPActive(), ilStudyProgrammeLPTest\testInitialLPDraft(), ilStudyProgrammeLPTest\testInitialProgressOutdated(), ilStudyProgrammeLPTest\testMarkAccredited(), ilStudyProgrammeLPTest\testMarkFailed(), ilStudyProgrammeLPTest\testMarkNotFailed(), ilStudyProgrammeLPTest\testMarkNotRelevant(), and ilStudyProgrammeLPTest\testUnmarkAccredited().

◆ LP_STATUS_NOT_ATTEMPTED

◆ LP_STATUS_NOT_ATTEMPTED_NUM

const ilLPStatus::LP_STATUS_NOT_ATTEMPTED_NUM = 0

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

Referenced by ilLPObjectStatisticsLPTableGUI\__construct(), ilLearningProgressBaseGUI\__readStatus(), ilLearningProgressBaseGUI\_getStatusText(), ilTrQuery\buildFilters(), ilLMExplorerGUI\checkLPIcon(), ilMStListCourses\createWhereStatement(), ilLPStatusCollection\determineStatus(), ilLPStatusCollectionManual\determineStatus(), ilLPStatusCollectionMobs\determineStatus(), ilLPStatusCollectionTLT\determineStatus(), ilLPStatusEvent\determineStatus(), ilLPStatusExerciseReturned\determineStatus(), ilLPStatusIndividualAssessment\determineStatus(), ilLPStatusManual\determineStatus(), ilLPStatusManualByTutor\determineStatus(), ilLPStatusObjectives\determineStatus(), ilLPStatusPlugin\determineStatus(), ilLPStatusQuestions\determineStatus(), ilLPStatusSCORM\determineStatus(), ilLPStatusSCORMPackage\determineStatus(), ilLPStatusStudyProgramme\determineStatus(), ilLPStatusSurveyFinished\determineStatus(), ilLPStatusTestFinished\determineStatus(), ilLPStatusTestPassed\determineStatus(), ilLPStatusTypicalLearningTime\determineStatus(), ilLPStatusVisitedPages\determineStatus(), ilLPStatusVisits\determineStatus(), ilIndividualAssessmentLPInterface\determineStatusOfMember(), ilTrSummaryTableGUI\fillHeaderCSV(), ilTrSummaryTableGUI\fillHeaderExcel(), ilTrMatrixTableGUI\fillRow(), ilLPObjectStatisticsLPTableGUI\getGraph(), ilTrSummaryTableGUI\getItems(), ilTrMatrixTableGUI\getItems(), ilLPStatusPlugin\getLPDataForUser(), getLPStatusForObjects(), ilTrQuery\getObjectivesStatusForUser(), ilTrQuery\getObjectsDataForUser(), ilTrQuery\getObjectsStatusForUser(), ilTrQuery\getUserObjectiveMatrix(), ilObjSCORM2004LearningModule\importSuccess(), ilObjSCORMLearningModule\importSuccess(), ilLearningProgressGUI\initCollectionManualForm(), ilMStListCoursesTableGUI\initFilter(), ilMStShowUserCoursesTableGUI\initFilter(), ilTrObjectUsersPropsTableGUI\initFilter(), ilTrSummaryTableGUI\initFilter(), ilLearningProgressGUI\showtlt(), ilStudyProgrammeLPTest\testInitialLPDraft(), ilStudyProgrammeLPTest\testInitialProgressOutdated(), ilStudyProgrammeLPTest\testMarkNotRelevant(), ilStudyProgrammeLPTest\testNewNodesAreNotRelevant(), and ilLTIAppEventListener\tryOutcomeService().

◆ LP_STATUS_NOT_PARTICIPATED

const ilLPStatus::LP_STATUS_NOT_PARTICIPATED = 'trac_not_participated'

◆ LP_STATUS_NOT_REGISTERED

const ilLPStatus::LP_STATUS_NOT_REGISTERED = 'trac_not_registered'

◆ LP_STATUS_PARTICIPATED

const ilLPStatus::LP_STATUS_PARTICIPATED = 'trac_participated'

◆ LP_STATUS_REGISTERED

const ilLPStatus::LP_STATUS_REGISTERED = 'trac_registered'

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