28 private \ILIAS\Test\InternalRequestService
$request;
38 $this->request = $DIC->test()->internal()->request();
76 $this->testObj = $test;
88 $testOBJ->removeTestResultsByUserIds($user_ids);
91 $test_ref_id = $this->request->int(
'ref_id');
92 if ($this->testObj && $this->testObj->getRefId()) {
93 $test_ref_id = $this->testObj->getRefId();
96 if ($test_ref_id === 0) {
101 if ($course_obj_id === 0) {
115 if (strtolower(get_class($lp_status)) !==
'illpstatus') {
116 foreach ($user_ids as $user_id) {
117 $lp_status->_updateStatus($course_obj_id, $user_id);
122 protected static function isLPMember(array &$a_res,
int $a_usr_id, array $a_obj_ids): bool
125 $ilDB = $DIC[
'ilDB'];
128 $set =
$ilDB->query(
"SELECT tt.obj_fi" .
129 " FROM tst_active ta" .
130 " JOIN tst_tests tt ON (ta.test_fi = tt.test_id)" .
131 " WHERE " .
$ilDB->in(
"tt.obj_fi", (array) $a_obj_ids,
false,
"integer") .
132 " AND ta.user_fi = " .
$ilDB->quote($a_usr_id,
"integer"));
133 while ($row =
$ilDB->fetchAssoc($set)) {
134 $a_res[$row[
"obj_fi"]] =
true;
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
static getDefaultModes(bool $a_lp_active)
static isLPMember(array &$a_res, int $a_usr_id, array $a_obj_ids)
const LP_MODE_TEST_FINISHED
static _lookupAnonymity($a_obj_id)
Returns the anonymity status of a test with a given object id.
static deleteResultsFromLP(int $a_course_id, array $a_user_ids, bool $a_remove_initial, bool $a_remove_qualified, array $a_objective_ids)
const LP_MODE_TEST_PASSED
static lookupObjectivesForTest(int $a_test_ref_id)
setTestObject(\ilObjTest $test)
static getInstanceByObjId(?int $obj_id, bool $stop_on_error=true)
get an instance of an Ilias object by object id
ILIAS Test InternalRequestService $request
const LP_MODE_DEACTIVATED
resetCustomLPDataForUserIds(array $user_ids, bool $recursive=true)
static _getInstance(int $a_obj_id, ?int $a_mode=null)
__construct(Container $dic, ilPlugin $plugin)
static getInstance(int $a_container_id)
const TYPE_TEST_QUALIFIED
static lookupContainerForTest(int $a_test_ref_id)